summaryrefslogtreecommitdiffstats
path: root/Kconfig
diff options
context:
space:
mode:
authorTejun Heo <tj@kernel.org>2015-05-22 17:13:45 -0400
committerJens Axboe <axboe@fb.com>2015-06-02 08:33:35 -0600
commitd6c10f1fc8626dc55946f4768ae322b4c57b07dd (patch)
tree7ec5a99a1a93856f74d0cdfb10c4ff40f77f9818 /Kconfig
parent703c270887bb5106c4c46a00cc7477d30d5e04f5 (diff)
downloadlinux-d6c10f1fc8626dc55946f4768ae322b4c57b07dd.tar.gz
linux-d6c10f1fc8626dc55946f4768ae322b4c57b07dd.tar.bz2
linux-d6c10f1fc8626dc55946f4768ae322b4c57b07dd.zip
writeback: implement WB_has_dirty_io wb_state flag
Currently, wb_has_dirty_io() determines whether a wb (bdi_writeback) has any dirty inode by testing all three IO lists on each invocation without actively keeping track. For cgroup writeback support, a single bdi will host multiple wb's each of which will host dirty inodes separately and we'll need to make bdi_has_dirty_io(), which currently only represents the root wb, aggregate has_dirty_io from all member wb's, which requires tracking transitions in has_dirty_io state on each wb. This patch introduces inode_wb_list_{move|del}_locked() to consolidate IO list operations leaving queue_io() the only other function which directly manipulates IO lists (via move_expired_inodes()). All three functions are updated to call wb_io_lists_[de]populated() which keep track of whether the wb has dirty inodes or not and record it using the new WB_has_dirty_io flag. inode_wb_list_moved_locked()'s return value indicates whether the wb had no dirty inodes before. mark_inode_dirty() is restructured so that the return value of inode_wb_list_move_locked() can be used for deciding whether to wake up the wb. While at it, change {bdi|wb}_has_dirty_io()'s return values to bool. These functions were returning 0 and 1 before. Also, add a comment explaining the synchronization of wb_state flags. v2: Updated to accommodate b_dirty_time. Signed-off-by: Tejun Heo <tj@kernel.org> Cc: Jens Axboe <axboe@kernel.dk> Cc: Jan Kara <jack@suse.cz> Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'Kconfig')
0 files changed, 0 insertions, 0 deletions