defaultenv: boot/net: Boot initramfs from tftp if present
Use an 'initramfs' file if it exists instead of nfsroot. This offers the possibility to quickly boot complete filesystems as initramfs without the need to flash an SD-card or similar. If the initramfs does not exist, it uses the default nfsroot mechanism. Signed-off-by: Markus Pargmann <mpa@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This commit is contained in:
parent
eda3453331
commit
2803b258e6
|
@ -11,4 +11,10 @@ fi
|
|||
|
||||
nfsroot="/home/${global.user}/nfsroot/${global.hostname}"
|
||||
bootargs-ip
|
||||
global.linux.bootargs.dyn.root="root=/dev/nfs nfsroot=$nfsroot,v3,tcp"
|
||||
|
||||
initramfs="${path}/${global.user}-initramfs-${global.hostname}"
|
||||
if [ -f "${initramfs}" ]; then
|
||||
global.bootm.initrd="$initramfs"
|
||||
else
|
||||
global.linux.bootargs.dyn.root="root=/dev/nfs nfsroot=$nfsroot,v3,tcp"
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue