uboot usb initial failed on fastboot

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

uboot usb initial failed on fastboot

6,059 Views
Justin_Yeh
Contributor I

Hi all 

We hit "No USB device found" at uuu downloading, it looks SPL initial USB success, but usb_gadget_initialize() got failure in do_fastboot_usb(), please help, Thanks.

---------------------------------

U-Boot SPL 2020.04-5.4.47-2.2.0+geb4fb30 (Dec 10 2020 - 01:09:29 +0000)
power_bd71837_init
DDRINFO: start DRAM init
DDRINFO: DRAM rate 1600MTS
DDRINFO:ddrphy calibration done
DDRINFO: ddrmix config done
Normal Boot
Trying to boot from USB SDP
SDP: initialize...
SDP: handle requests...
Downloading file of size 3299584 to 0x40400000... done
Jumping to header at 0x40400000
Header Tag is not an IMX image
Found header at 0x404339a0
NOTICE: BL31: v2.2(release):rel_imx_5.4.47_2.2.0-0-gc949a88
NOTICE: BL31: Built : 02:08:35, Dec 10 2020


U-Boot 2020.04-5.4.47-2.2.0+geb4fb30 (Dec 10 2020 - 01:09:29 +0000)

CPU: i.MX8MMQ rev1.0 1800 MHz (running at 1200 MHz)
CPU: Commercial temperature grade (0C to 95C) at 36C
Reset cause: POR
Model: NXP i.MX8MM DDR3L Validation board
DRAM: 2 GiB
NAND: 0 MiB
MMC: FSL_SDHC: 1
Loading Environment from MMC... Card did not respond to voltage select!
*** Warning - No block device, using default environment

In: serial
Out: serial
Err: serial

BuildInfo:
- ATF c949a88
- U-Boot 2020.04-5.4.47-2.2.0+geb4fb30

Card did not respond to voltage select!
Detect USB boot. Will enter fastboot mode!
Net: Could not get PHY for FEC0: addr 3
Could not get PHY for FEC0: addr 3
No ethernet found.

Fastboot: Normal
Boot from USB for mfgtools
*** Warning - Use default environment for mfgtool s
, using default environment

Run bootcmd_mfg: run mfgtool_args;if iminfo ${initrd_addr}; then if test ${tee}
= yes; then bootm ${tee_addr} ${initrd_addr} ${fdt_addr}; else booti ${loadaddr} ${initrd_addr} ${fdt_addr}; fi; else echo "Run fastboot ..."; fastboot 0; fi;
Hit any key to stop autoboot: 0

## Checking Image at 43800000 ...
Unknown image format!
Run fastboot ...
No USB device found
USB init failed: -19
u-boot=>

0 Kudos
20 Replies

6,026 Views
WoodyCheng
Contributor II

Hi Weidong,

We are using imx8mm in our project.

But we cannot find any USB driver has "compatible = "fsl,imx8mm-usb",". 

It seems the codebase lacks some USB driver source code files.

The uboot branch we used is "imx_v2020.04_5.4.47_2.2.0".

Could you help to check it?

Thanks.

 

0 Kudos

6,020 Views
weidong_sun
NXP TechSupport
NXP TechSupport

Hi woody,

    I sent my schematic to your personal email, for you reference.

   The BSP I used is L5.4.24, which is valuable for you reference.

   check it, please!

Have a nice day!

B.R,

Weidong

0 Kudos

6,014 Views
WoodyCheng
Contributor II

Hi Weidong, 

Could you please help to check if we lack some USB driver source code files in our codebase?

Thanks.

 

0 Kudos

6,044 Views
Justin_Yeh
Contributor I

Hi Weidong

For imx8mm-ddr3l-val.dts, default without extcon = <&ptn5110>; Do you have any idea ? Thanks. 

&usbotg1 {
dr_mode = "host";
status = "okay";
};

&usbotg2 {
dr_mode = "peripheral";
status = "okay";
};

0 Kudos

6,032 Views
weidong_sun
NXP TechSupport
NXP TechSupport

On hardware:

1. USB1---Host

GPIO1_IO10(USB1_OTG_ID) should be pulled down to LOW via 2.2K/3.3K reisgtor. USB1_ID can be left floating.

2. USB2: device mode

GPIO1_IO11(USB2_OTG_ID) should be pulled up to High (via 4.7K resistor to 1.8V). USB2_ID can be left floating.

 

For software ( in device tree)

See last post, chage USB1 to USB2 node.

 

have a  nice day!

B.R,

weidong

 

0 Kudos

6,010 Views
Justin_Yeh
Contributor I

Hi Weidong

I try to pull high GPIO1_IO10(USB1_OTG_ID), but USB still not found. 

---------------------------------

## Checking Image at 43800000 ...
Unknown image format!
Run fastboot ...
No USB device found
USB init failed: -19

---------------------------------

0 Kudos

6,003 Views
weidong_sun
NXP TechSupport
NXP TechSupport

your USB1 is Host. AND USB2 is device, so you should use USB2 to download image.

0 Kudos

2,285 Views
venu_mos
Contributor II

iam also getting the same issue when i use fastboot on my board can i get any help ?

board: phyboard pollux

soc: imx8mp 

whenever i use fastboot command in uboot shell it gives error USB init failed NO usb device found

any help would be apprreciated.

 

