* [RESEND PATCH] selftests/mincore: fix skip condition for check_huge_pages test
@ 2023-06-29 8:35 Ricardo Cañuelo
2023-07-13 15:39 ` Shuah Khan
0 siblings, 1 reply; 2+ messages in thread
From: Ricardo Cañuelo @ 2023-06-29 8:35 UTC (permalink / raw)
To: shuah
Cc: linux-kselftest, linux-kernel, kernel, naresh.kamboju,
dan.carpenter, skhan
The check_huge_pages test was failing instead of skipping on qemu-armv7
because the skip condition wasn't handled properly. Add an additional
check to fix it.
Signed-off-by: Ricardo Cañuelo <ricardo.canuelo@collabora.com>
Reported-by: Naresh Kamboju <naresh.kamboju@linaro.org>
Reported-by: Linux Kernel Functional Testing <lkft@linaro.org>
Reviewed-by: Muhammad Usama Anjum <usama.anjum@collabora.com>
Tested-by: Anders Roxell <anders.roxell@linaro.org>
Closes: https://lore.kernel.org/all/CA+G9fYuoB8Ug8PcTU-YGmemL7_eeEksXFihvxWF6OikD7sK7pA@mail.gmail.com
---
tools/testing/selftests/mincore/mincore_selftest.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/tools/testing/selftests/mincore/mincore_selftest.c b/tools/testing/selftests/mincore/mincore_selftest.c
index 4c88238fc8f0..6fb3eea5b6ee 100644
--- a/tools/testing/selftests/mincore/mincore_selftest.c
+++ b/tools/testing/selftests/mincore/mincore_selftest.c
@@ -150,8 +149,8 @@ TEST(check_huge_pages)
MAP_PRIVATE | MAP_ANONYMOUS | MAP_HUGETLB,
-1, 0);
if (addr == MAP_FAILED) {
- if (errno == ENOMEM)
- SKIP(return, "No huge pages available.");
+ if (errno == ENOMEM || errno == EINVAL)
+ SKIP(return, "No huge pages available or CONFIG_HUGETLB_PAGE disabled.");
else
TH_LOG("mmap error: %s", strerror(errno));
}
--
2.25.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [RESEND PATCH] selftests/mincore: fix skip condition for check_huge_pages test
2023-06-29 8:35 [RESEND PATCH] selftests/mincore: fix skip condition for check_huge_pages test Ricardo Cañuelo
@ 2023-07-13 15:39 ` Shuah Khan
0 siblings, 0 replies; 2+ messages in thread
From: Shuah Khan @ 2023-07-13 15:39 UTC (permalink / raw)
To: Ricardo Cañuelo, shuah
Cc: linux-kselftest, linux-kernel, kernel, naresh.kamboju,
dan.carpenter, Shuah Khan
On 6/29/23 02:35, Ricardo Cañuelo wrote:
> The check_huge_pages test was failing instead of skipping on qemu-armv7
> because the skip condition wasn't handled properly. Add an additional
> check to fix it.
>
> Signed-off-by: Ricardo Cañuelo <ricardo.canuelo@collabora.com>
> Reported-by: Naresh Kamboju <naresh.kamboju@linaro.org>
> Reported-by: Linux Kernel Functional Testing <lkft@linaro.org>
> Reviewed-by: Muhammad Usama Anjum <usama.anjum@collabora.com>
> Tested-by: Anders Roxell <anders.roxell@linaro.org>
> Closes: https://lore.kernel.org/all/CA+G9fYuoB8Ug8PcTU-YGmemL7_eeEksXFihvxWF6OikD7sK7pA@mail.gmail.com
> ---
> tools/testing/selftests/mincore/mincore_selftest.c | 5 +++--
> 1 file changed, 3 insertions(+), 2 deletions(-)
>
Thank you for the patch and sorry for the delay due to conference
travel and vacation.
Will be queued for the next rc.
thanks,
-- Shuah
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-07-13 15:39 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-06-29 8:35 [RESEND PATCH] selftests/mincore: fix skip condition for check_huge_pages test Ricardo Cañuelo
2023-07-13 15:39 ` Shuah Khan
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox