linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] ACPI: x86: Introduce an acpi_quirk_skip_gpio_event_handlers() helper
@ 2023-02-18 10:32 Hans de Goede
  2023-02-18 10:32 ` [PATCH 1/3] " Hans de Goede
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Hans de Goede @ 2023-02-18 10:32 UTC (permalink / raw)
  To: Rafael J . Wysocki, Sebastian Reichel, Mika Westerberg,
	Andy Shevchenko, Linus Walleij
  Cc: Hans de Goede, Len Brown, linux-acpi, linux-pm, linux-gpio

<Resend with the gpiolib-acpi.c folks added to the To: list>

Hi All,

x86 ACPI boards which ship with only Android as their factory image usually
have pretty broken ACPI tables, relying on everything being hardcoded in
the factory kernel image and often disabling parts of the ACPI enumeration
kernel code to avoid the broken tables causing issues.

Part of this broken ACPI code is that sometimes these boards have _AEI
ACPI GPIO event handlers which are broken.

So far this has been dealt with in the platform/x86/x86-android-tablets.c
module by it calling acpi_gpiochip_free_interrupts() on gpiochip-s with
troublesome handlers to disable the handlers.

But this is racy and sometimes too late. This series adds a new
acpi_quirk_skip_gpio_event_handlers() function to drivers/acpi/x86/utils.c
using the existing DMI table for this to avoid duplication of DMI matches.

Patch 2 adds a new x86 Android tablet model which needs the new
SKIP_GPIO_EVENT_HANDLERS quirk.

Patch 3 uses acpi_quirk_skip_gpio_event_handlers() in axp288_charger.c
to deal with there not being a ACPI event handler to disable charging
from Vbus before enable 5V boost output on the tablets micro-USB conn.

Sebastian (sre), since patch 3 depends on patch 1, it is probably
easiest to just merge the entire series through the linux-pm tree.
May we have your ack for this ?

Regards,

Hans


Hans de Goede (3):
  ACPI: x86: Introduce an acpi_quirk_skip_gpio_event_handlers() helper
  ACPI: x86: Add skip i2c clients quirk for Acer Iconia One 7 B1-750
  power: supply: axp288_charger: Use alt usb-id extcon on some x86
    android tablets

 drivers/acpi/x86/utils.c              | 34 ++++++++++++++++++++++++---
 drivers/gpio/gpiolib-acpi.c           |  3 +++
 drivers/power/supply/axp288_charger.c | 15 ++++++++++--
 include/acpi/acpi_bus.h               |  5 ++++
 4 files changed, 52 insertions(+), 5 deletions(-)

-- 
2.39.1


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2023-02-20 15:53 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-02-18 10:32 [PATCH 0/3] ACPI: x86: Introduce an acpi_quirk_skip_gpio_event_handlers() helper Hans de Goede
2023-02-18 10:32 ` [PATCH 1/3] " Hans de Goede
2023-02-20 13:34   ` Andy Shevchenko
2023-02-20 15:23     ` Hans de Goede
2023-02-20 15:35       ` Andy Shevchenko
2023-02-20 15:51         ` Hans de Goede
2023-02-18 10:32 ` [PATCH 2/3] ACPI: x86: Add skip i2c clients quirk for Acer Iconia One 7 B1-750 Hans de Goede
2023-02-18 10:32 ` [PATCH 3/3] power: supply: axp288_charger: Use alt usb-id extcon on some x86 android tablets Hans de Goede

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).