Re: [PATCH v3] gpio: pca953x: Override IRQ for one of the expanders on Galileo Gen 2

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

 



On Tue, May 26, 2020 at 7:12 PM Andy Shevchenko
<andriy.shevchenko@xxxxxxxxxxxxxxx> wrote:

> +static int pca953x_acpi_get_irq(struct device *dev)
> +{
> +       int pin, ret;
> +
> +       pin = pca953x_acpi_find_pin(dev);
> +       if (pin < 0)
> +               return pin;
> +
> +       dev_info(dev, "Applying ACPI interrupt quirk (GPIO %d)\n", pin);
> +
> +       if (!gpio_is_valid(pin))
> +               return -EINVAL;
> +
> +       ret = gpio_request(pin, "pca953x interrupt");
> +       if (ret)
> +               return ret;

So would it work to do
gpiochip_request_own_desc() here in some form?
I.e. can you figure out the hardware offset number?

Yours,
Linus Walleij



[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