writeback: pass in '0' for nr_pages writeback in laptop mode
authorJens Axboe <axboe@kernel.dk>
Wed, 27 Sep 2017 12:11:24 +0000 (06:11 -0600)
committerJens Axboe <axboe@kernel.dk>
Wed, 27 Sep 2017 19:52:50 +0000 (13:52 -0600)
commitfd8efa1dd9bade7670abc1089638bac5d9091144
treea68eb0c459d7890bde4551dc57e2efeca2a61b70
parenta0385278c0b1d77fe1c21ee5ededb92dacc7aee7
writeback: pass in '0' for nr_pages writeback in laptop mode

Laptop mode really wants to writeback the number of dirty
pages and inodes. Instead of calculating this in the caller,
just pass in 0 and let wakeup_flusher_threads() handle it.

Use the new wakeup_flusher_threads_bdi() instead of rolling
our own.

Acked-by: Johannes Weiner <hannes@cmpxchg.org>
Tested-by: Chris Mason <clm@fb.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Reviewed-by: Jan Kara <jack@suse.cz>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
mm/page-writeback.c