Rafael J. Wysocki 9d09cb1108 ACPI: PM: s2idle: Cancel wakeup before dispatching EC GPE
commit dc0075ba7f387fe4c48a8c674b11ab6f374a6acc upstream.

Commit 4a9af6cac050 ("ACPI: EC: Rework flushing of EC work while
suspended to idle") made acpi_ec_dispatch_gpe() check
pm_wakeup_pending(), but that is before canceling the SCI wakeup,
so pm_wakeup_pending() is always true.  This causes the loop in
acpi_ec_dispatch_gpe() to always terminate after one iteration which
may not be correct.

Address this issue by canceling the SCI wakeup earlier, from
acpi_ec_dispatch_gpe() itself.

Fixes: 4a9af6cac050 ("ACPI: EC: Rework flushing of EC work while suspended to idle")
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-02-16 12:52:54 +01:00
..
2020-03-25 08:25:58 +01:00
2021-07-14 16:53:25 +02:00
2021-07-14 16:53:25 +02:00
2020-11-22 10:14:12 +01:00
2019-08-16 14:32:26 -07:00
2019-12-17 19:56:33 +01:00
2020-06-30 15:37:06 -04:00