]> git.baikalelectronics.ru Git - kernel.git/commit
selftests/powerpc: Fix exit status of pkey tests
authorSandipan Das <sandipan@linux.ibm.com>
Mon, 18 Jan 2021 09:31:45 +0000 (15:01 +0530)
committerMichael Ellerman <mpe@ellerman.id.au>
Mon, 18 Jan 2021 21:04:32 +0000 (08:04 +1100)
commit3213d1d58dde6317dfb9cbb4e203364190edc7ab
tree70068de8186ff59adb0c901ff7f42ac800b7ec8b
parentc15c697a5850ddf2b93fe16cfba5ac79fe6b0732
selftests/powerpc: Fix exit status of pkey tests

Since main() does not return a value explicitly, the
return values from FAIL_IF() conditions are ignored
and the tests can still pass irrespective of failures.
This makes sure that we always explicitly return the
correct test exit status.

Fixes: 1d50864b4133 ("selftests/powerpc: Add test for execute-disabled pkeys")
Fixes: 589f320b3081 ("selftests/powerpc: Add test for pkey siginfo verification")
Reported-by: Eirik Fuller <efuller@redhat.com>
Signed-off-by: Sandipan Das <sandipan@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20210118093145.10134-1-sandipan@linux.ibm.com
tools/testing/selftests/powerpc/mm/pkey_exec_prot.c
tools/testing/selftests/powerpc/mm/pkey_siginfo.c