[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#843448: linux-image-4.8.0-1-armmp-lpae: fails to boot on Odroid-Xu4 with rootfs on USB

Package: src:linux
Followup-For: Bug #843448


thanks to the pointers, I've condensed the first patch (74b9605e) to the
attached one against 4.9. Can you verify that it works?

I will try to port it to 4.11 and linux-next and post them.

The second patch (2166ffd00-updated.diff) looks good for me, would be great to
see it in mainline. Did someone send it to the maintainers already?

Cheers Jochen
>From a06c3727c1c19b2761b0aef267ce6338f0b2de7e Mon Sep 17 00:00:00 2001
From: Jochen Sprickerhof <git@jochen.sprickerhof.de>
Date: Mon, 3 Jul 2017 15:59:25 +0200
Subject: [PATCH] usb: dwc3: core: setup phy before trying to read from it

dwc3_readl needs the device to be set up with dwc3_phy_setup.

Tested with Odroid XU4.

This is a regression from c499ff71ff2a281366c6ec7a904c547d806cbcd1.

Signed-off-by: Jochen Sprickerhof <git@jochen.sprickerhof.de>
 drivers/usb/dwc3/core.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c
index 33d3eb0c944a..69ad59753590 100644
--- a/drivers/usb/dwc3/core.c
+++ b/drivers/usb/dwc3/core.c
@@ -606,6 +606,10 @@ static int dwc3_core_init(struct dwc3 *dwc)
 	u32			reg;
 	int			ret;
+	ret = dwc3_phy_setup(dwc);
+	if (ret)
+		goto err0;
 	reg = dwc3_readl(dwc->regs, DWC3_GSNPSID);
 	/* This should read as U3 followed by revision number */
 	if ((reg & DWC3_GSNPSID_MASK) == 0x55330000) {
@@ -643,10 +647,6 @@ static int dwc3_core_init(struct dwc3 *dwc)
 	if (ret)
 		goto err0;
-	ret = dwc3_phy_setup(dwc);
-	if (ret)
-		goto err0;
 	reg = dwc3_readl(dwc->regs, DWC3_GCTL);

Reply to: