mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 03:01:39 -04:00
MD RAID1: Further conditionalize 'fullsync'
A RAID1 device does not necessarily need a fullsync if the bitmap can be used instead.
Similar to commit d6b212f4b1 in raid5.c, if a raid1
device can be brought back (i.e. from a transient failure) it shouldn't need a
complete resync. Provided the bitmap is not to old, it will have recorded the areas
of the disk that need recovery.
Signed-off-by: Jonathan Brassow <[email protected]>
Signed-off-by: NeilBrown <[email protected]>
This commit is contained in:
parent
c32fb9e7ec
commit
4f0a5e012c
1 changed files with 2 additions and 1 deletions
|
|
@ -2600,7 +2600,8 @@ static struct r1conf *setup_conf(struct mddev *mddev)
|
|||
if (!disk->rdev ||
|
||||
!test_bit(In_sync, &disk->rdev->flags)) {
|
||||
disk->head_position = 0;
|
||||
if (disk->rdev)
|
||||
if (disk->rdev &&
|
||||
(disk->rdev->saved_raid_disk < 0))
|
||||
conf->fullsync = 1;
|
||||
} else if (conf->last_used < 0)
|
||||
/*
|
||||
|
|
|
|||
Loading…
Reference in a new issue