This series combines two kmemleak enhancements that were originally submitted
separately but both required rebasing after commit 79c37ae3733e9 ("mm/kmemleak:
fix checksum computation for per-cpu objects").
The first feature introduces a second scan to confirm suspected leaks:
https://lore.kernel.org/all/[email protected]/
The second feature adds a module parameter controlling the minimum number of
consecutive unreferenced scans before a leak is reported, as discussed in:
https://lore.kernel.org/all/[email protected]/
Changes from v1:
Now that commit 79c37ae3733e9 is upstream, the selftest includes an additional
priming phase scan as requested by Catalin.
Additionally, I've factored out the leak-detection conditional into a helper
function to be more digestible for the reader's eye.
This 4-patch series resolves all outstanding kmemleak issues I've been
tracking.
Signed-off-by: Breno Leitao <[email protected]>
---
Breno Leitao (3):
mm: kmemleak: report leaks only after N consecutive unreferenced scans
mm: kmemleak: factor leak confirmation into a helper
selftests: mm: test kmemleak's N-consecutive-scan leak confirmation
Catalin Marinas (1):
mm: kmemleak: confirm suspected leaks with a second scan
Documentation/dev-tools/kmemleak.rst | 8 ++
mm/kmemleak.c | 90 +++++++++++++-
tools/testing/selftests/mm/Makefile | 1 +
.../testing/selftests/mm/ksft_kmemleak_confirm.sh | 132 +++++++++++++++++++++
4 files changed, 225 insertions(+), 6 deletions(-)
---
base-commit: bee763d5f341b99cf472afeb508d4988f62a6ca1
change-id: 20260713-catalin_pto-dbacf66be3fa
Best regards,
--
Breno Leitao <[email protected]>