bcache: add idle_max_writeback_rate sysfs interface
authorColy Li <colyli@suse.de>
Wed, 13 Nov 2019 08:03:23 +0000 (16:03 +0800)
committerJens Axboe <axboe@kernel.dk>
Wed, 13 Nov 2019 22:42:50 +0000 (15:42 -0700)
commitc5fcdedcee4e6ae15c0eb5e0fbe25467e57d2963
tree43c13af43995fb936ab8a19012157445a3815f3a
parent5dccefd3ea0b33cf3e5a45cbccc7e0bf22791655
bcache: add idle_max_writeback_rate sysfs interface

For writeback mode, if there is no regular I/O request for a while,
the writeback rate will be set to the maximum value (1TB/s for now).
This is good for most of the storage workload, but there are still
people don't what the maximum writeback rate in I/O idle time.

This patch adds a sysfs interface file idle_max_writeback_rate to
permit people to disable maximum writeback rate. Then the minimum
writeback rate can be advised by writeback_rate_minimum in the
bcache device's sysfs interface.

Reported-by: Christian Balzer <chibi@gol.com>
Signed-off-by: Coly Li <colyli@suse.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/md/bcache/bcache.h
drivers/md/bcache/super.c
drivers/md/bcache/sysfs.c
drivers/md/bcache/writeback.c