]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commit
ACPI: PM: Set s2idle_wakeup earlier and clear it later
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 13 Jan 2020 09:40:00 +0000 (10:40 +0100)
committerKleber Sacilotto de Souza <kleber.souza@canonical.com>
Fri, 14 Feb 2020 10:57:31 +0000 (11:57 +0100)
commit322318530a5b7b769134f668b3049b46a7b16c51
tree491c6be0d141c5272160c2eccb72760d7e95fbb1
parentca8d59afd30950146c2372869e7d215af39a0755
ACPI: PM: Set s2idle_wakeup earlier and clear it later

BugLink: https://bugs.launchpad.net/bugs/1859407
The role of the s2idle_wakeup variable is to cause
acpi_pm_wakeup_event() and acpi_pm_notify_handler() to
increment pm_abort_suspend and trigger a wakeup from
suspend-to-idle in case the ACPI SCI wakeup was canceled
by acpi_s2idle_wake().

However, for this purpose it need not be set in acpi_s2idle_wake()
and cleared in acpi_s2idle_sync(), respectively.  In fact, it
may be set as early as in acpi_s2idle_prepare() and cleared as
late as in acpi_s2idle_restore(), so do that to allow subsequent
changes to be simpler.

This change is not expected to alter functionality.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: Thomas Gleixner <tglx@linutronix.de>
(cherry picked from commit 41275eb5c7181febdfaa63c3a0ad9b7acdadcd52)
Signed-off-by: You-Sheng Yang <vicamo.yang@canonical.com>
Acked-by: Stefan Bader <stefan.bader@canonical.com>
Acked-by: Marcelo Henrique Cerri <marcelo.cerri@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
drivers/acpi/sleep.c