AR# 72409

|

2019.1 Zynq UltraScale+ MPSoC: Linux USB 3.0 device mode does not work

描述

In the 2019.1 release U-boot for Zynq UltraScale+ devices, USB3.0 device mode does not work when booting through USB boot mode.

For example, if you are using an Ultra96 Rev 1 board with USB boot mode it hangs without a successful boot.


Xilinx Zynq MP First Stage Boot Loader
Release 2018.3   Nov 13 2018  -  12:39:17
PMU Firmware 2018.3     Nov 13 2018   12:38:36
PMU_ROM Version: xpbr-v8.1.0-0
PMUFW:  v1.1


U-Boot 2018.01 (Nov 13 2018 - 13:49:20 +0000)

Model: Avnet Ultra96 Rev1
Board: Xilinx ZynqMP
I2C:   ready
DRAM:  2 GiB
EL Level:       EL2
Chip ID:        zu3eg
Watchdog: Not found!
MMC:   mmc@ff160000: 0 (SD), mmc@ff170000: 1
reading uboot.env

** Unable to read "uboot.env" from mmc0:1 **
Using default environment

In:    serial@ff010000
Out:   serial@ff010000
Err:   serial@ff010000
Model: Avnet Ultra96 Rev1
Board: Xilinx ZynqMP
Bootmode: USB_MODE
Net:   Net Initialization Skipped
No ethernet found.
U-BOOT for xilinx-ultra96-reva-2018_3

Hit any key to stop autoboot:  0
ZynqMP>  run dfu_ram
#DOWNLOAD ... OK
Ctrl+C to exit ...
ZynqMP> bootm
## Loading kernel from FIT Image at 10000000 ...
   Using 'conf@system-top.dtb' configuration
   Trying 'kernel@1' kernel subimage
     Description:  Linux kernel
     Type:         Kernel Image
     Compression:  gzip compressed
     Data Start:   0x10000108
     Data Size:    7128010 Bytes = 6.8 MiB
     Architecture: AArch64
     OS:           Linux
     Load Address: 0x00080000
     Entry Point:  0x00080000
     Hash algo:    sha1
     Hash value:   34f588e3ef20ba73c09a13be97193388d067bc3f
   Verifying Hash Integrity ... sha1+ OK
## Loading fdt from FIT Image at 10000000 ...
   Using 'conf@system-top.dtb' configuration
   Trying 'fdt@system-top.dtb' fdt subimage
     Description:  Flattened Device Tree blob
     Type:         Flat Device Tree
     Compression:  uncompressed
     Data Start:   0x106cc5d8
     Data Size:    40994 Bytes = 40 KiB
     Architecture: AArch64
     Hash algo:    sha1
     Hash value:   93269a8aafec5d21478c02f42f856d896db34dcc
   Verifying Hash Integrity ... sha1+ OK
   Booting using the fdt blob at 0x106cc5d8
   Uncompressing Kernel Image ... OK
   Loading Device Tree to 0000000007ff2000, end 0000000007fff021 ... OK

Starting kernel ...