Thanks 

 

@weidong_sun 

Venu 

0 Kudos

2,274 Views
weidong_sun
NXP TechSupport
NXP TechSupport
please re-create a case in our system(SFDC) or post on community! Then my colleagues of MPU team will handle it for you.

Thanks!
Regards,
weidong
0 Kudos

5,995 Views
Justin_Yeh
Contributor I

Hi Weidong

The usb1 for downloading, I changed imx8mm-ddr3l-val.dts, but still got failed. 

diff --git a/workdir/uboot-imx/arch/arm/dts/imx8mm-ddr3l-val.dts b/workdir/uboot-imx/arch/arm/dts/imx8mm-ddr3l-val.dts
index 2496513..a90bdc3 100644
--- a/workdir/uboot-imx/arch/arm/dts/imx8mm-ddr3l-val.dts
+++ b/workdir/uboot-imx/arch/arm/dts/imx8mm-ddr3l-val.dts
@@ -360,12 +360,12 @@
};

&usbotg1 {
- dr_mode = "host";
+ dr_mode = "peripheral";
status = "okay";
};

&usbotg2 {
- dr_mode = "peripheral";
+ dr_mode = "host";
status = "okay";
};

---------------------------------------------

## Checking Image at 43800000 ...
Unknown image format!
Run fastboot ...
No USB device found
USB init failed: -19

0 Kudos

5,989 Views
weidong_sun
NXP TechSupport
NXP TechSupport

Hi,

Have you seen my previous post?

-u-boot : imx8mm-evk.dts

weidong_sun_0-1607931221990.png

-kernel : imx8mm-evk.dts

weidong_sun_1-1607931393484.png

weidong

0 Kudos

5,986 Views
Justin_Yeh
Contributor I

Hi Weidong

Due to our MACHINE=imx8mmddr3lval, so I modify the imx8mm-ddr3l-val.dts. 

0 Kudos

5,984 Views
weidong_sun
NXP TechSupport
NXP TechSupport

yes, right.

0 Kudos

5,982 Views
Justin_Yeh
Contributor I

Do you mean dr_mode is not necessary ? 

0 Kudos

5,977 Views
Justin_Yeh
Contributor I

I pulled high the GPIO1_IO10 and modify the dts. usb still not found...

------------------------------------------------------

diff --git a/workdir/uboot-imx/arch/arm/dts/imx8mm-ddr3l-val.dts b/workdir/uboot-imx/arch/arm/dts/imx8mm-ddr3l-val.dts
index 2496513..db9480a 100644
--- a/workdir/uboot-imx/arch/arm/dts/imx8mm-ddr3l-val.dts
+++ b/workdir/uboot-imx/arch/arm/dts/imx8mm-ddr3l-val.dts
@@ -4,7 +4,6 @@
*/

/dts-v1/;
-
#include "imx8mm.dtsi"

/ {
@@ -360,12 +359,12 @@
};

&usbotg1 {
- dr_mode = "host";
+ /*dr_mode = "peripheral";*/
status = "okay";
};

&usbotg2 {
- dr_mode = "peripheral";
+ /*dr_mode = "host";*/
status = "okay";
};

 

 

0 Kudos

5,980 Views
weidong_sun
NXP TechSupport
NXP TechSupport

I designed a board based on i.mx8mm, and the code I gave is what I used. it is no problem.

I have sent my schematic of usb to woody, @WoodyCheng , did you recieve it? if yes, send it to justin, please!

 

B.R,

Weidong

0 Kudos

6,004 Views
Justin_Yeh
Contributor I

Hi Weidong

Following is my usb info form uboot, any useful information to you ? 

u-boot=> usb info
1: Hub, USB Revision 2.0
- u-boot EHCI Host Controller
- Class: Hub
- PacketSize: 64 Configurations: 1
- Vendor: 0x0000 Product 0x0000 Version 1.0
Configuration: 1
- Interfaces: 1 Self Powered 0mA
Interface: 0
- Alternate Setting 0, Endpoints: 1
- Class Hub
- Endpoint 1 In Interrupt MaxPacket 8 Interval 255ms

 

0 Kudos

6,026 Views
Justin_Yeh
Contributor I

if we'd want to set two usb ports are device mode, 

we should pull high GPIO1_IO10 and GPIO1_IO11 both, right ? Thanks. 

Tags (1)
0 Kudos

5,975 Views
weidong_sun
NXP TechSupport
NXP TechSupport

yes , pull USBx_OTG_ID up to High, please!

0 Kudos

6,054 Views
weidong_sun
NXP TechSupport
NXP TechSupport

Hi,

   if there is no PD chip for USB type-c, and only use USB OTG (or device) mode. modify dts in u-boot and kernel.

---u-boot

&usbotg1 {
status = "okay";
/*extcon = <&ptn5110>;*/
};

 

--Kernel.

&usbotg1 {
dr_mode = "otg";
/* hnp-disable;
srp-disable;
adp-disable;
usb-role-switch;
*/
picophy,pre-emp-curr-control = <3>;
picophy,dc-vol-level-adjust = <7>;
status = "okay";
/*
port {
usb1_drd_sw: endpoint {
remote-endpoint = <&typec1_dr_sw>;
};
};
*/
};

 

Try it, please!

Have a nice day!

B.R,

Weidong

0 Kudos