summaryrefslogtreecommitdiff
path: root/usr
diff options
context:
space:
mode:
authorKefeng Wang <wangkefeng.wang@huawei.com>2024-04-18 16:56:44 +0300
committerAndrew Morton <akpm@linux-foundation.org>2024-05-06 03:53:42 +0300
commit80e75021486bd2f6463259c4569e2eb7668ae953 (patch)
treeecb9b5780263236d5b28e74f692158b525940ac8 /usr
parentd21f996b02a027f8915e493ee01370c4610ed2e2 (diff)
downloadlinux-80e75021486bd2f6463259c4569e2eb7668ae953.tar.xz
mm: swapfile: check usable swap device in __folio_throttle_swaprate()
Skip blk_cgroup_congested() if there is no usable swap device since no swapin/out will occur, Thereby avoid taking swap_lock. The difference is shown below from perf date of CoW pagefault, perf report -g -i perf.data.swapon | egrep "blk_cgroup_congested|__folio_throttle_swaprate" 1.01% 0.16% page_fault2_pro [kernel.kallsyms] [k] __folio_throttle_swaprate 0.83% 0.80% page_fault2_pro [kernel.kallsyms] [k] blk_cgroup_congested perf report -g -i perf.data.swapoff | egrep "blk_cgroup_congested|__folio_throttle_swaprate" 0.15% 0.15% page_fault2_pro [kernel.kallsyms] [k] __folio_throttle_swaprate Link: https://lkml.kernel.org/r/20240418135644.2736748-1-wangkefeng.wang@huawei.com Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com> Cc: Tejun Heo <tj@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'usr')
0 files changed, 0 insertions, 0 deletions