aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/md')
-rw-r--r--drivers/md/md.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/md/md.c b/drivers/md/md.c
index 4790c83d78d0..deeac4b44173 100644
--- a/drivers/md/md.c
+++ b/drivers/md/md.c
@@ -5761,7 +5761,11 @@ void md_do_sync(mddev_t *mddev)
5761 * time 'round when curr_resync == 2 5761 * time 'round when curr_resync == 2
5762 */ 5762 */
5763 continue; 5763 continue;
5764 prepare_to_wait(&resync_wait, &wq, TASK_UNINTERRUPTIBLE); 5764 /* We need to wait 'interruptible' so as not to
5765 * contribute to the load average, and not to
5766 * be caught by 'softlockup'
5767 */
5768 prepare_to_wait(&resync_wait, &wq, TASK_INTERRUPTIBLE);
5765 if (!kthread_should_stop() && 5769 if (!kthread_should_stop() &&
5766 mddev2->curr_resync >= mddev->curr_resync) { 5770 mddev2->curr_resync >= mddev->curr_resync) {
5767 printk(KERN_INFO "md: delaying %s of %s" 5771 printk(KERN_INFO "md: delaying %s of %s"
@@ -5769,6 +5773,8 @@ void md_do_sync(mddev_t *mddev)
5769 " share one or more physical units)\n", 5773 " share one or more physical units)\n",
5770 desc, mdname(mddev), mdname(mddev2)); 5774 desc, mdname(mddev), mdname(mddev2));
5771 mddev_put(mddev2); 5775 mddev_put(mddev2);
5776 if (signal_pending(current))
5777 flush_signals(current);
5772 schedule(); 5778 schedule();
5773 finish_wait(&resync_wait, &wq); 5779 finish_wait(&resync_wait, &wq);
5774 goto try_again; 5780 goto try_again;