This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM6442: u-boot crash upon loading USB driver

Part Number: AM6442
Other Parts Discussed in Thread: SK-AM64B

Tool/software:

Dear TI,

I'm porting u-boot to our custom HW and am modifying the am64x_gpevm DT for this purpose. My custom board has features from both EVM and SK devkits. We reuse the USB3.0 HOST mode from the SK board.

I'm stuck with a crash of the USB driver upon loading the u-boot SPL onto the A53 :

U-Boot 2024.04-svn18 (Sep 23 2024 - 10:04:03 +0200)

SoC:   AM64X SR2.0 HS-FS
Model: Texas Instruments AM642 EVM
[checkboard]
[do_board_detect]
Board: AM64-HSEVM rev
DRAM:  2 GiB
[board_init]
Core:  87 devices, 30 uclasses, devicetree: separate
NAND:  0 MiB
MMC:   mmc@fa10000: 0
Loading Environment from nowhere... OK
In:    serial@2800000
Out:   serial@2800000
Err:   serial@2800000
Failed to probe prueth driver
[board_late_init]
[setup_board_eeprom_env]
[do_board_detect]
[setup_board_eeprom_env]: am64x_gpevm
[setup_board_eeprom_env]
[setup_serial]
[init_daughtercard_det_gpio]
Failed to lookup gpio gpio@38_0: -22
Net:   eth0: ethernet@8000000port@1
Warning: ethernet@8000000port@2 (eth1) using random MAC address - 2e:1b:bd:6a:80:21
, eth1: ethernet@8000000port@2
Hit any key to stop autoboot:  0
MMC Device 1 not found
no mmc device at slot 1
** Bad device specification mmc 1 **
** Bad device specification mmc 1 **
Couldn't find partition mmc 1:2
Can't set block device
** Bad device specification mmc 1 **
Couldn't find partition mmc 1:2
Can't set block device
libfdt fdt_check_header(): FDT_ERR_BADMAGIC
No FDT memory address configured. Please configure
the FDT address via "fdt addr <address>" command.
Aborting!
Bad Linux ARM64 Image magic!
Scanning for bootflows in all bootdevs
Seq  Method       State   Uclass    Part  Name                      Filename
---  -----------  ------  --------  ----  ------------------------  ----------------
Scanning global bootmeth 'efi_mgr':
No EFI system partition
No EFI system partition
Failed to persist EFI variables
No EFI system partition
Failed to persist EFI variables
No EFI system partition
Failed to persist EFI variables
  0  efi_mgr      ready   (none)       0  <NULL>
** Booting bootflow '<NULL>' with efi_mgr
Loading Boot0000 'mmc 0' failed
EFI boot manager: Cannot load any image
Boot failed (err=-14)
Scanning bootdev 'mmc@fa10000.bootdev':
Bus usb@f400000: 02000000011a0000616d3634780000000000000048534653000002000000020002a6000000000000b018658ad99dc903c8c9bfb27b12751099920a042ad1dfea7b7ba57369f15546de285edde6a7b39a8bdc40a27b237f8fb1e57f245e80b929c1e28b024aa2ecc6ad0bc40b0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002be4ad95a01570beb1d27642b15943d3916611e7c74eaed12a2cc0d202505da9CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC

My device tree has following additions for the USB (for now I focus on USB2.0) :

        };

+       main_usb0_pins_default: main-usb0-default-pins {
+               bootph-all;
+               pinctrl-single,pins = <
+                       AM64X_IOPAD(0x02a8, PIN_OUTPUT, 0) /* (E19) USB0_DRVVBUS */
+               >;
+       };
+
        ospi0_pins_default: ospi0-default-pins {
                pinctrl-single,pins = <
                        AM64X_IOPAD(0x0000, PIN_OUTPUT, 0) /* (N20) OSPI0_CLK */
@@ -350,6 +357,20 @@
        disable-wp;
 };

+&usbss0 {
+       bootph-all;
+       u-boot,dm-spl;
+};
+
+&usb0 {
+       bootph-all;
+       dr_mode = "host";
+       u-boot,dm-spl;
+       maximum-speed = "high-speed";
+       pinctrl-names = "default";
+       pinctrl-0 = <&main_usb0_pins_default>;
+};
+

