From: Nicholas Piggin <npiggin@gmail.com> Date: 2018-05-12 03:35:40
The exec_target binary could segfault calling _exit(2) because r13
is not set up properly (and libc looks at that when performing a
syscall). Call SYS_exit using syscall(2) which doesn't seem to
have this problem.
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
---
tools/testing/selftests/powerpc/benchmarks/exec_target.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
Nick,
On Sat, May 12, 2018 at 5:35 AM, Nicholas Piggin [off-list ref] wrote:
quoted hunk
The exec_target binary could segfault calling _exit(2) because r13
is not set up properly (and libc looks at that when performing a
syscall). Call SYS_exit using syscall(2) which doesn't seem to
have this problem.
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
---
tools/testing/selftests/powerpc/benchmarks/exec_target.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
Could you please apply the same patch to :
./tools/testing/selftests/size/get_size.c
It segfault on ppc32 with default cross compiler from Debian.
Thanks
On Sat, May 12, 2018 at 10:54 AM, Mathieu Malaterre [off-list ref] wrote:
Nick,
On Sat, May 12, 2018 at 5:35 AM, Nicholas Piggin [off-list ref] wrote:
quoted
The exec_target binary could segfault calling _exit(2) because r13
is not set up properly (and libc looks at that when performing a
syscall). Call SYS_exit using syscall(2) which doesn't seem to
have this problem.
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
---
tools/testing/selftests/powerpc/benchmarks/exec_target.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
From: Michael Ellerman <hidden> Date: 2018-05-16 13:38:52
On Sat, 2018-05-12 at 03:35:24 UTC, Nicholas Piggin wrote:
The exec_target binary could segfault calling _exit(2) because r13
is not set up properly (and libc looks at that when performing a
syscall). Call SYS_exit using syscall(2) which doesn't seem to
have this problem.
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>