[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 4.14.0-xilinx-v2018.3 (oe-user@oe-host) (gcc version 7.3.0 (GCC)) #1 SMP Mon Nov 12 14:13:59 UTC 2018
[    0.000000] Boot CPU: AArch64 Processor [410fd034]
[    0.000000] Machine model: Avnet Ultra96 Rev1
[    0.000000] earlycon: cdns0 at MMIO 0x00000000ff010000 (options '115200n8')
[    0.000000] bootconsole [cdns0] enabled
[    0.000000] efi: Getting EFI parameters from FDT:
[    0.000000] efi: UEFI not found.
[    0.000000] cma: Reserved 256 MiB at 0x000000006fc00000
[    0.000000] psci: probing for conduit method from DT.
[    0.000000] psci: PSCIv1.1 detected in firmware.
[    0.000000] psci: Using standard PSCI v0.2 function IDs
[    0.000000] psci: MIGRATE_INFO_TYPE not supported.
[    0.000000] random: fast init done
[    0.000000] percpu: Embedded 21 pages/cpu @ffffffc07fe68000 s46488 r8192 d31336 u86016
[    0.000000] Detected VIPT I-cache on CPU0
[    0.000000] CPU features: enabling workaround for ARM erratum 845719
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 512771
[    0.000000] Kernel command line: earlycon console=ttyPS0,115200 clk_ignore_unused root=/dev/mmcblk0p2 rw rootwait
[    0.000000] PID hash table entries: 4096 (order: 3, 32768 bytes)
[    0.000000] Dentry cache hash table entries: 262144 (order: 9, 2097152 bytes)
[    0.000000] Inode-cache hash table entries: 131072 (order: 8, 1048576 bytes)
[    0.000000] Memory: 1768112K/2079744K available (10172K kernel code, 666K rwdata, 3256K rodata, 512K init, 2360K bss, 49488K reserved, 262144K cma-reserved)
[    0.000000] Virtual kernel memory layout:
[    0.000000]     modules : 0xffffff8000000000 - 0xffffff8008000000   (   128 MB)
[    0.000000]     vmalloc : 0xffffff8008000000 - 0xffffffbebfff0000   (   250 GB)
[    0.000000]       .text : 0xffffff8008080000 - 0xffffff8008a70000   ( 10176 KB)
[    0.000000]     .rodata : 0xffffff8008a70000 - 0xffffff8008db0000   (  3328 KB)
[    0.000000]       .init : 0xffffff8008db0000 - 0xffffff8008e30000   (   512 KB)
[    0.000000]       .data : 0xffffff8008e30000 - 0xffffff8008ed6a00   (   667 KB)
[    0.000000]        .bss : 0xffffff8008ed6a00 - 0xffffff8009124db0   (  2361 KB)
[    0.000000]     fixed   : 0xffffffbefe7fd000 - 0xffffffbefec00000   (  4108 KB)
[    0.000000]     PCI I/O : 0xffffffbefee00000 - 0xffffffbeffe00000   (    16 MB)
[    0.000000]     vmemmap : 0xffffffbf00000000 - 0xffffffc000000000   (     4 GB maximum)
[    0.000000]               0xffffffbf00000000 - 0xffffffbf01bfc800   (    27 MB actual)
[    0.000000]     memory  : 0xffffffc000000000 - 0xffffffc07ff00000   (  2047 MB)
[    0.000000] Hierarchical RCU implementation.
[    0.000000]  RCU event tracing is enabled.
[    0.000000]  RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=4.
[    0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=4
[    0.000000] NR_IRQS: 64, nr_irqs: 64, preallocated irqs: 0
[    0.000000] GIC: Adjusting CPU interface base to 0x00000000f902f000
[    0.000000] GIC: Using split EOI/Deactivate mode
[    0.000000] arch_timer: cp15 timer(s) running at 99.99MHz (phys).
[    0.000000] clocksource: arch_sys_counter: mask: 0xffffffffffffff max_cycles: 0x17102373f5, max_idle_ns: 440795203772 ns
[    0.000004] sched_clock: 56 bits at 99MHz, resolution 10ns, wraps every 4398046511100ns
[    0.008344] Console: colour dummy device 80x25
[    0.012393] Calibrating delay loop (skipped), value calculated using timer frequency.. 199.99 BogoMIPS (lpj=399999)
[    0.022754] pid_max: default: 32768 minimum: 301
[    0.027447] Mount-cache hash table entries: 4096 (order: 3, 32768 bytes)
[    0.034008] Mountpoint-cache hash table entries: 4096 (order: 3, 32768 bytes)
[    0.041825] ASID allocator initialised with 65536 entries
[    0.046506] Hierarchical SRCU implementation.
[    0.051126] EFI services will not be available.
[    0.055299] zynqmp_plat_init Platform Management API v1.1
[    0.060641] zynqmp_plat_init Trustzone version v1.0
[    0.065590] smp: Bringing up secondary CPUs ...
[    0.070258] Detected VIPT I-cache on CPU1
[    0.070295] CPU1: Booted secondary processor [410fd034]
[    0.070593] Detected VIPT I-cache on CPU2
[    0.070612] CPU2: Booted secondary processor [410fd034]
[    0.070891] Detected VIPT I-cache on CPU3
[    0.070909] CPU3: Booted secondary processor [410fd034]
[    0.070952] smp: Brought up 1 node, 4 CPUs
[    0.101554] SMP: Total of 4 processors activated.
[    0.106228] CPU features: detected feature: 32-bit EL0 Support
[    0.112026] CPU: All CPU(s) started at EL2
[    0.116098] alternatives: patching kernel code
[    0.121225] devtmpfs: initialized
[    0.128470] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 7645041785100000 ns
[    0.133488] futex hash table entries: 1024 (order: 5, 131072 bytes)
[    0.145831] xor: measuring software checksum speed
[    0.183802]    8regs     :  2303.000 MB/sec
[    0.223831]    8regs_prefetch:  2053.000 MB/sec
[    0.263861]    32regs    :  2830.000 MB/sec
[    0.303892]    32regs_prefetch:  2379.000 MB/sec
[    0.303924] xor: using function: 32regs (2830.000 MB/sec)
[    0.308317] pinctrl core: initialized pinctrl subsystem
[    0.314085] NET: Registered protocol family 16
[    0.318552] cpuidle: using governor menu
[    0.322320] vdso: 2 pages (1 code @ ffffff8008a76000, 1 data @ ffffff8008e34000)
[    0.329085] hw-breakpoint: found 6 breakpoint and 4 watchpoint registers.
[    0.336438] DMA: preallocated 256 KiB pool for atomic allocations
[    0.363603] reset_zynqmp reset-controller: Xilinx zynqmp reset driver probed
[    0.365577] ARM CCI_400_r1 PMU driver probed
[    0.370166] zynqmp-pinctrl ff180000.pinctrl: zynqmp pinctrl initialized
[    0.385865] HugeTLB registered 2.00 MiB page size, pre-allocated 0 pages
[    0.453648] raid6: int64x1  gen()   402 MB/s
[    0.521642] raid6: int64x1  xor()   445 MB/s
[    0.589686] raid6: int64x2  gen()   689 MB/s
[    0.657724] raid6: int64x2  xor()   602 MB/s
[    0.725783] raid6: int64x4  gen()  1042 MB/s
[    0.793845] raid6: int64x4  xor()   739 MB/s
[    0.861918] raid6: int64x8  gen()   980 MB/s
[    0.929939] raid6: int64x8  xor()   737 MB/s
[    0.997977] raid6: neonx1   gen()   726 MB/s
[    1.066039] raid6: neonx1   xor()   854 MB/s
[    1.134097] raid6: neonx2   gen()  1168 MB/s
[    1.202134] raid6: neonx2   xor()  1202 MB/s
[    1.270197] raid6: neonx4   gen()  1502 MB/s
[    1.338219] raid6: neonx4   xor()  1437 MB/s
[    1.406267] raid6: neonx8   gen()  1649 MB/s
[    1.474322] raid6: neonx8   xor()  1525 MB/s
[    1.474351] raid6: using algorithm neonx8 gen() 1649 MB/s
[    1.478315] raid6: .... xor() 1525 MB/s, rmw enabled
[    1.483245] raid6: using neon recovery algorithm
[    1.489188] SCSI subsystem initialized
[    1.491752] usbcore: registered new interface driver usbfs
[    1.497032] usbcore: registered new interface driver hub
[    1.502313] usbcore: registered new device driver usb
[    1.507361] media: Linux media interface: v0.10
[    1.511812] Linux video capture interface: v2.00
[    1.516414] pps_core: LinuxPPS API ver. 1 registered
[    1.521305] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[    1.530399] PTP clock support registered
[    1.534297] EDAC MC: Ver: 3.0.0
[    1.537860] zynqmp-ipi ff9905c0.mailbox: Probed ZynqMP IPI Mailbox driver.
[    1.544456] FPGA manager framework
[    1.547729] fpga-region fpga-full: FPGA Region probed
[    1.552780] Advanced Linux Sound Architecture Driver Initialized.
[    1.558977] Bluetooth: Core ver 2.22
[    1.562238] NET: Registered protocol family 31
[    1.566633] Bluetooth: HCI device and connection manager initialized
[    1.572950] Bluetooth: HCI socket layer initialized
[    1.577792] Bluetooth: L2CAP socket layer initialized
[    1.582827] Bluetooth: SCO socket layer initialized
[    1.588293] clocksource: Switched to clocksource arch_sys_counter
[    1.593801] VFS: Disk quotas dquot_6.6.0
[    1.597648] VFS: Dquot-cache hash table entries: 512 (order 0, 4096 bytes)
[    1.608644] NET: Registered protocol family 2
[    1.609104] TCP established hash table entries: 16384 (order: 5, 131072 bytes)
[    1.616044] TCP bind hash table entries: 16384 (order: 6, 262144 bytes)
[    1.622835] TCP: Hash tables configured (established 16384 bind 16384)
[    1.629097] UDP hash table entries: 1024 (order: 3, 32768 bytes)
[    1.635002] UDP-Lite hash table entries: 1024 (order: 3, 32768 bytes)
[    1.641503] NET: Registered protocol family 1
[    1.645916] RPC: Registered named UNIX socket transport module.
[    1.651580] RPC: Registered udp transport module.
[    1.656247] RPC: Registered tcp transport module.
[    1.660917] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    1.667908] hw perfevents: no interrupt-affinity property for /pmu, guessing.
[    1.674794] hw perfevents: enabled with armv8_pmuv3 PMU driver, 7 counters available
[    1.682904] audit: initializing netlink subsys (disabled)
[    1.687548] audit: type=2000 audit(1.632:1): state=initialized audit_enabled=0 res=1
[    1.687898] workingset: timestamp_bits=62 max_order=19 bucket_order=0
[    1.702305] NFS: Registering the id_resolver key type
[    1.706620] Key type id_resolver registered
[    1.710741] Key type id_legacy registered
[    1.714727] nfs4filelayout_init: NFSv4 File Layout Driver Registering...
[    1.721397] jffs2: version 2.2. (NAND) 2001-2006 Red Hat, Inc.
[    1.750992] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 247)
[    1.752743] io scheduler noop registered
[    1.756631] io scheduler deadline registered
[    1.760881] io scheduler cfq registered (default)
[    1.765540] io scheduler mq-deadline registered
[    1.770037] io scheduler kyber registered
[    1.775562] xilinx-dpdma fd4c0000.dma: Xilinx DPDMA engine is probed
[    1.780745] xilinx-zynqmp-dma fd500000.dma: ZynqMP DMA driver Probe success
[    1.787406] xilinx-zynqmp-dma fd510000.dma: ZynqMP DMA driver Probe success
[    1.794325] xilinx-zynqmp-dma fd520000.dma: ZynqMP DMA driver Probe success
[    1.801243] xilinx-zynqmp-dma fd530000.dma: ZynqMP DMA driver Probe success
[    1.808160] xilinx-zynqmp-dma fd540000.dma: ZynqMP DMA driver Probe success
[    1.815076] xilinx-zynqmp-dma fd550000.dma: ZynqMP DMA driver Probe success
[    1.822002] xilinx-zynqmp-dma fd560000.dma: ZynqMP DMA driver Probe success
[    1.828928] xilinx-zynqmp-dma fd570000.dma: ZynqMP DMA driver Probe success
[    1.835913] xilinx-zynqmp-dma ffa80000.dma: ZynqMP DMA driver Probe success
[    1.842763] xilinx-zynqmp-dma ffa90000.dma: ZynqMP DMA driver Probe success
[    1.849678] xilinx-zynqmp-dma ffaa0000.dma: ZynqMP DMA driver Probe success
[    1.856600] xilinx-zynqmp-dma ffab0000.dma: ZynqMP DMA driver Probe success
[    1.863519] xilinx-zynqmp-dma ffac0000.dma: ZynqMP DMA driver Probe success
[    1.870441] xilinx-zynqmp-dma ffad0000.dma: ZynqMP DMA driver Probe success
[    1.877369] xilinx-zynqmp-dma ffae0000.dma: ZynqMP DMA driver Probe success
[    1.884293] xilinx-zynqmp-dma ffaf0000.dma: ZynqMP DMA driver Probe success
[    1.891320] xilinx-frmbuf 80020000.v_frmbuf_wr: Probe deferred due to GPIO reset defer
[    1.926283] Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
[    1.928738] 80060000.serial: ttyS2 at MMIO 0x80061000 (irq = 46, base_baud = 6249993) is a 16550A
[

解决方案

To fix this issue, you will need to apply the attached patch:

The patch should be applied to <plnx-proj-root>/project-spec/meta-user/recipes-bsp/u-boot/u-boot-xlnx_%.bbappend

Note: To apply a patch to recipes, please refer to (UG1144) or https://xilinx-wiki.atlassian.net/wiki/spaces/A/pages/18842475/PetaLinux+Yocto+Tips

1) Copy the attached patch to the u-boot directory as show below.

