[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAMuHMdVLgpxPCK0chTY=GvMVPgF5G1Oyj=XXoJZBORvH5shFxQ@mail.gmail.com>
Date: Thu, 30 May 2024 09:13:23 +0200
From: Geert Uytterhoeven <geert@...ux-m68k.org>
To: Samuel Holland <samuel.holland@...ive.com>
Cc: Thomas Gleixner <tglx@...utronix.de>, Albert Ou <aou@...s.berkeley.edu>,
Anup Patel <apatel@...tanamicro.com>, Palmer Dabbelt <palmer@...belt.com>,
Paul Walmsley <paul.walmsley@...ive.com>, linux-kernel@...r.kernel.org,
linux-riscv@...ts.infradead.org
Subject: Re: [PATCH] irqchip/sifive-plic: Chain to parent IRQ after handlers
are ready
Hi Samuel,
On Wed, May 29, 2024 at 11:55 PM Samuel Holland
<samuel.holland@...ive.com> wrote:
> Now that the PLIC uses a platform driver, the driver 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(). 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@...ux-m68k.org>
> Closes: https://lore.kernel.org/r/CAMuHMdVYFFR7K5SbHBLY-JHhb7YpgGMS_hnRWm8H0KD-wBo+4A@mail.gmail.com/
> Signed-off-by: Samuel Holland <samuel.holland@...ive.com>
Thanks for your patch!
This fixes the issue I was seering on Starlight, and does not seem to
cause regressions on RZ/Five, Icicle, K210, or VexRiscV.
Tested-by: Geert Uytterhoeven <geert+renesas@...der.be>
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@...ux-m68korg
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
Powered by blists - more mailing lists