Skip to content

Disable Suspend-to-Idle in Hyper-V and Fix Hibernation Interruptions

Erni Sri Satya Vennela linux-hyperv linux-input lkml stable 5 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v4 Latest posting 2/23 patches 3 repliesIn review
  2. v4 posting 1/21 of 3 patches 0 repliesSuperseded
  3. v33 patches 0 repliesSuperseded
Earlier versions · 2
VersionPostedPatchesRepliesStatus
v23 patches0 repliesSuperseded
v13 patches13 repliesSuperseded

Changes in v4 from the cover letter

* Make keyboard and mouse wakeup capable by adding
device_set_wakeup_capable but not enabling them as wakeup sources.
https://lore.kernel.org/lkml/[email protected]/
* Remove device_wakeup_init() call in mousevsc_remove() v3:https://lore.kernel.org/lkml/[email protected]/

Patches in v4 posting 2/2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3Drivers: hv: vmbus: Disable Suspend-to-Idle for VMBusdrivers/hv/vmbus_drv.c+15 -13 replies
2/3Input: hyperv-keyboard - disable as wakeup sourcedrivers/input/serio/hyperv-keyboard.c+1 -10 replies
3/3HID: hyperv: disable as wakeup sourcedrivers/hid/hid-hyperv.c+1 -20 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v4 yet.

Read the v4 thread

Cover letter [PATCH v4 0/3] Disable Suspend-to-Idle in Hyper-V and Fix Hibernation Interruptions

It has been reported that Hyper-V VM users can unintentionally abort hibernation by mouse or keyboard movements. To address this issue, we have decided to remove the wakeup events for the Hyper-V keyboard and mouse driver. However, this change introduces another problem:
Suspend-to-Idle brings the system down with no method to wake it back up.

Given that there are no real users of Suspend-to-Idle in Hyper-V, we have decided to disable this feature for VMBus. This results in:

$echo freeze > /sys/power/state

Quoted 1 line

bash: echo: write error: Operation not supported

The keyboard and mouse were previously registered as wakeup sources to interrupt the freeze operation in a VM. Since the freeze operation itself is no longer supported, we are disabling them as wakeup events.

This patchset ensures that the system remains stable and prevents
unintended interruptions during hibernation.
---
Changes in v4:
* Make keyboard and mouse wakeup capable by adding
device_set_wakeup_capable but not enabling them as wakeup sources.
https://lore.kernel.org/lkml/[email protected]/
* Remove device_wakeup_init() call in mousevsc_remove() v3:https://lore.kernel.org/lkml/[email protected]/

Changes in v3:
* Add 'Cc: [email protected]' in sign-off area. v2:https://lore.kernel.org/lkml/[email protected]/

Changes in v2:
* Add "#define vmbus_freeze NULL" when CONFIG_PM_SLEEP is not
enabled.
* Change commit message to clarify that this change is specifc to
Hyper-V based VMs.
v1:https://lore.kernel.org/lkml/[email protected]/
---

Erni Sri Satya Vennela (3):
Drivers: hv: vmbus: Disable Suspend-to-Idle for VMBus
Input: hyperv-keyboard - disable as wakeup source
HID: hyperv: disable as wakeup source

 drivers/hid/hid-hyperv.c              |  3 +--
 drivers/hv/vmbus_drv.c                | 16 +++++++++++++++-
 drivers/input/serio/hyperv-keyboard.c |  2 +-
 3 files changed, 17 insertions(+), 4 deletions(-)
Signature · 1 line
2.34.1