]> git.baikalelectronics.ru Git - kernel.git/commit
selftests/rseq: Fix ppc32 offsets by using long rather than off_t
authorMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Mon, 24 Jan 2022 17:12:48 +0000 (12:12 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 7 Jul 2022 15:36:52 +0000 (17:36 +0200)
commit85c261b4e45d244c40955101e1d4637892a82b28
treecf56f383c57b21c251aa6b856db9bc7371a37711
parentc28fb1a4418e35b956e9321be9c783bdb39c23ae
selftests/rseq: Fix ppc32 offsets by using long rather than off_t

commit ad8b6c6aa622e84baeed57ccdb991d17db55160e upstream.

The semantic of off_t is for file offsets. We mean to use it as an
offset from a pointer. We really expect it to fit in a single register,
and not use a 64-bit type on 32-bit architectures.

Fix runtime issues on ppc32 where the offset is always 0 due to
inconsistency between the argument type (off_t -> 64-bit) and type
expected by the inline assembler (32-bit).

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/20220124171253.22072-11-mathieu.desnoyers@efficios.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
tools/testing/selftests/rseq/basic_percpu_ops_test.c
tools/testing/selftests/rseq/param_test.c
tools/testing/selftests/rseq/rseq-arm.h
tools/testing/selftests/rseq/rseq-arm64.h
tools/testing/selftests/rseq/rseq-mips.h
tools/testing/selftests/rseq/rseq-ppc.h
tools/testing/selftests/rseq/rseq-s390.h
tools/testing/selftests/rseq/rseq-skip.h
tools/testing/selftests/rseq/rseq-x86.h