Skip to contentSkip to conversation

am57xx: beagle-x15: get usb host working

PATCH Superseded Roger Quadros 5 participants 34 messages May 13, 2016 – May 30, 2016

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

cover am57xx: beagle-x15: get usb host working

Hi,

This series fixes dwc3 usb config issues and am57xx-evm USB configuration to get USB host ports working properly on am57xx-evm and beagle-x15.

--
cheers,
-roger

Roger Quadros (4):
usb: dwc3: fix kconfig
board: ti: am57xx: Fix USB configuration
usb: dwc3: Makefile: Don't build gadget code if USB_GADGET is disabled
usb: gadget: udc: Build on USB_GADGET

 drivers/usb/dwc3/Kconfig        | 9 +++++----
 drivers/usb/dwc3/Makefile       | 2 +-
 drivers/usb/gadget/udc/Makefile | 2 +-
 include/configs/am57xx_evm.h    | 3 +++
 4 files changed, 10 insertions(+), 6 deletions(-)
Signature · 1 line
2.7.4
#1 lore raw

PATCH 1/4 usb: dwc3: fix kconfig

DWC3 can be used in host only or gadget only mode.

---
 drivers/usb/dwc3/Kconfig | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)
drivers/usb/dwc3/Kconfig +5 -4
index e93398f..caf695b 100644
@@ -1,15 +1,16 @@
 config USB_DWC3
 	bool "DesignWare USB3 DRD Core Support"
-	depends on (USB && USB_GADGET)
-	select USB_GADGET_DUALSPEED
+	depends on (USB || USB_GADGET)
+	select USB_GADGET_DUALSPEED if USB_GADGET
 	help
-	  Say Y here if your system has a Dual Role SuperSpeed
-	  USB controller based on the DesignWare USB3 IP Core.
+	  Say Y here if your system has DesignWare USB3 IP Core.
 
 if USB_DWC3
 
 choice
 	bool "DWC3 Mode Selection"
+	default USB_DWC3_HOST if (USB && !USB_GADGET)
+	default USB_DWC3_GADGET if (!USB && USB_GADGET)
 
 config USB_DWC3_HOST
 	bool "Host only mode"
Signature · 1 line
2.7.4
#2 lore raw

PATCH 1/4 usb: dwc3: fix kconfig

Quoted 19 lines · Roger Quadros

DWC3 can be used in host only or gadget only mode.

---
 drivers/usb/dwc3/Kconfig | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)
drivers/usb/dwc3/Kconfig +2 -2
index e93398f..caf695b 100644
@@ -1,15 +1,16 @@
 config USB_DWC3
 	bool "DesignWare USB3 DRD Core Support"
-	depends on (USB && USB_GADGET)
-	select USB_GADGET_DUALSPEED
+	depends on (USB || USB_GADGET)
+	select USB_GADGET_DUALSPEED if USB_GADGET
 	help

drivers/usb/dwc3/Kconfig line 13

Quoted 10 lines
drivers/usb/dwc3/Kconfig +3 -2
-	  Say Y here if your system has a Dual Role SuperSpeed
-	  USB controller based on the DesignWare USB3 IP Core.
+	  Say Y here if your system has DesignWare USB3 IP Core.
 
 if USB_DWC3
 
 choice
 	bool "DWC3 Mode Selection"
+	default USB_DWC3_HOST if (USB && !USB_GADGET)
+	default USB_DWC3_GADGET if (!USB && USB_GADGET)

What happens if I select both USB and USB_GADGET ?

Quoted 3 lines
drivers/usb/dwc3/Kconfig +0 -0
 config USB_DWC3_HOST
 	bool "Host only mode"
 
Signature · 2 lines
Best regards,
Marek Vasut
#3 lore raw

PATCH 1/4 usb: dwc3: fix kconfig

Quoted 24 lines · Marek Vasut
Quoted 23 lines · Roger Quadros

DWC3 can be used in host only or gadget only mode.

---
 drivers/usb/dwc3/Kconfig | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)
drivers/usb/dwc3/Kconfig +3 -4
index e93398f..caf695b 100644
@@ -1,15 +1,16 @@
 config USB_DWC3
 	bool "DesignWare USB3 DRD Core Support"
-	depends on (USB && USB_GADGET)
-	select USB_GADGET_DUALSPEED
+	depends on (USB || USB_GADGET)
+	select USB_GADGET_DUALSPEED if USB_GADGET
 	help
-	  Say Y here if your system has a Dual Role SuperSpeed
-	  USB controller based on the DesignWare USB3 IP Core.
+	  Say Y here if your system has DesignWare USB3 IP Core.
 
Quoted 8 lines

drivers/usb/dwc3/Kconfig line 13

Quoted 6 lines
drivers/usb/dwc3/Kconfig +2 -0
 if USB_DWC3
 
 choice
 	bool "DWC3 Mode Selection"
+	default USB_DWC3_HOST if (USB && !USB_GADGET)
+	default USB_DWC3_GADGET if (!USB && USB_GADGET)

What happens if I select both USB and USB_GADGET ?

Ideally we want to have dual role operation but that code seems to have been stripped off from the dwc3/core.c.

So till dual-role is added back it will work in HOST mode by default but user can still choose GADGET mode.

Quoted 6 lines

drivers/usb/dwc3/Kconfig

Quoted 4 lines
drivers/usb/dwc3/Kconfig +0 -0
 config USB_DWC3_HOST
 	bool "Host only mode"
 

cheers,
-roger

#4 lore raw

PATCH 1/4 usb: dwc3: fix kconfig

Quoted 34 lines · Roger Quadros
Quoted 24 lines · Marek Vasut
Quoted 23 lines · Roger Quadros

DWC3 can be used in host only or gadget only mode.

---
 drivers/usb/dwc3/Kconfig | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)
drivers/usb/dwc3/Kconfig +3 -4
index e93398f..caf695b 100644
@@ -1,15 +1,16 @@
 config USB_DWC3
 	bool "DesignWare USB3 DRD Core Support"
-	depends on (USB && USB_GADGET)
-	select USB_GADGET_DUALSPEED
+	depends on (USB || USB_GADGET)
+	select USB_GADGET_DUALSPEED if USB_GADGET
 	help
-	  Say Y here if your system has a Dual Role SuperSpeed
-	  USB controller based on the DesignWare USB3 IP Core.
+	  Say Y here if your system has DesignWare USB3 IP Core.
 
Quoted 8 lines

drivers/usb/dwc3/Kconfig line 13

Quoted 6 lines
drivers/usb/dwc3/Kconfig +2 -0
 if USB_DWC3
 
 choice
 	bool "DWC3 Mode Selection"
+	default USB_DWC3_HOST if (USB && !USB_GADGET)
+	default USB_DWC3_GADGET if (!USB && USB_GADGET)

What happens if I select both USB and USB_GADGET ?

Quoted 5 lines

Ideally we want to have dual role operation but that code seems to have been stripped off from the dwc3/core.c.

So till dual-role is added back it will work in HOST mode by default but user can still choose GADGET mode.

All right, not great, but let's go with this.
Thanks

Signature · 2 lines
Best regards,
Marek Vasut
#5 lore raw

PATCH 1/4 usb: dwc3: fix kconfig

In reply to Marek Vasut

2016-05-13 21:23 GMT+09:00 Marek Vasut <[email protected]>:

Quoted 24 lines · Roger Quadros
Quoted 23 lines

DWC3 can be used in host only or gadget only mode.

---
 drivers/usb/dwc3/Kconfig | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)
drivers/usb/dwc3/Kconfig +3 -4
index e93398f..caf695b 100644
@@ -1,15 +1,16 @@
 config USB_DWC3
      bool "DesignWare USB3 DRD Core Support"
-     depends on (USB && USB_GADGET)
-     select USB_GADGET_DUALSPEED
+     depends on (USB || USB_GADGET)
+     select USB_GADGET_DUALSPEED if USB_GADGET
      help
-       Say Y here if your system has a Dual Role SuperSpeed
-       USB controller based on the DesignWare USB3 IP Core.
+       Say Y here if your system has DesignWare USB3 IP Core.
 
Quoted 9 lines

drivers/usb/dwc3/Kconfig line 13

Quoted 6 lines
drivers/usb/dwc3/Kconfig +2 -0
 if USB_DWC3
 
 choice
      bool "DWC3 Mode Selection"
+     default USB_DWC3_HOST if (USB && !USB_GADGET)
+     default USB_DWC3_GADGET if (!USB && USB_GADGET)

What happens if I select both USB and USB_GADGET ?

Unlike Linux, CONFIG_USB_GADGET depends on CONFIG_USB in U-Boot.

So, (!USB && USB_GADGET) never happens.

Signature · 2 lines
Best Regards
Masahiro Yamada
#6 lore raw

PATCH 1/4 usb: dwc3: fix kconfig

In reply to Roger Quadros

Hi.

2016-05-13 21:17 GMT+09:00 Roger Quadros <[email protected]>:

Quoted 35 lines

DWC3 can be used in host only or gadget only mode.

---
 drivers/usb/dwc3/Kconfig | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)
drivers/usb/dwc3/Kconfig +5 -5
index e93398f..caf695b 100644
@@ -1,15 +1,16 @@
 config USB_DWC3
        bool "DesignWare USB3 DRD Core Support"
