Commit 1c6b1d48 authored by Kevin Brodsky's avatar Kevin Brodsky Committed by Andrew Morton
Browse files

selftests/mm: skip pkey_sighandler_tests if support is missing

The pkey_sighandler_tests are bound to fail if either the kernel or CPU
doesn't support pkeys.  Skip the tests if pkeys support is missing.

Link: https://lkml.kernel.org/r/20241209095019.1732120-14-kevin.brodsky@arm.com


Signed-off-by: default avatarKevin Brodsky <kevin.brodsky@arm.com>
Cc: Aruna Ramakrishna <aruna.ramakrishna@oracle.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Dave Hansen <dave.hansen@linux.intel.com>
Cc: Joey Gouly <joey.gouly@arm.com>
Cc: Keith Lucas <keith.lucas@oracle.com>
Cc: Ryan Roberts <ryan.roberts@arm.com>
Cc: Shuah Khan <shuah@kernel.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
parent 28501aa1
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -535,6 +535,9 @@ int main(int argc, char *argv[])
	ksft_print_header();
	ksft_set_plan(ARRAY_SIZE(pkey_tests));

	if (!is_pkeys_supported())
		ksft_exit_skip("pkeys not supported\n");

	for (i = 0; i < ARRAY_SIZE(pkey_tests); i++)
		(*pkey_tests[i])();