aboutsummaryrefslogtreecommitdiffstats
path: root/fs/jbd2/commit.c
diff options
context:
space:
mode:
authorTejun Heo <[email protected]>2016-05-27 18:34:46 +0000
committerJens Axboe <[email protected]>2016-05-30 14:54:40 +0000
commit62a584fe05eef1f80ed49a286a29328f1a224fb9 (patch)
treecf34bae00e267a9e5fb94a70d7f24f893d325e6b /fs/jbd2/commit.c
parentMerge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/... (diff)
downloadkernel-62a584fe05eef1f80ed49a286a29328f1a224fb9.tar.gz
kernel-62a584fe05eef1f80ed49a286a29328f1a224fb9.zip
writeback: use higher precision calculation in domain_dirty_limits()
As vm.dirty_[background_]bytes can't be applied verbatim to multiple cgroup writeback domains, they get converted to percentages in domain_dirty_limits() and applied the same way as vm.dirty_[background]ratio. However, if the specified bytes is lower than 1% of available memory, the calculated ratios become zero and the writeback domain gets throttled constantly. Fix it by using per-PAGE_SIZE instead of percentage for ratio calculations. Also, the updated DIV_ROUND_UP() usages now should yield 1/4096 (0.0244%) as the minimum ratio as long as the specified bytes are above zero. Signed-off-by: Tejun Heo <[email protected]> Reported-by: Miao Xie <[email protected]> Link: http://lkml.kernel.org/g/[email protected] Cc: [email protected] # v4.2+ Fixes: 9fc3a43e1757 ("writeback: separate out domain_dirty_limits()") Reviewed-by: Jan Kara <[email protected]> Adjusted comment based on Jan's suggestion. Signed-off-by: Jens Axboe <[email protected]>
Diffstat (limited to 'fs/jbd2/commit.c')
0 files changed, 0 insertions, 0 deletions