[PATCH] usb: dwc3: remove non existent Kconfig option

Sascha Hauer s.hauer at pengutronix.de
Mon Sep 15 07:41:19 PDT 2025


CONFIG_USB_ROLE_SWITCH does not exist in barebox. Remove the test for
this option.

Fixes: 5d01c33175 ("usb: dwc3: sync with Linux-6.3-rc2")
Signed-off-by: Sascha Hauer <s.hauer at pengutronix.de>
---
 drivers/usb/dwc3/core.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c
index dfc9c85ad8..985213deb4 100644
--- a/drivers/usb/dwc3/core.c
+++ b/drivers/usb/dwc3/core.c
@@ -70,8 +70,7 @@ static int dwc3_get_dr_mode(struct dwc3 *dwc)
 		 * specified or set to OTG, then set the mode to peripheral.
 		 */
 		if (mode == USB_DR_MODE_OTG && !dwc->edev &&
-		    (!IS_ENABLED(CONFIG_USB_ROLE_SWITCH) ||
-		     !of_property_read_bool(dwc->dev->of_node, "usb-role-switch")) &&
+		    (!of_property_read_bool(dwc->dev->of_node, "usb-role-switch")) &&
 		    !DWC3_VER_IS_PRIOR(DWC3, 330A))
 			mode = USB_DR_MODE_PERIPHERAL;
 	}
-- 
2.47.3




More information about the barebox mailing list