[PATCH 0/3] Minor hmm_test fixes and cleanups

From: Alistair Popple

Date: Tue Mar 31 2026 - 02:35:07 EST


Just a couple of minor fixups and cleanups for the HMM kernel selftests. These
were mostly reported by Zenghui Yu with special thanks to Lorenzo for analysing
and pointing out the problems.

Alistair Popple (3):
lib: test_hmm: evict device pages on file close to avoid
use-after-free
selftests/mm: hmm-tests: don't hardcode THP size to 2MB
lib: test_hmm: Implement a device release method

lib/test_hmm.c | 130 +++++++++++++++----------
tools/testing/selftests/mm/hmm-tests.c | 83 +++-------------
2 files changed, 93 insertions(+), 120 deletions(-)

--
2.53.0