Any help is appreciated!

  • Hi,

    Could you share the changes in the form of a diff/patch file.

    Regards,
    Aparna

  • Hi, attached the original and modified DT files (based from EVM board), as well as patch file

    8750.diff.zip

  • Hi Marc,

    - Which Processor SDK version do you use?

    - It seems the board boots from eMMC? If so, which interface is used to flash the U-Boot binaries to eMMC?

    - Please provide the entire console boot log.

  • Hi,

    - I'm on 'ti-processor-sdk-linux-am64xx-evm-10.00.07.04',

    - I'm currently booting uboot from UAR0, so in UART bootmode, the eMMC is on MMC0 interface,

    I'm sending my latest log; where the USB is disabled (to get over the crash/reboot).

    devel@hc3ubuntu:~/SVN/LINUXDCS/branches$ sudo ./loaddcs.sh
    
    =================================================
    
    -------------------------------------------------
    Sending ./ti-processor-sdk-linux/board-support/u-boot-build/r5/tiboot3.bin, 4832 blocks: Give your local XMODEM receive command now.
    Bytes Sent: 618624   BPS:10002
    
    Transfer complete
    
    -------------------------------------------------
    Sending ./ti-processor-sdk-linux/board-support/u-boot-build/r5/tiboot3.bin, 4832 blocks: Give your local XMODEM receive command now.
    Bytes Sent: 618624   BPS:9988
    
    Transfer complete
    
    U-Boot SPL 2024.04-dirty (Sep 24 2024 - 14:32:59 +0200)
    SYSFW ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
    [board_init_f]
    [do_dt_magic]
    [do_board_detect]
    DM_I2C
    probe ok
    header 0xffffffff
    rc 0
    rc 0
    rc 0
    Read board magic 0xffffffff and ID 0xff
    Next
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    [do_dt_magic] fdt resetup
    [fdtdec_resetup]
    [locate_dtb_in_fit]
    [fdt_offset]
    [fit_find_config_node]
    [board_fit_config_name_match]
    [board_fit_config_name_match]: k3-am642-evm
    Selecting config 'k3-am642-r5-evm'
    [fdtdec_resetup]: no change
    [k3_ddrss_probe]
    [k3_ddrss_power_on]
    [spl_relocate_stack_gd]
    [spl_relocate_stack_check]
    SPL initial stack usage: 13392 bytes
    [board_init_r]
    [spl_board_init]
    [init_daughtercard_det_gpio]
    Failed to lookup gpio gpio@38_0: -22
    Trying to boot from UART
    C
    -------------------------------------------------
    Sending: tispl.bin
    Bytes Sent:1023488   BPS:9809
    Sending:
    Ymodem sectors/kbytes sent:   0/ 0k
    Transfer complete
    Loaded 1023395 bytes
    Loading Environment from MMC... *** Warning - No MMC card found, using default environment
    
    init_env from device 7 not supported!
    Starting ATF on ARM64 core...
    
    NOTICE:  BL31: v2.10.0(release):v2.10.0-367-g00f1ec6b87-dirty
    NOTICE:  BL31: Built : 16:09:05, Feb  9 2024
    I/TC:
    I/TC: OP-TEE version: 4.2.0-dev (gcc version 13.3.0 (GCC)) #1 Fri Apr 12 09:51:21 UTC 2024 aarch64
    I/TC: WARNING: This OP-TEE configuration might be insecure!
    I/TC: WARNING: Please check https://optee.readthedocs.io/en/latest/architecture/porting_guidelines.html
    I/TC: Primary CPU initializing
    I/TC: GIC redistributor base address not provided
    I/TC: Assuming default GIC group status and modifier
    I/TC: SYSFW ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
    I/TC: HUK Initialized
    I/TC: Activated SA2UL device
    I/TC: Enabled firewalls for SA2UL TRNG device
    I/TC: SA2UL TRNG initialized
    I/TC: SA2UL Drivers initialized
    I/TC: Primary CPU switching to normal world boot
    
    U-Boot SPL 2024.04-dirty (Sep 24 2024 - 14:45:06 +0200)
    SYSFW ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
    [board_init_f]
    [do_dt_magic]
    [do_board_detect]
    [spl_relocate_stack_gd]
    [board_init_r]
    [spl_board_init]
    [init_daughtercard_det_gpio]
    Failed to lookup gpio gpio@38_0: -22
    Trying to boot from UART
    C
    -------------------------------------------------
    Sending: u-boot-dtb.img
    Ymodem sectors/kbytes sent:  16/ 2kRetry 0: Got 5b for sector ACK
    Retry 0: NAK on sector
    Ymodem sectors/kbytes sent: 9408/1176kRetry 0: Got 57 for sector ACK
    Retry 0: NAK on sector
    Ymodem sectors/kbytes sent: 9944/1243kRetry 0: Got 57 for sector ACK
    Retry 0: NAK on sector
    Bytes Sent:1344000   BPS:8931
    Sending:
    Ymodem sectors/kbytes sent:   0/ 0k
    Transfer complete
    Loaded 1343972 bytes
    [display_options]
    
    
    U-Boot 2024.04-dirty (Sep 24 2024 - 14:45:06 +0200)
    
    SoC:   AM64X SR2.0 HS-FS
    Model: Texas Instruments AM642 EVM
    [checkboard]
    [do_board_detect]
    Board: AM64-HSEVM rev
    DRAM:  2 GiB
    cdns3_bind: unsupported dr_mode
    [board_init]
    Core:  85 devices, 29 uclasses, devicetree: separate
    NAND:  0 MiB
    MMC:   mmc@fa10000: 0
    Loading Environment from nowhere... OK
    In:    serial@2800000
    Out:   serial@2800000
    Err:   serial@2800000
    Failed to probe prueth driver
    [board_late_init]
    [setup_board_eeprom_env]
    [do_board_detect]
    [setup_board_eeprom_env]: am64x_gpevm
    [setup_board_eeprom_env]
    [setup_serial]
    [init_daughtercard_det_gpio]
    Failed to lookup gpio gpio@38_0: -22
    Net:   eth0: ethernet@8000000port@1
    Warning: ethernet@8000000port@2 (eth1) using random MAC address - 1a:27:84:21:be:ed
    , eth1: ethernet@8000000port@2
    Hit any key to stop autoboot:  0
    MMC Device 1 not found
    no mmc device at slot 1
    ** Bad device specification mmc 1 **
    ** Bad device specification mmc 1 **
    Couldn't find partition mmc 1:2
    Can't set block device
    ** Bad device specification mmc 1 **
    Couldn't find partition mmc 1:2
    Can't set block device
    libfdt fdt_check_header(): FDT_ERR_TRUNCATED
    No FDT memory address configured. Please configure
    the FDT address via "fdt addr <address>" command.
    Aborting!
    Bad Linux ARM64 Image magic!
    Scanning for bootflows in all bootdevs
    Seq  Method       State   Uclass    Part  Name                      Filename
    ---  -----------  ------  --------  ----  ------------------------  ----------------
    Scanning global bootmeth 'efi_mgr':
    No EFI system partition
    No EFI system partition
    Failed to persist EFI variables
    No EFI system partition
    Failed to persist EFI variables
    No EFI system partition
    Failed to persist EFI variables
      0  efi_mgr      ready   (none)       0  <NULL>
    ** Booting bootflow '<NULL>' with efi_mgr
    Loading Boot0000 'mmc 0' failed
    EFI boot manager: Cannot load any image
    Boot failed (err=-14)
    Scanning bootdev 'mmc@fa10000.bootdev':
    No working controllers found
    ethernet@8000000port@1 Waiting for PHY auto negotiation to complete... done
    link up on port 1, speed 1000, full duplex
    BOOTP broadcast 1
    BOOTP broadcast 2
    DHCP client bound to address 192.168.40.160 (255 ms)
    Scanning bootdev 'port@1.bootdev':
    missing environment variable: pxeuuid
    Retrieving file: pxelinux.cfg/01-28-b5-e8-cf-e8-2e
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C0A828A0
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C0A828A
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C0A828
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C0A82
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C0A8
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C0A
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C0
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/default-arm-k3-am64x
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/default-arm-k3
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/default-arm
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/default
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Scanning bootdev 'port@2.bootdev':
    missing environment variable: pxeuuid
    Retrieving file: pxelinux.cfg/01-28-b5-e8-cf-e8-2e
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C0A828A0
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C0A828A
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C0A828
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C0A82
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C0A8
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C0A
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C0
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/C
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/default-arm-k3-am64x
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/default-arm-k3
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/default-arm
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Retrieving file: pxelinux.cfg/default
    link up on port 1, speed 1000, full duplex
    *** ERROR: `serverip' not set
    Scanning bootdev 'port@1.bootdev':
    link up on port 1, speed 1000, full duplex
    BOOTP broadcast 1
    DHCP client bound to address 192.168.40.160 (3 ms)
    *** ERROR: `serverip' not set
    Cannot autoload with TFTPGET
    Scanning bootdev 'port@2.bootdev':
    link up on port 1, speed 1000, full duplex
    BOOTP broadcast 1
    DHCP client bound to address 192.168.40.160 (3 ms)
    *** ERROR: `serverip' not set
    Cannot autoload with TFTPGET
    No more bootdevs
    ---  -----------  ------  --------  ----  ------------------------  ----------------
    (1 bootflow, 1 valid)
    => mmc part
    ## Unknown partition table type 0
    => printenv partitions
    partitions=name=rootfs,start=0,size=-,uuid=${uuid_gpt_rootfs}
    => setenv uuid_disk ${uuid_gpt_disk};name=rootfs,start=2MiB,size=-,uuid=${uuid_gpt_rootfs}
    => printenv partitions
    partitions=name=rootfs,start=0,size=-,uuid=${uuid_gpt_rootfs}
    => setenv partitions uuid_disk=${uuid_gpt_disk};name=rootfs,start=2MiB,size=-,uuid=${uuid_gpt_rootfs}
    => printenv partitions
    partitions=uuid_disk=
    =>
    partitions=uuid_disk=
    => setenv partitions 'uuid_disk=${uuid_gpt_disk};name=rootfs,start=2MiB,size=-,uuid=${uuid_gpt_rootfs}'
    => printenv partitions
    partitions=uuid_disk=${uuid_gpt_disk};name=rootfs,start=2MiB,size=-,uuid=${uuid_gpt_rootfs}
    => setenv uuid_disk '${uuid_gpt_disk};name=rootfs,start=2MiB,size=-,uuid=${uuid_gpt_rootfs}'
    => printenv partitions
    partitions=uuid_disk=${uuid_gpt_disk};name=rootfs,start=2MiB,size=-,uuid=${uuid_gpt_rootfs}
    => setenv partitions
    => printenv partitions
    ## Error: "partitions" not defined
    => setenv partitions 'uuid_disk=${uuid_gpt_disk};name=rootfs,start=2MiB,size=-,uuid=${uuid_gpt_rootfs}'
    => printenv partitions
    partitions=uuid_disk=${uuid_gpt_disk};name=rootfs,start=2MiB,size=-,uuid=${uuid_gpt_rootfs}
    => setenv uuid_gpt_disk cab3577b-1ef4-4598-b42b-119a742b498a
    => setenv uuid_gpt_rootfs ea50d110-575d-45a7-81a9-f867dd199e5f
    => gpt write mmc 0 ${partitions}
    Writing GPT: success!
    => mmc list
    mmc@fa10000: 0 (eMMC)
    => mmc part
    
    Partition Map for MMC device 0  --   Partition Type: EFI
    
    Part    Start LBA       End LBA         Name
            Attributes
            Type GUID
            Partition GUID
      1     0x00001000      0x01da3fde      "rootfs"
            attrs:  0x0000000000000000
            type:   ebd0a0a2-b9e5-4433-87c0-68b6b72699c7
            guid:   ea50d110-575d-45a7-81a9-f867dd199e5f
    => saveenv
    Unknown command 'saveenv' - try 'help'
    => mmc dev 0 1
    switch to partitions #1, OK
    mmc0(part 1) is current device
    => setenv serverip 192.168.40.166
    => tftp ${loadaddr} tiboot3.bin
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'tiboot3.bin'.
    Load address: 0x82000000
    Loading: #################################################################
             ########################################################  0 Bytes
             6.3 MiB/s
    done
    Bytes transferred = 619206 (972c6 hex)
    => mmc write ${loadaddr} 0x0 0x400
    
    MMC write: dev # 0, block # 0, count 1024 ... 1024 blocks written: OK
    => tftp ${loadaddr} tispl.bin
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'tispl.bin'.
    Load address: 0x82000000
    Loading: #################################################################
             #################################################################
             ####################################################T #############
             ######  0 Bytes
             193.4 KiB/s
    done
    Bytes transferred = 1024099 (fa063 hex)
    => mmc write ${loadaddr} 0x800 0x1000
    
    MMC write: dev # 0, block # 2048, count 4096 ... 4096 blocks written: OK
    => tftp ${loadaddr} u-boot.bin
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'u-boot.bin'.
    Load address: 0x82000000
    Loading: #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################  0 Bytes
             6.6 MiB/s
    done
    Bytes transferred = 1413536 (1591a0 hex)
    => mmc write ${loadaddr} 0x1800 0x2000
    
    MMC write: dev # 0, block # 6144, count 8192 ... 8192 blocks written: OK
    => mmc partconf 0 1 1 1
    => mmc bootbus 0 2 0 0
    Set to BOOT_BUS_WIDTH = 0x2, RESET = 0x0, BOOT_MODE = 0x0
    =>
    =>
    =>
    => mmc part
    
    Partition Map for MMC device 0  --   Partition Type: EFI
    
    => run findfdt
    WARN: fdtfile already set. Stop using findfdt in script
    => tftp ${loadaddr} Image
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'Image'.
    Load address: 0x82000000
    Loading: #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             #################################################################
             ############################################  0 Bytes
             7 MiB/s
    done
    Bytes transferred = 26511872 (1948a00 hex)
    => tftp ${fdtaddr} ${name_fdt}
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'ti/k3-am642-evm.dtb'.
    Load address: 0x88000000
    Loading: ##############  0 Bytes
             4.1 MiB/s
    done
    Bytes transferred = 69328 (10ed0 hex)
    => booti ${loadaddr} - ${fdtaddr}
    ## Flattened Device Tree blob at 88000000
       Booting using the fdt blob at 0x88000000
    Working FDT set to 88000000
       Loading Device Tree to 000000008ffec000, end 000000008ffffecf ... OK
    Working FDT set to 8ffec000
    
    Starting kernel ...
    
    [    0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd034]
    [    0.000000] Linux version 6.6.32-g6de6e418c80e-dirty (devel@hc3ubuntu) (aarch64-oe-linux-gcc (GCC) 13.3.0, GNU ld (GNU Binutils) 2.42.0.20240716) #2 SMP P                                   REEMPT Tue Sep 24 14:41:02 CEST 2024
    [    0.000000] KASLR disabled due to lack of seed
    [    0.000000] Machine model: Texas Instruments AM642 EVM
    [    0.000000] earlycon: ns16550a0 at MMIO32 0x0000000002800000 (options '')
    [    0.000000] printk: bootconsole [ns16550a0] enabled
    [    0.000000] efi: UEFI not found.
    [    0.000000] OF: reserved mem: 0x000000009e800000..0x000000009fffffff (24576 KiB) nomap non-reusable optee@9e800000
    [    0.000000] Reserved memory: created DMA memory pool at 0x00000000a0000000, size 1 MiB
    [    0.000000] OF: reserved mem: initialized node r5f-dma-memory@a0000000, compatible id shared-dma-pool
    [    0.000000] OF: reserved mem: 0x00000000a0000000..0x00000000a00fffff (1024 KiB) nomap non-reusable r5f-dma-memory@a0000000
    [    0.000000] Reserved memory: created DMA memory pool at 0x00000000a0100000, size 15 MiB
    [    0.000000] OF: reserved mem: initialized node r5f-memory@a0100000, compatible id shared-dma-pool
    [    0.000000] OF: reserved mem: 0x00000000a0100000..0x00000000a0ffffff (15360 KiB) nomap non-reusable r5f-memory@a0100000
    [    0.000000] Reserved memory: created DMA memory pool at 0x00000000a1000000, size 1 MiB
    [    0.000000] OF: reserved mem: initialized node r5f-dma-memory@a1000000, compatible id shared-dma-pool
    [    0.000000] OF: reserved mem: 0x00000000a1000000..0x00000000a10fffff (1024 KiB) nomap non-reusable r5f-dma-memory@a1000000
    [    0.000000] Reserved memory: created DMA memory pool at 0x00000000a1100000, size 15 MiB
    [    0.000000] OF: reserved mem: initialized node r5f-memory@a1100000, compatible id shared-dma-pool
    [    0.000000] OF: reserved mem: 0x00000000a1100000..0x00000000a1ffffff (15360 KiB) nomap non-reusable r5f-memory@a1100000
    [    0.000000] Reserved memory: created DMA memory pool at 0x00000000a2000000, size 1 MiB
    [    0.000000] OF: reserved mem: initialized node r5f-dma-memory@a2000000, compatible id shared-dma-pool
    [    0.000000] OF: reserved mem: 0x00000000a2000000..0x00000000a20fffff (1024 KiB) nomap non-reusable r5f-dma-memory@a2000000
    [    0.000000] Reserved memory: created DMA memory pool at 0x00000000a2100000, size 15 MiB
    [    0.000000] OF: reserved mem: initialized node r5f-memory@a2100000, compatible id shared-dma-pool
    [    0.000000] OF: reserved mem: 0x00000000a2100000..0x00000000a2ffffff (15360 KiB) nomap non-reusable r5f-memory@a2100000
    [    0.000000] Reserved memory: created DMA memory pool at 0x00000000a3000000, size 1 MiB
    [    0.000000] OF: reserved mem: initialized node r5f-dma-memory@a3000000, compatible id shared-dma-pool
    [    0.000000] OF: reserved mem: 0x00000000a3000000..0x00000000a30fffff (1024 KiB) nomap non-reusable r5f-dma-memory@a3000000
    [    0.000000] Reserved memory: created DMA memory pool at 0x00000000a3100000, size 15 MiB
    [    0.000000] OF: reserved mem: initialized node r5f-memory@a3100000, compatible id shared-dma-pool
    [    0.000000] OF: reserved mem: 0x00000000a3100000..0x00000000a3ffffff (15360 KiB) nomap non-reusable r5f-memory@a3100000
    [    0.000000] Reserved memory: created DMA memory pool at 0x00000000a4000000, size 1 MiB
    [    0.000000] OF: reserved mem: initialized node m4f-dma-memory@a4000000, compatible id shared-dma-pool
    [    0.000000] OF: reserved mem: 0x00000000a4000000..0x00000000a40fffff (1024 KiB) nomap non-reusable m4f-dma-memory@a4000000
    [    0.000000] Reserved memory: created DMA memory pool at 0x00000000a4100000, size 15 MiB
    [    0.000000] OF: reserved mem: initialized node m4f-memory@a4100000, compatible id shared-dma-pool
    [    0.000000] OF: reserved mem: 0x00000000a4100000..0x00000000a4ffffff (15360 KiB) nomap non-reusable m4f-memory@a4100000
    [    0.000000] OF: reserved mem: 0x00000000a5000000..0x00000000a57fffff (8192 KiB) nomap non-reusable ipc-memories@a5000000
    [    0.000000] Zone ranges:
    [    0.000000]   DMA      [mem 0x0000000080000000-0x00000000ffffffff]
    [    0.000000]   DMA32    empty
    [    0.000000]   Normal   empty
    [    0.000000] Movable zone start for each node
    [    0.000000] Early memory node ranges
    [    0.000000]   node   0: [mem 0x0000000080000000-0x000000009e7fffff]
    [    0.000000]   node   0: [mem 0x000000009e800000-0x00000000a57fffff]
    [    0.000000]   node   0: [mem 0x00000000a5800000-0x00000000ffffffff]
    [    0.000000] Initmem setup node 0 [mem 0x0000000080000000-0x00000000ffffffff]
    [    0.000000] cma: Reserved 32 MiB at 0x00000000fba00000 on node -1
    [    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: Trusted OS migration not required
    [    0.000000] psci: SMC Calling Convention v1.4
    [    0.000000] percpu: Embedded 20 pages/cpu s42920 r8192 d30808 u81920
    [    0.000000] Detected VIPT I-cache on CPU0
    [    0.000000] CPU features: detected: GIC system register CPU interface
    [    0.000000] CPU features: detected: ARM erratum 845719
    [    0.000000] alternatives: applying boot alternatives
    [    0.000000] Kernel command line: console=ttyS2,115200n8 earlycon=ns16550a,mmio32,0x02800000 omap2-nand.0:2m(NAND.tiboot3),2m(NAND.tispl),2m(NAND.tiboot3.b                                   ackup),4m(NAND.u-boot),256k(NAND.u-boot-env),256k(NAND.u-boot-env.backup),-(NAND.file-system) root=PARTUUID= rw rootfstype=ext4 rootwait
    [    0.000000] Dentry cache hash table entries: 262144 (order: 9, 2097152 bytes, linear)
    [    0.000000] Inode-cache hash table entries: 131072 (order: 8, 1048576 bytes, linear)
    [    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 516096
    [    0.000000] mem auto-init: stack:all(zero), heap alloc:off, heap free:off
    [    0.000000] software IO TLB: area num 2.
    [    0.000000] software IO TLB: mapped [mem 0x00000000f7800000-0x00000000fb800000] (64MB)
    [    0.000000] Memory: 1816664K/2097152K available (11968K kernel code, 1250K rwdata, 4032K rodata, 8512K init, 502K bss, 247720K reserved, 32768K cma-reserv                                   ed)
    [    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=2, Nodes=1
    [    0.000000] rcu: Preemptible hierarchical RCU implementation.
    [    0.000000] rcu:     RCU event tracing is enabled.
    [    0.000000] rcu:     RCU restricting CPUs from NR_CPUS=256 to nr_cpu_ids=2.
    [    0.000000]  Trampoline variant of Tasks RCU enabled.
    [    0.000000]  Tracing variant of Tasks RCU enabled.
    [    0.000000] rcu: RCU calculated value of scheduler-enlistment delay is 25 jiffies.
    [    0.000000] rcu: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=2
    [    0.000000] NR_IRQS: 64, nr_irqs: 64, preallocated irqs: 0
    [    0.000000] GICv3: GIC: Using split EOI/Deactivate mode
    [    0.000000] GICv3: 256 SPIs implemented
    [    0.000000] GICv3: 0 Extended SPIs implemented
    [    0.000000] Root IRQ handler: gic_handle_irq
    [    0.000000] GICv3: GICv3 features: 16 PPIs
    [    0.000000] GICv3: CPU0: found redistributor 0 region 0:0x0000000001840000
    [    0.000000] ITS [mem 0x01820000-0x0182ffff]
    [    0.000000] GIC: enabling workaround for ITS: Socionext Synquacer pre-ITS
    [    0.000000] ITS@0x0000000001820000: Devices Table too large, reduce ids 20->19
    [    0.000000] ITS@0x0000000001820000: allocated 524288 Devices @80800000 (flat, esz 8, psz 64K, shr 0)
    [    0.000000] ITS: using cache flushing for cmd queue
    [    0.000000] GICv3: using LPI property table @0x0000000080040000
    [    0.000000] GIC: using cache flushing for LPI property table
    [    0.000000] GICv3: CPU0: using allocated LPI pending table @0x0000000080050000
    [    0.000000] rcu: srcu_init: Setting srcu_struct sizes based on contention.
    [    0.000000] arch_timer: cp15 timer(s) running at 200.00MHz (phys).
    [    0.000000] clocksource: arch_sys_counter: mask: 0x3ffffffffffffff max_cycles: 0x2e2049d3e8, max_idle_ns: 440795210634 ns
    [    0.000001] sched_clock: 58 bits at 200MHz, resolution 5ns, wraps every 4398046511102ns
    [    0.008739] Console: colour dummy device 80x25
    [    0.013358] Calibrating delay loop (skipped), value calculated using timer frequency.. 400.00 BogoMIPS (lpj=800000)
    [    0.024039] pid_max: default: 32768 minimum: 301
    [    0.028870] LSM: initializing lsm=capability,integrity
    [    0.034261] Mount-cache hash table entries: 4096 (order: 3, 32768 bytes, linear)
    [    0.041843] Mountpoint-cache hash table entries: 4096 (order: 3, 32768 bytes, linear)
    [    0.051962] RCU Tasks: Setting shift to 1 and lim to 1 rcu_task_cb_adjust=1.
    [    0.059316] RCU Tasks Trace: Setting shift to 1 and lim to 1 rcu_task_cb_adjust=1.
    [    0.067307] rcu: Hierarchical SRCU implementation.
    [    0.072218] rcu:     Max phase no-delay instances is 1000.
    [    0.077879] Platform MSI: msi-controller@1820000 domain created
    [    0.084340] PCI/MSI: /bus@f4000/interrupt-controller@1800000/msi-controller@1820000 domain created
    [    0.094066] EFI services will not be available.
    [    0.099102] smp: Bringing up secondary CPUs ...
    I/TC: Secondary CPU 1 initializing
    I/TC: Secondary CPU 1 switching to normal world boot
    [    0.112784] Detected VIPT I-cache on CPU1
    [    0.112889] GICv3: CPU1: found redistributor 1 region 0:0x0000000001860000
    [    0.112909] GICv3: CPU1: using allocated LPI pending table @0x0000000080060000
    [    0.112970] CPU1: Booted secondary processor 0x0000000001 [0x410fd034]
    [    0.113117] smp: Brought up 1 node, 2 CPUs
    [    0.142506] SMP: Total of 2 processors activated.
    [    0.147317] CPU features: detected: 32-bit EL0 Support
    [    0.152588] CPU features: detected: CRC32 instructions
    [    0.157912] CPU: All CPU(s) started at EL2
    [    0.162099] alternatives: applying system-wide alternatives
    [    0.169865] devtmpfs: initialized
    [    0.185004] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 7645041785100000 ns
    [    0.195031] futex hash table entries: 512 (order: 3, 32768 bytes, linear)
    [    0.203519] pinctrl core: initialized pinctrl subsystem
    [    0.209477] DMI not present or invalid.
    [    0.214236] NET: Registered PF_NETLINK/PF_ROUTE protocol family
    [    0.221701] DMA: preallocated 256 KiB GFP_KERNEL pool for atomic allocations
    [    0.229155] DMA: preallocated 256 KiB GFP_KERNEL|GFP_DMA pool for atomic allocations
    [    0.237270] DMA: preallocated 256 KiB GFP_KERNEL|GFP_DMA32 pool for atomic allocations
    [    0.245475] audit: initializing netlink subsys (disabled)
    [    0.251356] audit: type=2000 audit(0.176:1): state=initialized audit_enabled=0 res=1
    [    0.251969] thermal_sys: Registered thermal governor 'step_wise'
    [    0.259313] thermal_sys: Registered thermal governor 'power_allocator'
    [    0.265523] cpuidle: using governor menu
    [    0.276430] hw-breakpoint: found 6 breakpoint and 4 watchpoint registers.
    [    0.283438] ASID allocator initialised with 65536 entries
    [    0.305040] Modules: 26160 pages in range for non-PLT usage
    [    0.305117] Modules: 517680 pages in range for PLT usage
    [    0.311903] HugeTLB: registered 1.00 GiB page size, pre-allocated 0 pages
    [    0.324305] HugeTLB: 0 KiB vmemmap can be freed for a 1.00 GiB page
    [    0.330712] HugeTLB: registered 32.0 MiB page size, pre-allocated 0 pages
    [    0.337648] HugeTLB: 0 KiB vmemmap can be freed for a 32.0 MiB page
    [    0.344053] HugeTLB: registered 2.00 MiB page size, pre-allocated 0 pages
    [    0.350988] HugeTLB: 0 KiB vmemmap can be freed for a 2.00 MiB page
    [    0.357393] HugeTLB: registered 64.0 KiB page size, pre-allocated 0 pages
    [    0.364328] HugeTLB: 0 KiB vmemmap can be freed for a 64.0 KiB page
    [    0.372681] k3-chipinfo 43000014.chipid: Family:AM64X rev:SR2.0 JTAGID[0x1bb3802f] Detected
    [    0.382299] iommu: Default domain type: Translated
    [    0.387238] iommu: DMA domain TLB invalidation policy: strict mode
    [    0.393956] SCSI subsystem initialized
    [    0.398312] usbcore: registered new interface driver usbfs
    [    0.403974] usbcore: registered new interface driver hub
    [    0.409447] usbcore: registered new device driver usb
    [    0.415217] pps_core: LinuxPPS API ver. 1 registered
    [    0.420299] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
    [    0.429647] PTP clock support registered
    [    0.433853] EDAC MC: Ver: 3.0.0
    [    0.437962] scmi_core: SCMI protocol bus registered
    [    0.443472] FPGA manager framework
    [    0.447100] Advanced Linux Sound Architecture Driver Initialized.
    [    0.454519] vgaarb: loaded
    [    0.457856] clocksource: Switched to clocksource arch_sys_counter
    [    0.464432] VFS: Disk quotas dquot_6.6.0
    [    0.468494] VFS: Dquot-cache hash table entries: 512 (order 0, 4096 bytes)
    [    0.483419] NET: Registered PF_INET protocol family
    [    0.488756] IP idents hash table entries: 32768 (order: 6, 262144 bytes, linear)
    [    0.498534] tcp_listen_portaddr_hash hash table entries: 1024 (order: 2, 16384 bytes, linear)
    [    0.507320] Table-perturb hash table entries: 65536 (order: 6, 262144 bytes, linear)
    [    0.515254] TCP established hash table entries: 16384 (order: 5, 131072 bytes, linear)
    [    0.523477] TCP bind hash table entries: 16384 (order: 7, 524288 bytes, linear)
    [    0.531522] TCP: Hash tables configured (established 16384 bind 16384)
    [    0.538489] UDP hash table entries: 1024 (order: 3, 32768 bytes, linear)
    [    0.545416] UDP-Lite hash table entries: 1024 (order: 3, 32768 bytes, linear)
    [    0.552951] NET: Registered PF_UNIX/PF_LOCAL protocol family
    [    0.559403] RPC: Registered named UNIX socket transport module.
    [    0.565511] RPC: Registered udp transport module.
    [    0.570320] RPC: Registered tcp transport module.
    [    0.575127] RPC: Registered tcp-with-tls transport module.
    [    0.580733] RPC: Registered tcp NFSv4.1 backchannel transport module.
    [    0.587327] NET: Registered PF_XDP protocol family
    [    0.592257] PCI: CLS 0 bytes, default 64
    [    0.599400] Initialise system trusted keyrings
    [    0.604489] workingset: timestamp_bits=46 max_order=19 bucket_order=0
    [    0.611755] squashfs: version 4.0 (2009/01/31) Phillip Lougher
    [    0.618581] NFS: Registering the id_resolver key type
    [    0.623996] Key type id_resolver registered
    [    0.628381] Key type id_legacy registered
    [    0.632641] nfs4filelayout_init: NFSv4 File Layout Driver Registering...
    [    0.639551] nfs4flexfilelayout_init: NFSv4 Flexfile Layout Driver Registering...
    [    0.688407] Key type asymmetric registered
    [    0.692678] Asymmetric key parser 'x509' registered
    [    0.697931] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 244)
    [    0.705572] io scheduler mq-deadline registered
    [    0.710269] io scheduler kyber registered
    [    0.714517] io scheduler bfq registered
    [    0.722761] pinctrl-single 4084000.pinctrl: 33 pins, size 132
    [    0.729497] pinctrl-single f4000.pinctrl: 180 pins, size 720
    [    0.737276] pinctrl-single a40000.pinctrl: 512 pins, size 2048
    [    0.751872] Serial: 8250/16550 driver, 12 ports, IRQ sharing enabled
    [    0.775478] loop: module loaded
    [    0.780388] megasas: 07.725.01.00-rc1
    [    0.789426] tun: Universal TUN/TAP device driver, 1.6
    [    0.796471] VFIO - User Level meta-driver version: 0.3
    [    0.803462] usbcore: registered new interface driver usb-storage
    [    0.810809] i2c_dev: i2c /dev entries driver
    [    0.817035] sdhci: Secure Digital Host Controller Interface driver
    [    0.823438] sdhci: Copyright(c) Pierre Ossman
    [    0.828439] sdhci-pltfm: SDHCI platform and OF driver helper
    [    0.835440] ledtrig-cpu: registered to indicate activity on CPUs
    [    0.842549] SMCCC: SOC_ID: ARCH_SOC_ID not implemented, skipping ....
    [    0.850560] usbcore: registered new interface driver usbhid
    [    0.856369] usbhid: USB HID core driver
    [    0.860980] omap-mailbox 29020000.mailbox: omap mailbox rev 0x66fc9100
    [    0.868171] omap-mailbox 29040000.mailbox: omap mailbox rev 0x66fc9100
    [    0.875345] omap-mailbox 29060000.mailbox: omap mailbox rev 0x66fc9100
    [    0.884471] hw perfevents: enabled with armv8_cortex_a53 PMU driver, 7 counters available
    [    0.894017] optee: probing for conduit method.
    I/TC: Reserved shared memory is enabled
    I/TC: Dynamic shared memory is enabled
    I/TC: Normal World virtualization support is disabled
    I/TC: Asynchronous notifications are disabled
    [    0.898638] optee: revision 4.2 (12d7c4ee)
    [    0.915407] optee: dynamic shared memory is enabled
    [    0.925595] random: crng init done
    [    0.929258] optee: initialized driver
    [    0.935620] NET: Registered PF_PACKET protocol family
    [    0.940971] Key type dns_resolver registered
    [    0.954899] registered taskstats version 1
    [    0.959469] Loading compiled-in X.509 certificates
    [    0.979944] ti-sci 44043000.system-controller: ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
    [    1.129498] omap_i2c 20000000.i2c: bus 0 rev0.12 at 400 kHz
    [    1.136035] ti-sci-intr bus@f4000:interrupt-controller@a00000: Interrupt Router 3 domain created
    [    1.145422] ti-sci-inta 48000000.interrupt-controller: Interrupt Aggregator domain 28 created
    [    1.157672] ti-udma 485c0100.dma-controller: Number of rings: 68
    [    1.165622] ti-udma 485c0100.dma-controller: Channels: 24 (bchan: 12, tchan: 6, rchan: 6)
    [    1.175959] ti-udma 485c0000.dma-controller: Number of rings: 288
    [    1.193794] ti-udma 485c0000.dma-controller: Channels: 44 (tchan: 29, rchan: 15)
    [    1.204639] omap8250 4a10000.serial: failed to get alias
    [    1.211683] printk: console [ttyS2] disabled
    [    1.216547] 2800000.serial: ttyS2 at MMIO 0x2800000 (irq = 317, base_baud = 3000000) is a 8250
    [    1.225630] printk: console [ttyS2] enabled
    [    1.225630] printk: console [ttyS2] enabled
    [    1.234115] printk: bootconsole [ns16550a0] disabled
    [    1.234115] printk: bootconsole [ns16550a0] disabled
    [    1.247100] omap8250 2820000.serial: failed to get alias
    [    1.254407] 2830000.serial: ttyS3 at MMIO 0x2830000 (irq = 319, base_baud = 3000000) is a 8250
    [    1.264157] omap8250 2840000.serial: failed to get alias
    [    1.273695] spi-nor spi0.0: spi-nor-generic (65536 Kbytes)
    [    1.279392] 7 fixed-partitions partitions found on MTD device fc40000.spi.0
    [    1.286361] Creating 7 MTD partitions on "fc40000.spi.0":
    [    1.291759] 0x000000000000-0x000000100000 : "ospi.tiboot3"
    [    1.298809] 0x000000100000-0x000000300000 : "ospi.tispl"
    [    1.305543] 0x000000300000-0x000000700000 : "ospi.u-boot"
    [    1.312333] 0x000000700000-0x000000740000 : "ospi.env"
    [    1.318987] 0x000000740000-0x000000780000 : "ospi.env.backup"
    [    1.326248] 0x000000800000-0x000003fc0000 : "ospi.rootfs"
    [    1.333039] 0x000003fc0000-0x000004000000 : "ospi.phypattern"
    [    1.342136] davinci_mdio 8000f00.mdio: Configuring MDIO in manual mode
    [    1.385865] davinci_mdio 8000f00.mdio: davinci mdio revision 9.7, bus freq 1000000
    [    1.412081] davinci_mdio 8000f00.mdio: phy[1]: device 8000f00.mdio:01, driver TI DP83867
    [    1.420242] davinci_mdio 8000f00.mdio: phy[2]: device 8000f00.mdio:02, driver TI DP83867
    [    1.428590] am65-cpsw-nuss 8000000.ethernet: initializing am65 cpsw nuss version 0x6BA00903, cpsw version 0x6BA80903 Ports: 3 quirks:00000006
    [    1.441544] am65-cpsw-nuss 8000000.ethernet: initialized cpsw ale version 1.4
    [    1.448692] am65-cpsw-nuss 8000000.ethernet: ALE Table size 512
    [    1.455691] am65-cpsw-nuss 8000000.ethernet: CPTS ver 0x4e8a010c, freq:500000000, add_val:1 pps:0
    [    1.473744] am65-cpsw-nuss 8000000.ethernet: set new flow-id-base 16
    [    1.486711] am65-cpts 39000000.cpts: CPTS ver 0x4e8a010c, freq:500000000, add_val:1 pps:0
    [    1.496838] mmc0: CQHCI version 5.10
    [    1.506751] cdns-torrent-phy f000000.serdes: No available link subnodes found
    [    1.514052] cdns-torrent-phy: probe of f000000.serdes failed with error -22
    [    1.526946] clk: Disabling unused clocks
    [    1.537933] mmc0: SDHCI controller on fa10000.mmc [fa10000.mmc] using ADMA 64-bit
    [    1.566766] ALSA device list:
    [    1.569757]   No soundcards found.
    [    1.573324] Warning: unable to open an initial console.
    [    1.584160] Freeing unused kernel memory: 8512K
    [    1.588847] Run /init as init process
    [    1.626366] mmc0: Command Queue Engine enabled
    [    1.630864] mmc0: new HS200 MMC card at address 0001
    [    1.636699] mmcblk0: mmc0:0001 S0J56X 14.8 GiB
    [    1.645227]  mmcblk0: p1
    [    1.648579] mmcblk0boot0: mmc0:0001 S0J56X 31.5 MiB
    [    1.654855] mmcblk0boot1: mmc0:0001 S0J56X 31.5 MiB
    [    1.660992] mmcblk0rpmb: mmc0:0001 S0J56X 4.00 MiB, chardev (239:0)
    [    2.353494] udevd[95]: starting version 3.2.14
    [    2.367861] udevd[96]: starting eudev-3.2.14
    [    2.723599] udevd[119]: failed to execute '/etc/udev/scripts/mount.sh' '/etc/udev/scripts/mount.sh': No such file or directory
    [    3.443428] am65-cpsw-nuss 8000000.ethernet eth0: PHY [8000f00.mdio:02] driver [TI DP83867] (irq=POLL)
    [    3.452769] am65-cpsw-nuss 8000000.ethernet eth0: configuring for phy/rgmii-rxid link mode
    [    7.562752] am65-cpsw-nuss 8000000.ethernet eth0: Link is Up - 1Gbps/Full - flow control off
    
     _____                    _____           _         _
    |  _  |___ ___ ___ ___   |  _  |___ ___  |_|___ ___| |_
    |     |  _| .'| . | . |  |   __|  _| . | | | -_|  _|  _|
    |__|__|_| |__,|_  |___|  |__|  |_| |___|_| |___|___|_|
                  |___|                    |___|
    
    Arago Project am62xx-evm /dev/ttyS2
    
    Arago 2023.10 am62xx-evm /dev/ttyS2
    
    am62xx-evm login: [   11.595189] platform regulator-5: deferred probe pending
    [   11.600544] platform 4201000.gpio: deferred probe pending
    root
    root@am62xx-evm:~#
    root@am62xx-evm:~#
    root@am62xx-evm:~#
    root@am62xx-evm:~#
    root@am62xx-evm:~# cat /proc/partitions
    major minor  #blocks  name
    
      31        0       1024 mtdblock0
      31        1       2048 mtdblock1
      31        2       4096 mtdblock2
      31        3        256 mtdblock3
      31        4        256 mtdblock4
      31        5      57088 mtdblock5
      31        6        256 mtdblock6
     179        0   15540224 mmcblk0
     179        1   15538159 mmcblk0p1
     179       32      32256 mmcblk0boot0
     179       64      32256 mmcblk0boot1
    root@am62xx-evm:~# lsblk
    -sh: lsblk: not found
    root@am62xx-evm:~#
    root@am62xx-evm:~#
    root@am62xx-evm:~#
    root@am62xx-evm:~# df
    Filesystem           1K-blocks      Used Available Use% Mounted on
    devtmpfs                908332         0    908332   0% /dev
    tmpfs                   928972        92    928880   0% /run
    tmpfs                   928972        60    928912   0% /var/volatile
    root@am62xx-evm:~#
    root@am62xx-evm:~#
    root@am62xx-evm:~#
    root@am62xx-evm:~# fdisk
    BusyBox v1.36.1 () multi-call binary.
    
    Usage: fdisk [-ul] [-C CYLINDERS] [-H HEADS] [-S SECTORS] [-b SSZ] DISK
    root@am62xx-evm:~# fdisk /dev/mmcblk0
    
    The number of cylinders for this disk is set to 1942528.
    There is nothing wrong with that, but this is larger than 1024,
    and could in certain setups cause problems with:
    1) software that runs at boot time (e.g., old versions of LILO)
    2) booting and partitioning software from other OSs
       (e.g., DOS FDISK, OS/2 FDISK)
    
    Command (m for help): p
    Disk /dev/mmcblk0: 15 GB, 15913189376 bytes, 31080448 sectors
    1942528 cylinders, 1 heads, 16 sectors/track
    Units: sectors of 1 * 512 = 512 bytes
    
    Device       Boot StartCHS    EndCHS        StartLBA     EndLBA    Sectors  Size Id Type
    /dev/mmcblk0p1    0,0,0       0,0,0                1   31080447   31080447 14.8G ee EFI GPT
    
    Command (m for help): q
    
    root@am62xx-evm:~# [  326.411222]  mmcblk0: p1
    [  326.423292] udevd[302]: failed to execute '/etc/udev/scripts/mount.sh' '/etc/udev/scripts/mount.sh': No such file or directory
    [  326.481587] udevd[303]: failed to execute '/etc/udev/scripts/mount.sh' '/etc/udev/scripts/mount.sh': No such file or directory
    
    root@am62xx-evm:~#
    root@am62xx-evm:~#
    root@am62xx-evm:~#
    root@am62xx-evm:~#
    

  • Hi Marc,

    Thanks for providing the information. The boot log shows Linux is booted properly. Can you please elaborate the problem which you need help?

  • Hi Bin,

    I'm sorry to have caused confusion : the last bootlog is with USB DISABLED in the DT. I sent it so you can also see the bootlog from the very beginning of UART boot.

    With USB enabled in DT, the crash happens as in the log which I sent in my initial message and log. So this is in the A53 execution of uboot.bin, which is the first place I believe where USB is being initialised and used. Upon initing the USB, the AM64 crashes and goes into reset and again shows the UART boot sequence.

    Scanning bootdev 'mmc@fa10000.bootdev':
    Bus usb@f400000: 02000000011a0000616d3634780000000000000048534653000002000000020002a6000000000000b018658ad99dc903c8c9bfb27b12751099920a042ad1dfea7b7ba57369f15546de285edde6a7b39a8bdc40a27b237f8fb1e57f245e80b929c1e28b024aa2ecc6ad0bc40b0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002be4ad95a01570beb1d27642b15943d3916611e7c74eaed12a2cc0d202505da9CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC

    So with the DT files (and diff) which I provided earlier : when USB is enabled, then processor crashes and resets at the very first moment the USB is inited. (this is how I understand it).

    kind regards,
    Marc

  • Hi Marc,

    Thanks for the explanation. I understand the problem now.

    Can you please apply the following U-Boot patch and let me know if it resolves the crash issue?

    diff --git a/board/ti/am64x/am64x.env b/board/ti/am64x/am64x.env
    index 43c299115b10..06020e6421c0 100644
    --- a/board/ti/am64x/am64x.env
    +++ b/board/ti/am64x/am64x.env
    @@ -14,7 +14,7 @@ console=ttyS2,115200n8
     args_all=setenv optargs earlycon=ns16550a,mmio32,0x02800000 ${mtdparts}
     run_kern=booti ${loadaddr} ${rd_spec} ${fdtaddr}
     
    -boot_targets=mmc1 mmc0 usb pxe dhcp
    +boot_targets=mmc1 mmc0 pxe dhcp
     boot=mmc
     mmcdev=1
     bootpart=1:2

  • Hi Bin,

    I tried changing the environment (boot_targets), but this only masks the problem. The u-boot will boot properly (without trying to boot from usb), but when I try to enable the USB, then I again get the system crash and reset (see log below).

    For a good understanding; I do want to use the USB host port in my system (both u-boot and linux).

    Is there anything I can do to get more details before the USB crash? I guess this would be inside the USB driver model?

    devel@hc3ubuntu:~/SVN/LINUXDCS/branches$ sudo ./loaddcs.sh
    
    =================================================
    
    -------------------------------------------------
    Sending /tftpboot/uboot/tiboot3.bin, 4837 blocks: Give your local XMODEM receive command now.
    Bytes Sent: 619264   BPS:10006
    
    Transfer complete
    
    -------------------------------------------------
    Sending /tftpboot/uboot/tiboot3.bin, 4837 blocks: Give your local XMODEM receive command now.
    Bytes Sent: 619264   BPS:9973
    
    Transfer complete
    
    U-Boot SPL 2024.04-dirty (Sep 26 2024 - 08:42:59 +0200)
    SYSFW ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
    [board_init_f]
    [do_dt_magic]
    [do_board_detect]
    DM_I2C
    probe ok
    header 0xffffffff
    rc 0
    rc 0
    rc 0
    Read board magic 0xffffffff and ID 0xff
    Next
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    [do_dt_magic] fdt resetup
    [fdtdec_resetup]
    [locate_dtb_in_fit]
    [fdt_offset]
    [fit_find_config_node]
    [board_fit_config_name_match]
    [board_fit_config_name_match]: k3-am642-evm
    Selecting config 'k3-am642-r5-evm'
    [fdtdec_resetup]: no change
    [k3_ddrss_probe]
    [k3_ddrss_power_on]
    [spl_relocate_stack_gd]
    [spl_relocate_stack_check]
    SPL initial stack usage: 13392 bytes
    [board_init_r]
    [spl_board_init]
    [init_daughtercard_det_gpio]
    Failed to lookup gpio gpio@38_0: -22
    Trying to boot from UART
    CC
    -------------------------------------------------
    Sending: tispl.bin
    Bytes Sent:1024128   BPS:9757
    Sending:
    Ymodem sectors/kbytes sent:   0/ 0k
    Transfer complete
    Loaded 1024115 bytes
    Loading Environment from MMC... *** Warning - No MMC card found, using default environment
    
    init_env from device 7 not supported!
    Starting ATF on ARM64 core...
    
    NOTICE:  BL31: v2.10.0(release):v2.10.0-367-g00f1ec6b87-dirty
    NOTICE:  BL31: Built : 16:09:05, Feb  9 2024
    I/TC:
    I/TC: OP-TEE version: 4.2.0-dev (gcc version 13.3.0 (GCC)) #1 Fri Apr 12 09:51:21 UTC 2024 aarch64
    I/TC: WARNING: This OP-TEE configuration might be insecure!
    I/TC: WARNING: Please check https://optee.readthedocs.io/en/latest/architecture/porting_guidelines.html
    I/TC: Primary CPU initializing
    I/TC: GIC redistributor base address not provided
    I/TC: Assuming default GIC group status and modifier
    I/TC: SYSFW ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
    I/TC: HUK Initialized
    I/TC: Activated SA2UL device
    I/TC: Enabled firewalls for SA2UL TRNG device
    I/TC: SA2UL TRNG initialized
    I/TC: SA2UL Drivers initialized
    I/TC: Primary CPU switching to normal world boot
    
    U-Boot SPL 2024.04-dirty (Sep 26 2024 - 08:43:49 +0200)
    SYSFW ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
    [board_init_f]
    [do_dt_magic]
    [do_board_detect]
    [spl_relocate_stack_gd]
    [board_init_r]
    [spl_board_init]
    [init_daughtercard_det_gpio]
    Failed to lookup gpio gpio@38_0: -22
    Trying to boot from UART
    CC
    -------------------------------------------------
    Sending: u-boot.img
    Bytes Sent:1355392   BPS:9843
    Sending:
    Ymodem sectors/kbytes sent:   0/ 0k
    Transfer complete
    config 'k3-am642-evm'
    Loaded 1355343 bytes
    [display_options]
    
    
    U-Boot 2024.04-dirty (Sep 26 2024 - 08:43:49 +0200)
    
    SoC:   AM64X SR2.0 HS-FS
    Model: Texas Instruments AM642 EVM
    [checkboard]
    [do_board_detect]
    Board: AM64-HSEVM rev
    DRAM:  2 GiB
    [board_init]
    Core:  87 devices, 30 uclasses, devicetree: separate
    NAND:  0 MiB
    MMC:   mmc@fa10000: 0
    Loading Environment from nowhere... OK
    In:    serial@2800000
    Out:   serial@2800000
    Err:   serial@2800000
    Failed to probe prueth driver
    [board_late_init]
    [setup_board_eeprom_env]
    [do_board_detect]
    [setup_board_eeprom_env]: am64x_gpevm
    [setup_board_eeprom_env]
    [setup_serial]
    [init_daughtercard_det_gpio]
    Failed to lookup gpio gpio@38_0: -22
    Net:   eth0: ethernet@8000000port@1
    Warning: ethernet@8000000port@2 (eth1) using random MAC address - e6:3e:10:23:0b:70
    , eth1: ethernet@8000000port@2
    Hit any key to stop autoboot:  0
    MMC Device 1 not found
    no mmc device at slot 1
    ** Bad device specification mmc 1 **
    ** Bad device specification mmc 1 **
    Couldn't find partition mmc 1:2
    Can't set block device
    ** Bad device specification mmc 1 **
    Couldn't find partition mmc 1:2
    Can't set block device
    libfdt fdt_check_header(): FDT_ERR_BADMAGIC
    No FDT memory address configured. Please configure
    the FDT address via "fdt addr <address>" command.
    Aborting!
    Bad Linux ARM64 Image magic!
    Scanning for bootflows in all bootdevs
    Seq  Method       State   Uclass    Part  Name                      Filename
    ---  -----------  ------  --------  ----  ------------------------  ----------------
    Scanning global bootmeth 'efi_mgr':
    No EFI system partition
    No EFI system partition
    Failed to persist EFI variables
    No EFI system partition
    Failed to persist EFI variables
    No EFI system partition
    Failed to persist EFI variables
      0  efi_mgr      ready   (none)       0  <NULL>
    ** Booting bootflow '<NULL>' with efi_mgr
    Loading Boot0000 'mmc 0' failed
    EFI boot manager: Cannot load any image
    Boot failed (err=-14)
    Scanning bootdev 'mmc@fa10000.bootdev':
    ethernet@8000000port@1 Waiting for PHY auto negotiation to complete. done
    link up on port 1, speed 1000, full duplex
    BOOTP broadcast 1
    DHCP client bound to address 192.168.40.160 (3 ms)
    Scanning bootdev 'port@1.bootdev':
    missing environment variable: pxeuuid
    Retrieving file: pxelinux.cfg/01-28-b5-e8-cf-e8-2e
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/01-28-b5-e8-cf-e8-2e'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C0A828A0
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C0A828A0'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C0A828A
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C0A828A'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C0A828
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C0A828'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C0A82
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C0A82'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C0A8
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C0A8'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C0A
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C0A'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C0
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C0'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/default-arm-k3-am64x
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/default-arm-k3-am64x'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/default-arm-k3
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/default-arm-k3'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/default-arm
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/default-arm'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/default
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/default'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Scanning bootdev 'port@2.bootdev':
    missing environment variable: pxeuuid
    Retrieving file: pxelinux.cfg/01-28-b5-e8-cf-e8-2e
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/01-28-b5-e8-cf-e8-2e'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C0A828A0
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C0A828A0'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C0A828A
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C0A828A'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C0A828
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C0A828'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C0A82
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C0A82'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C0A8
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C0A8'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C0A
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C0A'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C0
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C0'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/C
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/C'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/default-arm-k3-am64x
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/default-arm-k3-am64x'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/default-arm-k3
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/default-arm-k3'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/default-arm
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/default-arm'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Retrieving file: pxelinux.cfg/default
    link up on port 1, speed 1000, full duplex
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'pxelinux.cfg/default'.
    Load address: 0x80100000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Scanning bootdev 'port@1.bootdev':
    link up on port 1, speed 1000, full duplex
    BOOTP broadcast 1
    DHCP client bound to address 192.168.40.160 (3 ms)
    *** Warning: no boot file name; using 'C0A828A0.img'
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'C0A828A0.img'.
    Load address: 0x82000000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    Scanning bootdev 'port@2.bootdev':
    link up on port 1, speed 1000, full duplex
    BOOTP broadcast 1
    DHCP client bound to address 192.168.40.160 (3 ms)
    *** Warning: no boot file name; using 'C0A828A0.img'
    Using ethernet@8000000port@1 device
    TFTP from server 192.168.40.166; our IP address is 192.168.40.160
    Filename 'C0A828A0.img'.
    Load address: 0x82000000
    Loading: *
    TFTP error: 'File not found' (1)
    Not retrying...
    am65_cpsw_nuss_port ethernet@8000000port@1: RX dma free_pkt failed -22
    No more bootdevs
    ---  -----------  ------  --------  ----  ------------------------  ----------------
    (1 bootflow, 1 valid)
    => help usb
    usb - USB sub-system
    
    Usage:
    usb start - start (scan) USB controller
    usb reset - reset (rescan) USB controller
    usb stop [f] - stop USB [f]=force stop
    usb tree - show USB device tree
    usb info [dev] - show available USB devices
    usb test [dev] [port] [mode] - set USB 2.0 test mode
        (specify port 0 to indicate the device's upstream port)
        Available modes: J, K, S[E0_NAK], P[acket], F[orce_Enable]
    usb storage - show details of USB storage devices
    usb dev [dev] - show or set current USB storage device
    usb part [dev] - print partition table of one or all USB storage    devices
    usb read addr blk# cnt - read `cnt' blocks starting at block `blk#'
        to memory address `addr'
    usb write addr blk# cnt - write `cnt' blocks starting at block `blk#'
        from memory address `addr'
    => usb start
    starting USB...
    Bus usb@f400000: 02000000011a0000616d3634780000000000000048534653000002000000020002a6000000000000b018658ad99dc903c8c9bfb27b12751099920a042ad1dfea7b7ba57369f15546de285edde6a7b39a8bdc40a27b237f8fb1e57f245e80b929c1e28b024aa2ecc6ad0bc40b0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002be4ad95a01570beb1d27642b15943d3916611e7c74eaed12a2cc0d202505da9CCCCCCCCC
    

  • Hi Marc,

    The AM64x U-Boot supports both AM64x GPEVM and SK-AM64B EVM. The SK-AM64B EVM USB port is configured as an USB host.

    Instead of my previous U-Boot ENV patch, can you please apply the following U-Boot patch and test it on your board to see if you can use USB host in U-Boot? This patch removes the GPEVM device tree but only use thr SK-AM64B EVM device tree. You don't need any other USB related changes in U-Boot.

    diff --git a/arch/arm/dts/k3-am64x-binman.dtsi b/arch/arm/dts/k3-am64x-binman.dtsi
    index e609ef627efe..99c2aeaa5121 100644
    --- a/arch/arm/dts/k3-am64x-binman.dtsi
    +++ b/arch/arm/dts/k3-am64x-binman.dtsi
    @@ -152,7 +152,7 @@
     						keyfile = "custMpk.pem";
     					};
     					spl_am64x_evm_dtb: blob-ext {
    -						filename = SPL_AM642_EVM_DTB;
    +						filename = SPL_AM642_SK_DTB;
     					};
     
     				};
    diff --git a/arch/arm/mach-k3/am64x/Kconfig b/arch/arm/mach-k3/am64x/Kconfig
    index 73e7e039471a..7ceb5dbc0f48 100644
    --- a/arch/arm/mach-k3/am64x/Kconfig
    +++ b/arch/arm/mach-k3/am64x/Kconfig
    @@ -15,7 +15,6 @@ config TARGET_AM642_A53_EVM
     	select BINMAN
     	imply BOARD
     	imply SPL_BOARD
    -	imply TI_I2C_BOARD_DETECT
     	imply TI_COMMON_CMD_OPTIONS
     
     config TARGET_AM642_R5_EVM
    @@ -28,7 +27,6 @@ config TARGET_AM642_R5_EVM
     	select K3_DDRSS
     	select BINMAN
     	imply SYS_K3_SPL_ATF
    -	imply TI_I2C_BOARD_DETECT
     
     endchoice
     
    diff --git a/board/ti/common/Kconfig b/board/ti/common/Kconfig
    index de44e4de2115..0e5e31344c49 100644
    --- a/board/ti/common/Kconfig
    +++ b/board/ti/common/Kconfig
    @@ -8,13 +8,11 @@ config EEPROM_BUS_ADDRESS
     	int "Board EEPROM's I2C bus address"
     	range 0 8
     	default 0
    -	depends on TI_I2C_BOARD_DETECT
     
     config EEPROM_CHIP_ADDRESS
     	hex "Board EEPROM's I2C chip address"
     	range 0 0xff
     	default 0x50
    -	depends on TI_I2C_BOARD_DETECT
     
     config CAPE_EEPROM_BUS_NUM
     	int "Cape EEPROM's I2C bus address"
    diff --git a/configs/am64x_evm_a53_defconfig b/configs/am64x_evm_a53_defconfig
    index 7312d3ae2421..e64e1748d300 100644
    --- a/configs/am64x_evm_a53_defconfig
    +++ b/configs/am64x_evm_a53_defconfig
    @@ -79,7 +79,7 @@ CONFIG_MTDPARTS_DEFAULT="mtdparts=omap2-nand.0:2m(NAND.tiboot3),2m(NAND.tispl),2
     CONFIG_CMD_UBI=y
     CONFIG_OF_CONTROL=y
     CONFIG_SPL_OF_CONTROL=y
    -CONFIG_OF_LIST="k3-am642-evm k3-am642-sk"
    +CONFIG_OF_LIST="k3-am642-sk"
     CONFIG_MULTI_DTB_FIT=y
     CONFIG_SPL_MULTI_DTB_FIT=y
     CONFIG_SPL_MULTI_DTB_FIT_NO_COMPRESSION=y
    diff --git a/configs/am64x_evm_r5_defconfig b/configs/am64x_evm_r5_defconfig
    index 7a20a0e67d97..2bbd9523c1eb 100644
    --- a/configs/am64x_evm_r5_defconfig
    +++ b/configs/am64x_evm_r5_defconfig
    @@ -86,7 +86,7 @@ CONFIG_CMD_FAT=y
     CONFIG_OF_CONTROL=y
     CONFIG_SPL_OF_CONTROL=y
     CONFIG_SPL_MULTI_DTB_FIT=y
    -CONFIG_SPL_OF_LIST="k3-am642-r5-evm k3-am642-r5-sk"
    +CONFIG_SPL_OF_LIST="k3-am642-r5-sk"
     CONFIG_SPL_MULTI_DTB_FIT_NO_COMPRESSION=y
     CONFIG_ENV_IS_IN_MMC=y
     CONFIG_SYS_RELOC_GD_ENV_ADDR=y
    

  • Hi Bin,

    That will not do.

    As I have tried to explain earlier; I'm having a custom board with features from both EVM and SK. I'm using DDR3 which requires enabling a VTT regulator during SPL. Otherwise I'm using SK features like USB3.0 Host mode, CPSW attached ethernet, etc...

    I started from the EVM DEvice tree configuration and modified this as needed. I have sent you the files above together with a diff versus original file.

    I don't even need to try working with SPL_AM642_SK_DTB as suggested, because it won't initialise the DDR3 memory on my board and I will be stuck in SPL.

    Do you have any clue what could cause the USB initialisation to crash (and make AM64 reboot) at the moment USB3.0 is started? I have verified the HW pins and am quite sure about allocation.

    Is there something I can do to further debug the USB start itself?

  • Hi Marc,

    With all the information in this thread, I don't have a clue what the root cause is. I didn't have similar issue report from other customers before.

    Using the SK DTB, which has the known good USB host configuration on the SK-AM64B EVM, is the start of the debugging.

    Similar to how you enabled DDR3 with GPEVM DTB, is it possible to add your DDR3 config to the SK DTB so that you can boot your board with the SK DTB to the U-Boot prompt and test USB? We don't need to boot to Linux for this U-Boot USB issue.

  • Hi Bin,

    Would there be a difference between

    starting from EVM DTB and adding in the USB sections from the SK DTB

    Or

    starting from the SK DTB and adding in EVM sections?

    In the first case; I'm forcing the FW to recognise the board as EVM, in the second case I would force the FW to recognise an SK board. I'm patching the EEPROM detection firmware for this.

    kind regards,

    Marc

  • Hi Bin,

    Following up on your suggestion, I have now started from the SK DTB with modifications for my custom HW and for the DDR3 as used in the EVM kit. I attach here the diff and dts files which I am using; modified from the original SK dts files.

    The result is the same as in my approach (starting from EVM dts files with modifs taken in from SK) : when booting u-boot; upon initialisation of the USB peripheral; the processor crashes and resets; resulting in the UART bootmode xmodem sequence being shown.

    Please advise on how to go forward?

    Bootlog with tiboot3 / spl / uboot outputs; loaded using UART bootmode :

    devel@hc3ubuntu:~/SVN/LINUXDCS/branches$ sudo ./loaddcs.sh
    
    =================================================
    
    -------------------------------------------------
    Sending /tftpboot/tiboot3.bin, 4817 blocks: Give your local XMODEM receive command now.
    Bytes Sent: 616704   BPS:9670
    
    Transfer complete
    
    U-Boot SPL 2024.04-dirty (Sep 30 2024 - 10:12:41 +0200)
    Resetting on cold boot to workaround ErrataID:i2331
    Please resend tiboot3.bin in case of UART/DFU boot
    resetting ...
    02000000011a0000616d3634780000000000000048534653000002000000020002a6000000000000b018658ad99dc903c8c9bfb27b12751099920a042ad1dfea7b7ba57369f15546de285edde6a7b39a8bdc40a27b237f8fb1e57f245e80b929c1e28b024aa2ecc6ad0bc40b0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000006dbe88622e2543b0f764e78d09320445844765a3faab5cda29503a493f788023CCCCCCCCCCCCCCCCCC
    -------------------------------------------------
    Sending /tftpboot/tiboot3.bin, 4817 blocks: Give your local XMODEM receive command now.
    Bytes Sent: 616704   BPS:9495
    
    Transfer complete
    
    U-Boot SPL 2024.04-dirty (Sep 30 2024 - 10:12:41 +0200)
    SYSFW ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
    [board_init_f]
    [do_dt_magic]
    [do_board_detect]
    DM_I2C
    probe ok
    header 0xffffffff
    rc 0
    rc 0
    rc 0
    Read board magic 0xffffffff and ID 0xff
    Next
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    ti_i2c_eeprom_am6_get: Ignoring record id 255
    [do_dt_magic] fdt resetup
    [fdtdec_resetup]
    [locate_dtb_in_fit]
    [fdt_offset]
    [fit_find_config_node]
    [board_fit_config_name_match]
    [board_fit_config_name_match]
    [board_fit_config_name_match]: k3-am642-sk
    Selecting config 'k3-am642-r5-sk'
    [fdtdec_resetup]: changed
    [fdtdec_prepare_fdt]
    [k3_ddrss_probe]
    [k3_ddrss_power_on]
    [spl_relocate_stack_gd]
    [spl_relocate_stack_check]
    SPL initial stack usage: 13392 bytes
    [board_init_r]
    [spl_board_init]
    Trying to boot from UART
    CCCC
    -------------------------------------------------
    Sending: tispl.bin
    Bytes Sent:1020928   BPS:9333
    Sending:
    Ymodem sectors/kbytes sent:   0/ 0k
    Transfer complete
     k3-am642-sk
    Selecting config 'k3-am642-sk'
    Loaded 1020875 bytes
    Loading Environment from MMC... *** Warning - No MMC card found, using default environment
    
    init_env from device 7 not supported!
    Starting ATF on ARM64 core...
    
    NOTICE:  BL31: v2.10.0(release):v2.10.0-367-g00f1ec6b87-dirty
    NOTICE:  BL31: Built : 16:09:05, Feb  9 2024
    I/TC:
    I/TC: OP-TEE version: 4.2.0-dev (gcc version 13.3.0 (GCC)) #1 Fri Apr 12 09:51:21 UTC 2024 aarch64
    I/TC: WARNING: This OP-TEE configuration might be insecure!
    I/TC: WARNING: Please check https://optee.readthedocs.io/en/latest/architecture/porting_guidelines.html
    I/TC: Primary CPU initializing
    I/TC: GIC redistributor base address not provided
    I/TC: Assuming default GIC group status and modifier
    I/TC: SYSFW ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
    I/TC: HUK Initialized
    I/TC: Activated SA2UL device
    I/TC: Enabled firewalls for SA2UL TRNG device
    I/TC: SA2UL TRNG initialized
    I/TC: SA2UL Drivers initialized
    I/TC: Primary CPU switching to normal world boot
    
    U-Boot SPL 2024.04-dirty (Sep 30 2024 - 10:18:20 +0200)
    SYSFW ABI: 4.0 (firmware rev 0x000a '10.0.8--v10.00.08 (Fiery Fox)')
    [board_init_f]
    [do_dt_magic]
    [do_board_detect]
    [spl_relocate_stack_gd]
    [board_init_r]
    [spl_board_init]
    Trying to boot from UART
    CCCCCC
    -------------------------------------------------
    Sending: u-boot.img
    Bytes Sent:1352320   BPS:9279
    Sending:
    Ymodem sectors/kbytes sent:   0/ 0k
    Transfer complete
    Loaded 1352287 bytes
    [display_options]
    
    
    U-Boot 2024.04-dirty (Sep 30 2024 - 10:18:20 +0200)
    
    SoC:   AM64X SR2.0 HS-FS
    Model: Texas Instruments AM642 SK
    [checkboard]
    [do_board_detect]
    Board: AM64B-SKEVM rev
    DRAM:  2 GiB
    [board_init]
    Core:  79 devices, 30 uclasses, devicetree: separate
    NAND:  0 MiB
    MMC:   mmc@fa10000: 0
    Loading Environment from nowhere... OK
    In:    serial@2800000
    Out:   serial@2800000
    Err:   serial@2800000
    Failed to probe prueth driver
    [board_late_init]
    [setup_board_eeprom_env]
    [do_board_detect]
    [setup_board_eeprom_env]: am64x_skevm
    [setup_board_eeprom_env]
    [setup_serial]
    Net:   eth0: ethernet@8000000port@1
    Warning: ethernet@8000000port@2 (eth1) using random MAC address - fa:63:00:13:cf:6b
    , eth1: ethernet@8000000port@2
    Hit any key to stop autoboot:  0
    switch to partitions #0, OK
    mmc0(part 0) is current device
    SD/MMC found on device 0
    Can't set block device
    ** No partition table - mmc 0 **
    ** No partition table - mmc 0 **
    Couldn't find partition mmc 0:2
    Can't set block device
    ** No partition table - mmc 0 **
    Couldn't find partition mmc 0:2
    Can't set block device
    libfdt fdt_check_header(): FDT_ERR_BADMAGIC
    No FDT memory address configured. Please configure
    the FDT address via "fdt addr <address>" command.
    Aborting!
    Bad Linux ARM64 Image magic!
    Scanning for bootflows in all bootdevs
    Seq  Method       State   Uclass    Part  Name                      Filename
    ---  -----------  ------  --------  ----  ------------------------  ----------------
    Scanning global bootmeth 'efi_mgr':
    No EFI system partition
    No EFI system partition
    Failed to persist EFI variables
    No EFI system partition
    Failed to persist EFI variables
    No EFI system partition
    Failed to persist EFI variables
      0  efi_mgr      ready   (none)       0  <NULL>
    ** Booting bootflow '<NULL>' with efi_mgr
    Loading Boot0000 'mmc 0' failed
    EFI boot manager: Cannot load any image
    Boot failed (err=-14)
    Scanning bootdev 'mmc@fa10000.bootdev':
    Bus usb@f400000: Register 2000840▒02000000011a0000616d3634780000000000000048534653000002000000020002a6000000000000b018658ad99dc903c8c9bfb27b12751099920a042ad1dfea7b7ba57369f15546de285edde6a7b39a8bdc40a27b237f8fb1e57f245e80b929c1e28b024aa2ecc6ad0bc40b0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000006dbe88622e2543b0f764e78d09320445844765a3faab5cda29503a493f788023CCCCCCCCCCCCCC
    

    The diff of the SK DTB files; modified for my custom HW and for use of DDR3 (with VTT enable) :

    diff -bur orig/k3-am642-r5-sk.dts mod/k3-am642-r5-sk.dts
    --- orig/k3-am642-r5-sk.dts     2024-09-18 12:28:01.725962800 +0200
    +++ mod/k3-am642-r5-sk.dts      2024-09-30 10:02:31.447918900 +0200
    @@ -4,7 +4,7 @@
      */
    
     #include "k3-am642-sk.dts"
    -#include "k3-am64-sk-lp4-1600MTs.dtsi"
    +#include "k3-am64-evm-ddr4-1600MTs.dtsi"
     #include "k3-am64-ddr.dtsi"
    
     #include "k3-am642-sk-u-boot.dtsi"
    @@ -40,6 +40,10 @@
            };
     };
    
    +&vtt_supply {
    +       bootph-pre-ram;
    +};
    +
     &cbass_main {
            sysctrler: sysctrler {
                    compatible = "ti,am654-system-controller";
    @@ -88,15 +92,30 @@
            ti,secure-host;
     };
    
    -&sdhci1 {
    +&memorycontroller {
    +       vtt-supply = <&vtt_supply>;
    +};
    +
    +&sdhci0 {
    +       /delete-property/ power-domains;
            clocks = <&clk_200mhz>;
            clock-names = "clk_xin";
    +       ti,driver-strength-ohm = <50>;
    +       disable-wp;
     };
    
     &serdes_wiz0 {
            status = "okay";
     };
    
    +&mcu_gpio0 {
    +       bootph-pre-ram;
    +};
    +
    +&main_gpio0 {
    +       bootph-pre-ram;
    +};
    +
     /* UART is initialized before SYSFW is started
      * so we can't do any power-domain/clock operations.
      * Delete clock/power-domain properties to avoid
    @@ -151,32 +170,42 @@
    
                            partition@0 {
                                    label = "ospi.tiboot3";
    -                               reg = <0x0 0x100000>;
    +                               reg = <0x0 0x80000>;
                            };
    
    -                       partition@100000 {
    +                       partition@80000 {
                                    label = "ospi.tispl";
    -                               reg = <0x100000 0x200000>;
    +                               reg = <0x80000 0x200000>;
                            };
    
    -                       partition@300000 {
    +                       partition@280000 {
                                    label = "ospi.u-boot";
    -                               reg = <0x300000 0x400000>;
    +                               reg = <0x280000 0x400000>;
                            };
    
    -                       partition@700000 {
    +                       partition@680000 {
                                    label = "ospi.env";
    -                               reg = <0x700000 0x40000>;
    +                               reg = <0x680000 0x40000>;
                            };
    
    -                       partition@740000 {
    +                       partition@6c0000 {
                                    label = "ospi.env.backup";
    -                               reg = <0x740000 0x40000>;
    +                               reg = <0x6c0000 0x40000>;
    +                       };
    +
    +                       partition@700000 {
    +                               label = "ospi.dtb";
    +                               reg = <0x700000 0x100000>;
                            };
    
                            partition@800000 {
    +                               label = "ospi.kernel";
    +                               reg = <0x800000 0x1400000>;
    +                       };
    +
    +                       partition@1c00000 {
                                    label = "ospi.rootfs";
    -                               reg = <0x800000 0x37c0000>;
    +                               reg = <0x1c00000 0x23C0000>;
                            };
    
                            partition@3fc0000 {
    diff -bur orig/k3-am642-sk.dts mod/k3-am642-sk.dts
    --- orig/k3-am642-sk.dts        2024-09-18 12:28:01.760941000 +0200
    +++ mod/k3-am642-sk.dts 2024-09-30 10:05:31.055753200 +0200
    @@ -8,7 +8,6 @@
     #include <dt-bindings/phy/phy.h>
     #include <dt-bindings/gpio/gpio.h>
     #include <dt-bindings/net/ti-dp83867.h>
    -#include <dt-bindings/leds/common.h>
     #include "k3-am642.dtsi"
    
     #include "k3-serdes.h"
    @@ -26,9 +25,7 @@
                    serial1 = &main_uart1;
                    serial2 = &main_uart0;
                    i2c0 = &main_i2c0;
    -               i2c1 = &main_i2c1;
                    mmc0 = &sdhci0;
    -               mmc1 = &sdhci1;
                    ethernet0 = &cpsw_port1;
                    ethernet1 = &cpsw_port2;
            };
    @@ -118,152 +115,43 @@
                    };
            };
    
    -       vusb_main: regulator-0 {
    -               /* USB MAIN INPUT 5V DC */
    +       vsys_5v0: regulator-1 {
                    bootph-all;
                    compatible = "regulator-fixed";
    -               regulator-name = "vusb_main5v0";
    +               regulator-name = "vsys_5v0";
                    regulator-min-microvolt = <5000000>;
                    regulator-max-microvolt = <5000000>;
                    regulator-always-on;
                    regulator-boot-on;
            };
    
    -       vcc_3v3_sys: regulator-1 {
    -               /* output of LP8733xx */
    +       vsys_3v3: regulator-2 {
                    bootph-all;
                    compatible = "regulator-fixed";
    -               regulator-name = "vcc_3v3_sys";
    +               regulator-name = "vsys_3v3";
                    regulator-min-microvolt = <3300000>;
                    regulator-max-microvolt = <3300000>;
    -               vin-supply = <&vusb_main>;
                    regulator-always-on;
                    regulator-boot-on;
            };
    
    -       vdd_mmc1: regulator-2 {
    -               /* TPS2051BD */
    +       vtt_supply: regulator-5 {
                    bootph-all;
                    compatible = "regulator-fixed";
    -               regulator-name = "vdd_mmc1";
    +               regulator-name = "vtt";
    +               pinctrl-names = "default";
    +               pinctrl-0 = <&ddr_vtt_pins_default>;
                    regulator-min-microvolt = <3300000>;
                    regulator-max-microvolt = <3300000>;
    -               regulator-boot-on;
    +               gpio = <&mcu_gpio0 6 GPIO_ACTIVE_HIGH>;
    +               vin-supply = <&vsys_3v3>;
                    enable-active-high;
    -               vin-supply = <&vcc_3v3_sys>;
    -               gpio = <&exp1 3 GPIO_ACTIVE_HIGH>;
    -       };
    -
    -       com8_ls_en: regulator-3 {
    -               compatible = "regulator-fixed";
    -               regulator-name = "com8_ls_en";
    -               regulator-min-microvolt = <3300000>;
    -               regulator-max-microvolt = <3300000>;
                    regulator-always-on;
                    regulator-boot-on;
    -               pinctrl-0 = <&main_com8_ls_en_pins_default>;
    -               pinctrl-names = "default";
    -               gpio = <&main_gpio0 62 GPIO_ACTIVE_LOW>;
    -       };
    -
    -       wlan_en: regulator-4 {
    -               /* output of SN74AVC4T245RSVR */
    -               compatible = "regulator-fixed";
    -               regulator-name = "wlan_en";
    -               regulator-min-microvolt = <1800000>;
    -               regulator-max-microvolt = <1800000>;
    -               enable-active-high;
    -               pinctrl-0 = <&main_wlan_en_pins_default>;
    -               pinctrl-names = "default";
    -               vin-supply = <&com8_ls_en>;
    -               gpio = <&main_gpio0 48 GPIO_ACTIVE_HIGH>;
    -       };
    -
    -       led-controller {
    -               compatible = "gpio-leds";
    -
    -               led-0 {
    -                       color = <LED_COLOR_ID_GREEN>;
    -                       function = LED_FUNCTION_INDICATOR;
    -                       function-enumerator = <1>;
    -                       gpios = <&exp2 0 GPIO_ACTIVE_HIGH>;
    -                       default-state = "off";
    -               };
    -
    -               led-1 {
    -                       color = <LED_COLOR_ID_RED>;
    -                       function = LED_FUNCTION_INDICATOR;
    -                       function-enumerator = <2>;
    -                       gpios = <&exp2 1 GPIO_ACTIVE_HIGH>;
    -                       default-state = "off";
    -               };
    -
    -               led-2 {
    -                       color = <LED_COLOR_ID_GREEN>;
    -                       function = LED_FUNCTION_INDICATOR;
    -                       function-enumerator = <3>;
    -                       gpios = <&exp2 2 GPIO_ACTIVE_HIGH>;
    -                       default-state = "off";
    -               };
    -
    -               led-3 {
    -                       color = <LED_COLOR_ID_AMBER>;
    -                       function = LED_FUNCTION_INDICATOR;
    -                       function-enumerator = <4>;
    -                       gpios = <&exp2 3 GPIO_ACTIVE_HIGH>;
    -                       default-state = "off";
    -               };
    -
    -               led-4 {
    -                       color = <LED_COLOR_ID_GREEN>;
    -                       function = LED_FUNCTION_INDICATOR;
    -                       function-enumerator = <5>;
    -                       gpios = <&exp2 4 GPIO_ACTIVE_HIGH>;
    -                       default-state = "off";
    -               };
    -
    -               led-5 {
    -                       color = <LED_COLOR_ID_RED>;
    -                       function = LED_FUNCTION_INDICATOR;
    -                       function-enumerator = <6>;
    -                       gpios = <&exp2 5 GPIO_ACTIVE_HIGH>;
    -                       default-state = "off";
    -               };
    -
    -               led-6 {
    -                       color = <LED_COLOR_ID_GREEN>;
    -                       function = LED_FUNCTION_INDICATOR;
    -                       function-enumerator = <7>;
    -                       gpios = <&exp2 6 GPIO_ACTIVE_HIGH>;
    -                       default-state = "off";
    -               };
    -
    -               led-7 {
    -                       color = <LED_COLOR_ID_AMBER>;
    -                       function = LED_FUNCTION_HEARTBEAT;
    -                       function-enumerator = <8>;
    -                       linux,default-trigger = "heartbeat";
    -                       gpios = <&exp2 7 GPIO_ACTIVE_HIGH>;
    -               };
            };
     };
    
     &main_pmx0 {
    -       main_mmc1_pins_default: main-mmc1-default-pins {
    -               bootph-all;
    -               pinctrl-single,pins = <
    -                       AM64X_IOPAD(0x029c, PIN_INPUT_PULLUP, 0) /* (C20) MMC1_SDWP */
    -                       AM64X_IOPAD(0x0298, PIN_INPUT_PULLUP, 0) /* (D19) MMC1_SDCD */
    -                       AM64X_IOPAD(0x0294, PIN_INPUT_PULLUP, 0) /* (J19) MMC1_CMD */
    -                       AM64X_IOPAD(0x0290, PIN_INPUT, 0) /* (#N/A) MMC1_CLKLB */
    -                       AM64X_IOPAD(0x028c, PIN_INPUT_PULLDOWN, 0) /* (L20) MMC1_CLK */
    -                       AM64X_IOPAD(0x0288, PIN_INPUT_PULLUP, 0) /* (K21) MMC1_DAT0 */
    -                       AM64X_IOPAD(0x0284, PIN_INPUT_PULLUP, 0) /* (L21) MMC1_DAT1 */
    -                       AM64X_IOPAD(0x0280, PIN_INPUT_PULLUP, 0) /* (K19) MMC1_DAT2 */
    -                       AM64X_IOPAD(0x027c, PIN_INPUT_PULLUP, 0) /* (K18) MMC1_DAT3 */
    -               >;
    -       };
    -
            main_uart0_pins_default: main-uart0-default-pins {
                    bootph-all;
                    pinctrl-single,pins = <
    @@ -274,16 +162,6 @@
                    >;
            };
    
    -       main_uart1_pins_default: main-uart1-default-pins {
    -               bootph-pre-ram;
    -               pinctrl-single,pins = <
    -                       AM64X_IOPAD(0x0248, PIN_INPUT, 0) /* (D16) UART1_CTSn */
    -                       AM64X_IOPAD(0x024c, PIN_OUTPUT, 0) /* (E16) UART1_RTSn */
    -                       AM64X_IOPAD(0x0240, PIN_INPUT, 0) /* (E15) UART1_RXD */
    -                       AM64X_IOPAD(0x0244, PIN_OUTPUT, 0) /* (E14) UART1_TXD */
    -               >;
    -       };
    -
            main_usb0_pins_default: main-usb0-default-pins {
                    bootph-all;
                    pinctrl-single,pins = <
    @@ -299,18 +177,10 @@
                    >;
            };
    
    -       main_i2c1_pins_default: main-i2c1-default-pins {
    -               bootph-all;
    -               pinctrl-single,pins = <
    -                       AM64X_IOPAD(0x0268, PIN_INPUT_PULLUP, 0) /* (C18) I2C1_SCL */
    -                       AM64X_IOPAD(0x026c, PIN_INPUT_PULLUP, 0) /* (B19) I2C1_SDA */
    -               >;
    -       };
    -
            mdio1_pins_default: mdio1-default-pins {
                    pinctrl-single,pins = <
    -                       AM64X_IOPAD(0x01fc, PIN_OUTPUT, 4) /* (R2) PRG0_PRU1_GPO19.MDIO0_MDC */
    -                       AM64X_IOPAD(0x01f8, PIN_INPUT, 4) /* (P5) PRG0_PRU1_GPO18.MDIO0_MDIO */
    +                       AM64X_IOPAD(0x015c, PIN_OUTPUT, 4) /* (Y6) PRG1_MDIO0_MDC.MDIO0_MDC */
    +                       AM64X_IOPAD(0x0158, PIN_INPUT, 4) /* (AA6) PRG1_MDIO0_MDIO.MDIO0_MDIO */
                    >;
            };
    
    @@ -365,44 +235,14 @@
                    bootph-all;
            };
    
    -       main_ecap0_pins_default: main-ecap0-default-pins {
    -               pinctrl-single,pins = <
    -                       AM64X_IOPAD(0x0270, PIN_INPUT, 0) /* (D18) ECAP0_IN_APWM_OUT */
    -               >;
    -       };
    -
    -       main_eqep0_pins_default: main-eqep0-default-pins {
    -               pinctrl-single,pins = <
    -                       AM64X_IOPAD(0x00a0, PIN_INPUT, 3) /* (N16) GPMC0_WPn.EQEP0_A */
    -                       AM64X_IOPAD(0x00a4, PIN_INPUT, 3) /* (N17) GPMC0_DIR.EQEP0_B */
    -                       AM64X_IOPAD(0x00ac, PIN_INPUT, 3) /* (R20) GPMC0_CSn1.EQEP0_I */
    -                       AM64X_IOPAD(0x00a8, PIN_INPUT, 3) /* (R19) GPMC0_CSn0.EQEP0_S */
    -               >;
    -       };
    -
    -       main_wlan_en_pins_default: main-wlan-en-default-pins {
    -               pinctrl-single,pins = <
    -                       AM64X_IOPAD(0x00c4, PIN_OUTPUT_PULLUP, 7) /* (V8) GPIO0_48 */
    -               >;
    -       };
    -
    -       main_com8_ls_en_pins_default: main-com8-ls-en-default-pins {
    -               pinctrl-single,pins = <
    -                       AM64X_IOPAD(0x00fc, PIN_OUTPUT, 7) /* (U7) PRG1_PRU0_GPO17.GPIO0_62 */
    -               >;
    -       };
    -
    -       main_wlan_pins_default: main-wlan-default-pins {
    +       ddr_vtt_pins_default: ddr-vtt-default-pins {
    +               bootph-all;
                    pinctrl-single,pins = <
    -                       AM64X_IOPAD(0x00bc, PIN_INPUT, 7) /* (U8) GPIO0_46 */
    +                       AM64X_MCU_IOPAD(0x0018, PIN_OUTPUT, 7) /* (B7) MCU_SPI1_CS1.MCU_GPIO0_6 */
                    >;
            };
     };
    
    -&fss {
    -       bootph-all;
    -};
    -
     &main_uart0 {
            bootph-all;
            status = "okay";
    @@ -411,14 +251,6 @@
            current-speed = <115200>;
     };
    
    -&main_uart1 {
    -       /* main_uart1 is reserved for firmware usage */
    -       bootph-pre-ram;
    -       status = "reserved";
    -       pinctrl-names = "default";
    -       pinctrl-0 = <&main_uart1_pins_default>;
    -};
    -
     &main_i2c0 {
            bootph-all;
            status = "okay";
    @@ -432,71 +264,11 @@
            };
     };
    
    -&main_i2c1 {
    -       bootph-all;
    -       status = "okay";
    -       pinctrl-names = "default";
    -       pinctrl-0 = <&main_i2c1_pins_default>;
    -       clock-frequency = <400000>;
    -
    -       exp1: gpio@70 {
    -               bootph-all;
    -               compatible = "nxp,pca9538";
    -               reg = <0x70>;
    -               gpio-controller;
    -               #gpio-cells = <2>;
    -               gpio-line-names = "GPIO_CPSW2_RST", "GPIO_CPSW1_RST",
    -                                 "PRU_DETECT", "MMC1_SD_EN",
    -                                 "VPP_LDO_EN", "RPI_PS_3V3_En",
    -                                 "RPI_PS_5V0_En", "RPI_HAT_DETECT";
    -       };
    -
    -       exp2: gpio@60 {
    -               compatible = "ti,tpic2810";
    -               reg = <0x60>;
    -               gpio-controller;
    -               #gpio-cells = <2>;
    -               gpio-line-names = "LED1","LED2","LED3","LED4","LED5","LED6","LED7","LED8";
    -       };
    -};
    -
    -/* mcu_gpio0 and mcu_gpio_intr are reserved for mcu firmware usage */
    -&mcu_gpio0 {
    -       status = "reserved";
    -};
    -
    -&mcu_gpio_intr {
    -       status = "reserved";
    -};
    -
     &sdhci0 {
    +       bootph-all;
            status = "okay";
    -       vmmc-supply = <&wlan_en>;
    -       bus-width = <4>;
            non-removable;
    -       cap-power-off-card;
    -       keep-power-in-suspend;
            ti,driver-strength-ohm = <50>;
    -
    -       #address-cells = <1>;
    -       #size-cells = <0>;
    -       wlcore: wlcore@2 {
    -               compatible = "ti,wl1837";
    -               reg = <2>;
    -               pinctrl-0 = <&main_wlan_pins_default>;
    -               pinctrl-names = "default";
    -               interrupt-parent = <&main_gpio0>;
    -               interrupts = <46 IRQ_TYPE_EDGE_FALLING>;
    -       };
    -};
    -
    -/* SD/MMC */
    -&sdhci1 {
    -       bootph-all;
    -       status = "okay";
    -       vmmc-supply = <&vdd_mmc1>;
    -       pinctrl-names = "default";
    -       pinctrl-0 = <&main_mmc1_pins_default>;
            disable-wp;
     };
    
    @@ -543,11 +315,6 @@
     &cpsw3g {
            pinctrl-names = "default";
            pinctrl-0 = <&rgmii1_pins_default>, <&rgmii2_pins_default>;
    -
    -       /* Map HW8_TS_PUSH to GENF1 */
    -       cpts@3d000 {
    -               ti,pps = <7 1>;
    -       };
     };
    
     &cpsw_port1 {
    @@ -566,7 +333,7 @@
            pinctrl-0 = <&mdio1_pins_default>;
    
            cpsw3g_phy0: ethernet-phy@0 {
    -               reg = <0>;
    +               reg = <2>;
                    ti,rx-internal-delay = <DP83867_RGMIIDCTL_2_00_NS>;
                    ti,fifo-depth = <DP83867_PHYCR_FIFO_DEPTH_4_B_NIB>;
            };
    @@ -606,32 +373,42 @@
    
                            partition@0 {
                                    label = "ospi.tiboot3";
    -                               reg = <0x0 0x100000>;
    +                               reg = <0x0 0x80000>;
                            };
    
    -                       partition@100000 {
    +                       partition@80000 {
                                    label = "ospi.tispl";
    -                               reg = <0x100000 0x200000>;
    +                               reg = <0x80000 0x200000>;
                            };
    
    -                       partition@300000 {
    +                       partition@280000 {
                                    label = "ospi.u-boot";
    -                               reg = <0x300000 0x400000>;
    +                               reg = <0x280000 0x400000>;
                            };
    
    -                       partition@700000 {
    +                       partition@680000 {
                                    label = "ospi.env";
    -                               reg = <0x700000 0x40000>;
    +                               reg = <0x680000 0x40000>;
                            };
    
    -                       partition@740000 {
    +                       partition@6c0000 {
                                    label = "ospi.env.backup";
    -                               reg = <0x740000 0x40000>;
    +                               reg = <0x6c0000 0x40000>;
    +                       };
    +
    +                       partition@700000 {
    +                               label = "ospi.dtb";
    +                               reg = <0x700000 0x100000>;
                            };
    
                            partition@800000 {
    +                               label = "ospi.kernel";
    +                               reg = <0x800000 0x1400000>;
    +                       };
    +
    +                       partition@1c00000 {
                                    label = "ospi.rootfs";
    -                               reg = <0x800000 0x37c0000>;
    +                               reg = <0x1c00000 0x23C0000>;
                            };
    
                            partition@3fc0000 {
    @@ -711,37 +488,3 @@
            status = "okay";
     };
    
    -&ecap0 {
    -       status = "okay";
    -       /* PWM is available on Pin 1 of header J3 */
    -       pinctrl-names = "default";
    -       pinctrl-0 = <&main_ecap0_pins_default>;
    -};
    -
    -&eqep0 {
    -       status = "okay";
    -       /* EQEP0 A & B available on pins 18 & 22 of J4 header */
    -       pinctrl-names = "default";
    -       pinctrl-0 = <&main_eqep0_pins_default>;
    -};
    -
    -#define TS_OFFSET(pa, val)     (0x4+(pa)*4) (0x10000 | val)
    -
    -&timesync_router {
    -       status = "okay";
    -       pinctrl-names = "default";
    -       pinctrl-0 = <&cpsw_cpts_pps>;
    -
    -       /*
    -        * Use Time Sync Router to map GENF1 input to HW8_TS_PUSH output as well
    -        * as the PRU ICSSG0 SYNC1 output.
    -        */
    -       cpsw_cpts_pps: cpsw-cpts-pps {
    -               pinctrl-single,pins = <
    -                       /* pps [cpts genf1] in22 -> out37 [cpts hw8_push] */
    -                       TS_OFFSET(37, 22)
    -                       /* pps [cpts genf1] in22 -> out26 [SYNC1_OUT pin] */
    -                       TS_OFFSET(26, 22)
    -                       >;
    -       };
    -};
    diff -bur orig/k3-am642-sk-u-boot.dtsi mod/k3-am642-sk-u-boot.dtsi
    --- orig/k3-am642-sk-u-boot.dtsi        2024-09-18 12:28:01.741954600 +0200
    +++ mod/k3-am642-sk-u-boot.dtsi 2024-09-30 09:58:12.065193900 +0200
    @@ -41,15 +41,6 @@
     };
    
     &sdhci0 {
    -       status = "disabled";
    -       bootph-all;
    -};
    -
    -&sdhci1 {
    -       bootph-all;
    -};
    -
    -&main_mmc1_pins_default {
            bootph-all;
     };
    
    @@ -93,6 +84,10 @@
            bootph-all;
     };
    
    +&cpsw_port1 {
    +       bootph-all;
    +};
    +
     &cpsw_port2 {
            bootph-all;
     };
    @@ -117,10 +112,6 @@
            bootph-all;
     };
    
    -&cpsw3g_phy1 {
    -       bootph-all;
    -};
    -
     &main_usb0_pins_default {
            bootph-all;
     };
    

  • I also send the modified SK DTB files versus the originals :

    diff_sk.zip

  • Hi Marc,

    Typically this type of Bus errors is caused by accessing the module registers while the module is not powered or clocked. But I reviewed your device tree change and don't see anything obviously could cause it.

    Did you modify the U-Boot defconfig files am64x_evm_r5_defconfig and am64x_evm_a53_defconfig?

    Can you please apply the following U-Boot patch and see if you will see both new debug messages in the U-Boot log when starting USB? If both messages are printed, the issue is not related to USB module powering or clocking. But if only the first message is printed before the reset, it is the power or clock issue.

    diff --git a/drivers/usb/cdns3/cdns3-ti.c b/drivers/usb/cdns3/cdns3-ti.c
    index 2e44aadea47b..670b7bac031b 100644
    --- a/drivers/usb/cdns3/cdns3-ti.c
    +++ b/drivers/usb/cdns3/cdns3-ti.c
    @@ -121,7 +121,9 @@ static int cdns_ti_probe(struct udevice *dev)
            rate_code = i;
     
            /* assert RESET */
    +       dev_info(dev, "before first read\n");
            reg = cdns_ti_readl(data, USBSS_W1);
    +       dev_info(dev, "after first read\n");
            reg &= ~USBSS_W1_PWRUP_RST;
            cdns_ti_writel(data, USBSS_W1, reg);

  • Hi Bin,

    to my best knowledge, the defconfigs are original.

    Adding the debug traces doesn't give any feedback : is the crash happening before probe of the cadence usb driver?

    -------------------------------------------------
    Sending: u-boot.img
    Bytes Sent:1350272   BPS:9541
    Sending:
    Ymodem sectors/kbytes sent:   0/ 0k
    Transfer complete
    [board_fit_config_name_match]
    [board_fit_config_name_match]
    [bing config 'k3-am642-sk'
    Loaded 1350239 bytes
    [display_options]
    
    
    U-Boot 2024.04-dirty (Sep 30 2024 - 16:33:33 +0200)
    
    SoC:   AM64X SR2.0 HS-FS
    Model: Texas Instruments AM642 SK
    [checkboard]
    [do_board_detect]
    Board: AM64B-SKEVM rev
    DRAM:  2 GiB
    [board_init]
    Core:  79 devices, 30 uclasses, devicetree: separate
    NAND:  0 MiB
    MMC:   mmc@fa10000: 0
    Loading Environment from nowhere... OK
    In:    serial@2800000
    Out:   serial@2800000
    Err:   serial@2800000
    Failed to probe prueth driver
    [board_late_init]
    [setup_board_eeprom_env]
    [do_board_detect]
    [setup_board_eeprom_env]: am64x_skevm
    [setup_board_eeprom_env]
    [setup_serial]
    Net:   eth0: ethernet@8000000port@1
    Warning: ethernet@8000000port@2 (eth1) using random MAC address - 96:5a:d7:87:b6:9a
    , eth1: ethernet@8000000port@2
    Hit any key to stop autoboot:  0
    switch to partitions #0, OK
    mmc0(part 0) is current device
    SD/MMC found on device 0
    Can't set block device
    ** No partition table - mmc 0 **
    ** No partition table - mmc 0 **
    Couldn't find partition mmc 0:2
    Can't set block device
    ** No partition table - mmc 0 **
    Couldn't find partition mmc 0:2
    Can't set block device
    libfdt fdt_check_header(): FDT_ERR_BADMAGIC
    No FDT memory address configured. Please configure
    the FDT address via "fdt addr <address>" command.
    Aborting!
    Bad Linux ARM64 Image magic!
    Scanning for bootflows in all bootdevs
    Seq  Method       State   Uclass    Part  Name                      Filename
    ---  -----------  ------  --------  ----  ------------------------  ----------------
    Scanning global bootmeth 'efi_mgr':
    No EFI system partition
    No EFI system partition
    Failed to persist EFI variables
    No EFI system partition
    Failed to persist EFI variables
    No EFI system partition
    Failed to persist EFI variables
      0  efi_mgr      ready   (none)       0  <NULL>
    ** Booting bootflow '<NULL>' with efi_mgr
    Loading Boot0000 'mmc 0' failed
    EFI boot manager: Cannot load any image
    Boot failed (err=-14)
    Scanning bootdev 'mmc@fa10000.bootdev':
    Bus usb@f400000: Register 2000840▒02000000011a0000616d3634780000000000000048534653000002000000020002a6000000000000b018658ad99dc903c8c9bfb27b12751099920a042ad1dfea7b7ba57369f15546de285edde6a7b39a8bdc40a27b237f8fb1e57f245e80b929c1e28b024aa2ecc6ad0bc40b0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000006dbe88622e2543b0f764e78d09320445844765a3faab5cda29503a493f788023CCCCCCCCCCCCCCCCCCCCCC
    

  • Hi Marc,

    Sorry, please change the function name "dev_info" to "dev_err" in the patch. I don't typically debug u-boot code, but now I just ran the patch on my board, and it seems dev_info() really don't print anything on the console, but dev_err() does. Here is the working log on my board with dev_err().

    => usb start
    starting USB...
    Bus usb@f400000: cdns-ti cdns-usb@f900000: before first read
    cdns-ti cdns-usb@f900000: after first read
    Register 2000840 NbrPorts 2
    Starting the controller
    USB XHCI 1.00
    scanning bus usb@f400000 for devices... 1 USB Device(s) found
           scanning usb for storage devices... 0 Storage Device(s) found

  • Hi Bin,

    it seems both debug prints pass, so I added some more. The crash is not happening in the probe function.

    Sending: u-boot.img
    Bytes Sent:1350528   BPS:9590
    Sending:
    Ymodem sectors/kbytes sent:   0/ 0k
    Transfer complete
    Loaded 1350527 bytes
    [display_options]
    
    
    U-Boot 2024.04-dirty (Sep 30 2024 - 17:48:07 +0200)
    
    SoC:   AM64X SR2.0 HS-FS
    Model: Texas Instruments AM642 SK
    [checkboard]
    [do_board_detect]
    Board: AM64B-SKEVM rev
    DRAM:  2 GiB
    [board_init]
    Core:  79 devices, 30 uclasses, devicetree: separate
    NAND:  0 MiB
    MMC:   mmc@fa10000: 0
    Loading Environment from nowhere... OK
    In:    serial@2800000
    Out:   serial@2800000
    Err:   serial@2800000
    Failed to probe prueth driver
    [board_late_init]
    [setup_board_eeprom_env]
    [do_board_detect]
    [setup_board_eeprom_env]: am64x_skevm
    [setup_board_eeprom_env]
    [setup_serial]
    Net:   eth0: ethernet@8000000port@1
    Warning: ethernet@8000000port@2 (eth1) using random MAC address - ce:87:b4:44:c9:07
    , eth1: ethernet@8000000port@2
    Hit any key to stop autoboot:  0
    switch to partitions #0, OK
    mmc0(part 0) is current device
    SD/MMC found on device 0
    Can't set block device
    ** No partition table - mmc 0 **
    ** No partition table - mmc 0 **
    Couldn't find partition mmc 0:2
    Can't set block device
    ** No partition table - mmc 0 **
    Couldn't find partition mmc 0:2
    Can't set block device
    libfdt fdt_check_header(): FDT_ERR_BADMAGIC
    No FDT memory address configured. Please configure
    the FDT address via "fdt addr <address>" command.
    Aborting!
    Bad Linux ARM64 Image magic!
    Scanning for bootflows in all bootdevs
    Seq  Method       State   Uclass    Part  Name                      Filename
    ---  -----------  ------  --------  ----  ------------------------  ----------------
    Scanning global bootmeth 'efi_mgr':
    No EFI system partition
    No EFI system partition
    Failed to persist EFI variables
    No EFI system partition
    Failed to persist EFI variables
    No EFI system partition
    Failed to persist EFI variables
      0  efi_mgr      ready   (none)       0  <NULL>
    ** Booting bootflow '<NULL>' with efi_mgr
    Loading Boot0000 'mmc 0' failed
    EFI boot manager: Cannot load any image
    Boot failed (err=-14)
    Scanning bootdev 'mmc@fa10000.bootdev':
    Bus usb@f400000: cdns-ti cdns-usb@f900000: before first read
    cdns-ti cdns-usb@f900000: after first read
    [cdns_ti_probe] line 135
    [cdns_ti_probe] line 141
    [cdns_ti_probe] line 145
    [cdns_ti_probe] line 152
    [cdns_ti_probe] line 166
    [cdns_ti_probe] line 171
    Register 2000840▒02000000011a0000616d3634780000000000000048534653000002000000020002a6000000000000b018658ad99dc903c8c9bfb27b12751099920a042ad1dfea7b7ba57369f15546de285edde6a7b39a8bdc40a27b237f8fb1e57f245e80b929c1e28b024aa2ecc6ad0bc40b0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000006dbe88622e2543b0f764e78d09320445844765a3faab5cda29503a493f788023CCCCCCCCCCCCCC
    

  • Hi Marc,

    The next USB probe function would be cdns3_probe() in drivers/usb/cdns3/core.c. Please add some print in this function to see if the crash happens here.

  • Hi,

    I added some debug statements as deep as I could. It seems the crash happens when switching roles (to HOST mode, I presume).

    Not all debug lines show up (probably due to lagging of the printk function in tty buffers), but I think the crash occurs in 

    xhci_lowlevel_init()

    because there is also the following print statement which in earlier logs showed up right before the crash :

        printf("Register %x NbrPorts %d\n", reg, ctrl->hub_desc.bNbrPorts);
    

    I hope this gives you more information?

    kind regards, Marc

    Sending: u-boot.img
    Bytes Sent:1351680   BPS:9531
    Sending:
    Ymodem sectors/kbytes sent:   0/ 0k
    Transfer complete
    Loaded 1351623 bytes
    [display_options]
    
    
    U-Boot 2024.04-dirty (Oct 01 2024 - 09:48:08 +0200)
    
    SoC:   AM64X SR2.0 HS-FS
    Model: Texas Instruments AM642 SK
    [checkboard]
    [do_board_detect]
    Board: AM64B-SKEVM rev
    DRAM:  2 GiB
    [board_init]
    Core:  79 devices, 30 uclasses, devicetree: separate
    NAND:  0 MiB
    MMC:   mmc@fa10000: 0
    Loading Environment from nowhere... OK
    In:    serial@2800000
    Out:   serial@2800000
    Err:   serial@2800000
    Failed to probe prueth driver
    [board_late_init]
    [setup_board_eeprom_env]
    [do_board_detect]
    [setup_board_eeprom_env]: am64x_skevm
    [setup_board_eeprom_env]
    [setup_serial]
    Net:   eth0: ethernet@8000000port@1
    Warning: ethernet@8000000port@2 (eth1) using random MAC address - 62:50:68:9a:10:f6
    , eth1: ethernet@8000000port@2
    Hit any key to stop autoboot:  0
    switch to partitions #0, OK
    mmc0(part 0) is current device
    SD/MMC found on device 0
    Can't set block device
    ** No partition table - mmc 0 **
    ** No partition table - mmc 0 **
    Couldn't find partition mmc 0:2
    Can't set block device
    ** No partition table - mmc 0 **
    Couldn't find partition mmc 0:2
    Can't set block device
    libfdt fdt_check_header(): FDT_ERR_BADMAGIC
    No FDT memory address configured. Please configure
    the FDT address via "fdt addr <address>" command.
    Aborting!
    Bad Linux ARM64 Image magic!
    Scanning for bootflows in all bootdevs
    Seq  Method       State   Uclass    Part  Name                      Filename
    ---  -----------  ------  --------  ----  ------------------------  ----------------
    Scanning global bootmeth 'efi_mgr':
    No EFI system partition
    No EFI system partition
    Failed to persist EFI variables
    No EFI system partition
    Failed to persist EFI variables
    No EFI system partition
    Failed to persist EFI variables
      0  efi_mgr      ready   (none)       0  <NULL>
    ** Booting bootflow '<NULL>' with efi_mgr
    Loading Boot0000 'mmc 0' failed
    EFI boot manager: Cannot load any image
    Boot failed (err=-14)
    Scanning bootdev 'mmc@fa10000.bootdev':
    Bus usb@f400000: cdns-ti cdns-usb@f900000: before first read
    cdns-ti cdns-usb@f900000: after first read
    [cdns_ti_probe] line 135
    [cdns_ti_probe] line 141
    [cdns_ti_probe] line 145
    [cdns_ti_probe] line 152
    [cdns_ti_probe] line 166
    [cdns_ti_probe] line 171
    [cdns3_probe] line 344
    [cdns3_probe] line 349
    [cdns3_probe] line 356
    [cdns3_probe] line 369
    [cdns3_probe] line 382
    [cdns3_probe] line 387
    [cdns3_probe] line 392
    [cdns3_probe] line 397
    [cdns3_core_init_role] line 115
    [cdns3_core_init_role] line 124
    [cdns3_core_init_role] line 141
    [cdns3_core_init_role] line 157
    [cdns3_host_init] line 46
    [cdns3_core_init_role] line 169
    [cdns3_core_init_role] line 183
    [cdns3_core_init_role] line 188
    [cdns3_hw_role_switch] line 302
    [cdns3_hw_role_switch] line 308
    [cdns3_hw_role_switch] line 315
    [cdns3_hw_role_switch] line 320 : role 0 -> 1
    [cdns3_role_start] line 57
    [cdns3_role_start] line 69
    [__cdns3_host_init] line 25
    [__cdns3_host_init▒02000000011a0000616d3634780000000000000048534653000002000000020002a6000000000000b018658ad99dc903c8c9bfb27b12751099920a042ad1dfea7b7ba57369f15546de285edde6a7b39a8bdc40a27b237f8fb1e57f245e80b929c1e28b024aa2ecc6ad0bc40b0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000006dbe88622e2543b0f764e78d09320445844765a3faab5cda29503a493f788023CCCCCCCCCCCCC
    

  • here with the source files for interpreting the line numbers..7065.usb.zip

  • I just noticed that the USB power switch we are using is different from the one in the SK devkit. We are using TPS2552DRV (Enable input, logic low turns on power switch) while SK kit uses TPS2051CDBVR (Enable input, logic high turns on power switch).

    So the required polarity for USB power switch enable line (AM64 pin E19, signal USB0_DRVVBUS) is different for my custom board... So quite likely this will be the cause of the crash I'm seeing.

    Is there a way to change via DTB?

    If not, is there a way to change via patch in the Cadence CDNS3 driver code?

    thanks for the help,
    Marc

  • I need to recall my last message, since I overlooked that we invert the USB0_DRVVBUS signal to cope with the different polarity of the USB switch... I'm adding here the section of the schematic with the enable signal inverter and the power switch.

    So this would *not* be the cause of the crash..

  • Hi Marc,

    Even if you didn't revert the DRVVBUS signal, I don't think it is the cause. The DRVVBUS signal is to enable VBUS power for the attached USB device, it shouldn't have anything to do with the USB controller.

    I am going to review your update of the debug information in a couple hours.

  • Hi Marc,

    xhci_lowlevel_init()

    because there is also the following print statement which in earlier logs showed up right before the crash :

        printf("Register %x NbrPorts %d\n", reg, ctrl->hub_desc.bNbrPorts);

    Thanks for pointing this out. Now I noticed we have 3 different prints right before the crash/reset.

    - Bus usb@f400000: 02000000011...
    - Bus usb@f400000: Register 2000840▒0...
    - [__cdns3_host_init▒0200000001...

    This seems showing the reset happened at different places of the execution.

    Now let's check the board hardware, can you please probe all the power rails when you run command "usb start" to trigger the reset? and check if they are all in the valid ranges defined in the Datasheet?

    I am wondering if the issue is due to insufficient power supply which causes power droops when starting the USB module, and causes the SoC reset.

  • Hi,

    could you be more specific of which supplies are of interest? I assume core voltages especially, which are supplying the AM64?

    I now also notice that USB0_ID signal is floating. Could that be problematic?

    kind regards,

    Marc

  • Marc,

    could you be more specific of which supplies are of interest? I assume core voltages especially, which are supplying the AM64?

    I actually don't know if it would be one particular power rail. I believe there are several rails go to AM64x. You might start with VDD_CORE and VDD_MPU.

    This issue happened many times in the past. Whenever I asked customer to probe power rails, they always found the power supply design defect. And the reset problem got resolved after fixed the power supply issue, but customers never told me which rail had the problem.

    I now also notice that USB0_ID signal is floating. Could that be problematic?

    It is not. The ID pin is ignored when dr_mode = "host" or "peripheral" in device tree.

  • Hi,

    There was indeed a glitch in the primary 5V input power rail; due to a power switch which was implemented on the development target (test automation for cold boot). Bypassing this power switch solved the USB issue!

    thanks for your guidance and support!

    kind regards,
    Marc

  • Hi Marc,

    I am glad the issue is resolved. Thanks for the update.