-       depends on (USB && USB_GADGET)
-       select USB_GADGET_DUALSPEED
+       depends on (USB || USB_GADGET)
+       select USB_GADGET_DUALSPEED if USB_GADGET
        help
-         Say Y here if your system has a Dual Role SuperSpeed
-         USB controller based on the DesignWare USB3 IP Core.
+         Say Y here if your system has DesignWare USB3 IP Core.
 
 if USB_DWC3
 
 choice
        bool "DWC3 Mode Selection"
+       default USB_DWC3_HOST if (USB && !USB_GADGET)
+       default USB_DWC3_GADGET if (!USB && USB_GADGET)
 
 config USB_DWC3_HOST
        bool "Host only mode"
--

2.7.4

Quoted 4 lines

_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Please note the following commit changed
the meaning of CONFIG_USB.

commit 68f7c5db2d1e714c15b49b0759ddef8f8344f184

Author:     Paul Kocialkowski <[email protected]>
AuthorDate: Tue Aug 4 17:04:05 2015 +0200
Commit:     Marek Vasut <[email protected]>
CommitDate: Wed Aug 5 17:20:34 2015 +0200

usb: Generic USB Kconfig option, that fits both host and gadget and comments

There is no particular reason why the USB Kconfig option should be specific host mode. In prevision of adding MUSB host and gadget to Kconfig, this move the title and help message of the USB Kconfig option to a more generic forma

Adding comments to the usb Kconfig allows for a better separation and more readability in generated configs and in menuconfig.

In Linux, CONFIG_USB enables the host mode of USB. So, "depends on (USB || USB_GADGET)" makes sense.

In U-Boot, since the commit above, CONFIG_USB enables the whole of USB frame-work, including host, gadget.

USB_DWC3 already resides inside of if USB ... endif so, depends on (USB || USB_GADGET) does not make sense.

Signature · 2 lines
Best Regards
Masahiro Yamada
#7 lore raw

PATCH 1/4 usb: dwc3: fix kconfig

Quoted 72 lines · Masahiro Yamada

Hi.

2016-05-13 21:17 GMT+09:00 Roger Quadros <[email protected]>:

Quoted 35 lines

DWC3 can be used in host only or gadget only mode.

---
 drivers/usb/dwc3/Kconfig | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)
drivers/usb/dwc3/Kconfig +5 -5
index e93398f..caf695b 100644
@@ -1,15 +1,16 @@
 config USB_DWC3
        bool "DesignWare USB3 DRD Core Support"
-       depends on (USB && USB_GADGET)
-       select USB_GADGET_DUALSPEED
+       depends on (USB || USB_GADGET)
+       select USB_GADGET_DUALSPEED if USB_GADGET
        help
-         Say Y here if your system has a Dual Role SuperSpeed
-         USB controller based on the DesignWare USB3 IP Core.
+         Say Y here if your system has DesignWare USB3 IP Core.
 
 if USB_DWC3
 
 choice
        bool "DWC3 Mode Selection"
+       default USB_DWC3_HOST if (USB && !USB_GADGET)
+       default USB_DWC3_GADGET if (!USB && USB_GADGET)
 
 config USB_DWC3_HOST
        bool "Host only mode"
--

2.7.4

Quoted 4 lines

_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Please note the following commit changed
the meaning of CONFIG_USB.

commit 68f7c5db2d1e714c15b49b0759ddef8f8344f184

Author:     Paul Kocialkowski <[email protected]>
AuthorDate: Tue Aug 4 17:04:05 2015 +0200
Commit:     Marek Vasut <[email protected]>
CommitDate: Wed Aug 5 17:20:34 2015 +0200

usb: Generic USB Kconfig option, that fits both host and gadget and comments

There is no particular reason why the USB Kconfig option should be specific host mode. In prevision of adding MUSB host and gadget to Kconfig, this move the title and help message of the USB Kconfig option to a more generic forma

Adding comments to the usb Kconfig allows for a better separation and more readability in generated configs and in menuconfig.

In Linux, CONFIG_USB enables the host mode of USB. So, "depends on (USB || USB_GADGET)" makes sense.

Quoted 8 lines

In U-Boot, since the commit above, CONFIG_USB enables the whole of USB frame-work, including host, gadget.

USB_DWC3 already resides inside of if USB ... endif so, depends on (USB || USB_GADGET) does not make sense.

OK, thanks for pointing this out.

But USB doesn't mean Host is active and USB_GADGET means gadget framework is available.

So I think we have incomplete information for deciding about Host role based on just Kconfig.

cheers,
-roger

#8 lore raw

PATCH 1/4 usb: dwc3: fix kconfig

Quoted 81 lines · Roger Quadros
Quoted 72 lines · Masahiro Yamada

Hi.

2016-05-13 21:17 GMT+09:00 Roger Quadros <[email protected]>:

Quoted 35 lines

DWC3 can be used in host only or gadget only mode.

---
 drivers/usb/dwc3/Kconfig | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)
drivers/usb/dwc3/Kconfig +5 -5
index e93398f..caf695b 100644
@@ -1,15 +1,16 @@
 config USB_DWC3
        bool "DesignWare USB3 DRD Core Support"
-       depends on (USB && USB_GADGET)
-       select USB_GADGET_DUALSPEED
+       depends on (USB || USB_GADGET)
+       select USB_GADGET_DUALSPEED if USB_GADGET
        help
-         Say Y here if your system has a Dual Role SuperSpeed
-         USB controller based on the DesignWare USB3 IP Core.
+         Say Y here if your system has DesignWare USB3 IP Core.
 
 if USB_DWC3
 
 choice
        bool "DWC3 Mode Selection"
+       default USB_DWC3_HOST if (USB && !USB_GADGET)
+       default USB_DWC3_GADGET if (!USB && USB_GADGET)
 
 config USB_DWC3_HOST
        bool "Host only mode"
--

2.7.4

Quoted 4 lines

_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Please note the following commit changed
the meaning of CONFIG_USB.

commit 68f7c5db2d1e714c15b49b0759ddef8f8344f184

Author:     Paul Kocialkowski <[email protected]>
AuthorDate: Tue Aug 4 17:04:05 2015 +0200
Commit:     Marek Vasut <[email protected]>
CommitDate: Wed Aug 5 17:20:34 2015 +0200

usb: Generic USB Kconfig option, that fits both host and gadget and comments

There is no particular reason why the USB Kconfig option should be specific host mode. In prevision of adding MUSB host and gadget to Kconfig, this move the title and help message of the USB Kconfig option to a more generic forma

Adding comments to the usb Kconfig allows for a better separation and more readability in generated configs and in menuconfig.

In Linux, CONFIG_USB enables the host mode of USB. So, "depends on (USB || USB_GADGET)" makes sense.

Quoted 8 lines

In U-Boot, since the commit above, CONFIG_USB enables the whole of USB frame-work, including host, gadget.

USB_DWC3 already resides inside of if USB ... endif so, depends on (USB || USB_GADGET) does not make sense.

Quoted 7 lines

OK, thanks for pointing this out.

But USB doesn't mean Host is active and USB_GADGET means gadget framework is available.

So I think we have incomplete information for deciding about Host role based on just Kconfig.

On an OTG controller, you should check the ID pin at runtime to determine which mode the controller should work in. The Kconfig options should select the supported modes, not enforce particular one. If the ID pin is not available or you want to force the controller into particular mode, do it via DT or platdata.

Signature · 2 lines
Best regards,
Marek Vasut
#9 lore raw

PATCH v2 1/4 usb: dwc3: fix kconfig

In reply to Roger Quadros

DWC3 can be used as host or as gadget controller and the actual mode is determined at runtime so USB_DWC3_DUAL_ROLE must be the default mode when both host and gadget drivers are available.

As DWC3 core implements an XHCI host controller, we use USB_XHCI_HCD to check if host driver is available.

USB_DWC3_HOST and USB_DWC3_GADGET are only set if a particular mode needs to be forced or if both host and gadget drivers are not available.

Build the dwc3 gadget drivers only if gadget mode can be used at runtime.

---
v2:
- don't depend on USB as dwc3/kconfig already depends on that
- use USB_XHCI_HCD to decide whether host operation is available.
- Add USB_DWC3_DUAL_ROLE, which means that controller can operate either in host or gadget mode. The actual mode is decided at runtime based on dwc3->dr_mode.

 drivers/usb/dwc3/Kconfig  | 18 +++++++++++++-----
 drivers/usb/dwc3/Makefile |  4 +++-
 drivers/usb/dwc3/core.h   |  4 ++--
 3 files changed, 18 insertions(+), 8 deletions(-)
drivers/usb/dwc3/Kconfig +13 -5
index e93398f..0db536e 100644
@@ -1,19 +1,20 @@
 config USB_DWC3
 	bool "DesignWare USB3 DRD Core Support"
-	depends on (USB && USB_GADGET)
-	select USB_GADGET_DUALSPEED
+	select USB_GADGET_DUALSPEED if USB_GADGET
 	help
