diff options
author | Coly Li <colyli@suse.de> | 2019-11-13 16:03:23 +0800 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2019-11-13 15:42:50 -0700 |
commit | c5fcdedcee4e6ae15c0eb5e0fbe25467e57d2963 (patch) | |
tree | 43c13af43995fb936ab8a19012157445a3815f3a /drivers/md/bcache/super.c | |
parent | 5dccefd3ea0b33cf3e5a45cbccc7e0bf22791655 (diff) | |
download | lwn-c5fcdedcee4e6ae15c0eb5e0fbe25467e57d2963.tar.gz lwn-c5fcdedcee4e6ae15c0eb5e0fbe25467e57d2963.zip |
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>
Diffstat (limited to 'drivers/md/bcache/super.c')
-rw-r--r-- | drivers/md/bcache/super.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/md/bcache/super.c b/drivers/md/bcache/super.c index d1352fcc6ff2..77e9869345e7 100644 --- a/drivers/md/bcache/super.c +++ b/drivers/md/bcache/super.c @@ -1834,6 +1834,7 @@ struct cache_set *bch_cache_set_alloc(struct cache_sb *sb) c->congested_read_threshold_us = 2000; c->congested_write_threshold_us = 20000; c->error_limit = DEFAULT_IO_ERROR_LIMIT; + c->idle_max_writeback_rate_enabled = 1; WARN_ON(test_and_clear_bit(CACHE_SET_IO_DISABLE, &c->flags)); return c; |