]> git.baikalelectronics.ru Git - kernel.git/commit
md/raid5: fix refcount problem when blocked_rdev is set.
authorNeilBrown <neilb@suse.de>
Tue, 3 Jul 2012 02:13:29 +0000 (12:13 +1000)
committerNeilBrown <neilb@suse.de>
Tue, 3 Jul 2012 02:13:29 +0000 (12:13 +1000)
commita58ae33c1a7e2db8756b9cd1ba4ebd396cd79f77
tree9a659a20661d4a2b13f796cd2409879c0596b5c1
parentd6125b72665569fd84c07eef7d95d9ffc35324dd
md/raid5: fix refcount problem when blocked_rdev is set.

commit 5de36dc0752c8b6b22b02553d7a1871ffd498f6f
    md/raid5: fix a hang on device failure.

fixed a hang, but introduced a refcounting in-balance so
that if the presence of bad-blocks ever caused an rdev to
be 'blocked' we would increment the refcount on the rdev and
never decrement it.

So added the needed rdev_dec_pending when md_wait_for_blocked_rdev
is not called.

Reported-by: majianpeng <majianpeng@gmail.com>
Signed-off-by: NeilBrown <neilb@suse.de>
drivers/md/raid5.c