-	  Say Y here if your system has a Dual Role SuperSpeed
-	  USB controller based on the DesignWare USB3 IP Core.
+	  Say Y here if your system has DesignWare USB3 IP Core.
 
 if USB_DWC3
 
 choice
 	bool "DWC3 Mode Selection"
+	default USB_DWC3_DUAL_ROLE if (USB_GADGET && USB_XHCI_HCD)
+	default USB_DWC3_HOST if (!USB_GADGET && USB_XHCI_HCD)
+	default USB_DWC3_GADGET if (USB_GADGET && !USB_XHCI_HCD)
 
 config USB_DWC3_HOST
 	bool "Host only mode"
-	depends on USB
+	depends on USB_XHCI_HCD
 	help
 	  Select this when you want to use DWC3 in host mode only,
 	  thereby the gadget feature will be regressed.
@@ -25,6 +26,13 @@ config USB_DWC3_GADGET
 	  Select this when you want to use DWC3 in gadget mode only,
 	  thereby the host feature will be regressed.
 
+config USB_DWC3_DUAL_ROLE
+	bool "Dual role mode"
+	depends on (USB_XHCI_HCD && USB_GADGET)
+	help
+	 This is the default mode of working of DWC3 controller where
+	 both host and gadget features are enabled.
+
 endchoice
 
 comment "Platform Glue Driver Support"
drivers/usb/dwc3/Makefile +3 -1
index 0cd7302..d2ad2e9 100644
@@ -6,7 +6,9 @@ obj-$(CONFIG_USB_DWC3)			+= dwc3.o
 
 dwc3-y					:= core.o
 
-dwc3-y					+= gadget.o ep0.o
+ifneq ($(filter y,$(CONFIG_USB_DWC3_GADGET) $(CONFIG_USB_DWC3_DUAL_ROLE)),)
+dwc3-yi					+= gadget.o ep0.o
+endif
 
 obj-$(CONFIG_USB_DWC3_OMAP)		+= dwc3-omap.o
 obj-$(CONFIG_USB_DWC3_PHY_OMAP)		+= ti_usb_phy.o
drivers/usb/dwc3/core.h +2 -2
index 72d2fcd..faf0c0f 100644
@@ -989,7 +989,7 @@ struct dwc3_gadget_ep_cmd_params {
 /* prototypes */
 int dwc3_gadget_resize_tx_fifos(struct dwc3 *dwc);
 
-#ifdef CONFIG_USB_DWC3_HOST
+#if IS_ENABLED(CONFIG_USB_DWC3_HOST) || IS_ENABLED(CONFIG_USB_DWC3_DUAL_ROLE)
 int dwc3_host_init(struct dwc3 *dwc);
 void dwc3_host_exit(struct dwc3 *dwc);
 #else
@@ -999,7 +999,7 @@ static inline void dwc3_host_exit(struct dwc3 *dwc)
 { }
 #endif
 
-#ifdef CONFIG_USB_DWC3_GADGET
+#if IS_ENABLED(CONFIG_USB_DWC3_GADGET) || IS_ENABLED(CONFIG_USB_DWC3_DUAL_ROLE)
 int dwc3_gadget_init(struct dwc3 *dwc);
 void dwc3_gadget_exit(struct dwc3 *dwc);
 int dwc3_gadget_set_test_mode(struct dwc3 *dwc, int mode);
Signature · 1 line
2.7.4
#10 lore raw

PATCH 2/4 board: ti: am57xx: Fix USB configuration

In reply to Roger Quadros

This fixes build.

---
 include/configs/am57xx_evm.h | 3 +++
 1 file changed, 3 insertions(+)
include/configs/am57xx_evm.h +3 -0
index 32d7d4d..939057c 100644
@@ -63,6 +63,7 @@
 #define CONFIG_SUPPORT_EMMC_BOOT
 
 /* USB xHCI HOST */
+#define CONFIG_USB_DWC3
 #define CONFIG_USB_HOST
 #define CONFIG_USB_XHCI_DWC3
 #define CONFIG_USB_XHCI
@@ -72,6 +73,8 @@
 
 #define CONFIG_OMAP_USB_PHY
 #define CONFIG_OMAP_USB3PHY1_HOST
+#define CONFIG_USB_DWC3_PHY_OMAP
+#define CONFIG_USB_DWC3_OMAP
 
 /* SATA */
 #define CONFIG_BOARD_LATE_INIT
Signature · 1 line
2.7.4
#11 lore raw

PATCH 2/4 board: ti: am57xx: Fix USB configuration

Quoted 1 line · Roger Quadros

This fixes build.

This commit message needs a fix.

Quoted 27 lines
---
 include/configs/am57xx_evm.h | 3 +++
 1 file changed, 3 insertions(+)
include/configs/am57xx_evm.h +3 -0
index 32d7d4d..939057c 100644
@@ -63,6 +63,7 @@
 #define CONFIG_SUPPORT_EMMC_BOOT
 
 /* USB xHCI HOST */
+#define CONFIG_USB_DWC3
 #define CONFIG_USB_HOST
 #define CONFIG_USB_XHCI_DWC3
 #define CONFIG_USB_XHCI
@@ -72,6 +73,8 @@
 
 #define CONFIG_OMAP_USB_PHY
 #define CONFIG_OMAP_USB3PHY1_HOST
+#define CONFIG_USB_DWC3_PHY_OMAP
+#define CONFIG_USB_DWC3_OMAP
 
 /* SATA */
 #define CONFIG_BOARD_LATE_INIT
Signature · 2 lines
Best regards,
Marek Vasut
#12 lore raw

PATCH v2 2/4 board: ti: am57xx: Fix USB configuration

In reply to Roger Quadros

Currently CONFIG_USB_DWC3 is not selected so doing a usb start command results in a serious error [1].

Fix that by enabling CONFIG_USB_DWC3 and other related options CONFIG_USB_DWC3_PHY_OMAP and CONFIG_USB_DWC3_OMAP.

[1]
=> usb start
starting USB...
USB0: data abort

pc : [<fff7ed10>]          lr : [<fff7ebbf>]

reloc pc : [<8081dd10>] lr : [<8081dbbf>]
sp : fef3d260 ip : 00000000 fp : fef3d2a8
r10: fffa4610 r9 : fef50ed0 r8 : 00000000
r7 : fef3d280 r6 : fef3d284 r5 : fffbc380 r4 : 00000000
r3 : 48880000 r2 : 00000000 r1 : 00000000 r0 : fffbc380
Flags: nzcv IRQs off FIQs off Mode SVC_32
Resetting CPU ...

---
 include/configs/am57xx_evm.h | 3 +++
 1 file changed, 3 insertions(+)
include/configs/am57xx_evm.h +3 -0
index 32d7d4d..939057c 100644
@@ -63,6 +63,7 @@
 #define CONFIG_SUPPORT_EMMC_BOOT
 
 /* USB xHCI HOST */
+#define CONFIG_USB_DWC3
 #define CONFIG_USB_HOST
 #define CONFIG_USB_XHCI_DWC3
 #define CONFIG_USB_XHCI
@@ -72,6 +73,8 @@
 
 #define CONFIG_OMAP_USB_PHY
 #define CONFIG_OMAP_USB3PHY1_HOST
+#define CONFIG_USB_DWC3_PHY_OMAP
+#define CONFIG_USB_DWC3_OMAP
 
 /* SATA */
 #define CONFIG_BOARD_LATE_INIT
Signature · 1 line
2.7.4
#13 lore raw

PATCH v2 2/4 board: ti: am57xx: Fix USB configuration

Quoted 2 lines · Roger Quadros

Currently CONFIG_USB_DWC3 is not selected so doing a usb start command results in a serious error [1].

Why does this error happen ? That is what should be fixed. Selecting some random options seems like papering over a bug.

Quoted 16 lines

Fix that by enabling CONFIG_USB_DWC3 and other related options CONFIG_USB_DWC3_PHY_OMAP and CONFIG_USB_DWC3_OMAP.

[1]
=> usb start
starting USB...
USB0: data abort

pc : [<fff7ed10>]          lr : [<fff7ebbf>]

reloc pc : [<8081dd10>] lr : [<8081dbbf>]
sp : fef3d260 ip : 00000000 fp : fef3d2a8
r10: fffa4610 r9 : fef50ed0 r8 : 00000000
r7 : fef3d280 r6 : fef3d284 r5 : fffbc380 r4 : 00000000
r3 : 48880000 r2 : 00000000 r1 : 00000000 r0 : fffbc380
Flags: nzcv IRQs off FIQs off Mode SVC_32
Resetting CPU ...

Quoted 4 lines
---
 include/configs/am57xx_evm.h | 3 +++
 1 file changed, 3 insertions(+)

Changelog is missing ;-)

Quoted 22 lines
include/configs/am57xx_evm.h +3 -0
index 32d7d4d..939057c 100644
@@ -63,6 +63,7 @@
 #define CONFIG_SUPPORT_EMMC_BOOT
 
 /* USB xHCI HOST */
+#define CONFIG_USB_DWC3
 #define CONFIG_USB_HOST
 #define CONFIG_USB_XHCI_DWC3
 #define CONFIG_USB_XHCI
@@ -72,6 +73,8 @@
 
 #define CONFIG_OMAP_USB_PHY
 #define CONFIG_OMAP_USB3PHY1_HOST
