Skip to content

Commit 02991ac

Browse files
committed
usb: dwc3: core: Allow phy suspend during init for role_switch_reset_quirk
Disabling phy suspend during init breaks USB3 on Apple silicon systems. The pipehandler lock in atc-phy will not be acked breaking USB3 but not always USB2 and produces following log message | phy-apple-atc b03000000.phy: pipehandler lock not acked, this type-c port is probably dead until the next reboot. Fixes: 6d73572 ("usb: dwc3: core: Prevent phy suspend during init") Signed-off-by: Janne Grunau <j@jannau.net>
1 parent 7c462a3 commit 02991ac

2 files changed

Lines changed: 5 additions & 1 deletion

File tree

drivers/usb/dwc3/core.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1394,6 +1394,9 @@ static int dwc3_core_init(struct dwc3 *dwc)
13941394
if (ret)
13951395
goto err_exit_phy;
13961396

1397+
if (dwc->role_switch_reset_quirk)
1398+
dwc3_enable_susphy(dwc, true);
1399+
13971400
dwc3_core_setup_global_control(dwc);
13981401
dwc3_core_num_eps(dwc);
13991402

drivers/usb/dwc3/host.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,8 @@ void dwc3_host_exit(struct dwc3 *dwc)
226226
if (dwc->sys_wakeup)
227227
device_init_wakeup(&dwc->xhci->dev, false);
228228

229-
dwc3_enable_susphy(dwc, false);
229+
if (!dwc->role_switch_reset_quirk)
230+
dwc3_enable_susphy(dwc, false);
230231
platform_device_unregister(dwc->xhci);
231232
dwc->xhci = NULL;
232233
}

0 commit comments

Comments
 (0)