summaryrefslogtreecommitdiffstats
path: root/drivers/md/dm-raid.c
diff options
context:
space:
mode:
authorHeinz Mauelshagen <heinzm@redhat.com>2016-06-25 02:42:54 +0200
committerMike Snitzer <snitzer@redhat.com>2016-07-18 21:37:29 +0200
commit345a6cdc250d1519c5d15576965629eab6858257 (patch)
tree587c15ed6605691e6b10fc1ecbc9096a746e3640 /drivers/md/dm-raid.c
parentdm raid: fix rebuild and catch bogus sync/resync flags (diff)
downloadlinux-345a6cdc250d1519c5d15576965629eab6858257.tar.xz
linux-345a6cdc250d1519c5d15576965629eab6858257.zip
dm raid: fix rs_is_recovering() to allow for lvextend
Signed-off-by: Heinz Mauelshagen <heinzm@redhat.com> Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Diffstat (limited to 'drivers/md/dm-raid.c')
-rw-r--r--drivers/md/dm-raid.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/md/dm-raid.c b/drivers/md/dm-raid.c
index 14b3d93e84cb..1ff469f14ff2 100644
--- a/drivers/md/dm-raid.c
+++ b/drivers/md/dm-raid.c
@@ -372,7 +372,7 @@ static bool rs_is_reshapable(struct raid_set *rs)
/* Return true, if raid set in @rs is recovering */
static bool rs_is_recovering(struct raid_set *rs)
{
- return rs->md.recovery_cp != MaxSector;
+ return rs->md.recovery_cp < rs->dev[0].rdev.sectors;
}
/* Return true, if raid set in @rs is reshaping */
@@ -3532,7 +3532,7 @@ static int raid_preresume(struct dm_target *ti)
rs_set_capacity(rs);
- /* Check for any reshape request and region size change unless new raid set */
+ /* Check for any reshape request unless new raid set */
if (test_and_clear_bit(RT_FLAG_RESHAPE_RS, &rs->runtime_flags)) {
/* Initiate a reshape. */
mddev_lock_nointr(mddev);