diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-09-19 19:02:52 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-09-19 19:02:52 -0400 |
commit | 79d57ab98b7bc32e5bb20683814cfb76dbb54a9e (patch) | |
tree | abd4438990d6215cfabd2d780061ee0025f6f1c4 /drivers | |
parent | a19eee5e5e8b11b4a37490f1272d9509dcfcb263 (diff) | |
parent | 9744197c3d7b329590c2be33ad7b17409bd798fe (diff) |
Merge branch 'for-linus' of git://neil.brown.name/md
* 'for-linus' of git://neil.brown.name/md:
md: Don't wait UNINTERRUPTIBLE for other resync to finish
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/md/md.c | 8 |
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; |