Other Parts Discussed in Thread: BEAGLEBOARD-X15, AM5728, PMP
Tool/software: Linux
Hi,
I'm trying to get a network boot up and running on the 572X EVM, using the out of the box Linux SDK for the 572x EVM, version 3.01.00.06. I've attempted to configure both the TFTP and NFS servers as static. Furthermore, I've attempted to configure the uboot.env environment variables to allow both static TFTP server and NFS server configuration, but during kernel boot, while the kernel appears to load from the static TFTP server, the kernel appears to be sending DHCP/RARP requests to find and mount the NFS server.
The test configuration is currently a little strange. I'm using an intermediate BeagleBone black as the TFTP server to load the 572XEVM with the kernel, while I'm attempting to use an Ubuntu VM to directly host the NFS server. I wasn't able to get the Ubuntu VM to also host the TFTP server within a "reasonable timeframe" due to port 69 conflicts with PXELiteServer running on the host Windows machine, so that and other protections/policies by our IT department is why a more experienced LInux person suggested I try using the BBB as an intermediate. I may end up having to use the BBB as both the TFTP server, NFS server, and DHCP server (if the SDK's default kernel build is only able to get the NFS server IP via DHCHP).
The test configuration, console bootup log, and environment variables are below. Also, I commented out everything in UEnv.txt. I am relatively new to the embedded Linux and new to the net booting process.
I found a thread for the 3539/Beaglebone with the very same issue (thread "unable to boot from NFS with static ip on am335x evm (sdk6) "), and configured the 572XEVM environment variables per that thread, but my kernel still is looking for a DHCP server for the NFS server address. Also, I attempted to remove any references to DHCP to any of the environment variables, but was wondering if there's anything else one needs to do to hand the static NFS server address to the kernel on the 5718 SDK (see version above) . The Linux Core U-Boot User's guide indicates "..The most important variables in AM57x/DRA7x are rootpath and nfsopts, and tftp_root and nfs_root in K2H/K/E/L/G....."
Please take a look below.
Thanks! Jeff
Test Environment Configuration (probably needs a picture):
*A switch/hub with the following entities on a static IP network.
1)An Ubuntu VM as the host machine (192.168.8.10, 255.255.255.0)
2)An intermediate BeagleBone Black as the TFTP server (192.168.8.9, 255.255.255.0)
3)AM572XEVM - with SDCard only (MLO, uboot.env, u-boot.img, uEnv.txt (all lines commented out) (192.168.8.2, 255.255.255.0)
Console Bootup Log (excerpt):
U-Boot SPL 2016.05-g2f757e5b2c (Oct 03 2016 - 19:01:26)
DRA752-GP ES2.0
Trying to boot from MMC1
reading args
spl_load_image_fat_os: error reading image args, err - -1
reading u-boot.img
reading u-boot.img
reading u-boot.img
reading u-boot.img
U-Boot 2016.05-g2f757e5b2c (Oct 03 2016 - 19:01:26 -0400)
CPU : DRA752-GP ES2.0
Model: TI AM5728 BeagleBoard-X15
Board: AM572x EVM REV A.3A
DRAM: 2 GiB
MMC: no pinctrl for sdr104
no pinctrl for ddr50
no pinctrl for sdr50
no pinctrl for sdr25
no pinctrl for sdr12
OMAP SD/MMC: 0, OMAP SD/MMC: 1
reading uboot.env
SCSI: SATA link 0 timeout.
AHCI 0001.0300 32 slots 1 ports 3 Gbps 0x1 impl SATA mode
flags: 64bit ncq stag pm led clo only pmp pio slum part ccc apst
scanning bus for devices...
Found 0 device(s).
Net: eth0: ethernet@48484000
Hit any key to stop autoboot: 2 1 0
switch to partitions #0, OK
mmc0 is current device
reading uEnv.txt
1704 bytes read in 4 ms (416 KiB/s)
Importing environment from mmc0 ...
Unknown command 'static' - try 'help'
ethernet@48484000 Waiting for PHY auto negotiation to complete.. done
link up on port 0, speed 100, full duplex
Using ethernet@48484000 device
TFTP from server 192.168.8.9; our IP address is 192.168.8.2
Filename 'zImage-am57xx-evm.bin'.
Load address: 0x82000000
Loading: *#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################################
#################################################
508.8 KiB/s
done
Bytes transferred = 3576208 (369190 hex)
link up on port 0, speed 100, full duplex
Using ethernet@48484000 device
TFTP from server 192.168.8.9; our IP address is 192.168.8.2
Filename 'am57xx-evm-reva3.dtb'.
Load address: 0x88000000
Loading: *####################
1.2 MiB/s
done
Bytes transferred = 101816 (18db8 hex)
Kernel image @ 0x82000000 [ 0x000000 - 0x369190 ]
## Flattened Device Tree blob at 88000000
Booting using the fdt blob at 0x88000000
Loading Device Tree to 8ffe4000, end 8ffffdb7 ... OK
Starting kernel ...
[ 0.000000] Booting Linux on physical CPU 0x0
[ 0.000000] Initializing cgroup subsys cpuset
[ 0.000000] Initializing cgroup subsys cpu
[ 0.000000] Initializing cgroup subsys cpuacct
[ 0.000000] Linux version 4.4.19-gdb0b54cdad (gtbldadm@ubuntu-16) (gcc version 5.3.1 20160113 (Linaro GCC 5.3-2016.02) ) #1 SMP PREEMPT Mon Oct 3 18:04:11 EDT 2016
[ 0.000000] CPU: ARMv7 Processor [412fc0f2] revision 2 (ARMv7), cr=30c5387d
[ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, PIPT instruction cache
[ 0.000000] Machine model: TI AM572x EVM Rev A3
.
.
.
[ 2.499971] IPv6: ADDRCONF(NETDEV_UP): eth1: link is not ready
[ 5.386917] cpsw 48484000.ethernet eth0: Link is Up - 100Mbps/Full - flow control rx/tx
[ 5.398311] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
[ 5.418290] Sending DHCP and RARP requests ...... timed out!
[ 87.240485] IP-Config: Reopening network devices...
[ 87.245398] net eth0: initializing cpsw version 1.15 (0)
[ 87.250785] net eth0: initialized cpsw ale version 1.4
[ 87.255946] net eth0: ALE Table size 1024
[ 87.351163] net eth0: phy found : id is : 0x221622
[ 87.360625] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[ 87.366506] net eth1: initializing cpsw version 1.15 (0)
[ 87.460362] net eth1: phy found : id is : 0x221622
[ 87.468292] IPv6: ADDRCONF(NETDEV_UP): eth1: link is not ready
[ 90.356897] cpsw 48484000.ethernet eth0: Link is Up - 100Mbps/Full - flow control rx/tx
[ 90.368310] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
[ 90.388291] Sending DHCP and RARP requests ....
[ 118.091595] random: nonblocking pool is initialized
[ 123.028280] .. timed out!
[ 179.119441] IP-Config: Auto-configuration of network failed
[ 179.125188] aic_dvdd_fixed: disabling
[ 179.128887] vmmcwl_fixed: disabling
[ 179.132586] ldousb: disabling
[ 179.136051] ALSA device list:
[ 179.139055] No soundcards found.
[ 179.143320] Root-NFS: no NFS server address
[ 179.147522] VFS: Unable to mount root fs via NFS, trying floppy.
[ 179.153876] VFS: Cannot open root device "nfs" or unknown-block(2,0): error -6
[ 179.161153] Please append a correct "root=" boot option; here are the available partitions:
[ 179.169572] b300 30375936 mmcblk0 driver: mmcblk
[ 179.174918] b301 71680 mmcblk0p1 722d9dbf-01
[ 179.180281] b302 30286848 mmcblk0p2 722d9dbf-02
[ 179.185624] b310 3735552 mmcblk1 driver: mmcblk
[ 179.190988] b311 80896 mmcblk1p1 1e50ed75-01
[ 179.196330] b312 1047552 mmcblk1p2 1e50ed75-02
[ 179.201689] b313 2604032 mmcblk1p3 1e50ed75-03
[ 179.207032] b330 4096 mmcblk1boot1 (driver?)
[ 179.212396] b320 4096 mmcblk1boot0 (driver?)
[ 179.217737] Kernel panic - not syncing: VFS: Unable to mount root fs
uBoot.env: printenv
=> printenv
arch=arm
args_mmc=run finduuid;setenv bootargs console=${console} ${optargs} root=PARTUUID=${uuid} rw rootfstype=${mmcrootfstype}
autoload=no
baudrate=115200
board=am57xx
board_name=am57xx_evm_reva3
board_rev=A.3A
board_serial=32164P551096
bootargs=console=ttyO2,115200n8 root=/dev/nfs nfsroot=192.168.8.10:/home/bhidev/ti-processor-sdk-linux-am57xx-evm-03.01.00.06/targetNFS,nolock,v3,tcp,rsize=4096,wsize=4096 rw ip=static
bootcmd=run findfdt; run getuenv; setenv autoload no;static ;tftp ${loadaddr} zImage-am57xx-evm.bin; tftp ${fdtaddr} ${fdtfile}; run netargs; bootz ${loadaddr} - ${fdtaddr}
bootdelay=2
bootdir=/tftpboot
bootenvfile=uEnv.txt
bootfile=zImage-am57xx-evm.bin
bootm_size=0x10000000
bootpart=0:2
bootscript=echo Running bootscript from mmc${mmcdev} ...; source ${loadaddr}
console=ttyO2,115200n8
cpu=armv7
dofastboot=0
envboot=mmc dev ${mmcdev}; if mmc rescan; then echo SD/MMC found on device ${mmcdev};if run loadbootscript; then run bootscript;else if run loadbootenv; then echo Loaded env from ${bootenvfile};run importbootenv;fi;if test -n $uenvcmd; then echo Running uenvcmd ...;run uenvcmd;fi;fi;fi;
ethact=ethernet@48484000
ethaddr=5c:f8:21:36:b9:f4
fdt_addr_r=0x88000000
fdtaddr=0x88000000
fdtcontroladdr=fef2cfd8
fdtfile=am57xx-evm-reva3.dtb
fileaddr=82000000
filesize=5e2
findfdt=if test $board_name = omap5_uevm; then setenv fdtfile omap5-uevm.dtb; fi; if test $board_name = dra7xx; then setenv fdtfile dra7-evm.dtb; fi;if test $board_name = dra72x-revc; then setenv fdtfile dra72-evm-revc.dtb; fi;if test $board_name = dra72x; then setenv fdtfile dra72-evm.dtb; fi;if test $board_name = beagle_x15; then setenv fdtfile am57xx-beagle-x15.dtb; fi;if test $board_name = beagle_x15_revb1; then setenv fdtfile am57xx-beagle-x15-revb1.dtb; fi;if test $board_name = am57xx_evm; then setenv fdtfile am57xx-evm.dtb; fi;if test $board_name = am57xx_evm_reva3; then setenv fdtfile am57xx-evm-reva3.dtb; fi;if test $board_name = am572x_idk && test $idk_lcd = no; then setenv fdtfile am572x-idk.dtb; fi;if test $board_name = am572x_idk && test $idk_lcd = osd101t2045; then setenv fdtfile am572x-idk-lcd-osd.dtb; fi;if test $board_name = am572x_idk && test $idk_lcd = osd101t2587; then setenv fdtfile am572x-idk-lcd-osd101t2587.dtb; fi;if test $board_name = am571x_idk && test $idk_lcd = no; then setenv fdtfile am571x-idk.dtb; fi;if test $board_name = am571x_idk && test $idk_lcd = osd101t2045; then setenv fdtfile am571x-idk-lcd-osd.dtb; fi;if test $board_name = am571x_idk && test $idk_lcd = osd101t2587; then setenv fdtfile am571x-idk-lcd-osd101t2587.dtb; fi;if test $fdtfile = undefined; then echo WARNING: Could not determine device tree to use; fi;
finduuid=part uuid mmc ${bootpart} uuid
getuenv=mmc dev ${mmcdev}; if mmc rescan; then if run loadbootenv; then run importbootenv; fi; fi;
importbootenv=echo Importing environment from mmc${mmcdev} ...; env import -t ${loadaddr} ${filesize}
ip_method=static
ipaddr=192.168.8.2
kernel_addr_r=0x82000000
loadaddr=0x82000000
loadbootenv=fatload mmc ${mmcdev} ${loadaddr} ${bootenvfile}
loadbootscript=fatload mmc ${mmcdev} ${loadaddr} boot.scr
loadfdt=load mmc ${bootpart} ${fdtaddr} ${bootdir}/${fdtfile};
loadimage=load mmc ${bootpart} ${loadaddr} ${bootdir}/${bootfile}
mmcboot=mmc dev ${mmcdev}; if mmc rescan; then echo SD/MMC found on device ${mmcdev};if run loadimage; then run loadfdt; echo Booting from mmc${mmcdev} ...; run args_mmc; bootz ${loadaddr} - ${fdtaddr}; fi;fi;
mmcdev=0
mmcrootfstype=ext4 rootwait
netargs=setenv bootargs console=${console} ${optargs} root=/dev/nfs fsroot=${nfsserverip}:${rootpath},${nfsopts} rw ip=${nfsserverip}
netboot=echo Booting from network ...; setenv autoload no; static; run netloadimage; run netloadfdt; run netargs; bootz ${loadaddr} - ${fdtaddr}
netloadfdt=tftp ${fdtaddr} ${fdtfile}
netloadimage=tftp ${loadaddr} ${bootfile}
netmask=255.255.255.0
nfsopts=nolock,v3,tcp,rsize=4096,wsize=4096
nfsserverip=192.168.8.10
partitions=uuid_disk=${uuid_gpt_disk};name=rootfs,start=2MiB,size=-,uuid=${uuid_gpt_rootfs}
pxefile_addr_r=0x80100000
ramdisk_addr_r=0x88080000
rdaddr=0x88080000
rootpath=/home/bhidev/ti-processor-sdk-linux-am57xx-evm-03.01.00.06/targetNFS
scriptaddr=0x80000000
scsidevs=0
serverip=192.168.8.9
soc=omap5
static_ip=${ipaddr}:${serverip}:${gatewayip}:${netmask}:${hostname}::off
stderr=serial@48020000
stdin=serial@48020000
stdout=serial@48020000
tftp_nfs_boot=echo Booting from network...; ${loadaddr} 192.168.8.9:${bootfile}; run netargs; bootm ${loadaddr}
uenvcmd=run tftp_nfs_boot
usbtty=cdc_acm
vendor=ti
ver=U-Boot 2016.05-g2f757e5b2c (Oct 03 2016 - 19:01:26 -0400)
vram=16M
Environment size: 4762/65532 bytes