+#define CONFIG_USB_DWC3_PHY_OMAP
+#define CONFIG_USB_DWC3_OMAP
 
 /* SATA */
 #define CONFIG_BOARD_LATE_INIT
Signature · 2 lines
Best regards,
Marek Vasut
#14 lore raw

PATCH v2 2/4 board: ti: am57xx: Fix USB configuration

Quoted 6 lines · Marek Vasut
Quoted 2 lines · Roger Quadros

Currently CONFIG_USB_DWC3 is not selected so doing a usb start command results in a serious error [1].

Why does this error happen ? That is what should be fixed. Selecting some random options seems like papering over a bug.

Agreed. I was lazy :P.

cheers,
-roger

Quoted 48 lines
Quoted 17 lines

Fix that by enabling CONFIG_USB_DWC3 and other related options CONFIG_USB_DWC3_PHY_OMAP and CONFIG_USB_DWC3_OMAP.

[1]
=> usb start
starting USB...
USB0: data abort

pc : [<fff7ed10>]          lr : [<fff7ebbf>]

reloc pc : [<8081dd10>] lr : [<8081dbbf>]
sp : fef3d260 ip : 00000000 fp : fef3d2a8
r10: fffa4610 r9 : fef50ed0 r8 : 00000000
r7 : fef3d280 r6 : fef3d284 r5 : fffbc380 r4 : 00000000
r3 : 48880000 r2 : 00000000 r1 : 00000000 r0 : fffbc380
Flags: nzcv IRQs off FIQs off Mode SVC_32
Resetting CPU ...

Quoted 4 lines
---
 include/configs/am57xx_evm.h | 3 +++
 1 file changed, 3 insertions(+)

Changelog is missing ;-)

Quoted 22 lines
include/configs/am57xx_evm.h +3 -0
index 32d7d4d..939057c 100644
@@ -63,6 +63,7 @@
 #define CONFIG_SUPPORT_EMMC_BOOT
 
 /* USB xHCI HOST */
+#define CONFIG_USB_DWC3
 #define CONFIG_USB_HOST
 #define CONFIG_USB_XHCI_DWC3
 #define CONFIG_USB_XHCI
@@ -72,6 +73,8 @@
 
 #define CONFIG_OMAP_USB_PHY
 #define CONFIG_OMAP_USB3PHY1_HOST
+#define CONFIG_USB_DWC3_PHY_OMAP
+#define CONFIG_USB_DWC3_OMAP
 
 /* SATA */
 #define CONFIG_BOARD_LATE_INIT
#15 lore raw

PATCH v2 2/4 board: ti: am57xx: Fix USB configuration

Quoted 9 lines · Roger Quadros
Quoted 6 lines · Marek Vasut
Quoted 2 lines · Roger Quadros

Currently CONFIG_USB_DWC3 is not selected so doing a usb start command results in a serious error [1].

Why does this error happen ? That is what should be fixed. Selecting some random options seems like papering over a bug.

Agreed. I was lazy :P.

OK. The issue is like this.

CONFIG_CMD_USB and CONFIG_USB_XHCI is defined, so usb_init() calls usb_lowlevel_init() in xhci.c which calls xhci_hcd_init in xhci-omap.c which calls board_usb_init().

But board_usb_init() in am57xx/board.c is defined only if CONFIG_USB_DWC3 is defined and that is missing in am57xx_evm.h leading to the serious error. We're trying to access the IP without turning on the necessary clocks.

So it looks like we need to define it based on CONFIG_USB_XHCI_OMAP or something else.

But then again looking into the future, what if we want only gadget operation? That would not define XHCI, but we still need board_usb_init(). So board_usb_init() should be defined based on CONFIG_CMD_USB=y?

What do you suggest?

cheers,
-roger

Quoted 57 lines

cheers,
-roger

Quoted 38 lines
Quoted 17 lines

Fix that by enabling CONFIG_USB_DWC3 and other related options CONFIG_USB_DWC3_PHY_OMAP and CONFIG_USB_DWC3_OMAP.

[1]
=> usb start
starting USB...
USB0: data abort

pc : [<fff7ed10>]          lr : [<fff7ebbf>]

reloc pc : [<8081dd10>] lr : [<8081dbbf>]
sp : fef3d260 ip : 00000000 fp : fef3d2a8
r10: fffa4610 r9 : fef50ed0 r8 : 00000000
r7 : fef3d280 r6 : fef3d284 r5 : fffbc380 r4 : 00000000
r3 : 48880000 r2 : 00000000 r1 : 00000000 r0 : fffbc380
Flags: nzcv IRQs off FIQs off Mode SVC_32
Resetting CPU ...

Quoted 4 lines
---
 include/configs/am57xx_evm.h | 3 +++
 1 file changed, 3 insertions(+)

Changelog is missing ;-)

Quoted 14 lines
include/configs/am57xx_evm.h +1 -0
index 32d7d4d..939057c 100644
@@ -63,6 +63,7 @@
 #define CONFIG_SUPPORT_EMMC_BOOT
 
 /* USB xHCI HOST */
+#define CONFIG_USB_DWC3
 #define CONFIG_USB_HOST
 #define CONFIG_USB_XHCI_DWC3
 #define CONFIG_USB_XHCI
@@ -72,6 +73,8 @@
 
Quoted 10 lines

include/configs/am57xx_evm.h line 80

Quoted 8 lines
include/configs/am57xx_evm.h +2 -0
 #define CONFIG_OMAP_USB_PHY
 #define CONFIG_OMAP_USB3PHY1_HOST
+#define CONFIG_USB_DWC3_PHY_OMAP
+#define CONFIG_USB_DWC3_OMAP
 
 /* SATA */
 #define CONFIG_BOARD_LATE_INIT

_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

#16 lore raw

PATCH v2 2/4 board: ti: am57xx: Fix USB configuration

Quoted 21 lines · Roger Quadros
Quoted 9 lines · Roger Quadros
Quoted 6 lines · Marek Vasut
Quoted 2 lines · Roger Quadros

Currently CONFIG_USB_DWC3 is not selected so doing a usb start command results in a serious error [1].

Why does this error happen ? That is what should be fixed. Selecting some random options seems like papering over a bug.

Agreed. I was lazy :P.

OK. The issue is like this.

CONFIG_CMD_USB and CONFIG_USB_XHCI is defined, so usb_init() calls usb_lowlevel_init() in xhci.c which calls xhci_hcd_init in xhci-omap.c which calls board_usb_init().

But board_usb_init() in am57xx/board.c is defined only if CONFIG_USB_DWC3 is defined and that is missing in am57xx_evm.h leading to the serious error. We're trying to access the IP without turning on the necessary clocks.

Quoted 7 lines

So it looks like we need to define it based on CONFIG_USB_XHCI_OMAP or something else.

But then again looking into the future, what if we want only gadget operation? That would not define XHCI, but we still need board_usb_init(). So board_usb_init() should be defined based on CONFIG_CMD_USB=y?

What do you suggest?

But board_usb_init() calls

                ti_usb_phy_uboot_init(&usb_phy1_device);
                dwc3_omap_uboot_init(&usb_otg_ss1_glue);
                dwc3_uboot_init(&usb_otg_ss1);

which depend on CONFIG_USB_DWC3_PHY_OMAP, CONFIG_USB_DWC3_OMAP and CONFIG_USB_DWC3 respectively.

So I really don't know how to fix all this.

--
cheers,
-roger

Quoted 59 lines
Quoted 49 lines
Quoted 39 lines
Quoted 18 lines

Fix that by enabling CONFIG_USB_DWC3 and other related options CONFIG_USB_DWC3_PHY_OMAP and CONFIG_USB_DWC3_OMAP.

[1]
=> usb start
starting USB...
USB0: data abort

pc : [<fff7ed10>]          lr : [<fff7ebbf>]

reloc pc : [<8081dd10>] lr : [<8081dbbf>]
sp : fef3d260 ip : 00000000 fp : fef3d2a8
r10: fffa4610 r9 : fef50ed0 r8 : 00000000
r7 : fef3d280 r6 : fef3d284 r5 : fffbc380 r4 : 00000000
r3 : 48880000 r2 : 00000000 r1 : 00000000 r0 : fffbc380
Flags: nzcv IRQs off FIQs off Mode SVC_32
Resetting CPU ...

Quoted 4 lines
---
 include/configs/am57xx_evm.h | 3 +++
 1 file changed, 3 insertions(+)

Changelog is missing ;-)

Quoted 14 lines
include/configs/am57xx_evm.h +1 -0
index 32d7d4d..939057c 100644
@@ -63,6 +63,7 @@
 #define CONFIG_SUPPORT_EMMC_BOOT
 
 /* USB xHCI HOST */
+#define CONFIG_USB_DWC3
 #define CONFIG_USB_HOST
 #define CONFIG_USB_XHCI_DWC3
 #define CONFIG_USB_XHCI
@@ -72,6 +73,8 @@
 
Quoted 10 lines

include/configs/am57xx_evm.h line 80

Quoted 8 lines
include/configs/am57xx_evm.h +2 -0
 #define CONFIG_OMAP_USB_PHY
 #define CONFIG_OMAP_USB3PHY1_HOST
