Merge branch 'pm-sleep'
* pm-sleep: ACPI / PM: Check low power idle constraints for debug only PM / s2idle: Rename platform operations structure PM / s2idle: Rename ->enter_freeze to ->enter_s2idle PM / s2idle: Rename freeze_state enum and related items PM / s2idle: Rename PM_SUSPEND_FREEZE to PM_SUSPEND_TO_IDLE ACPI / PM: Prefer suspend-to-idle over S3 on some systems platform/x86: intel-hid: Wake up Dell Latitude 7275 from suspend-to-idle PM / suspend: Define pr_fmt() in suspend.c PM / suspend: Use mem_sleep_labels[] strings in messages PM / sleep: Put pm_test under CONFIG_PM_SLEEP_DEBUG PM / sleep: Check pm_wakeup_pending() in __device_suspend_noirq() PM / core: Add error argument to dpm_show_time() PM / core: Split dpm_suspend_noirq() and dpm_resume_noirq() PM / s2idle: Rearrange the main suspend-to-idle loop PM / timekeeping: Print debug messages when requested PM / sleep: Mark suspend/hibernation start and finish PM / sleep: Do not print debug messages by default PM / suspend: Export pm_suspend_target_state
This commit is contained in:
@@ -203,15 +203,26 @@ static void notify_handler(acpi_handle handle, u32 event, void *context)
|
||||
acpi_status status;
|
||||
|
||||
if (priv->wakeup_mode) {
|
||||
/*
|
||||
* Needed for wakeup from suspend-to-idle to work on some
|
||||
* platforms that don't expose the 5-button array, but still
|
||||
* send notifies with the power button event code to this
|
||||
* device object on power button actions while suspended.
|
||||
*/
|
||||
if (event == 0xce)
|
||||
goto wakeup;
|
||||
|
||||
/* Wake up on 5-button array events only. */
|
||||
if (event == 0xc0 || !priv->array)
|
||||
return;
|
||||
|
||||
if (sparse_keymap_entry_from_scancode(priv->array, event))
|
||||
pm_wakeup_hard_event(&device->dev);
|
||||
else
|
||||
if (!sparse_keymap_entry_from_scancode(priv->array, event)) {
|
||||
dev_info(&device->dev, "unknown event 0x%x\n", event);
|
||||
return;
|
||||
}
|
||||
|
||||
wakeup:
|
||||
pm_wakeup_hard_event(&device->dev);
|
||||
return;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user