summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorHarry Yoo (Oracle) <harry@kernel.org>2026-07-13 23:28:49 +0900
committerVlastimil Babka (SUSE) <vbabka@kernel.org>2026-07-14 16:40:07 +0200
commit1dba91a0493b7ffe9cbbcf7a8df1b361ddcac515 (patch)
tree00b91d0386e3ff7c7f27259adce5c88debb5677c /tools/perf/scripts/python
parentaf9ea231c0b4530edc389a3126a69e0699b7699d (diff)
mm/slab: fix a memory leak due to bootstrapping sheaves twice
When kmalloc caches are aliased, multiple cache pointers reference the same kmem_cache. As a result, iterating over kmalloc indices and bootstrapping sheaves can bootstrap the same cache more than once and leak memory. Currently, this could happen when the architecture specifies minimum alignment for slab caches that is larger than ARCH_KMALLOC_MINALIGN. Bootstrap sheaves only when the cache does not have them already. Add a warning when bootstrap_cache_sheaves() is called for a cache that already has sheaves enabled. Fixes: 913ffd3a1bf5 ("slab: handle kmalloc sheaves bootstrap") Cc: stable@vger.kernel.org Signed-off-by: Harry Yoo (Oracle) <harry@kernel.org> Reviewed-by: Suren Baghdasaryan <surenb@google.com> Link: https://patch.msgid.link/20260713-kmalloc-no-objext-v3-1-47c7bd138de7@kernel.org Signed-off-by: Vlastimil Babka (SUSE) <vbabka@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions