Re: [PATCH v1 5/5] gpio: pca953x: Override GpioInt() pin for Intel Galileo Gen 2

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, May 25, 2020 at 02:35:51PM +0300, Andy Shevchenko wrote:
> On Mon, May 25, 2020 at 02:05:56PM +0300, Mika Westerberg wrote:
> > On Mon, May 25, 2020 at 01:13:35PM +0300, Andy Shevchenko wrote:
> > > Due to parsing of ACPI tables. I don't want to copy'n'paste 25% of
> > > gpiolib-acpi.c in here. I think provided solution is cleaner and (more)
> > > flexible in terms of maintenance.
> > 
> > Hmm, you seem to pass a hard-coded pin number (1) to the core that then
> > passes it back to the driver. Why you can't simple use that number here
> > directly? You don't need to parse anything. What I'm missing? :-)
> 
> Okay, so, AFAIU you are proposing something like this:
> 
> 1) find a GPIO controller by the ACPI path (somehow, I guess by finding a
>    handle followed by physical device behind it); 2) somehow to request a
>    pin from that device by number;
> 3) convert to IRQ and use.
> 
> Is it correct?

Ah, and before all these, to detect properly the IO expander that actually has
that resource in the table (something like gpiod_count() or do we have better
approach to answer the question "does this device has a GpioInt() resource?").

-- 
With Best Regards,
Andy Shevchenko





[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux