summaryrefslogtreecommitdiffstats
path: root/fs/fs-writeback.c
diff options
context:
space:
mode:
authorTejun Heo <tj@kernel.org>2015-05-22 17:13:56 -0400
committerJens Axboe <axboe@fb.com>2015-06-02 08:33:36 -0600
commit001fe6f617b1a352ad29cc3643384b3d8141dc07 (patch)
tree42dadb5be0402a3a3b2e6f49aff9a22ec3373e45 /fs/fs-writeback.c
parentf2b65121607631df0753eedd624262818707af32 (diff)
downloadop-kernel-dev-001fe6f617b1a352ad29cc3643384b3d8141dc07.zip
op-kernel-dev-001fe6f617b1a352ad29cc3643384b3d8141dc07.tar.gz
writeback: make wakeup_dirtytime_writeback() handle multiple bdi_writeback's
wakeup_dirtytime_writeback() currently only starts writeback on the root wb (bdi_writeback). For cgroup writeback support, update the function to check all wbs. Signed-off-by: Tejun Heo <tj@kernel.org> Cc: Jens Axboe <axboe@kernel.dk> Cc: Jan Kara <jack@suse.cz> Cc: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'fs/fs-writeback.c')
-rw-r--r--fs/fs-writeback.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c
index 508e10c..8ae212e 100644
--- a/fs/fs-writeback.c
+++ b/fs/fs-writeback.c
@@ -1260,9 +1260,12 @@ static void wakeup_dirtytime_writeback(struct work_struct *w)
rcu_read_lock();
list_for_each_entry_rcu(bdi, &bdi_list, bdi_list) {
- if (list_empty(&bdi->wb.b_dirty_time))
- continue;
- wb_wakeup(&bdi->wb);
+ struct bdi_writeback *wb;
+ struct wb_iter iter;
+
+ bdi_for_each_wb(wb, bdi, &iter, 0)
+ if (!list_empty(&bdi->wb.b_dirty_time))
+ wb_wakeup(&bdi->wb);
}
rcu_read_unlock();
schedule_delayed_work(&dirtytime_work, dirtytime_expire_interval * HZ);
OpenPOWER on IntegriCloud