Switch the nfsboot and other relevant commands to use
wget instead of tftp. This also includes the addition of
the httpdstp variable for selecting the wget port.

There is no longer any automatic DHCP configuration. Before
running a command with wget, either 'dhcp' must be run or
the 'ipaddr' and 'serverip' variables must be set. Additionally,
the nfsboot command looks for the file named 'fitImage' on the
server to use to boot.

The default port is set to 8000 instead of the usual 80
to allow for use with an unprivileged web server.

Signed-off-by: Caleb Ethridge <[email protected]>
---
 include/env/adi/adi_boot.env | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)

diff --git a/include/env/adi/adi_boot.env b/include/env/adi/adi_boot.env
index b4b725247f7..be4d8521ac9 100644
--- a/include/env/adi/adi_boot.env
+++ b/include/env/adi/adi_boot.env
@@ -14,6 +14,7 @@
 /* Config options */
 ethaddr=02:80:ad:20:31:e8
 eth1addr=02:80:ad:20:31:e9
+httpdstp=8000
 uart_console=CONFIG_UART_CONSOLE
 #ifdef CONFIG_SC59X_64
 initrd_high=0xffffffffffffffff
@@ -26,15 +27,14 @@ adi_bootargs=EARLY_PRINTK console=ttySC0,CONFIG_BAUDRATE 
vmalloc=512M
 ramargs=setenv bootargs ${adi_bootargs}
 
 addip=setenv bootargs ${bootargs} 
ip=${ipaddr}:${serverip}:${gatewayip}:${netmask}:${hostname}:eth0:off
+rootpath=/romfs
 
 /* Boot modes are selectable and should be defined in the board env before 
including */
 #if defined(USE_NFS)
-// rootpath is set by CONFIG_ROOTPATH
 nfsargs=setenv bootargs root=/dev/nfs rw 
nfsroot=${serverip}:${rootpath},tcp,nfsvers=3 ${adi_bootargs}
-nfsboot=run init_ethernet;
-       tftp ${loadaddr} ${tftp_dir_prefix}${imagefile};
-       run nfsargs;
+nfsboot=run nfsargs;
        run addip;
+       wget ${loadaddr} ${serverip}:/fitImage;
        bootm ${loadaddr}
 #endif
 
@@ -63,8 +63,7 @@ ospiboot=run ospiargs;
 #endif
 
 #if defined(USE_RAM)
-ramboot=run init_ethernet;
-       tftp ${loadaddr} ${tfpt_dir_prefix}${imagefile};
+ramboot=wget ${loadaddr} ${serverip}:/fitImage;
        run ramargs;
        bootm ${loadaddr}
 #endif
-- 
2.34.1

Reply via email to