]> git.baikalelectronics.ru Git - kernel.git/commit
md: Fix removal of extra drives when converting RAID6 to RAID5
authorNeilBrown <neilb@suse.de>
Thu, 13 Jan 2011 22:14:34 +0000 (09:14 +1100)
committerNeilBrown <neilb@suse.de>
Thu, 13 Jan 2011 22:14:34 +0000 (09:14 +1100)
commite3a9e1149fcb6c8d42c17dda72bb173c622d3436
tree68587eaff5c7cb85628c1f68aecb19f2a18c8f6e
parent012ef2a6c85d1f48d020eb57eb2c18352d030ff7
md: Fix removal of extra drives when converting RAID6 to RAID5

When a RAID6 is converted to a RAID5, the extra drive should
be discarded.  However it isn't due to a typo in a comparison.

This bug was introduced in commit 2b21bfd978e in 2.6.35-rc4
and is suitable for any -stable since than.

As the extra drive is not removed, the 'degraded' counter is wrong and
so the RAID5 will not respond correctly to a subsequent failure.

Cc: stable@kernel.org
Signed-off-by: NeilBrown <neilb@suse.de>
drivers/md/md.c