mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-06 02:50:49 +09:00
phy: usb: Use slow clock for wake enabled suspend
[ Upstream commit700c44b508] The logic was incorrect when switching to slow clock. We want the slow clock if wake_enabled is set. Fixes:ae532b2b7a("phy: usb: Add "wake on" functionality for newer Synopsis XHCI controllers") Signed-off-by: Justin Chen <justinpopo6@gmail.com> Acked-by: Florian Fainelli <f.fainelli@gmail.com> Link: https://lore.kernel.org/r/1665005418-15807-6-git-send-email-justinpopo6@gmail.com Signed-off-by: Vinod Koul <vkoul@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
0bceef84f7
commit
d19f1664c8
@@ -331,13 +331,12 @@ static void usb_uninit_common_7216(struct brcm_usb_init_params *params)
|
||||
|
||||
pr_debug("%s\n", __func__);
|
||||
|
||||
if (!params->wake_enabled) {
|
||||
USB_CTRL_SET(ctrl, USB_PM, USB_PWRDN);
|
||||
|
||||
if (params->wake_enabled) {
|
||||
/* Switch to using slower clock during suspend to save power */
|
||||
USB_CTRL_SET(ctrl, USB_PM, XHC_S2_CLK_SWITCH_EN);
|
||||
} else {
|
||||
usb_wake_enable_7216(params, true);
|
||||
} else {
|
||||
USB_CTRL_SET(ctrl, USB_PM, USB_PWRDN);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user