From: NeilBrown Date: Wed, 18 Aug 2010 01:56:59 +0000 (+1000) Subject: md: provide appropriate return value for spare_active functions. X-Git-Tag: v2.6.36-rc2~43^2~1 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6b9656205469269c050963c71fca1998b247a560;p=pandora-kernel.git md: provide appropriate return value for spare_active functions. md_check_recovery expects ->spare_active to return 'true' if any spares were activated, but none of them do, so the consequent change in 'degraded' is not notified through sysfs. So count the number of spares activated, subtract it from 'degraded' just once, and return it. Reported-by: Adrian Drzewiecki Signed-off-by: NeilBrown --- Reading git-diff-tree failed