$ cp 0001-usb-composite-add-BOS-descriptor-support-to-composit.patch <plnx-proj-root>/project-spec/meta-user/recipes-bsp/u-boot/files
$ cp 0001-drivers-usb-dwc3-setup-phy-before-dwc3-core-soft-res.patch <plnx-proj-root>/project-spec/meta-user/recipes-bsp/u-boot/files

2) Modify the u-boot-xlnx_%.bbappend file with the below content.

$ vim <plnx-proj-root>/project-spec/meta-user/recipes-bsp/u-boot/u-boot-xlnx_%.bbappend
# u-boot-xlnx_%.bbappend content 

SRC_URI_append = " file://platform-top.h"

SRC_URI += " \
    file://bsp.cfg \
    file://0001-usb-composite-add-BOS-descriptor-support-to-composit.patch \
    file://0001-drivers-usb-dwc3-setup-phy-before-dwc3-core-soft-res.patch \

"

FILESEXTRAPATHS_prepend := "${THISDIR}/files:"


3) Clean the u-boot sstate cache and rebuild the u-boot.

$ petalinux-build -c u-boot-xlnx -x cleansstate
$ petalinux-build -c u-boot-xlnx

附件

AR# 72409
日期 06/04/2019
状态 Active
Type 综合文章
器件
Tools
Boards & Kits
People Also Viewed