PM / sleep: Check pm_wakeup_pending() in __device_suspend_noirq()
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Fri, 21 Jul 2017 00:12:10 +0000 (02:12 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 24 Jul 2017 21:53:46 +0000 (23:53 +0200)
commit9a3ebe3523cc8297301d5d95332536ad123856bf
tree2c99ca6d2ba28b7ed99702f0596683f0bb6c1052
parent48059c095bafc2ba23da1b3fa26b6ba142cb854f
PM / sleep: Check pm_wakeup_pending() in __device_suspend_noirq()

Restore the pm_wakeup_pending() check in __device_suspend_noirq()
removed by commit eed4d47efe95 (ACPI / sleep: Ignore spurious SCI
wakeups from suspend-to-idle) as that allows the function to return
earlier if there's a wakeup event pending already (so that it may
spend less time on carrying out operations that will be reversed
shortly anyway) and rework the main suspend-to-idle loop to take
that optimization into account.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/base/power/main.c
kernel/power/suspend.c