aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'drivers')
-rw-r--r--drivers/md/md.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/drivers/md/md.c b/drivers/md/md.c
index 3b9b032aa006..d4f31e195e26 100644
--- a/drivers/md/md.c
+++ b/drivers/md/md.c
@@ -7880,11 +7880,18 @@ void md_do_sync(struct md_thread *thread)
7880 /((jiffies-mddev->resync_mark)/HZ +1) +1; 7880 /((jiffies-mddev->resync_mark)/HZ +1) +1;
7881 7881
7882 if (currspeed > speed_min(mddev)) { 7882 if (currspeed > speed_min(mddev)) {
7883 if ((currspeed > speed_max(mddev)) || 7883 if (currspeed > speed_max(mddev)) {
7884 !is_mddev_idle(mddev, 0)) {
7885 msleep(500); 7884 msleep(500);
7886 goto repeat; 7885 goto repeat;
7887 } 7886 }
7887 if (!is_mddev_idle(mddev, 0)) {
7888 /*
7889 * Give other IO more of a chance.
7890 * The faster the devices, the less we wait.
7891 */
7892 wait_event(mddev->recovery_wait,
7893 !atomic_read(&mddev->recovery_active));
7894 }
7888 } 7895 }
7889 } 7896 }
7890 printk(KERN_INFO "md: %s: %s %s.\n",mdname(mddev), desc, 7897 printk(KERN_INFO "md: %s: %s %s.\n",mdname(mddev), desc,