summaryrefslogtreecommitdiffstats
path: root/tools/perf/scripts/python/libxed.py
diff options
context:
space:
mode:
authorKemeng Shi <shikemeng@huaweicloud.com>2025-03-26 00:25:23 +0800
committerAndrew Morton <akpm@linux-foundation.org>2025-05-11 17:48:13 -0700
commit835b868878d0127bd29b8c0009dc424a63dadffb (patch)
tree311cce2430a06414a942c92d8b6794f57309b08e /tools/perf/scripts/python/libxed.py
parent64944ef6a13e774546eb7635bdd26ef963335a41 (diff)
downloadlinux-835b868878d0127bd29b8c0009dc424a63dadffb.tar.gz
linux-835b868878d0127bd29b8c0009dc424a63dadffb.zip
mm: swap: use swap_entries_free() to free swap entry in swap_entry_put_locked()
In swap_entry_put_locked(), we will set slot to SWAP_HAS_CACHE before using swap_entries_free() to do actual swap entry freeing. This introduce an unnecessary intermediate state. By using swap_entries_free() in swap_entry_put_locked(), we can eliminate the need to set slot to SWAP_HAS_CACHE. This change would make the behavior of swap_entry_put_locked() more consistent with other put() operations which will do actual free work after put last reference. Link: https://lkml.kernel.org/r/20250325162528.68385-4-shikemeng@huaweicloud.com Signed-off-by: Kemeng Shi <shikemeng@huaweicloud.com> Reviewed-by: Tim Chen <tim.c.chen@linux.intel.com> Reviewed-by: Kairui Song <kasong@tencent.com> Reviewed-by: Baoquan He <bhe@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'tools/perf/scripts/python/libxed.py')
0 files changed, 0 insertions, 0 deletions