Re: [PATCH] gpio: aspeed: Lock GPIO pin used as IRQ

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

 



On Thu, Dec 10, 2020 at 9:36 AM Troy Lee <troy_lee@xxxxxxxxxxxxxx> wrote:
>
> GPIO pins can be used as IRQ indicators. When they do,
> those pins should be flaged with locks to avoid kernel

flagged

> warning message.

...

> @@ -651,6 +651,13 @@ static int aspeed_gpio_set_type(struct irq_data *d, unsigned int type)

> +       rc = gpiochip_lock_as_irq(&gpio->chip, d->hwirq);
> +       if (rc) {
> +               dev_err(gpio->chip.parent, "unable to lock GPIO %lu as IRQ\n",
> +                       d->hwirq);
> +               return rc;
> +       }

It's a copy'n'paste of generic code. Why do you need it in an unusual
place, i.e. ->irq_set_type() IIUC?
Can you elaborate about an issue, because this seems to be a hack?

-- 
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