]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
usb: sl811-hcd: Add PM_EVENT_POWEROFF into suspend callbacks
authorMario Limonciello (AMD) <superm1@kernel.org>
Wed, 12 Nov 2025 22:40:25 +0000 (16:40 -0600)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Fri, 14 Nov 2025 16:05:53 +0000 (17:05 +0100)
When the PM core uses hibernation callbacks for shutdown drivers
will receive PM_EVENT_POWEROFF and should handle it the same as
PM_EVENT_HIBERNATE would have been used.

Tested-by: Eric Naim <dnaim@cachyos.org>
Signed-off-by: Mario Limonciello (AMD) <superm1@kernel.org>
[ rjw: Changelog adjustment ]
Link: https://patch.msgid.link/20251112224025.2051702-4-superm1@kernel.org
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/usb/host/sl811-hcd.c

index ea3cab99c5d409c5abb4bff09505b9d90022d051..5d6dba681e5032921c7add7d0b33458f54782651 100644 (file)
@@ -1748,6 +1748,7 @@ sl811h_suspend(struct platform_device *dev, pm_message_t state)
                break;
        case PM_EVENT_SUSPEND:
        case PM_EVENT_HIBERNATE:
+       case PM_EVENT_POWEROFF:
        case PM_EVENT_PRETHAW:          /* explicitly discard hw state */
                port_power(sl811, 0);
                break;