diff options
author | NeilBrown <neilb@suse.de> | 2009-03-31 15:19:03 +1100 |
---|---|---|
committer | NeilBrown <neilb@suse.de> | 2009-03-31 15:19:03 +1100 |
commit | 86b42c713be3e5f6807aa14b4cbdb005d35c64d5 (patch) | |
tree | d6c70a966a6bda99e6cd4ce055efa84ab0ded701 /drivers/md/raid5.h | |
parent | 11373542344bdc35be1e6e68b0baadd1b6f7acbb (diff) | |
download | op-kernel-dev-86b42c713be3e5f6807aa14b4cbdb005d35c64d5.zip op-kernel-dev-86b42c713be3e5f6807aa14b4cbdb005d35c64d5.tar.gz |
md/raid5: clearly differentiate 'before' and 'after' stripes during reshape.
During a raid5 reshape, we have some stripes in the cache that are
'before' the reshape (and are still to be processed) and some that are
'after'. They are currently differentiated by having different
->disks values as the only reshape current supported involves changing
the number of disks.
However we will soon support reshapes that do not change the number
of disks (chunk parity or chunk size). So make the difference more
explicit with a 'generation' number.
Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'drivers/md/raid5.h')
-rw-r--r-- | drivers/md/raid5.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/md/raid5.h b/drivers/md/raid5.h index b2edcc4..a081fb4 100644 --- a/drivers/md/raid5.h +++ b/drivers/md/raid5.h @@ -198,6 +198,8 @@ struct stripe_head { struct hlist_node hash; struct list_head lru; /* inactive_list or handle_list */ struct raid5_private_data *raid_conf; + short generation; /* increments with every + * reshape */ sector_t sector; /* sector of this row */ short pd_idx; /* parity disk index */ short qd_idx; /* 'Q' disk index for raid6 */ @@ -348,6 +350,7 @@ struct raid5_private_data { */ sector_t reshape_safe; int previous_raid_disks; + short generation; /* increments with every reshape */ struct list_head handle_list; /* stripes needing handling */ struct list_head hold_list; /* preread ready stripes */ |