[PATCH v2 2/2] RISC-V: make use of variadic sbi_ecall

Paul Walmsley pjw at kernel.org
Wed Oct 7 19:46:57 PDT 2026


On Wed, 7 Oct 2026, Radim Krcmar wrote:

> 2026-10-06T03:55:12-06:00, Paul Walmsley <pjw at kernel.org>:
> > On Thu, 19 Jun 2025, Radim Krčmář wrote:
> >
> >> The new sbi_ecall doesn't have to list all 8 arguments anymore, so only
> >> pass the actual numbers of arguments for each SBI function.
> >> 
> >> The remaining trailing 0 are intentional as they represent an argument.
> >> 
> >> SBI 0.1 shouldn't be using the sbi_ecall, because it's only for 0.2+,
> >> but allow it by passing 0 is the reserved register.
> >> 
> >> Signed-off-by: Radim Krčmář <rkrcmar at ventanamicro.com>
> >
> > Thanks, queued for v7.4.  
> >
> > For everyone, not just Radim - probably it's worth looking through the 
> > codebase to convert any SBI ecalls that were added over the past year that 
> > weren't covered by this patch (e.g., the MPXY drivers) and to doublecheck 
> > the overall argument counts.
> 
> I started working on a followup and noticed a bug.
> 
> Please squash the following change or just drop the second patch, since
> we may be touching the same lines again soon, sorry about that.

Thanks, squashed in.


- Paul


More information about the linux-riscv mailing list