diff options
author | 2019-04-29 11:27:58 -0400 | |
---|---|---|
committer | 2019-05-07 15:32:14 -0600 | |
commit | 3d4d1f05bc990f240d66b0ffaf7121397e14df19 (patch) | |
tree | cacfa4eb53e092e4418d01e15259507657b23ccb /tools/testing/selftests/rseq | |
parent | rseq/selftests: x86: use ud1 instruction as RSEQ_SIG opcode (diff) | |
download | linux-3d4d1f05bc990f240d66b0ffaf7121397e14df19.tar.gz linux-3d4d1f05bc990f240d66b0ffaf7121397e14df19.tar.bz2 linux-3d4d1f05bc990f240d66b0ffaf7121397e14df19.zip |
rseq/selftests: s390: use trap4 for RSEQ_SIG
Use trap4 as the guard instruction for the restartable sequence abort
handler.
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Diffstat (limited to 'tools/testing/selftests/rseq')
-rw-r--r-- | tools/testing/selftests/rseq/rseq-s390.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/tools/testing/selftests/rseq/rseq-s390.h b/tools/testing/selftests/rseq/rseq-s390.h index 7c4f3a70b6c7..1d05c5187ae6 100644 --- a/tools/testing/selftests/rseq/rseq-s390.h +++ b/tools/testing/selftests/rseq/rseq-s390.h @@ -1,6 +1,13 @@ /* SPDX-License-Identifier: LGPL-2.1 OR MIT */ -#define RSEQ_SIG 0x53053053 +/* + * RSEQ_SIG uses the trap4 instruction. As Linux does not make use of the + * access-register mode nor the linkage stack this instruction will always + * cause a special-operation exception (the trap-enabled bit in the DUCT + * is and will stay 0). The instruction pattern is + * b2 ff 0f ff trap4 4095(%r0) + */ +#define RSEQ_SIG 0xB2FF0FFF #define rseq_smp_mb() __asm__ __volatile__ ("bcr 15,0" ::: "memory") #define rseq_smp_rmb() rseq_smp_mb() |