Message ID | 20220127195554.15705-1-palmer@rivosinc.com |
---|---|
State | New |
Headers | show |
Series | RISC-V: Prevent sbi_ecall() from being inlined | expand |
diff --git a/arch/riscv/kernel/sbi.c b/arch/riscv/kernel/sbi.c index f72527fcb347..7be586f5dc69 100644 --- a/arch/riscv/kernel/sbi.c +++ b/arch/riscv/kernel/sbi.c @@ -21,6 +21,11 @@ static int (*__sbi_rfence)(int fid, const struct cpumask *cpu_mask, unsigned long start, unsigned long size, unsigned long arg4, unsigned long arg5) __ro_after_init; +/* + * This ecall stub can't be inlined because we're relying on the presence of a + * function call to enforce the calling convention. + */ +noinline struct sbiret sbi_ecall(int ext, int fid, unsigned long arg0, unsigned long arg1, unsigned long arg2, unsigned long arg3, unsigned long arg4,