md: close a livelock window in handle_parity_checks5
authorDan Williams <dan.j.williams@intel.com>
Fri, 11 Apr 2008 16:55:06 +0000 (16:55 +0000)
committerChris Wright <chrisw@sous-sol.org>
Sat, 19 Apr 2008 01:53:29 +0000 (18:53 -0700)
commitf1e310c26a37a98efba28f6ea65f1f33f353786d
tree07c4c0f1825b95b8dc0078c4cce167170959da44
parentc9c5091171cbf780bb293e6406dd8632b678bae8
md: close a livelock window in handle_parity_checks5

upstream commit: bd2ab67030e9116f1e4aae1289220255412b37fd

If a failure is detected after a parity check operation has been initiated,
but before it completes handle_parity_checks5 will never quiesce operations on
the stripe.

Explicitly handle this case by "canceling" the parity check, i.e.  clear the
STRIPE_OP_CHECK flags and queue the stripe on the handle list again to refresh
any non-uptodate blocks.

Kernel versions >= 2.6.23 are susceptible.

Cc: <stable@kernel.org>
Cc: NeilBrown <neilb@suse.de>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Chris Wright <chrisw@sous-sol.org>
drivers/md/raid5.c