From 87cd826b5979d91d4f2ba189e0652820f2da417f Mon Sep 17 00:00:00 2001 From: Erik Schmauss Date: Wed, 14 Mar 2018 16:12:59 -0700 Subject: ACPICA: Events: Dispatch GPEs after enabling for the first time After being enabled for the first time, the GPEs may have STS bits already set. Setting EN bits is not sufficient to trigger the GPEs again, so this patch polls GPEs after enabling them for the first time. This is a cleaner version on top of the "GPE clear" fix generated according to Mika's report and Rafael's original Linux based fix. Based on Linux commit originated from Rafael J. Wysocki, fixed by Lv Zheng. Signed-off-by: Lv Zheng Signed-off-by: Erik Schmauss Signed-off-by: Rafael J. Wysocki --- include/acpi/actypes.h | 1 + include/acpi/platform/aclinux.h | 1 + 2 files changed, 2 insertions(+) (limited to 'include/acpi') diff --git a/include/acpi/actypes.h b/include/acpi/actypes.h index 310b542abe23..a894ea13dcba 100644 --- a/include/acpi/actypes.h +++ b/include/acpi/actypes.h @@ -802,6 +802,7 @@ typedef u32 acpi_event_status; #define ACPI_GPE_CAN_WAKE (u8) 0x10 #define ACPI_GPE_AUTO_ENABLED (u8) 0x20 +#define ACPI_GPE_INITIALIZED (u8) 0x40 /* * Flags for GPE and Lock interfaces diff --git a/include/acpi/platform/aclinux.h b/include/acpi/platform/aclinux.h index e6e757254138..88c50bbcc4d0 100644 --- a/include/acpi/platform/aclinux.h +++ b/include/acpi/platform/aclinux.h @@ -63,6 +63,7 @@ #ifdef __KERNEL__ #define ACPI_USE_SYSTEM_INTTYPES +#define ACPI_USE_GPE_POLLING /* Kernel specific ACPICA configuration */ -- cgit v1.2.3