[PATCH 6/9] usb: dwc3: Clarify error message

Sascha Hauer s.hauer at pengutronix.de
Mon Oct 11 01:03:43 PDT 2021


When the DWC3 controller uses a mode which is currently not compiled
into barebox we answer with "Controller does not support ... mode". Make
clear that it's not the controller which doesn't support it, but the
currently running barebox.

Signed-off-by: Sascha Hauer <s.hauer at pengutronix.de>
---
 drivers/usb/dwc3/core.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c
index f618435cb6..17caf136ef 100644
--- a/drivers/usb/dwc3/core.c
+++ b/drivers/usb/dwc3/core.c
@@ -43,7 +43,7 @@ static int dwc3_get_dr_mode(struct dwc3 *dwc)
 	case DWC3_GHWPARAMS0_MODE_GADGET:
 		if (IS_ENABLED(CONFIG_USB_DWC3_HOST)) {
 			dev_err(dev,
-				"Controller does not support host mode.\n");
+				"This barebox does not support DWC3 host mode.\n");
 			return -EINVAL;
 		}
 		mode = USB_DR_MODE_PERIPHERAL;
@@ -51,7 +51,7 @@ static int dwc3_get_dr_mode(struct dwc3 *dwc)
 	case DWC3_GHWPARAMS0_MODE_HOST:
 		if (IS_ENABLED(CONFIG_USB_DWC3_GADGET)) {
 			dev_err(dev,
-				"Controller does not support device mode.\n");
+				"This barebox does not support DWC3 device mode.\n");
 			return -EINVAL;
 		}
 		mode = USB_DR_MODE_HOST;
-- 
2.30.2




More information about the barebox mailing list