diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-09-17 10:22:48 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-09-17 10:22:48 -0700 |
commit | 343d04d44bb069064180f5763a41acaa9245f8e6 (patch) | |
tree | cdb2b444a4f45ec9b629b9cc7897090de8352846 | |
parent | 653d48b22166db2d8b1515ebe6f9f0f7c95dfc86 (diff) | |
parent | ddcf3522cf03a147c867a2e0155761652dbd156a (diff) | |
download | op-kernel-dev-343d04d44bb069064180f5763a41acaa9245f8e6.zip op-kernel-dev-343d04d44bb069064180f5763a41acaa9245f8e6.tar.gz |
Merge branch 'for-linus' of git://neil.brown.name/md
* 'for-linus' of git://neil.brown.name/md:
md: fix v1.x metadata update when a disk is missing.
md: call md_update_sb even for 'external' metadata arrays.
-rw-r--r-- | drivers/md/md.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/md/md.c b/drivers/md/md.c index 43cf9cc..f20d13e 100644 --- a/drivers/md/md.c +++ b/drivers/md/md.c @@ -1643,7 +1643,9 @@ static void super_1_sync(mddev_t *mddev, mdk_rdev_t *rdev) bmask = queue_logical_block_size(rdev->bdev->bd_disk->queue)-1; if (rdev->sb_size & bmask) rdev->sb_size = (rdev->sb_size | bmask) + 1; - } + } else + max_dev = le32_to_cpu(sb->max_dev); + for (i=0; i<max_dev;i++) sb->dev_roles[i] = cpu_to_le16(0xfffe); @@ -7069,7 +7071,7 @@ void md_check_recovery(mddev_t *mddev) if (mddev->ro && !test_bit(MD_RECOVERY_NEEDED, &mddev->recovery)) return; if ( ! ( - (mddev->flags && !mddev->external) || + (mddev->flags & ~ (1<<MD_CHANGE_PENDING)) || test_bit(MD_RECOVERY_NEEDED, &mddev->recovery) || test_bit(MD_RECOVERY_DONE, &mddev->recovery) || (mddev->external == 0 && mddev->safemode == 1) || |