Skip to content
Commit 908f4fbd authored by NeilBrown's avatar NeilBrown
Browse files

md/raid5: be more thorough in calculating 'degraded' value.



When an array is being reshaped to change the number of devices,
the two halves can be differently degraded.  e.g. one could be
missing a device and the other not.

So we need to be more careful about calculating the 'degraded'
attribute.

Instead of just inc/dec at appropriate times, perform a full
re-calculation examining both possible cases.  This doesn't happen
often so it not a big cost, and we already have most of the code to
do it.

Signed-off-by: default avatarNeilBrown <neilb@suse.de>
parent 2e61ebbc
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment