diff options
author | 2021-02-25 18:33:18 +0200 | |
---|---|---|
committer | 2021-03-08 11:59:17 +0100 | |
commit | 62d5247d239d4b48762192a251c647d7c997616a (patch) | |
tree | 4fec5cd62cf2471020dcfd2f0f773c2d9096f0a4 /include/linux/gpio | |
parent | gpiolib: acpi: Add missing IRQF_ONESHOT (diff) | |
download | linux-62d5247d239d4b48762192a251c647d7c997616a.tar.gz linux-62d5247d239d4b48762192a251c647d7c997616a.tar.bz2 linux-62d5247d239d4b48762192a251c647d7c997616a.zip |
gpiolib: acpi: Add ACPI_GPIO_QUIRK_ABSOLUTE_NUMBER quirk
On some systems the ACPI tables has wrong pin number and instead of
having a relative one it provides an absolute one in the global GPIO
number space.
Add ACPI_GPIO_QUIRK_ABSOLUTE_NUMBER quirk to cope with such cases.
Fixes: ba8c90c61847 ("gpio: pca953x: Override IRQ for one of the expanders on Galileo Gen 2")
Depends-on: 0ea683931adb ("gpio: dwapb: Convert driver to using the GPIO-lib-based IRQ-chip")
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'include/linux/gpio')
-rw-r--r-- | include/linux/gpio/consumer.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/gpio/consumer.h b/include/linux/gpio/consumer.h index ef49307611d2..c73b25bc9213 100644 --- a/include/linux/gpio/consumer.h +++ b/include/linux/gpio/consumer.h @@ -674,6 +674,8 @@ struct acpi_gpio_mapping { * get GpioIo type explicitly, this quirk may be used. */ #define ACPI_GPIO_QUIRK_ONLY_GPIOIO BIT(1) +/* Use given pin as an absolute GPIO number in the system */ +#define ACPI_GPIO_QUIRK_ABSOLUTE_NUMBER BIT(2) unsigned int quirks; }; |