Commit bc148def authored by Sven Peter's avatar Sven Peter Committed by Vinod Koul
Browse files

phy: apple: atc: Reset USB2 PHY during probe as well



Now that the upstream Type-C PHY code is getting broader test coverage we
got reports of USB devices plugged in during boot or those plugged in for
the first time after boot occasionally not working correctly.
This is partially caused by the USB2 parts of the PHY being left in an
unknown state by the previous boot stages. We reset all other parts during
probe but forgot about the USB2 PHY so let's fix that and actually reset
and power off the USB2 PHY as well.

Reported-by: default avatarJames Calligeros <jcalligeros99@gmail.com>
Reported-by: default avatarJanne Grunau <j@jannau.net>
Fixes: 8e98ca1e ("phy: apple: Add Apple Type-C PHY")
Signed-off-by: default avatarSven Peter <sven@kernel.org>
Reviewed-by: default avatarJanne Grunau <j@jannau.net>
Tested-by: default avatarJanne Grunau <j@jannau.net>
Link: https://patch.msgid.link/20260108-atcphy-coldboot-fix-v1-1-01c41c6e84f2@kernel.org


Signed-off-by: default avatarVinod Koul <vkoul@kernel.org>
parent 7d55b44e
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -2227,6 +2227,7 @@ static int atcphy_probe_finalize(struct apple_atcphy *atcphy)
	_atcphy_dwc3_reset_assert(atcphy);

	/* Reset atcphy to clear any state potentially left by the bootloader */
	atcphy_usb2_power_off(atcphy);
	atcphy_power_off(atcphy);
	atcphy_setup_pipehandler(atcphy);