summaryrefslogtreecommitdiff
path: root/samples/pidfd
diff options
context:
space:
mode:
authorSamuel Holland <samuel.holland@sifive.com>2024-05-30 00:54:56 +0300
committerThomas Gleixner <tglx@linutronix.de>2024-06-03 14:53:12 +0300
commite306a894bd511804ba9db7c00ca9cc05b55df1f2 (patch)
treed12fab36ac185f390bb5637dc2308a62e3cbcd5b /samples/pidfd
parent0110c4b110477bb1f19b0d02361846be7ab08300 (diff)
downloadlinux-e306a894bd511804ba9db7c00ca9cc05b55df1f2.tar.xz
irqchip/sifive-plic: Chain to parent IRQ after handlers are ready
Now that the PLIC uses a platform driver, the driver is probed later in the boot process, where interrupts from peripherals might already be pending. As a result, plic_handle_irq() may be called as early as the call to irq_set_chained_handler() completes. But this call happens before the per-context handler is completely set up, so there is a window where plic_handle_irq() can see incomplete per-context state and crash. Avoid this by delaying the call to irq_set_chained_handler() until all handlers from all PLICs are initialized. Fixes: 8ec99b033147 ("irqchip/sifive-plic: Convert PLIC driver into a platform driver") Reported-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Samuel Holland <samuel.holland@sifive.com> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Tested-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Anup Patel <anup@brainfault.org> Cc: stable@vger.kernel.org Link: https://lore.kernel.org/r/20240529215458.937817-1-samuel.holland@sifive.com Closes: https://lore.kernel.org/r/CAMuHMdVYFFR7K5SbHBLY-JHhb7YpgGMS_hnRWm8H0KD-wBo+4A@mail.gmail.com/
Diffstat (limited to 'samples/pidfd')
0 files changed, 0 insertions, 0 deletions