| d5f578f9 | 06-Nov-2024 |
Michael Ellerman <mpe@ellerman.id.au> |
selftests/powerpc: Fix 32-bit BE build errors on Ubuntu 24.04
Starting with Ubuntu 24.04, building the selftests with the big endian compiler (which defaults to 32-bit) fails with errors:
stack_e
selftests/powerpc: Fix 32-bit BE build errors on Ubuntu 24.04
Starting with Ubuntu 24.04, building the selftests with the big endian compiler (which defaults to 32-bit) fails with errors:
stack_expansion_ldst.c:178:37: error: format '%lx' expects argument of type 'long unsigned int', but argument 2 has type 'rlim_t' {aka 'long long unsigned int'} subpage_prot.c:214:38: error: format '%lx' expects argument of type 'long unsigned int', but argument 3 has type 'off_t' {aka 'long long int'}
Prior to 24.04 rlim_t was long unsigned int, and off_t was long int.
Cast to unsigned long long and long long before passing to printf to avoid the errors.
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://patch.msgid.link/20241106130453.1741013-3-mpe@ellerman.id.au
show more ...
|
| 24ded46f | 21-Aug-2020 |
Shawn Anastasio <shawn@anastas.io> |
selftests/powerpc: Update PROT_SAO test to skip ISA 3.1
Since SAO support was removed from ISA 3.1, skip the prot_sao test if PPC_FEATURE2_ARCH_3_1 is set.
Signed-off-by: Shawn Anastasio <shawn@ana
selftests/powerpc: Update PROT_SAO test to skip ISA 3.1
Since SAO support was removed from ISA 3.1, skip the prot_sao test if PPC_FEATURE2_ARCH_3_1 is set.
Signed-off-by: Shawn Anastasio <shawn@anastas.io> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://lore.kernel.org/r/20200821185558.35561-4-shawn@anastas.io
show more ...
|
| 73da08f6 | 24-Jul-2020 |
Michael Ellerman <mpe@ellerman.id.au> |
selftests/powerpc: Remove powerpc special cases from stack expansion test
Now that the powerpc code behaves the same as other architectures we can drop the special cases we had.
Signed-off-by: Mich
selftests/powerpc: Remove powerpc special cases from stack expansion test
Now that the powerpc code behaves the same as other architectures we can drop the special cases we had.
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://lore.kernel.org/r/20200724092528.1578671-5-mpe@ellerman.id.au
show more ...
|
| 9ee571d8 | 24-Jul-2020 |
Michael Ellerman <mpe@ellerman.id.au> |
selftests/powerpc: Update the stack expansion test
Update the stack expansion load/store test to take into account the new allowance of 4224 bytes below the stack pointer.
Signed-off-by: Michael El
selftests/powerpc: Update the stack expansion test
Update the stack expansion load/store test to take into account the new allowance of 4224 bytes below the stack pointer.
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://lore.kernel.org/r/20200724092528.1578671-3-mpe@ellerman.id.au
show more ...
|
| c9938a9d | 24-Jul-2020 |
Michael Ellerman <mpe@ellerman.id.au> |
selftests/powerpc: Add test of stack expansion logic
We have custom stack expansion checks that it turns out are extremely badly tested and contain bugs, surprise. So add some tests that exercise th
selftests/powerpc: Add test of stack expansion logic
We have custom stack expansion checks that it turns out are extremely badly tested and contain bugs, surprise. So add some tests that exercise the code and capture the current boundary conditions.
The signal test currently fails on 64-bit kernels because the 2048 byte allowance for the signal frame is too small, we will fix that in a subsequent patch.
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://lore.kernel.org/r/20200724092528.1578671-1-mpe@ellerman.id.au
show more ...
|
| c27f2fd1 | 27-Jul-2020 |
Sandipan Das <sandipan@linux.ibm.com> |
selftests/powerpc: Add test for pkey siginfo verification
Commit c46241a370a61 ("powerpc/pkeys: Check vma before returning key fault error to the user") fixes a bug which causes the kernel to set th
selftests/powerpc: Add test for pkey siginfo verification
Commit c46241a370a61 ("powerpc/pkeys: Check vma before returning key fault error to the user") fixes a bug which causes the kernel to set the wrong pkey in siginfo when a pkey fault occurs after two competing threads that have allocated different pkeys, one fully permissive and the other restrictive, attempt to protect a common page at the same time. This adds a test to detect the bug.
Signed-off-by: Sandipan Das <sandipan@linux.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://lore.kernel.org/r/ce40b6ee270bda52e8f4088578ed2faf7d1d509a.1595821792.git.sandipan@linux.ibm.com
show more ...
|
| 03634bbf | 27-Jul-2020 |
Sandipan Das <sandipan@linux.ibm.com> |
selftests/powerpc: Harden test for execute-disabled pkeys
Commit 192b6a7805989 ("powerpc/book3s64/pkeys: Fix pkey_access_permitted() for execute disable pkey") fixed a bug that caused repetitive fau
selftests/powerpc: Harden test for execute-disabled pkeys
Commit 192b6a7805989 ("powerpc/book3s64/pkeys: Fix pkey_access_permitted() for execute disable pkey") fixed a bug that caused repetitive faults for pkeys with no execute rights alongside some combination of read and write rights.
This removes the last two cases of the test, which check the behaviour of pkeys with read, write but no execute rights and all the rights, in favour of checking all the possible combinations of read, write and execute rights to be able to detect bugs like the one mentioned above.
Signed-off-by: Sandipan Das <sandipan@linux.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://lore.kernel.org/r/db467500f8af47727bba6b35796e8974a78b71e5.1595821792.git.sandipan@linux.ibm.com
show more ...
|