+#define CONFIG_USB_DWC3_PHY_OMAP
+#define CONFIG_USB_DWC3_OMAP
 
 /* SATA */
 #define CONFIG_BOARD_LATE_INIT
Quoted 5 lines

_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

#17 lore raw

PATCH v2 2/4 board: ti: am57xx: Fix USB configuration

Hi Roger,

Quoted 10 lines · Roger Quadros
Quoted 9 lines · Roger Quadros
Quoted 8 lines · Roger Quadros
Quoted 6 lines · Marek Vasut
Quoted 2 lines · Roger Quadros

Currently CONFIG_USB_DWC3 is not selected so doing a usb start command results in a serious error [1].

Why does this error happen ? That is what should be fixed. Selecting some random options seems like papering over a bug.

Quoted 7 lines
Quoted 7 lines
Quoted 1 line

Agreed. I was lazy :P.

OK. The issue is like this.

CONFIG_CMD_USB and CONFIG_USB_XHCI is defined, so usb_init() calls usb_lowlevel_init() in xhci.c which calls xhci_hcd_init in xhci-omap.c which calls board_usb_init().

IIRC, board_usb_init for xhci (omap) is mostly a NOP.

Quoted 4 lines
Quoted 4 lines

But board_usb_init() in am57xx/board.c is defined only if CONFIG_USB_DWC3 is defined and that is missing in am57xx_evm.h leading to the serious error. We're trying to access the IP without turning on the necessary clocks.

clocks are not turned on in board_usb_init() right? The board_usb_init() in am57xx/board.c is used only for gadget mode.

Quoted 2 lines
Quoted 2 lines

So it looks like we need to define it based on CONFIG_USB_XHCI_OMAP or something else.

right, but before that we might have to cleanup xhci-omap.

Quoted 7 lines
Quoted 6 lines

But then again looking into the future, what if we want only gadget operation? That would not define XHCI, but we still need board_usb_init(). So board_usb_init() should be defined based on CONFIG_CMD_USB=y?

What do you suggest?

Quoted 8 lines

But board_usb_init() calls

                ti_usb_phy_uboot_init(&usb_phy1_device);
                dwc3_omap_uboot_init(&usb_otg_ss1_glue);
                dwc3_uboot_init(&usb_otg_ss1);

which depend on CONFIG_USB_DWC3_PHY_OMAP, CONFIG_USB_DWC3_OMAP and CONFIG_USB_DWC3 respectively.

IMO we should cleanup xhci-omap so that all the initializations are done using ti_usb_phy_uboot_init, dwc3_omap_uboot_init and dwc3_uboot_init. Then modify dwc3_uboot_init to initialize host or device based on CONFIG_*.

Thanks
Kishon

#18 lore raw

PATCH v2 2/4 board: ti: am57xx: Fix USB configuration

Quoted 15 lines · Kishon Vijay Abraham I

Hi Roger,

Quoted 12 lines · Roger Quadros
Quoted 11 lines · Roger Quadros
Quoted 9 lines · Roger Quadros
Quoted 6 lines · Marek Vasut
Quoted 2 lines · Roger Quadros

Currently CONFIG_USB_DWC3 is not selected so doing a usb start command results in a serious error [1].

Why does this error happen ? That is what should be fixed. Selecting some random options seems like papering over a bug.

Agreed. I was lazy :P.

Quoted 7 lines
Quoted 5 lines
Quoted 5 lines

OK. The issue is like this.

CONFIG_CMD_USB and CONFIG_USB_XHCI is defined, so usb_init() calls usb_lowlevel_init() in xhci.c which calls xhci_hcd_init in xhci-omap.c which calls board_usb_init().

IIRC, board_usb_init for xhci (omap) is mostly a NOP.

Then who will call board_usb_init() for host case?

Quoted 24 lines
Quoted 4 lines
Quoted 4 lines

But board_usb_init() in am57xx/board.c is defined only if CONFIG_USB_DWC3 is defined and that is missing in am57xx_evm.h leading to the serious error. We're trying to access the IP without turning on the necessary clocks.

clocks are not turned on in board_usb_init() right? The board_usb_init() in am57xx/board.c is used only for gadget mode.

Quoted 2 lines
Quoted 2 lines

So it looks like we need to define it based on CONFIG_USB_XHCI_OMAP or something else.

right, but before that we might have to cleanup xhci-omap.

Quoted 13 lines
Quoted 6 lines

But then again looking into the future, what if we want only gadget operation? That would not define XHCI, but we still need board_usb_init(). So board_usb_init() should be defined based on CONFIG_CMD_USB=y?

What do you suggest?

But board_usb_init() calls

                ti_usb_phy_uboot_init(&usb_phy1_device);
                dwc3_omap_uboot_init(&usb_otg_ss1_glue);
                dwc3_uboot_init(&usb_otg_ss1);
Quoted 7 lines
Quoted 2 lines

which depend on CONFIG_USB_DWC3_PHY_OMAP, CONFIG_USB_DWC3_OMAP and CONFIG_USB_DWC3 respectively.

IMO we should cleanup xhci-omap so that all the initializations are done using ti_usb_phy_uboot_init, dwc3_omap_uboot_init and dwc3_uboot_init. Then modify dwc3_uboot_init to initialize host or device based on CONFIG_*.

I'm still trying to get a grip of how USB works in u-boot.
Is CONFIG_CMD_USB only meant for host mode or gadget mode as well? Is dual-role even required in u-boot? probably it is not a good idea and we just ignore it for simplicity.

What determines whether a USB port is meant for Host or device operation? Is it the CONFIG_ or caller of board_usb_init()?
I see board_usb_init() being used by gadget drivers, host drivers, dfu.c, etc.

cheers,
-roger

#19 lore raw

PATCH v2 2/4 board: ti: am57xx: Fix USB configuration

Hi Roger,

Quoted 53 lines · Roger Quadros
Quoted 15 lines · Kishon Vijay Abraham I

Hi Roger,

Quoted 12 lines · Roger Quadros
Quoted 11 lines · Roger Quadros
Quoted 9 lines · Roger Quadros
Quoted 6 lines · Marek Vasut
Quoted 2 lines · Roger Quadros

Currently CONFIG_USB_DWC3 is not selected so doing a usb start command results in a serious error [1].

Why does this error happen ? That is what should be fixed. Selecting some random options seems like papering over a bug.

Agreed. I was lazy :P.

Quoted 7 lines
Quoted 5 lines
Quoted 5 lines

OK. The issue is like this.

CONFIG_CMD_USB and CONFIG_USB_XHCI is defined, so usb_init() calls usb_lowlevel_init() in xhci.c which calls xhci_hcd_init in xhci-omap.c which calls board_usb_init().

IIRC, board_usb_init for xhci (omap) is mostly a NOP.

Then who will call board_usb_init() for host case?

Quoted 27 lines
Quoted 4 lines
Quoted 4 lines

But board_usb_init() in am57xx/board.c is defined only if CONFIG_USB_DWC3 is defined and that is missing in am57xx_evm.h leading to the serious error. We're trying to access the IP without turning on the necessary clocks.

clocks are not turned on in board_usb_init() right? The board_usb_init() in am57xx/board.c is used only for gadget mode.

Quoted 2 lines
Quoted 2 lines

So it looks like we need to define it based on CONFIG_USB_XHCI_OMAP or something else.

right, but before that we might have to cleanup xhci-omap.

Quoted 15 lines
Quoted 6 lines

But then again looking into the future, what if we want only gadget operation? That would not define XHCI, but we still need board_usb_init(). So board_usb_init() should be defined based on CONFIG_CMD_USB=y?

What do you suggest?

But board_usb_init() calls

                ti_usb_phy_uboot_init(&usb_phy1_device);
                dwc3_omap_uboot_init(&usb_otg_ss1_glue);
                dwc3_uboot_init(&usb_otg_ss1);

which depend on CONFIG_USB_DWC3_PHY_OMAP, CONFIG_USB_DWC3_OMAP and CONFIG_USB_DWC3 respectively.

Quoted 7 lines
Quoted 4 lines

IMO we should cleanup xhci-omap so that all the initializations are done using ti_usb_phy_uboot_init, dwc3_omap_uboot_init and dwc3_uboot_init. Then modify dwc3_uboot_init to initialize host or device based on CONFIG_*.

I'm still trying to get a grip of how USB works in u-boot. Is CONFIG_CMD_USB only meant for host mode or gadget mode as well?

IIRC it is only for host. Commands like usb start, usb stop are used to start and stop host.

Quoted 2 lines

Is dual-role even required in u-boot? probably it is not a good idea and we just ignore it for simplicity.

yeah.

Quoted 3 lines

What determines whether a USB port is meant for Host or device operation? Is it the CONFIG_ or caller of board_usb_init()?

It should be the caller of board_usb_init(). The same port can be used as device or host based on command used (the command determines the caller of board_usb_init).

Thanks
Kishon

#20 lore raw

PATCH v2 2/4 board: ti: am57xx: Fix USB configuration

Quoted 69 lines · Kishon Vijay Abraham I

Hi Roger,

Quoted 53 lines · Roger Quadros
Quoted 15 lines · Kishon Vijay Abraham I

