[PATCH] phy: exynos5-usbdrd: Fix broken USB on Exynos5422 (TYPEC dependency)
From: Krzysztof Kozlowski
Date: Sat Feb 15 2025 - 04:42:09 EST
Older Exynos designs, like Exynos5422, do not have USB Type-C and the
USB DRD PHY does not really depend on Type-C for these devices at all.
Incorrectly added dependency on CONFIG_TYPEC caused this driver to be
missing for exynos_defconfig and as result Exynos5422-based boards like
Hardkernel Odroid HC1 failed to probe USB.
Drop incorrect dependency and rely on module to be reachable by the
compiler.
Reported-by: Krzysztof Kozlowski <krzk@xxxxxxxxxx>
Closes: https://krzk.eu/#/builders/21/builds/6139
Reported-by: Marek Szyprowski <m.szyprowski@xxxxxxxxxxx>
Closes: https://lore.kernel.org/all/3c0b77e6-357d-453e-8b63-4757c3231bde@xxxxxxxxxxx/
Fixes: 09dc674295a3 ("phy: exynos5-usbdrd: subscribe to orientation notifier if required")
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@xxxxxxxxxx>
---
Patch for issue in linux-next
---
drivers/phy/samsung/Kconfig | 1 -
drivers/phy/samsung/phy-exynos5-usbdrd.c | 2 +-
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/phy/samsung/Kconfig b/drivers/phy/samsung/Kconfig
index 7fba571c0e2b..e2330b0894d6 100644
--- a/drivers/phy/samsung/Kconfig
+++ b/drivers/phy/samsung/Kconfig
@@ -81,7 +81,6 @@ config PHY_EXYNOS5_USBDRD
tristate "Exynos5 SoC series USB DRD PHY driver"
depends on (ARCH_EXYNOS && OF) || COMPILE_TEST
depends on HAS_IOMEM
- depends on TYPEC || (TYPEC=n && COMPILE_TEST)
depends on USB_DWC3_EXYNOS
select GENERIC_PHY
select MFD_SYSCON
diff --git a/drivers/phy/samsung/phy-exynos5-usbdrd.c b/drivers/phy/samsung/phy-exynos5-usbdrd.c
index ff2436f11d68..e8a9fef22107 100644
--- a/drivers/phy/samsung/phy-exynos5-usbdrd.c
+++ b/drivers/phy/samsung/phy-exynos5-usbdrd.c
@@ -1456,7 +1456,7 @@ static int exynos5_usbdrd_setup_notifiers(struct exynos5_usbdrd_phy *phy_drd)
{
int ret;
- if (!IS_ENABLED(CONFIG_TYPEC))
+ if (!IS_REACHABLE(CONFIG_TYPEC))
return 0;
if (device_property_present(phy_drd->dev, "orientation-switch")) {
--
2.43.0