[U-Boot] [PATCH 3/5] usb: host: dwc2: force reset assert

Patrick Delaunay patrick.delaunay at st.com
Fri Aug 2 12:33:40 UTC 2019


Assert reset before deassert in dwc2_reset;
It should be more safe for DWC2.

Signed-off-by: Patrick Delaunay <patrick.delaunay at st.com>
---

 drivers/usb/host/dwc2.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/usb/host/dwc2.c b/drivers/usb/host/dwc2.c
index 5c4c21b..836f706 100644
--- a/drivers/usb/host/dwc2.c
+++ b/drivers/usb/host/dwc2.c
@@ -1148,6 +1148,8 @@ static int dwc2_reset(struct udevice *dev)
 			return ret;
 	}
 
+	reset_assert_bulk(&priv->resets);
+	udelay(2);
 	ret = reset_deassert_bulk(&priv->resets);
 	if (ret) {
 		reset_release_bulk(&priv->resets);
-- 
2.7.4



More information about the U-Boot mailing list