mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
[PATCH] md: support md/linear array with components greater than 2 terabytes.
linear currently uses division by the size of the smallest componenet device to find which device a request goes to. If that smallest device is larger than 2 terabytes, then the division will not work on some systems. So we introduce a pre-shift, and take care not to make the hash table too large, much like the code in raid0. Also get rid of conf->nr_zones, which is not needed. Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
parent
4b6d287f62
commit
15945fee6f
2 changed files with 69 additions and 32 deletions
|
@ -14,8 +14,8 @@ typedef struct dev_info dev_info_t;
|
|||
struct linear_private_data
|
||||
{
|
||||
dev_info_t **hash_table;
|
||||
dev_info_t *smallest;
|
||||
int nr_zones;
|
||||
sector_t hash_spacing;
|
||||
int preshift; /* shift before dividing by hash_spacing */
|
||||
dev_info_t disks[0];
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue