Tool/software: Linux
Hi all!
I have u-boot.bin working on on my board. At this moment I can load and start u-boot.bin from CCS or boot board from SPI NOR flash via u-boot-spi.gph image. But only in u-boot console. Linux don't start properly, and spinning in kernel code. Here description of problem:
All software components from Processor SDK. All of them was properly configured and build without errors as stated in appropriate manuals:
u-boot-spi.gph
skern-k2e.bin - compile with #define DEBUG
k2-fw-initrd.cpio.gz (not build - use from prebuilt images)
keystone-k2e-evm.dtb
zImage - compile with #define DEBUG in some files
Here the boot messages:
**** cut some output above ****
Hit any key to stop autoboot: 0
K2E_EMAC0 Waiting for SGMII auto negotiation to complete. done
K2E_EMAC0 Waiting for PHY auto negotiation to complete. done
Using K2E_EMAC0 device
TFTP from server 192.168.0.102; our IP address is 192.168.0.241
Filename 'swh101v/skern-k2e.bin'.
Load address: 0xc1f0000
Loading: #######
5.9 KiB/s
done
Bytes transferred = 32832 (8040 hex)
DEBUG: skern_init(): CPU0: from = 0x00000001 dsp_base = 0x01e80000 freq = 208333333
DEBUG: skern_init(): Secure Mode: Core freq - 208333333 Hz
K2_BM_15. 07-nogit SoC:k2e built:10:53:40, Mar 6 2017
## installed monitor @ 0xc1f0000, freq [208333333], status 203390975
K2E_EMAC0 Waiting for SGMII auto negotiation to complete. done
Using K2E_EMAC0 device
TFTP from server 192.168.0.102; our IP address is 192.168.0.241
Filename 'swh101v/k2-fw-initrd.cpio.gz'.
Load address: 0x88080000
Loading: #############
1.7 MiB/s
done
Bytes transferred = 64887 (fd77 hex)
K2E_EMAC0 Waiting for SGMII auto negotiation to complete. done
Using K2E_EMAC0 device
TFTP from server 192.168.0.102; our IP address is 192.168.0.241
Filename 'swh101v/keystone-k2e-evm.dtb'.
Load address: 0x88000000
Loading: #########
1.5 MiB/s
done
Bytes transferred = 44611 (ae43 hex)
K2E_EMAC0 Waiting for SGMII auto negotiation to complete. done
Using K2E_EMAC0 device
TFTP from server 192.168.0.102; our IP address is 192.168.0.241
Filename 'swh101v/zImage'.
Load address: 0x82000000
Loading: #################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
##############################
1.6 MiB/s
done
Bytes transferred = 3480832 (351d00 hex)
Kernel image @ 0x82000000 [ 0x000000 - 0x351d00 ]
## Flattened Device Tree blob at 88000000
Booting using the fdt blob at 0x88000000
Loading Ramdisk to 8fff0000, end 8ffffd77 ... OK
Loading Device Tree to 8ffe2000, end 8ffefe42 ... OK
ft_board_setup()
ft_board_setup_ex()
Starting kernel ...
Uncompressing Linux... done, booting the kernel.
DEBUG: skern_poweron_cpu(): >>>> skern_poweron_cpu(1) >>>>
DEBUG: skern_123_init(): Secure Mode: Core freq - 208333333 Hz
DEBUG: skern_poweron_cpu(): >>>> skern_poweron_cpu(2) >>>>
DEBUG: skern_123_init(): Secure Mode: Core freq - 208333333 Hz
DEBUG: skern_poweron_cpu(): >>>> skern_poweron_cpu(3) >>>>
DEBUG: skern_123_init(): Secure Mode: Core freq - 208333333 Hz
Booting process stop here :(
I was try to debug this issue, and found that processor is working in linux area code and not hung. I can connect to A15 Core0 in CCS via JTAG.
1) Can you look into debug messages from boot monitor, and tell about monitor install errors? May be installed address not valid? In ti wiki address noted as 0x0C140000 but in boot-monitor code install address is 0x0C1F0000.
2) Can you tell me, please about possible reasons of such behavior and how I can debug this issue? If you need any additional information I will provide it.
3) Can you look into u-boot environment settings and compare it with EVM settings? May be some addresses are not valid? Thank you.
4) On my board installed less memory than on evm. No NAND, SD. Please can you tell me, how I can fix this issue in dtb?
Thank you.
P.S. U-boot environment settings:
addr_mon=0x0C1F0000
addr_secdb_key=0xc000000
addr_ubi=0x82000000
arch=arm
args_all=setenv bootargs console=ttyS0,115200n8 rootwait=1
args_net=setenv bootargs ${bootargs} rootfstype=nfs root=/dev/nfs rw nfsroot=${serverip}:${nfs_root},${nfs_options} ip=dhcp
args_ramfs=setenv bootargs ${bootargs} rdinit=/sbin/init rw root=/dev/ram0 initrd=0x808080000,80M
args_ubi=setenv bootargs ${bootargs} rootfstype=ubifs root=ubi0:rootfs rootflags=sync rw ubi.mtd=ubifs,2048
baudrate=115200
board=ks2_evm
board_name=ks2_evm
boot=net
boot_fdt=try
bootargs=console=ttyS0,115200n8 rootwait=1 rootfstype=nfs root=/dev/nfs rw nfsroot=192.168.0.102:/home/karak/targetfs-swh101v,v3,tcp,rsize=4096,wsize=4096 ip=dhcp
bootcmd=run init_${boot} get_mon_${boot} run_mon init_fw_rd_${boot} get_fdt_${boot} get_kern_${boot} run_kern
bootcmd_old=run init_${boot} get_mon_${boot} run_mon init_fw_rd_${boot} get_fdt_${boot} get_kern_${boot} run_kern
bootdelay=2
bootdir=/boot
bootm_size=0x10000000
burn_ubi=nand erase.part ubifs; nand write ${addr_ubi} ubifs ${filesize}
burn_uboot_nand=nand erase 0 0x100000; nand write ${loadaddr} 0 ${filesize}
burn_uboot_spi=sf probe; sf erase 0 0x90000; sf write ${loadaddr} 0 ${filesize}
cpu=armv7
ethact=K2E_EMAC0
ethaddr=b4:99:4c:11:64:36
fdt_addr_r=0x88000000
fdtaddr=0x88000000
fdtcontroladdr=beef3388
fileaddr=88000000
filesize=ae43
get_fdt_net=tftp ${fdtaddr} ${tftp_root}/${name_fdt}
get_fdt_nfs=nfs ${fdtaddr} ${nfs_root}/boot/${name_fdt}
get_fdt_ramfs=dhcp ${fdtaddr} ${tftp_root}/${name_fdt}
get_fdt_ubi=ubifsload ${fdtaddr} ${bootdir}/${name_fdt}
get_fs_ramfs=dhcp ${rdaddr} ${tftp_root}/${name_fs}
get_kern_net=tftp ${loadaddr} ${tftp_root}/${name_kern}
get_kern_nfs=nfs ${loadaddr} ${nfs_root}/boot/${name_kern}
get_kern_ramfs=dhcp ${loadaddr} ${tftp_root}/${name_kern}
get_kern_ubi=ubifsload ${loadaddr} ${bootdir}/${name_kern}
get_mon_net=tftp ${addr_mon} ${tftp_root}/${name_mon}
get_mon_nfs=nfs ${addr_mon} ${nfs_root}/boot/${name_mon}
get_mon_ramfs=dhcp ${addr_mon} ${tftp_root}/${name_mon}
get_mon_ubi=ubifsload ${addr_mon} ${bootdir}/${name_mon}
get_ubi_net=dhcp ${addr_ubi} ${tftp_root}/${name_ubi}
get_ubi_nfs=nfs ${addr_ubi} ${nfs_root}/boot/${name_ubi}
get_uboot_net=tftp ${loadaddr} ${tftp_root}/${name_uboot}
get_uboot_nfs=nfs ${loadaddr} ${nfs_root}/boot/${name_uboot}
init_fw_rd_net=tftp ${rdaddr} ${tftp_root}/${name_fw_rd}; run set_rd_spec
init_fw_rd_ramfs=setenv rd_spec -
init_fw_rd_ubi=ubifsload ${rdaddr} ${bootdir}/${name_fw_rd}; run set_rd_spec
init_net=run args_all args_net
init_nfs=setenv autoload no; dhcp; run args_all args_net
init_ramfs=run args_all args_ramfs get_fs_ramfs
init_ubi=run args_all args_ubi; ubi part ubifs; ubifsmount ubi:rootfs;
ipaddr=192.168.0.241
kernel_addr_r=0x82000000
loadaddr=0x82000000
mem_lpae=0
mtdparts=mtdparts=davinci_nand.0:1024k(bootloader)ro,512k(params)ro,-(ubifs)
name_fdt=keystone-k2e-evm.dtb
name_fs=arago-console-image-k2e-evm.cpio.gz
name_fw_rd=k2-fw-initrd.cpio.gz
name_kern=zImage
name_mon=skern-k2e.bin
name_ubi=k2e-evm-ubifs.ubi
name_uboot=u-boot-spi.gph
nfs_options=v3,tcp,rsize=4096,wsize=4096
nfs_root=/home/karak/targetfs-swh101v
no_post=1
pxefile_addr_r=0x80100000
ramdisk_addr_r=0x88080000
rd_spec=0x88080000:8040
rdaddr=0x88080000
run_kern=bootz ${loadaddr} ${rd_spec} ${fdtaddr}
run_mon=mon_install ${addr_mon}
scriptaddr=0x80000000
serverip=192.168.0.102
set_rd_spec=setenv rd_spec ${rdaddr}:${filesize}
soc=keystone
stderr=serial@02530c00
stdin=serial@02530c00
stdout=serial@02530c00
tftp_root=swh101v
vendor=ti
ver=U-Boot 2016.05-00304-ged00144-dirty (Mar 02 2017 - 16:51:47 +0300)