summaryrefslogtreecommitdiffstats
path: root/fs/btrfs/async-thread.c
diff options
context:
space:
mode:
authorChris Mason <chris.mason@oracle.com>2010-05-25 16:12:41 +0200
committerChris Mason <chris.mason@oracle.com>2010-05-25 16:34:58 +0200
commited3b3d314cd2f16fac42676839854a68cab2e22b (patch)
treea38462cdfbaa0dce3bbd26fe7167fe7368439a47 /fs/btrfs/async-thread.c
parentBtrfs: do aio_write instead of write (diff)
downloadlinux-ed3b3d314cd2f16fac42676839854a68cab2e22b.tar.xz
linux-ed3b3d314cd2f16fac42676839854a68cab2e22b.zip
Btrfs: don't walk around with task->state != TASK_RUNNING
Yan Zheng noticed two places we were doing a lot of work without task->state set to TASK_RUNNING. This sets the state properly after we get ready to sleep but decide not to. Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/async-thread.c')
-rw-r--r--fs/btrfs/async-thread.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/btrfs/async-thread.c b/fs/btrfs/async-thread.c
index 462859a30141..7ec14097fef1 100644
--- a/fs/btrfs/async-thread.c
+++ b/fs/btrfs/async-thread.c
@@ -377,6 +377,7 @@ again:
if (!list_empty(&worker->pending) ||
!list_empty(&worker->prio_pending)) {
spin_unlock_irq(&worker->lock);
+ set_current_state(TASK_RUNNING);
goto again;
}