[PATCH] riscv, libbpf: use a0 for RC register

Björn Töpel bjorn.topel at gmail.com
Thu Jul 7 01:53:44 PDT 2022


On Wed, 6 Jul 2022 at 16:03, Yixun Lan <dlan at gentoo.org> wrote:
>
> According to the RISC-V calling convention register usage here[1],
> a0 is used as return value register, so rename it to make it consistent
> with the spec.
>
> [1] section 18.2, table 18.2
> https://riscv.org/wp-content/uploads/2015/01/riscv-calling.pdf
>
> Fixes: 589fed479ba1 ("riscv, libbpf: Add RISC-V (RV64) support to bpf_tracing.h")
> Signed-off-by: Yixun Lan <dlan at gentoo.org>

Nice catch!

Acked-by: Björn Töpel <bjorn at kernel.org>



More information about the linux-riscv mailing list