Other Parts Discussed in Thread: AM3352, TPS65217
Hi,
I have a custom board and it is not booting the Linux kernel. I'm trying with a process that already works in a BBB. This custom board has 128MB of RAM and does not have the HW ID e2prom. Searching the forum, I made the following changes to u-boot:
board/ti/am335x/board.h:
static inline int board_is_bone_lt(void)
{
return 1;
//return board_ti_is("A335BNLT");
}
include/configs/ti_am335x_common.h:
/*#define CONFIG_MAX_RAM_BANK_SIZE (1024 << 20)*/ /* 1GB */
#define CONFIG_MAX_RAM_BANK_SIZE (128 << 20) /* 128MB */
include/configs/ti_amv7_common.h:
#define DEFAULT_LINUX_BOOT_ENV \
"loadaddr=0x82000000\0" \
"kernel_addr_r=0x82000000\0" \
"fdtaddr=0x84000000\0" \
"fdt_high=0x84000000\0" \
"dtboaddr=0x89000000\0" \
"fdt_addr_r=0x84000000\0" \
"rdaddr=0x84080000\0" \
"ramdisk_addr_r=0x84080000\0" \
"scriptaddr=0x80000000\0" \
"pxefile_addr_r=0x80100000\0" \
"bootm_size=0x10000000\0" \
"boot_fdt=try\0"
arc/arm/dts/am335x-bone.common.dtsi:
memory {
device_type = "memory";
reg = <0x80000000 0x08000000>; /* 128 MB */
};
.config:
CONFIG_BOOTCOMMAND="setenv autoload no; run init_console;dhcp;setenv bootargs 'console=ttyS0,115200n8 root=/dev/ram0 rw';tftpboot 0x82000000 zImage;tftpboot 0x84080000 initramfs;tftpboot 0x84000000 am335x-boneblack.dtb;bootz 0x82000000 0x84080000 0x84000000;"
At booting, it hang´s in loading ramdisk:
## Loading init Ramdisk from Legacy Image at 84080000 ...
Image Name: RootFilesystem
Created: 2022-03-08 17:48:59 UTC
Image Type: ARM Linux RAMDisk Image (uncompressed)
Data Size: 2887297 Bytes = 2.8 MiB
Load Address: 84080000
Entry Point: 84080000
Verifying Checksum ... OK
## Flattened Device Tree blob at 84000000
Booting using the fdt blob at 0x84000000
Loading Ramdisk to 8fd3f000, end 8ffffe81 ...
What did I forget to change?
At BBB, it work´s:
## Loading init Ramdisk from Legacy Image at 84080000 ...
Image Name: RootFilesystem
Created: 2022-03-08 17:48:59 UTC
Image Type: ARM Linux RAMDisk Image (uncompressed)
Data Size: 2887297 Bytes = 2.8 MiB
Load Address: 84080000
Entry Point: 84080000
Verifying Checksum ... OK
## Flattened Device Tree blob at 84000000
Booting using the fdt blob at 0x84000000
Loading Ramdisk to 8fd3f000, end 8ffffe81 ... OK
Loading Device Tree to 83fee000, end 83fff7f0 ... OK
Starting kernel ...
[ 0.000000] Booting Linux on physical CPU 0x0
[ 0.000000] Linux version 5.4.106-g023faefa70 (root@uservm-VirtualBox) (gcc version 9.2.1 20191025 (GNU Toolchain for the A-profile Architecture 9.2-2019.12 (arm-9.10))) #7 PREEMPT Wed Dec 1 07:13:43 -03 2021
[ 0.000000] CPU: ARMv7 Processor [413fc082] revision 2 (ARMv7), cr=10c5387d
[ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[ 0.000000] OF: fdt: Machine model: TI AM335x BeagleBone Black
[ 0.000000] Memory policy: Data cache writeback
[ 0.000000] efi: Getting EFI parameters from FDT:
[ 0.000000] efi: UEFI not found.
[ 0.000000] INITRD: 0x8fd3f000+0x002c1000 is not a memory region - disabling initrd
[ 0.000000] cma: Reserved 48 MiB at 0x84800000
[ 0.000000] CPU: All CPU(s) started in SVC mode.
[ 0.000000] AM335X ES2.1 (sgx neon)
[ 0.000000] Built 1 zonelists, mobility grouping on. Total pages: 32226
[ 0.000000] Kernel command line: console=ttyS0,115200n8 root=/dev/ram0 rw
[ 0.000000] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes, linear)
[ 0.000000] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes, linear)
[ 0.000000] mem auto-init: stack:off, heap alloc:off, heap free:off
[ 0.000000] Memory: 62320K/130048K available (9216K kernel code, 295K rwdata, 3064K rodata, 3072K init, 254K bss, 18576K reserved, 49152K cma-reserved, 0K highmem)
Following the complete log:
CCCCCCCC
U-Boot SPL 2020.01-gf0280d9-dirty (Mar 07 2022 - 14:50:17 -0300)
Trying to boot from USB eth
Warning: usb_ether using MAC address from ROM
eth0: usb_ether
using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in
MAC de:ad:be:ef:00:01
HOST MAC de:ad:be:ef:00:00
RNDIS ready
Change timeout...
musb-hdrc: peripheral reset irq lost!
high speed config #2: 2 mA, Ethernet Gadget, using RNDIS
USB RNDIS network up!
BOOTP broadcast 1
BOOTP broadcast 2
BOOTP broadcast 3
BOOTP broadcast 4
BOOTP broadcast 5
BOOTP broadcast 6
*** Unhandled DHCP Option in OFFER/ACK: 7
*** Unhandled DHCP Option in OFFER/ACK: 7
DHCP client bound to address 192.168.100.64 (10463 ms)
Using usb_ether device
TFTP from server 192.168.100.1; our IP address is 192.168.100.64
Filename 'u-boot-am335x-evm.img'.
Load address: 0x82000000
Loading: #################################################################
#################################################################
##################
2.3 MiB/s
done
Bytes transferred = 755332 (b8684 hex)
U-Boot 2020.01-gacbd275-dirty (Mar 10 2022 - 06:04:00 -0300)
CPU : AM335X-GP rev 2.1
Model: TI AM335x BeagleBone Black
DRAM: 128 MiB
WDT: Started with servicing (60s timeout)
NAND: 0 MiB
MMC: OMAP SD/MMC: 0, OMAP SD/MMC: 1
Loading Environment from FAT... <ethaddr> not set. Validating first E-fuse MAC
Net:
Warning: usb_ether MAC addresses don't match:
Address in ROM is de:ad:be:ef:00:01
Address in environment is cc:33:31:82:66:d6
eth0: usb_ether
Hit any key to stop autoboot: 0
using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in
MAC de:ad:be:ef:00:01
HOST MAC de:ad:be:ef:00:00
RNDIS ready
Change timeout...
musb-hdrc: peripheral reset irq lost!
high speed config #2: 2 mA, Ethernet Gadget, using RNDIS
USB RNDIS network up!
BOOTP broadcast 1
BOOTP broadcast 2
BOOTP broadcast 3
BOOTP broadcast 4
BOOTP broadcast 5
BOOTP broadcast 6
*** Unhandled DHCP Option in OFFER/ACK: 7
*** Unhandled DHCP Option in OFFER/ACK: 7
DHCP client bound to address 192.168.100.64 (10011 ms)
Warning: usb_ether MAC addresses don't match:
Address in ROM is de:ad:be:ef:00:01
Address in environment is cc:33:31:82:66:d6
using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in
MAC de:ad:be:ef:00:01
HOST MAC de:ad:be:ef:00:00
RNDIS ready
Change timeout...
musb-hdrc: peripheral reset irq lost!
high speed config #2: 2 mA, Ethernet Gadget, using RNDIS
USB RNDIS network up!
Using usb_ether device
TFTP from server 192.168.100.1; our IP address is 192.168.100.64
Load address: 0x82000000
Loading: #################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
###########################
1 MiB/s
done
Bytes transferred = 7066112 (6bd200 hex)
Warning: usb_ether MAC addresses don't match:
Address in ROM is de:ad:be:ef:00:01
Address in environment is cc:33:31:82:66:d6
using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in
MAC de:ad:be:ef:00:01
HOST MAC de:ad:be:ef:00:00
RNDIS ready
Change timeout...
musb-hdrc: peripheral reset irq lost!
high speed config #2: 2 mA, Ethernet Gadget, using RNDIS
USB RNDIS network up!
Using usb_ether device
TFTP from server 192.168.100.1; our IP address is 192.168.100.64
Load address: 0x84080000
Loading: #################################################################
#################################################################
#################################################################
##
495.1 KiB/s
done
Bytes transferred = 2887361 (2c0ec1 hex)
Warning: usb_ether MAC addresses don't match:
Address in ROM is de:ad:be:ef:00:01
Address in environment is cc:33:31:82:66:d6
using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in
MAC de:ad:be:ef:00:01
HOST MAC de:ad:be:ef:00:00
RNDIS ready
Change timeout...
musb-hdrc: peripheral reset irq lost!
high speed config #2: 2 mA, Ethernet Gadget, using RNDIS
USB RNDIS network up!
Using usb_ether device
TFTP from server 192.168.100.1; our IP address is 192.168.100.64
Load address: 0x84000000
Loading: #####
10.7 KiB/s
done
Bytes transferred = 59377 (e7f1 hex)
## Loading init Ramdisk from Legacy Image at 84080000 ...
Image Name: RootFilesystem
Created: 2022-03-08 17:48:59 UTC
Image Type: ARM Linux RAMDisk Image (uncompressed)
Data Size: 2887297 Bytes = 2.8 MiB
Load Address: 84080000
Entry Point: 84080000
Verifying Checksum ... OK
## Flattened Device Tree blob at 84000000
Booting using the fdt blob at 0x84000000
Loading Ramdisk to 8fd3f000, end 8ffffe81 ...