Re: [PATCH v2 8/8] selftests/livepatch: Add RISC-V syscall wrapper prefix
Marcos Paulo de Souza <[email protected]> Thu, 28 May 2026 10:33:34 -0300
| Newsgroups | org.kernel.vger.live-patching,org.infradead.lists.linux-riscv,org.kernel.vger.linux-kernel,org.kernel.vger.linux-kselftest,org.kernel.vger.linux-perf-users,org.kernel.vger.linux-trace-kernel |
|---|---|
| Message-ID | <[email protected]> |
On Thu, 2026-05-28 at 16:23 +0800, Wang Han wrote: > The syscall livepatch selftest resolves and patches a syscall wrapper > symbol. To use that test for RISC-V livepatch validation, add the > RISC-V FN_PREFIX definition for ARCH_HAS_SYSCALL_WRAPPER. > > Without this macro, the syscall livepatch selftest cannot resolve the > RISC-V target symbol, and the syscall-related livepatch test fails on > RISC-V. > > Signed-off-by: Wang Han <[email protected]> Reviewed-by: Marcos Paulo de Souza <[email protected]> > --- > .../testing/selftests/livepatch/test_modules/test_klp_syscall.c | 2 > ++ > 1 file changed, 2 insertions(+) > > diff --git > a/tools/testing/selftests/livepatch/test_modules/test_klp_syscall.c > b/tools/testing/selftests/livepatch/test_modules/test_klp_syscall.c > index dd802783ea84..275e4b10cf59 100644 > --- > a/tools/testing/selftests/livepatch/test_modules/test_klp_syscall.c > +++ > b/tools/testing/selftests/livepatch/test_modules/test_klp_syscall.c > @@ -18,6 +18,8 @@ > #define FN_PREFIX __s390x_ > #elif defined(__aarch64__) > #define FN_PREFIX __arm64_ > +#elif defined(__riscv) > +#define FN_PREFIX __riscv_ > #else > /* powerpc does not select ARCH_HAS_SYSCALL_WRAPPER */ > #define FN_PREFIX