Hi Roger,

Quoted 12 lines · Roger Quadros
Quoted 11 lines · Roger Quadros
Quoted 9 lines · Roger Quadros
Quoted 6 lines · Marek Vasut
Quoted 2 lines · Roger Quadros

Currently CONFIG_USB_DWC3 is not selected so doing a usb start command results in a serious error [1].

Why does this error happen ? That is what should be fixed. Selecting some random options seems like papering over a bug.

Agreed. I was lazy :P.

Quoted 7 lines
Quoted 5 lines
Quoted 5 lines

OK. The issue is like this.

CONFIG_CMD_USB and CONFIG_USB_XHCI is defined, so usb_init() calls usb_lowlevel_init() in xhci.c which calls xhci_hcd_init in xhci-omap.c which calls board_usb_init().

IIRC, board_usb_init for xhci (omap) is mostly a NOP.

Then who will call board_usb_init() for host case?

Quoted 27 lines
Quoted 4 lines
Quoted 4 lines

But board_usb_init() in am57xx/board.c is defined only if CONFIG_USB_DWC3 is defined and that is missing in am57xx_evm.h leading to the serious error. We're trying to access the IP without turning on the necessary clocks.

clocks are not turned on in board_usb_init() right? The board_usb_init() in am57xx/board.c is used only for gadget mode.

Quoted 2 lines
Quoted 2 lines

So it looks like we need to define it based on CONFIG_USB_XHCI_OMAP or something else.

right, but before that we might have to cleanup xhci-omap.

Quoted 15 lines
Quoted 6 lines

But then again looking into the future, what if we want only gadget operation? That would not define XHCI, but we still need board_usb_init(). So board_usb_init() should be defined based on CONFIG_CMD_USB=y?

What do you suggest?

But board_usb_init() calls

                ti_usb_phy_uboot_init(&usb_phy1_device);
                dwc3_omap_uboot_init(&usb_otg_ss1_glue);
                dwc3_uboot_init(&usb_otg_ss1);

which depend on CONFIG_USB_DWC3_PHY_OMAP, CONFIG_USB_DWC3_OMAP and CONFIG_USB_DWC3 respectively.

Quoted 7 lines
Quoted 4 lines

IMO we should cleanup xhci-omap so that all the initializations are done using ti_usb_phy_uboot_init, dwc3_omap_uboot_init and dwc3_uboot_init. Then modify dwc3_uboot_init to initialize host or device based on CONFIG_*.

I'm still trying to get a grip of how USB works in u-boot. Is CONFIG_CMD_USB only meant for host mode or gadget mode as well?

IIRC it is only for host. Commands like usb start, usb stop are used to start and stop host.

Quoted 2 lines

Is dual-role even required in u-boot? probably it is not a good idea and we just ignore it for simplicity.

Quoted 7 lines

yeah.

Quoted 3 lines

What determines whether a USB port is meant for Host or device operation? Is it the CONFIG_ or caller of board_usb_init()?

It should be the caller of board_usb_init(). The same port can be used as device or host based on command used (the command determines the caller of board_usb_init).

Then it is upto board_usb_init() to complain if it is called for some mode and the respective drivers are not enabled.

board_usb_init() must be defined in the board if CONFIG_CMD_USB || USB_GADGET

But there is no single config option for USB_GADGET. people seem to be calling board_usb_init() from all over the place without any dependency on USB_GADGET. e.g. dfu.c, ether.c, fastboot.c, thordown.c, usb_mass_storage.c, ether.c

So things will break with various configurations.
So probably for now board_usb_init() has to be always defined.

cheers,
-roger

#21 lore raw

PATCH 2/4 board: ti: am57xx: Fix USB configuration

In reply to Roger Quadros
Quoted 20 lines · Roger Quadros

This fixes build.

---
 include/configs/am57xx_evm.h | 3 +++
 1 file changed, 3 insertions(+)
include/configs/am57xx_evm.h +1 -0
index 32d7d4d..939057c 100644
@@ -63,6 +63,7 @@
 #define CONFIG_SUPPORT_EMMC_BOOT
 
 /* USB xHCI HOST */
+#define CONFIG_USB_DWC3
 #define CONFIG_USB_HOST
 #define CONFIG_USB_XHCI_DWC3
 #define CONFIG_USB_XHCI

include/configs/am57xx_evm.h line 77

Quoted 5 lines
include/configs/am57xx_evm.h +2 -0
@@ -72,6 +73,8 @@
 
 #define CONFIG_OMAP_USB_PHY
 #define CONFIG_OMAP_USB3PHY1_HOST
+#define CONFIG_USB_DWC3_PHY_OMAP
+#define CONFIG_USB_DWC3_OMAP

This needs to be done in the defconfig. And you're leaving other boards
broken: pcm051_rev1 and others, please do at least an am33xx build, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20160520/9866f367/attachment.sig>
#22 lore raw

PATCH 3/4 usb: dwc3: Makefile: Don't build gadget code if USB_GADGET is disabled

In reply to Roger Quadros

It is pointless to build gadget driver if USB_GADGET is disabled.

---
 drivers/usb/dwc3/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/usb/dwc3/Makefile +1 -1
index 0cd7302..2964bae 100644
@@ -6,7 +6,7 @@ obj-$(CONFIG_USB_DWC3)			+= dwc3.o
 
 dwc3-y					:= core.o
 
-dwc3-y					+= gadget.o ep0.o
+obj-$(CONFIG_USB_DWC3_GADGET)		+= gadget.o ep0.o
 
 obj-$(CONFIG_USB_DWC3_OMAP)		+= dwc3-omap.o
 obj-$(CONFIG_USB_DWC3_PHY_OMAP)		+= ti_usb_phy.o
Signature · 1 line
2.7.4
#23 lore raw

PATCH 3/4 usb: dwc3: Makefile: Don't build gadget code if USB_GADGET is disabled

Quoted 3 lines · Roger Quadros

It is pointless to build gadget driver if USB_GADGET is disabled.

Quoted 18 lines
---
 drivers/usb/dwc3/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/usb/dwc3/Makefile +1 -1
index 0cd7302..2964bae 100644
@@ -6,7 +6,7 @@ obj-$(CONFIG_USB_DWC3)			+= dwc3.o
 
 dwc3-y					:= core.o
 
-dwc3-y					+= gadget.o ep0.o
+obj-$(CONFIG_USB_DWC3_GADGET)		+= gadget.o ep0.o
 
 obj-$(CONFIG_USB_DWC3_OMAP)		+= dwc3-omap.o
 obj-$(CONFIG_USB_DWC3_PHY_OMAP)		+= ti_usb_phy.o
Signature · 2 lines
Best regards,
Marek Vasut
#24 lore raw

PATCH 3/4 usb: dwc3: Makefile: Don't build gadget code if USB_GADGET is disabled

In reply to Roger Quadros
Quoted 4 lines · Roger Quadros

It is pointless to build gadget driver if USB_GADGET is disabled.

Applied to u-boot/master, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20160530/a2542802/attachment.sig>
#25 lore raw

PATCH 4/4 usb: gadget: udc: Build on USB_GADGET

In reply to Roger Quadros

udc-core is a generic framework and not specific to dwc3. So build it based on USB_GADGET.

---
 drivers/usb/gadget/udc/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/usb/gadget/udc/Makefile +1 -1
index 1699ccd..68766c5 100644
@@ -4,4 +4,4 @@
 # SPDX-License-Identifier:	GPL-2.0+
 #
 
-obj-$(CONFIG_USB_DWC3_GADGET)	+= udc-core.o
+obj-$(CONFIG_USB_GADGET)	+= udc-core.o
Signature · 1 line
2.7.4
#26 lore raw

PATCH 4/4 usb: gadget: udc: Build on USB_GADGET

Quoted 14 lines · Roger Quadros

udc-core is a generic framework and not specific to dwc3. So build it based on USB_GADGET.

---
 drivers/usb/gadget/udc/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/usb/gadget/udc/Makefile +0 -0
index 1699ccd..68766c5 100644

drivers/usb/gadget/udc/Makefile line 7

Quoted 5 lines
drivers/usb/gadget/udc/Makefile +1 -1
@@ -4,4 +4,4 @@
 # SPDX-License-Identifier:	GPL-2.0+
 #
 
-obj-$(CONFIG_USB_DWC3_GADGET)	+= udc-core.o
+obj-$(CONFIG_USB_GADGET)	+= udc-core.o

Did you buildman this against all boards ?

Signature · 2 lines
Best regards,
Marek Vasut
#27 lore raw

PATCH 4/4 usb: gadget: udc: Build on USB_GADGET

Quoted 17 lines · Marek Vasut
Quoted 16 lines · Roger Quadros

udc-core is a generic framework and not specific to dwc3. So build it based on USB_GADGET.

---
 drivers/usb/gadget/udc/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/usb/gadget/udc/Makefile +0 -0
index 1699ccd..68766c5 100644
@@ -4,4 +4,4 @@
 # SPDX-License-Identifier:	GPL-2.0+
 #
 
Quoted 5 lines

drivers/usb/gadget/udc/Makefile line 7

