* + selftests-mm-uffd-stress-stricten-constraint-on-free-hugepages-before-the-test.patch added to mm-new branch
@ 2025-08-27 3:29 Andrew Morton
0 siblings, 0 replies; only message in thread
From: Andrew Morton @ 2025-08-27 3:29 UTC (permalink / raw)
To: mm-commits, vbabka, surenb, shuah, ryan.roberts, rppt, npache,
mhocko, lorenzo.stoakes, liam.howlett, david, dev.jain, akpm
The patch titled
Subject: selftests/mm/uffd-stress: Stricten constraint on free hugepages before the test
has been added to the -mm mm-new branch. Its filename is
selftests-mm-uffd-stress-stricten-constraint-on-free-hugepages-before-the-test.patch
This patch will shortly appear at
https://git.kernel.org/pub/scm/linux/kernel/git/akpm/25-new.git/tree/patches/selftests-mm-uffd-stress-stricten-constraint-on-free-hugepages-before-the-test.patch
This patch will later appear in the mm-new branch at
git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
Note, mm-new is a provisional staging ground for work-in-progress
patches, and acceptance into mm-new is a notification for others take
notice and to finish up reviews. Please do not hesitate to respond to
review feedback and post updated versions to replace or incrementally
fixup patches in mm-new.
Before you just go and hit "reply", please:
a) Consider who else should be cc'ed
b) Prefer to cc a suitable mailing list as well
c) Ideally: find the original patch on the mailing list and do a
reply-to-all to that, adding suitable additional cc's
*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***
The -mm tree is included into linux-next via the mm-everything
branch at git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
and is updated there every 2-3 working days
------------------------------------------------------
From: Dev Jain <dev.jain@arm.com>
Subject: selftests/mm/uffd-stress: Stricten constraint on free hugepages before the test
Date: Tue, 26 Aug 2025 12:37:05 +0530
The test requires at least 2 * (bytes/page_size) hugetlb memory, since we
require identical number of hugepages for src and dst location. Fix this.
Along with the above, as explained in patch "selftests/mm/uffd-stress:
Make test operate on less hugetlb memory", the racy nature of the test
requires that we have some extra number of hugepages left beyond what is
required. Therefore, stricten this constraint.
Link: https://lkml.kernel.org/r/20250826070705.53841-3-dev.jain@arm.com
Fixes: 5a6aa60d1823 ("selftests/mm: skip uffd hugetlb tests with insufficient hugepages")
Signed-off-by: Dev Jain <dev.jain@arm.com>
Cc: David Hildenbrand <david@redhat.com>
Cc: Liam Howlett <liam.howlett@oracle.com>
Cc: Lorenzo Stoakes <lorenzo.stoakes@oracle.com>
Cc: Mariano Pache <npache@redhat.com>
Cc: Michal Hocko <mhocko@suse.com>
Cc: Mike Rapoport <rppt@kernel.org>
Cc: Ryan Roberts <ryan.roberts@arm.com>
Cc: Shuah Khan <shuah@kernel.org>
Cc: Suren Baghdasaryan <surenb@google.com>
Cc: Vlastimil Babka <vbabka@suse.cz>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
tools/testing/selftests/mm/uffd-stress.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/tools/testing/selftests/mm/uffd-stress.c~selftests-mm-uffd-stress-stricten-constraint-on-free-hugepages-before-the-test
+++ a/tools/testing/selftests/mm/uffd-stress.c
@@ -469,7 +469,7 @@ int main(int argc, char **argv)
bytes = atol(argv[2]) * 1024 * 1024;
if (gopts->test_type == TEST_HUGETLB &&
- get_free_hugepages() < bytes / gopts->page_size) {
+ get_free_hugepages() < 2 * (bytes / gopts->page_size) + 10) {
printf("skip: Skipping userfaultfd... not enough hugepages\n");
return KSFT_SKIP;
}
_
Patches currently in -mm which might be from dev.jain@arm.com are
selftests-mm-uffd-stress-make-test-operate-on-less-hugetlb-memory.patch
selftests-mm-uffd-stress-stricten-constraint-on-free-hugepages-before-the-test.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2025-08-27 3:29 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-27 3:29 + selftests-mm-uffd-stress-stricten-constraint-on-free-hugepages-before-the-test.patch added to mm-new branch Andrew Morton
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).