This patch is the RV64 implementation of inline bpf_kptr_xchg()[0]. RV64 JIT supports 64-bit BPF_XCHG atomic instructions. At the same time, the underlying implementation of xchg() and atomic64_xchg() in RV64 both are raw_xchg() that supported 64-bit. Therefore inline bpf_kptr_xchg() will have equivalent semantics. Let's inline it for better performance. link: https://lore.kernel.org/bpf/20240105104819.3916743-1-houtao@xxxxxxxxxxxxxxx [0] Pu Lehui (2): riscv, bpf: Enable inline bpf_kptr_xchg() for RV64 selftests/bpf: Enable inline bpf_kptr_xchg() test for RV64 arch/riscv/net/bpf_jit_comp64.c | 5 +++++ tools/testing/selftests/bpf/prog_tests/kptr_xchg_inline.c | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) -- 2.34.1