From: Jonas Karlman Date: Mon, 21 Jul 2025 22:07:16 +0000 (+0000) Subject: phy: rockchip: typec: Fix improper use of UCLASS_PHY X-Git-Tag: v2025.10-rc4~8^2~3 X-Git-Url: https://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fca01a8792e6ed48a00e08124d55f4f74e47b11d;p=pandora-u-boot.git phy: rockchip: typec: Fix improper use of UCLASS_PHY The Rockchip TypeC glue driver improperly present itself as a UCLASS_PHY driver, without ever implementing the required phy_ops. This is something that in special circumstances can lead to a NULL pointer dereference followed by a SError crash. Change the glue driver to use UCLASS_NOP to fix this. Signed-off-by: Jonas Karlman Reviewed-by: Kever Yang --- diff --git a/drivers/phy/rockchip/phy-rockchip-typec.c b/drivers/phy/rockchip/phy-rockchip-typec.c index c48a5cd5267..66d1d32d25c 100644 --- a/drivers/phy/rockchip/phy-rockchip-typec.c +++ b/drivers/phy/rockchip/phy-rockchip-typec.c @@ -788,7 +788,7 @@ U_BOOT_DRIVER(rockchip_tcphy_usb3_port) = { U_BOOT_DRIVER(rockchip_typec_phy) = { .name = "rockchip_typec_phy", - .id = UCLASS_PHY, + .id = UCLASS_NOP, .of_match = rockchip_typec_phy_ids, .probe = rockchip_tcphy_probe, .bind = rockchip_tcphy_bind,