Re: [PATCH v8 2/3] gpio: regmap: Add optional runtime PM support

From: Andy Shevchenko

Date: Fri Sep 11 2026 - 01:46:55 EST


On Fri, Sep 11, 2026 at 08:41:57AM +0300, Andy Shevchenko wrote:
> On Thu, Sep 10, 2026 at 07:29:11PM +0200, Janani Sunil wrote:

...

> > - ret = gpio->reg_mask_xlate(gpio, GPIO_REGMAP_GET_OP, base, offset, &reg, &mask);
>
> Hmm... As far as I understand the xlate function should not touch the hardware.
> Is it not the case?

Answering to myself:
Yeah, it's not the case as the new driver in the follow up accesses HW.

> > + GPIO_REGMAP_RUNTIME_ACQUIRE(gpio, pm);
> > + ret = GPIO_REGMAP_RUNTIME_ACQUIRE_ERR(&pm);
> > + if (ret)
> > + return ret;
> > +
> > + ret = gpio->reg_mask_xlate(gpio, GPIO_REGMAP_GET_OP, base, offset,
> > + &reg, &mask);
> > if (ret)
> > return ret;
>
> Otherwise runtime PM may be handled after that call.
>
> ...
>
> Ditto for the rest.

--
With Best Regards,
Andy Shevchenko