script: use initrd_addr directly, one less sed call

Signed-off-by: Robert Nelson <robertcnelson@gmail.com>
pull/8/head
Robert Nelson 13 years ago
parent bc2d0f62d6
commit a8c4114e03

@ -435,14 +435,14 @@ function boot_uenv_txt_template {
cat >> ${TEMPDIR}/bootscripts/netinstall.cmd <<-__EOF__ cat >> ${TEMPDIR}/bootscripts/netinstall.cmd <<-__EOF__
kernel_addr=${kernel_addr} kernel_addr=${kernel_addr}
address_initrd=initrd_addr initrd_addr=${initrd_addr}
console=DICONSOLE console=DICONSOLE
mmcroot=/dev/ram0 rw mmcroot=/dev/ram0 rw
xyz_load_image=fatload mmc 0:1 \${kernel_addr} \${kernel_file} xyz_load_image=fatload mmc 0:1 \${kernel_addr} \${kernel_file}
xyz_load_initrd=fatload mmc 0:1 \${address_initrd} \${initrd_file} xyz_load_initrd=fatload mmc 0:1 \${initrd_addr} \${initrd_file}
xyz_mmcboot=run xyz_load_image; run xyz_load_initrd; echo Booting from mmc ... xyz_mmcboot=run xyz_load_image; run xyz_load_initrd; echo Booting from mmc ...
@ -452,7 +452,7 @@ function boot_uenv_txt_template {
cat >> ${TEMPDIR}/bootscripts/normal.cmd <<-__EOF__ cat >> ${TEMPDIR}/bootscripts/normal.cmd <<-__EOF__
kernel_addr=${kernel_addr} kernel_addr=${kernel_addr}
address_initrd=initrd_addr initrd_addr=${initrd_addr}
console=SERIAL_CONSOLE console=SERIAL_CONSOLE
@ -460,7 +460,7 @@ function boot_uenv_txt_template {
mmcrootfstype=FINAL_FSTYPE rootwait fixrtc mmcrootfstype=FINAL_FSTYPE rootwait fixrtc
xyz_load_image=fatload mmc 0:1 \${kernel_addr} \${kernel_file} xyz_load_image=fatload mmc 0:1 \${kernel_addr} \${kernel_file}
xyz_load_initrd=fatload mmc 0:1 \${address_initrd} \${initrd_file} xyz_load_initrd=fatload mmc 0:1 \${initrd_addr} \${initrd_file}
xyz_mmcboot=run xyz_load_image; run xyz_load_initrd; echo Booting from mmc ... xyz_mmcboot=run xyz_load_image; run xyz_load_initrd; echo Booting from mmc ...
@ -472,70 +472,70 @@ function boot_uenv_txt_template {
beagle_bx|beagle_cx) beagle_bx|beagle_cx)
cat >> ${TEMPDIR}/bootscripts/netinstall.cmd <<-__EOF__ cat >> ${TEMPDIR}/bootscripts/netinstall.cmd <<-__EOF__
deviceargs=setenv device_args mpurate=\${mpurate} buddy=\${buddy} buddy2=\${buddy2} musb_hdrc.fifo_mode=5 deviceargs=setenv device_args mpurate=\${mpurate} buddy=\${buddy} buddy2=\${buddy2} musb_hdrc.fifo_mode=5
loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${address_initrd}:\${filesize} loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${initrd_addr}:\${filesize}
__EOF__ __EOF__
cat >> ${TEMPDIR}/bootscripts/normal.cmd <<-__EOF__ cat >> ${TEMPDIR}/bootscripts/normal.cmd <<-__EOF__
optargs=VIDEO_CONSOLE optargs=VIDEO_CONSOLE
deviceargs=setenv device_args mpurate=\${mpurate} buddy=\${buddy} buddy2=\${buddy2} musb_hdrc.fifo_mode=5 deviceargs=setenv device_args mpurate=\${mpurate} buddy=\${buddy} buddy2=\${buddy2} musb_hdrc.fifo_mode=5
loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${address_initrd}:\${filesize} loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${initrd_addr}:\${filesize}
__EOF__ __EOF__
;; ;;
beagle_xm) beagle_xm)
cat >> ${TEMPDIR}/bootscripts/netinstall.cmd <<-__EOF__ cat >> ${TEMPDIR}/bootscripts/netinstall.cmd <<-__EOF__
deviceargs=setenv device_args mpurate=\${mpurate} buddy=\${buddy} buddy2=\${buddy2} deviceargs=setenv device_args mpurate=\${mpurate} buddy=\${buddy} buddy2=\${buddy2}
loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${address_initrd}:\${filesize} loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${initrd_addr}:\${filesize}
__EOF__ __EOF__
cat >> ${TEMPDIR}/bootscripts/normal.cmd <<-__EOF__ cat >> ${TEMPDIR}/bootscripts/normal.cmd <<-__EOF__
optargs=VIDEO_CONSOLE optargs=VIDEO_CONSOLE
deviceargs=setenv device_args mpurate=\${mpurate} buddy=\${buddy} buddy2=\${buddy2} deviceargs=setenv device_args mpurate=\${mpurate} buddy=\${buddy} buddy2=\${buddy2}
loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${address_initrd}:\${filesize} loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${initrd_addr}:\${filesize}
__EOF__ __EOF__
;; ;;
crane|igepv2|mx51evk|mx53loco|panda|panda_es) crane|igepv2|mx51evk|mx53loco|panda|panda_es)
cat >> ${TEMPDIR}/bootscripts/netinstall.cmd <<-__EOF__ cat >> ${TEMPDIR}/bootscripts/netinstall.cmd <<-__EOF__
deviceargs=setenv device_args deviceargs=setenv device_args
loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${address_initrd}:\${filesize} loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${initrd_addr}:\${filesize}
__EOF__ __EOF__
cat >> ${TEMPDIR}/bootscripts/normal.cmd <<-__EOF__ cat >> ${TEMPDIR}/bootscripts/normal.cmd <<-__EOF__
optargs=VIDEO_CONSOLE optargs=VIDEO_CONSOLE
deviceargs=setenv device_args deviceargs=setenv device_args
loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${address_initrd}:\${filesize} loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${initrd_addr}:\${filesize}
__EOF__ __EOF__
;; ;;
bone) bone)
cat >> ${TEMPDIR}/bootscripts/netinstall.cmd <<-__EOF__ cat >> ${TEMPDIR}/bootscripts/netinstall.cmd <<-__EOF__
deviceargs=setenv device_args ip=\${ip_method} deviceargs=setenv device_args ip=\${ip_method}
mmc_load_uimage=run xyz_mmcboot; run bootargs_defaults; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${address_initrd} mmc_load_uimage=run xyz_mmcboot; run bootargs_defaults; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${initrd_addr}
__EOF__ __EOF__
cat >> ${TEMPDIR}/bootscripts/normal.cmd <<-__EOF__ cat >> ${TEMPDIR}/bootscripts/normal.cmd <<-__EOF__
deviceargs=setenv device_args ip=\${ip_method} deviceargs=setenv device_args ip=\${ip_method}
mmc_load_uimage=run xyz_mmcboot; run bootargs_defaults; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${address_initrd} mmc_load_uimage=run xyz_mmcboot; run bootargs_defaults; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${initrd_addr}
__EOF__ __EOF__
;; ;;
bone_zimage) bone_zimage)
cat >> ${TEMPDIR}/bootscripts/netinstall.cmd <<-__EOF__ cat >> ${TEMPDIR}/bootscripts/netinstall.cmd <<-__EOF__
deviceargs=setenv device_args ip=\${ip_method} deviceargs=setenv device_args ip=\${ip_method}
mmc_load_uimage=run xyz_mmcboot; run bootargs_defaults; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${address_initrd}:\${filesize} mmc_load_uimage=run xyz_mmcboot; run bootargs_defaults; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${initrd_addr}:\${filesize}
loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${address_initrd}:\${filesize} loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${initrd_addr}:\${filesize}
__EOF__ __EOF__
cat >> ${TEMPDIR}/bootscripts/normal.cmd <<-__EOF__ cat >> ${TEMPDIR}/bootscripts/normal.cmd <<-__EOF__
deviceargs=setenv device_args ip=\${ip_method} deviceargs=setenv device_args ip=\${ip_method}
mmc_load_uimage=run xyz_mmcboot; run bootargs_defaults; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${address_initrd}:\${filesize} mmc_load_uimage=run xyz_mmcboot; run bootargs_defaults; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${initrd_addr}:\${filesize}
loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${address_initrd}:\${filesize} loaduimage=run xyz_mmcboot; run deviceargs; run mmcargs; \${boot} \${kernel_addr} \${initrd_addr}:\${filesize}
__EOF__ __EOF__
@ -575,9 +575,6 @@ function tweak_boot_scripts {
ALL="*.cmd" ALL="*.cmd"
NET="netinstall.cmd" NET="netinstall.cmd"
FINAL="normal.cmd" FINAL="normal.cmd"
#Set initrd boot address
sed -i -e 's:initrd_addr:'$initrd_addr':g' ${TEMPDIR}/bootscripts/${ALL}
#Set the Serial Console #Set the Serial Console
sed -i -e 's:SERIAL_CONSOLE:'$SERIAL_CONSOLE':g' ${TEMPDIR}/bootscripts/${ALL} sed -i -e 's:SERIAL_CONSOLE:'$SERIAL_CONSOLE':g' ${TEMPDIR}/bootscripts/${ALL}

Loading…
Cancel
Save