Quoted 3 lines
drivers/usb/gadget/udc/Makefile +1 -1
-obj-$(CONFIG_USB_DWC3_GADGET)	+= udc-core.o
+obj-$(CONFIG_USB_GADGET)	+= udc-core.o

Did you buildman this against all boards ?

Nope, I've never used it before but I'll give it a shot.

cheers,
-roger

#28 lore raw

PATCH 4/4 usb: gadget: udc: Build on USB_GADGET

Quoted 23 lines · Roger Quadros
Quoted 17 lines · Marek Vasut
Quoted 16 lines · Roger Quadros

udc-core is a generic framework and not specific to dwc3. So build it based on USB_GADGET.

---
 drivers/usb/gadget/udc/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/usb/gadget/udc/Makefile +0 -0
index 1699ccd..68766c5 100644
@@ -4,4 +4,4 @@
 # SPDX-License-Identifier:	GPL-2.0+
 #
 
Quoted 5 lines

drivers/usb/gadget/udc/Makefile line 7

Quoted 3 lines
drivers/usb/gadget/udc/Makefile +1 -1
-obj-$(CONFIG_USB_DWC3_GADGET)	+= udc-core.o
+obj-$(CONFIG_USB_GADGET)	+= udc-core.o

Did you buildman this against all boards ?

Quoted 5 lines

Nope, I've never used it before but I'll give it a shot.

cheers,
-roger

I use this script to do my buildmanning:

# U-Boot: Quick build test
bubm()
{(

        branch=`git branch | grep '^*' | sed "s/^..//"`
        dir=/tmp/bm-$1
        arch="arm aarch64 mips powerpc nios2"
        shift 1
        ./tools/buildman/buildman -o ${dir} -b ${branch} --step=0 ${arch} $@

)}

Signature · 2 lines
Best regards,
Marek Vasut
#29 lore raw

PATCH 4/4 usb: gadget: udc: Build on USB_GADGET

Quoted 34 lines · Marek Vasut
Quoted 23 lines · Roger Quadros
Quoted 17 lines · Marek Vasut
Quoted 16 lines · Roger Quadros

udc-core is a generic framework and not specific to dwc3. So build it based on USB_GADGET.

---
 drivers/usb/gadget/udc/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/usb/gadget/udc/Makefile +0 -0
index 1699ccd..68766c5 100644
@@ -4,4 +4,4 @@
 # SPDX-License-Identifier:	GPL-2.0+
 #
 
Quoted 5 lines

drivers/usb/gadget/udc/Makefile line 7

Quoted 3 lines
drivers/usb/gadget/udc/Makefile +1 -1
-obj-$(CONFIG_USB_DWC3_GADGET)	+= udc-core.o
+obj-$(CONFIG_USB_GADGET)	+= udc-core.o

Did you buildman this against all boards ?

Quoted 5 lines

Nope, I've never used it before but I'll give it a shot.

cheers,
-roger

I use this script to do my buildmanning:

# U-Boot: Quick build test
bubm()
{(

Quoted 7 lines
        branch=`git branch | grep '^*' | sed "s/^..//"`
        dir=/tmp/bm-$1
        arch="arm aarch64 mips powerpc nios2"
        shift 1
        ./tools/buildman/buildman -o ${dir} -b ${branch} --step=0 ${arch} $@

)}

Thanks Marek.

This patch sure breaks all non DWC3 USB platforms. So let's drop this. I wasn't aware that every other gadget driver is implementing its own usb core API.

cheers,
-roger

#30 lore raw

cover am57xx: beagle-x15: get usb host working

In reply to Roger Quadros
Quoted 1 line · Roger Quadros

Hi,

Hi!

Quoted 2 lines

This series fixes dwc3 usb config issues and am57xx-evm USB configuration to get USB host ports working properly on am57xx-evm and beagle-x15.

CCing Masahiro as he also did some DWC3 work and submitted some patches.

Quoted 16 lines

--
cheers,
-roger

Roger Quadros (4):
usb: dwc3: fix kconfig
board: ti: am57xx: Fix USB configuration
usb: dwc3: Makefile: Don't build gadget code if USB_GADGET is disabled
usb: gadget: udc: Build on USB_GADGET

 drivers/usb/dwc3/Kconfig        | 9 +++++----
 drivers/usb/dwc3/Makefile       | 2 +-
 drivers/usb/gadget/udc/Makefile | 2 +-
 include/configs/am57xx_evm.h    | 3 +++
 4 files changed, 10 insertions(+), 6 deletions(-)
Signature · 2 lines
Best regards,
Marek Vasut
#31 lore raw

cover am57xx: beagle-x15: get usb host working

In reply to Roger Quadros
Quoted 4 lines · Roger Quadros

Hi,

This series fixes dwc3 usb config issues and am57xx-evm USB configuration to get USB host ports working properly on am57xx-evm and beagle-x15.

Small update. Super-Speed devices are still not working, but that is a different issue which seems to have been existed since long ago. I will debug this issue in the coming days.

cheers,
-roger

Quoted 13 lines

Roger Quadros (4):
usb: dwc3: fix kconfig
board: ti: am57xx: Fix USB configuration
usb: dwc3: Makefile: Don't build gadget code if USB_GADGET is disabled
usb: gadget: udc: Build on USB_GADGET

 drivers/usb/dwc3/Kconfig        | 9 +++++----
 drivers/usb/dwc3/Makefile       | 2 +-
 drivers/usb/gadget/udc/Makefile | 2 +-
 include/configs/am57xx_evm.h    | 3 +++
 4 files changed, 10 insertions(+), 6 deletions(-)
#32 lore raw

cover am57xx: beagle-x15: get usb host working

Quoted 8 lines · Roger Quadros
Quoted 4 lines · Roger Quadros

Hi,

This series fixes dwc3 usb config issues and am57xx-evm USB configuration to get USB host ports working properly on am57xx-evm and beagle-x15.

Small update. Super-Speed devices are still not working, but that is a different issue which seems to have been existed since long ago. I will debug this issue in the coming days.

Cool. You have a whole MW for that ;-)

Quoted 16 lines

cheers,
-roger

Quoted 13 lines

Roger Quadros (4):
usb: dwc3: fix kconfig
board: ti: am57xx: Fix USB configuration
usb: dwc3: Makefile: Don't build gadget code if USB_GADGET is disabled
usb: gadget: udc: Build on USB_GADGET

 drivers/usb/dwc3/Kconfig        | 9 +++++----
 drivers/usb/dwc3/Makefile       | 2 +-
 drivers/usb/gadget/udc/Makefile | 2 +-
 include/configs/am57xx_evm.h    | 3 +++
 4 files changed, 10 insertions(+), 6 deletions(-)
Signature · 2 lines
Best regards,
Marek Vasut
#33 lore raw

cover am57xx: beagle-x15: get usb host working

Quoted 11 lines · Marek Vasut
Quoted 8 lines · Roger Quadros
Quoted 4 lines · Roger Quadros

Hi,

This series fixes dwc3 usb config issues and am57xx-evm USB configuration to get USB host ports working properly on am57xx-evm and beagle-x15.

Small update. Super-Speed devices are still not working, but that is a different issue which seems to have been existed since long ago. I will debug this issue in the coming days.

Cool. You have a whole MW for that ;-)

Still stuck with this issue. It seems like it finds both high-speed and super-speed hubs but fails getting descriptor of the super-speed hub.

Is super-speed host known to work on any platform on u-boot? Any ideas how to debug this further? The hub chip is on the board so I can't connect a USB bus analyzer there.

cheers,
-roger

