tools/testing/selftests/mm/guard-regions.c | 4 ++++ tools/testing/selftests/mm/soft-dirty.c | 4 +++- tools/testing/selftests/mm/split_huge_page_test.c | 9 +++++++-- tools/testing/selftests/mm/transhuge-stress.c | 4 ++++ 4 files changed, 18 insertions(+), 3 deletions(-)
There are several tests requires transprarent hugepages, when run on thp
disabled kernel such as realtime kernel, there will be false positve.
Mark those tests as skip when thp is not available.
Chunye Hu (4):
selftests/mm/guard-regions: skip collapse test when thp not enabled
selftests/mm: soft-dirty: skip two tests when thp not available
selftests/mm: split_huge_page_test: skip the test when thp not
available
selftests/mm: transhuge_stress: skip the test when thp not available
tools/testing/selftests/mm/guard-regions.c | 4 ++++
tools/testing/selftests/mm/soft-dirty.c | 4 +++-
tools/testing/selftests/mm/split_huge_page_test.c | 9 +++++++--
tools/testing/selftests/mm/transhuge-stress.c | 4 ++++
4 files changed, 18 insertions(+), 3 deletions(-)
base-commit: 80234b5ab240f52fa45d201e899e207b9265ef91
--
2.53.0
On 3/12/26 12:40, Chunyu Hu wrote: > There are several tests requires transprarent hugepages, when run on thp > disabled kernel such as realtime kernel, there will be false positve. > Mark those tests as skip when thp is not available. We expend that people that run the tests have the configs as contained in tools/testing/selftests/mm/config enabled. I'm fine with teaching the tests that that is no longer required. Should we then remove CONFIG_TRANSPARENT_HUGEPAGE=y from the file, or leave it in there for people building their configs to know what to enable for best test coverage? (I doubt people do use it for that purpose) -- Cheers, David
On Thu, Mar 12, 2026 at 08:39:31PM +0100, David Hildenbrand (Arm) wrote: > On 3/12/26 12:40, Chunyu Hu wrote: > > There are several tests requires transprarent hugepages, when run on thp > > disabled kernel such as realtime kernel, there will be false positve. > > Mark those tests as skip when thp is not available. > > We expend that people that run the tests have the configs as contained in > > tools/testing/selftests/mm/config I didn't notice we have such as file. It's a good template for people to refer to. We can see in the test log when some tests are skipped: 'skipped test(s) detected. Consider enabling relevant config options to improve coverage.' Then this template is helpful for user to 'enable relevant config' when they building kernle themself. But some users just run the default product kernel which is a pre-compiled kernel with product config. > > enabled. > > I'm fine with teaching the tests that that is no longer required. > > Should we then remove > > CONFIG_TRANSPARENT_HUGEPAGE=y > > from the file, or leave it in there for people building their configs to > know what to enable for best test coverage? (I doubt people do use it > for that purpose) The config template is good for people to getting better coverage. Maybe we leave it there, and point people to this config template in the log when some tests are skipped due to kernel config. And yes, user may not do this and they want to detect issue in there product config. 'skipped test(s) detected. Consider enabling relevant config options to improve coverage. See selftests/mm/config.' I find the commit that introduced this config template. And there's a guide in the commit message that about how to merge the config. '8c749ce93ee6 selftests: create test-specific kconfig fragments' > > -- > Cheers, > > David >
On Thu, Mar 12, 2026 at 07:40:23PM +0800, Chunyu Hu wrote: > There are several tests requires transprarent hugepages, when run on thp > disabled kernel such as realtime kernel, there will be false positve. I presume that when THP tests run on kernels with THP disabled they fail and it would be a false negative rather than false positive. > Mark those tests as skip when thp is not available. > > Chunye Hu (4): > selftests/mm/guard-regions: skip collapse test when thp not enabled > selftests/mm: soft-dirty: skip two tests when thp not available > selftests/mm: split_huge_page_test: skip the test when thp not > available > selftests/mm: transhuge_stress: skip the test when thp not available > > tools/testing/selftests/mm/guard-regions.c | 4 ++++ > tools/testing/selftests/mm/soft-dirty.c | 4 +++- > tools/testing/selftests/mm/split_huge_page_test.c | 9 +++++++-- > tools/testing/selftests/mm/transhuge-stress.c | 4 ++++ > 4 files changed, 18 insertions(+), 3 deletions(-) > > > base-commit: 80234b5ab240f52fa45d201e899e207b9265ef91 > -- > 2.53.0 > -- Sincerely yours, Mike.
On Thu, Mar 12, 2026 at 04:03:59PM +0200, Mike Rapoport wrote: > On Thu, Mar 12, 2026 at 07:40:23PM +0800, Chunyu Hu wrote: > > There are several tests requires transprarent hugepages, when run on thp > > disabled kernel such as realtime kernel, there will be false positve. > > I presume that when THP tests run on kernels with THP disabled they fail > and it would be a false negative rather than false positive. This is an interesting point. I'm not naitive speaker. I just learned from AI. It really matters what we define as 'postive'. I presume 'postive' is we run selftest and got a failure report, that's postive, not thinking as it's thp disabled kernel and a 'pass' is postive. I'll add statement about 'postive' in v2 like "a test failure is defiend as postive" > > > Mark those tests as skip when thp is not available. > > > > Chunye Hu (4): > > selftests/mm/guard-regions: skip collapse test when thp not enabled > > selftests/mm: soft-dirty: skip two tests when thp not available > > selftests/mm: split_huge_page_test: skip the test when thp not > > available > > selftests/mm: transhuge_stress: skip the test when thp not available > > > > tools/testing/selftests/mm/guard-regions.c | 4 ++++ > > tools/testing/selftests/mm/soft-dirty.c | 4 +++- > > tools/testing/selftests/mm/split_huge_page_test.c | 9 +++++++-- > > tools/testing/selftests/mm/transhuge-stress.c | 4 ++++ > > 4 files changed, 18 insertions(+), 3 deletions(-) > > > > > > base-commit: 80234b5ab240f52fa45d201e899e207b9265ef91 > > -- > > 2.53.0 > > > > -- > Sincerely yours, > Mike. >
On Fri, Mar 13, 2026 at 08:26:02AM +0800, Chunyu Hu wrote: > On Thu, Mar 12, 2026 at 04:03:59PM +0200, Mike Rapoport wrote: > > On Thu, Mar 12, 2026 at 07:40:23PM +0800, Chunyu Hu wrote: > > > There are several tests requires transprarent hugepages, when run on thp > > > disabled kernel such as realtime kernel, there will be false positve. > > > > I presume that when THP tests run on kernels with THP disabled they fail > > and it would be a false negative rather than false positive. > > This is an interesting point. I'm not naitive speaker. I just learned > from AI. It really matters what we define as 'postive'. I presume 'postive' > is we run selftest and got a failure report, that's postive, not thinking > as it's thp disabled kernel and a 'pass' is postive. I think that a passing test is "positive" and a failing test is "negative". So a test that fails because of misconfiguration is a false negative to me. > I'll add statement about 'postive' in v2 like "a test failure is > defiend as postive" > > > > > > Mark those tests as skip when thp is not available. > > > > > > Chunye Hu (4): > > > selftests/mm/guard-regions: skip collapse test when thp not enabled > > > selftests/mm: soft-dirty: skip two tests when thp not available > > > selftests/mm: split_huge_page_test: skip the test when thp not > > > available > > > selftests/mm: transhuge_stress: skip the test when thp not available > > > > > > tools/testing/selftests/mm/guard-regions.c | 4 ++++ > > > tools/testing/selftests/mm/soft-dirty.c | 4 +++- > > > tools/testing/selftests/mm/split_huge_page_test.c | 9 +++++++-- > > > tools/testing/selftests/mm/transhuge-stress.c | 4 ++++ > > > 4 files changed, 18 insertions(+), 3 deletions(-) > > > > > > > > > base-commit: 80234b5ab240f52fa45d201e899e207b9265ef91 > > > -- > > > 2.53.0 > > > > > > > -- > > Sincerely yours, > > Mike. > > > -- Sincerely yours, Mike.
On Fri, Mar 13, 2026 at 05:19:20PM +0200, Mike Rapoport wrote: > On Fri, Mar 13, 2026 at 08:26:02AM +0800, Chunyu Hu wrote: > > On Thu, Mar 12, 2026 at 04:03:59PM +0200, Mike Rapoport wrote: > > > On Thu, Mar 12, 2026 at 07:40:23PM +0800, Chunyu Hu wrote: > > > > There are several tests requires transprarent hugepages, when run on thp > > > > disabled kernel such as realtime kernel, there will be false positve. > > > > > > I presume that when THP tests run on kernels with THP disabled they fail > > > and it would be a false negative rather than false positive. > > > > This is an interesting point. I'm not naitive speaker. I just learned > > from AI. It really matters what we define as 'postive'. I presume 'postive' > > is we run selftest and got a failure report, that's postive, not thinking > > as it's thp disabled kernel and a 'pass' is postive. > > I think that a passing test is "positive" and a failing test is "negative". > So a test that fails because of misconfiguration is a false negative to me. Thank you for the explanation. I unserstand now. Let's use 'false negative'. > > > I'll add statement about 'postive' in v2 like "a test failure is > > defiend as postive" > > > > > > > > > Mark those tests as skip when thp is not available. > > > > > > > > Chunye Hu (4): > > > > selftests/mm/guard-regions: skip collapse test when thp not enabled > > > > selftests/mm: soft-dirty: skip two tests when thp not available > > > > selftests/mm: split_huge_page_test: skip the test when thp not > > > > available > > > > selftests/mm: transhuge_stress: skip the test when thp not available > > > > > > > > tools/testing/selftests/mm/guard-regions.c | 4 ++++ > > > > tools/testing/selftests/mm/soft-dirty.c | 4 +++- > > > > tools/testing/selftests/mm/split_huge_page_test.c | 9 +++++++-- > > > > tools/testing/selftests/mm/transhuge-stress.c | 4 ++++ > > > > 4 files changed, 18 insertions(+), 3 deletions(-) > > > > > > > > > > > > base-commit: 80234b5ab240f52fa45d201e899e207b9265ef91 > > > > -- > > > > 2.53.0 > > > > > > > > > > -- > > > Sincerely yours, > > > Mike. > > > > > > > -- > Sincerely yours, > Mike. >
On Fri, Mar 13, 2026 at 05:19:20PM +0200, Mike Rapoport wrote: > On Fri, Mar 13, 2026 at 08:26:02AM +0800, Chunyu Hu wrote: > > On Thu, Mar 12, 2026 at 04:03:59PM +0200, Mike Rapoport wrote: > > > On Thu, Mar 12, 2026 at 07:40:23PM +0800, Chunyu Hu wrote: > > > > There are several tests requires transprarent hugepages, when run on thp > > > > disabled kernel such as realtime kernel, there will be false positve. > > > > > > I presume that when THP tests run on kernels with THP disabled they fail > > > and it would be a false negative rather than false positive. > > > > This is an interesting point. I'm not naitive speaker. I just learned > > from AI. It really matters what we define as 'postive'. I presume 'postive' > > is we run selftest and got a failure report, that's postive, not thinking > > as it's thp disabled kernel and a 'pass' is postive. > > I think that a passing test is "positive" and a failing test is "negative". > So a test that fails because of misconfiguration is a false negative to me. (Ostensibly native speaker here :P) Yes. False positive = the test passed when it should have failed. False negative = The test failed when it should have passed. Cheers, Lorenzo
On Fri, Mar 13, 2026 at 03:40:14PM +0000, Lorenzo Stoakes (Oracle) wrote: > On Fri, Mar 13, 2026 at 05:19:20PM +0200, Mike Rapoport wrote: > > On Fri, Mar 13, 2026 at 08:26:02AM +0800, Chunyu Hu wrote: > > > On Thu, Mar 12, 2026 at 04:03:59PM +0200, Mike Rapoport wrote: > > > > On Thu, Mar 12, 2026 at 07:40:23PM +0800, Chunyu Hu wrote: > > > > > There are several tests requires transprarent hugepages, when run on thp > > > > > disabled kernel such as realtime kernel, there will be false positve. > > > > > > > > I presume that when THP tests run on kernels with THP disabled they fail > > > > and it would be a false negative rather than false positive. > > > > > > This is an interesting point. I'm not naitive speaker. I just learned > > > from AI. It really matters what we define as 'postive'. I presume 'postive' > > > is we run selftest and got a failure report, that's postive, not thinking > > > as it's thp disabled kernel and a 'pass' is postive. > > > > I think that a passing test is "positive" and a failing test is "negative". > > So a test that fails because of misconfiguration is a false negative to me. > > (Ostensibly native speaker here :P) > > Yes. > > False positive = the test passed when it should have failed. > False negative = The test failed when it should have passed. Ok. Thank you for clarify. I'll use 'false netative' instead . > > Cheers, Lorenzo >
© 2016 - 2026 Red Hat, Inc.