gpiolib: acpi: Add acpi_gpio_update_gpiod_lookup_flags() helper
This helper consolidates all settings of GPIO descriptor lookup flags and quirks in the future if any. No functional change intended. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Acked-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
This commit is contained in:

committed by
Linus Walleij

parent
24a4954333
commit
606be34440
@@ -4350,9 +4350,7 @@ struct gpio_desc *fwnode_get_named_gpiod(struct fwnode_handle *fwnode,
|
||||
return desc;
|
||||
|
||||
acpi_gpio_update_gpiod_flags(&dflags, &info);
|
||||
|
||||
if (info.polarity == GPIO_ACTIVE_LOW)
|
||||
lflags |= GPIO_ACTIVE_LOW;
|
||||
acpi_gpio_update_gpiod_lookup_flags(&lflags, &info);
|
||||
}
|
||||
|
||||
/* Currently only ACPI takes this path */
|
||||
|
Reference in New Issue
Block a user