=> usb start
starting USB...
USB0: board_usb_init 0
adding phy 0 to list
dwc3_core_soft_reset
ti_usb3_phy_power 1
usb3 power up done
dwc3_set_mode 1
config1 0x7d00e
config1 0x7d00e
config1 0x7d00e
Register 2000140 NbrPorts 2
Starting the controller
USB XHCI 1.00
scanning bus 0 for devices... USB hub found
2 ports detected
individual port power switching
standalone hub
individual port over-current protection
power on to power good time: 20ms
hub controller current requirement: 0mA
port 1 is removable
port 2 is removable
get_hub_status returned status 1, change 902
local power source is lost (inactive)
no over-current condition exists
enabling power on all ports
port 1 returns 0
port 2 returns 0
pgood_delay=20ms
devnum=1 poweron: query_delay=100 connect_timeout=1100
Port 1 Status 101 Change 1
devnum=1 port=1: USB dev found
portstatus 101, change 1, 12 Mb/s
legacy_hub_port_reset: resetting port 1...
portstatus 111, change 0, 12 Mb/s
STAT_C_CONNECTION = 0 STAT_CONNECTION = 1 USB_PORT_STAT_ENABLE 0
portstatus 503, change 10, 480 Mb/s
STAT_C_CONNECTION = 0 STAT_CONNECTION = 1 USB_PORT_STAT_ENABLE 1
req=6 (0x6), type=128 (0x80), value=256 (0x100), index=0
start_trb fef56940, start_cycle 1
req->requesttype = 128, req->request = 6,le16_to_cpu(req->value) = 256,le16_to_cpu(req->index) = 0,le16_to_cpu(req->length) = 18 XHCI done. status 0x0
req=6 (0x6), type=128 (0x80), value=512 (0x200), index=0
start_trb fef56970, start_cycle 1
req->requesttype = 128, req->request = 6,le16_to_cpu(req->value) = 512,le16_to_cpu(req->index) = 0,le16_to_cpu(req->length) = 9 XHCI done. status 0x0
req=6 (0x6), type=128 (0x80), value=512 (0x200), index=0
start_trb fef569a0, start_cycle 1
req->requesttype = 128, req->request = 6,le16_to_cpu(req->value) = 512,le16_to_cpu(req->index) = 0,le16_to_cpu(req->length) = 41 XHCI done. status 0x0
req=9 (0x9), type=0 (0x0), value=1 (0x1), index=0
start_trb fef569d0, start_cycle 1
req->requesttype = 0, req->request = 9,le16_to_cpu(req->value) = 1,le16_to_cpu(req->index) = 0,le16_to_cpu(req->length) = 0 XHCI done. status 0x0
req=6 (0x6), type=128 (0x80), value=768 (0x300), index=0
start_trb fef569f0, start_cycle 1
req->requesttype = 128, req->request = 6,le16_to_cpu(req->value) = 768,le16_to_cpu(req->index) = 0,le16_to_cpu(req->length) = 255 XHCI done. status 0x0
req=6 (0x6), type=128 (0x80), value=769 (0x301), index=1033
start_trb fef56a20, start_cycle 1
req->requesttype = 128, req->request = 6,le16_to_cpu(req->value) = 769,le16_to_cpu(req->index) = 1033,le16_to_cpu(req->length) = 255 XHCI done. status 0x0
USB hub found
req=6 (0x6), type=160 (0xa0), value=10496 (0x2900), index=0
start_trb fef56a50, start_cycle 1
req->requesttype = 160, req->request = 6,le16_to_cpu(req->value) = 10496,le16_to_cpu(req->index) = 0,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
req=6 (0x6), type=160 (0xa0), value=10496 (0x2900), index=0
start_trb fef56a80, start_cycle 1
req->requesttype = 160, req->request = 6,le16_to_cpu(req->value) = 10496,le16_to_cpu(req->index) = 0,le16_to_cpu(req->length) = 9 XHCI done. status 0x0
4 ports detected
individual port power switching
standalone hub
individual port over-current protection
power on to power good time: 100ms
hub controller current requirement: 0mA
port 1 is removable
port 2 is removable
port 3 is removable
port 4 is removable
req=0 (0x0), type=160 (0xa0), value=0 (0x0), index=0
start_trb fef56ab0, start_cycle 1
req->requesttype = 160, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 0,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
get_hub_status returned status 0, change 0
local power source is good
no over-current condition exists
enabling power on all ports
req=3 (0x3), type=35 (0x23), value=8 (0x8), index=1
start_trb fef56ae0, start_cycle 1
req->requesttype = 35, req->request = 3,le16_to_cpu(req->value) = 8,le16_to_cpu(req->index) = 1,le16_to_cpu(req->length) = 0 XHCI done. status 0x0
port 1 returns 0
req=3 (0x3), type=35 (0x23), value=8 (0x8), index=2
start_trb fef56b00, start_cycle 1
req->requesttype = 35, req->request = 3,le16_to_cpu(req->value) = 8,le16_to_cpu(req->index) = 2,le16_to_cpu(req->length) = 0 XHCI done. status 0x0
port 2 returns 0
req=3 (0x3), type=35 (0x23), value=8 (0x8), index=3
start_trb fef56b20, start_cycle 1
req->requesttype = 35, req->request = 3,le16_to_cpu(req->value) = 8,le16_to_cpu(req->index) = 3,le16_to_cpu(req->length) = 0 XHCI done. status 0x0
port 3 returns 0
req=3 (0x3), type=35 (0x23), value=8 (0x8), index=4
start_trb fef56b40, start_cycle 1
req->requesttype = 35, req->request = 3,le16_to_cpu(req->value) = 8,le16_to_cpu(req->index) = 4,le16_to_cpu(req->length) = 0 XHCI done. status 0x0
port 4 returns 0
pgood_delay=100ms
devnum=2 poweron: query_delay=100 connect_timeout=1100
Port 2 Status 703 Change 1
devnum=1 port=2: USB dev found
portstatus 703, change 1, 5 Gb/s
legacy_hub_port_reset: resetting port 2...
portstatus 703, change 10, 5 Gb/s
STAT_C_CONNECTION = 0 STAT_CONNECTION = 1 USB_PORT_STAT_ENABLE 1
req=6 (0x6), type=128 (0x80), value=256 (0x100), index=0
start_trb fef587c0, start_cycle 1
req->requesttype = 128, req->request = 6,le16_to_cpu(req->value) = 256,le16_to_cpu(req->index) = 0,le16_to_cpu(req->length) = 18 XHCI done. status 0x0
req=6 (0x6), type=128 (0x80), value=512 (0x200), index=0
start_trb fef587f0, start_cycle 1
req->requesttype = 128, req->request = 6,le16_to_cpu(req->value) = 512,le16_to_cpu(req->index) = 0,le16_to_cpu(req->length) = 9 XHCI done. status 0x0
req=6 (0x6), type=128 (0x80), value=512 (0x200), index=0
start_trb fef58820, start_cycle 1
req->requesttype = 128, req->request = 6,le16_to_cpu(req->value) = 512,le16_to_cpu(req->index) = 0,le16_to_cpu(req->length) = 31 XHCI done. status 0x0
req=9 (0x9), type=0 (0x0), value=1 (0x1), index=0
start_trb fef58850, start_cycle 1
req->requesttype = 0, req->request = 9,le16_to_cpu(req->value) = 1,le16_to_cpu(req->index) = 0,le16_to_cpu(req->length) = 0 XHCI done. status 0x0

*-------interesting part-------*
USB hub found
req=6 (0x6), type=160 (0xa0), value=10496 (0x2900), index=0
start_trb fef58870, start_cycle 1
req->requesttype = 160, req->request = 6,le16_to_cpu(req->value) = 10496,le16_to_cpu(req->index) = 0,le16_to_cpu(req->length) = 4 XHCI done. status 0x2
usb_hub_configure: failed to get hub descriptor, giving up 2
hub: disabling port 2
*-------end interesting part---*

req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=1
start_trb fef56b60, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 1,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 1 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=2
start_trb fef56b90, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 2,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 2 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=3
start_trb fef56bc0, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 3,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 3 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=4
start_trb fef56bf0, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 4,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 4 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=1
start_trb fef56c20, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 1,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 1 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=2
start_trb fef56c50, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 2,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 2 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=3
start_trb fef56c80, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 3,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 3 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=4
start_trb fef56cb0, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 4,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 4 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=1
start_trb fef56ce0, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 1,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 1 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=2
start_trb fef56d10, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 2,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 2 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=3
start_trb fef56950, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 3,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 3 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=4
start_trb fef56980, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 4,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 4 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=1
start_trb fef569b0, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 1,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 1 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=2
start_trb fef569e0, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 2,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 2 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=3
start_trb fef56a10, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 3,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 3 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=4
start_trb fef56a40, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 4,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 4 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=1
start_trb fef56a70, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 1,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 1 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=2
start_trb fef56aa0, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 2,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 2 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=3
start_trb fef56ad0, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 3,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 3 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=4
start_trb fef56b00, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 4,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 4 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=1
start_trb fef56b30, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 1,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 1 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=2
start_trb fef56b60, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 2,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 2 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=3
start_trb fef56b90, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 3,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 3 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=4
start_trb fef56bc0, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 4,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 4 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=1
start_trb fef56bf0, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 1,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 1 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=2
start_trb fef56c20, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 2,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 2 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=3
start_trb fef56c50, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 3,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 3 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=4
start_trb fef56c80, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 4,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 4 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=1
start_trb fef56cb0, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 1,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 1 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=2
start_trb fef56ce0, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 2,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 2 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=3
start_trb fef56d10, start_cycle 0
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 3,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 3 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=4
start_trb fef56950, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 4,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 4 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=1
start_trb fef56980, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 1,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 1 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=2
start_trb fef569b0, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 2,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 2 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=3
start_trb fef569e0, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 3,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 3 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=4
start_trb fef56a10, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 4,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 4 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=1
start_trb fef56a40, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 1,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 1 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=2
start_trb fef56a70, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 2,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 2 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=3
start_trb fef56aa0, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 3,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 3 Status 100 Change 0
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=4
start_trb fef56ad0, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 4,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 4 Status 100 Change 0
devnum=2 port=4: timeout
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=1
start_trb fef56b00, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 1,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 1 Status 100 Change 0
devnum=2 port=1: timeout
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=2
start_trb fef56b30, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 2,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 2 Status 100 Change 0
devnum=2 port=2: timeout
req=0 (0x0), type=163 (0xa3), value=0 (0x0), index=3
start_trb fef56b60, start_cycle 1
req->requesttype = 163, req->request = 0,le16_to_cpu(req->value) = 0,le16_to_cpu(req->index) = 3,le16_to_cpu(req->length) = 4 XHCI done. status 0x0
Port 3 Status 100 Change 0
devnum=2 port=3: timeout
2 USB Device(s) found
scanning usb for storage devices... 0 Storage Device(s) found
=>