Skip to content

Commit

Permalink
riscv: Fix irq_work when SMP is disabled
Browse files Browse the repository at this point in the history
irq_work is triggered via an IPI, but the IPI infrastructure is not
included in uniprocessor kernels. As a result, irq_work never runs.
Fall back to the tick-based irq_work implementation on uniprocessor
configurations.

Fixes: 2984479 ("riscv: Support irq_work via self IPIs")
Signed-off-by: Samuel Holland <samuel@sholland.org>
Reviewed-by: Heiko Stuebner <heiko@sntech.de>
Link: https://lore.kernel.org/r/20220430030025.58405-1-samuel@sholland.org
Cc: stable@vger.kernel.org
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
  • Loading branch information
Samuel Holland authored and Palmer Dabbelt committed Jun 2, 2022
1 parent 26b8f69 commit 2273272
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/riscv/include/asm/irq_work.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

static inline bool arch_irq_work_has_interrupt(void)
{
return true;
return IS_ENABLED(CONFIG_SMP);
}
extern void arch_irq_work_raise(void);
#endif /* _ASM_RISCV_IRQ_WORK_H */

0 comments on commit 2273272

Please sign in to comment.