Re: [PATCH v15 03/14] gpio: regmap: remove gpiochip before tearing down irqchip

From: Andy Shevchenko

Date: Fri Dec 04 2026 - 06:44:07 EST


On Thu, Nov 26, 2026 at 01:09:34PM +0100, Michael Walle wrote:
> On Thu Nov 26, 2026 at 12:00 PM CET, zl020895 wrote:
> > At 2026-11-19 15:40:14, "Andy Shevchenko" <andriy.shevchenko@xxxxxxxxxxxxxxx> wrote:
> >>So, AFAIR Michael rose the question that this patch makes the unregister flow
> >>not reverse symmetrical to the register one. I took a look at this and I can
> >>say that this is a bit twisted. The pure creation part is independent, but
> >>to function it requires GPIO chip to be instantiated. So, yeah, this patch
> >>is a bit controversial. Let me see what we can do here.
> > Hi Andy,
> >
> > Any conclusion on the unregister ordering in 03/14? I have a v16 ready
> > (Sashiko IRQ-defer fix). OK to send v16 as-is, or should I wait for your proposal
> > on the teardown order?
>
> FWIW, I'm working on a cleanup and a fix for
> https://lore.kernel.org/r/20261123040142.48880-1-joseph@xxxxxxxxxx
>
> This might also help with your case.
>
> I hope I'll have something ready later today.

Thanks! Indeed, that looks awesome. I suggest Ambarella people to incorporate
what Michael does into your tree and give a good test. And if works as
expected, rebase patches based on Michael's series.

--
With Best Regards,
Andy Shevchenko