Re: [PATCH] gpio: sodaville: fix use-after-free bug when registering the irqchip

From: Bartosz Golaszewski

Date: Tue Nov 10 2026 - 04:17:15 EST


On Thu, Nov 05, 2026 at 02:14:27PM +0100, Bartosz Golaszewski wrote:
> In sdv_register_irqsupport(), if irq_domain_create_legacy() fails during
> device probing, a generic IRQ chip is left registered in the global gc_list
> while its underlying memory is freed, leading to a use-after-free. Use
> the managed variant of irq_setup_generic_chip() to ensure that the chip
> gets unregistered before the memory it uses is freed.
>

Andy, will you queue this or should I take it for this week's PR with
fixes?

Bart