91 |
elif [[ ${ARCH} = ppc64 ]] || [[ ${ARCH} = ppc ]] |
elif [[ ${ARCH} = ppc64 ]] || [[ ${ARCH} = ppc ]] |
92 |
then |
then |
93 |
liloConfig=/etc/yaboot.conf |
liloConfig=/etc/yaboot.conf |
94 |
|
grub2Config=/boot/grub/grub.cfg |
95 |
bootPrefix=/boot |
bootPrefix=/boot |
96 |
lilo=/sbin/ybin |
lilo=/sbin/ybin |
97 |
liloFlag=yaboot |
liloFlag=yaboot |
114 |
isx86="" |
isx86="" |
115 |
elif [[ ${ARCH} = armv7l ]] || [[ ${ARCH} = armv7hl ]] || [[ ${ARCH} = armv5tel ]] |
elif [[ ${ARCH} = armv7l ]] || [[ ${ARCH} = armv7hl ]] || [[ ${ARCH} = armv5tel ]] |
116 |
then |
then |
|
machine=$(grep "^Hardware" /proc/cpuinfo | sed 's/Hardware\s*:\s*//') |
|
117 |
liloConfig="" |
liloConfig="" |
118 |
bootPrefix=/boot |
bootPrefix=/boot |
119 |
ubootDir=${UBOOT_DIR:-"/boot/uboot"} |
ubootDir=${UBOOT_DIR:-"/boot"} |
120 |
ubootScript=$ubootDir/${UBOOT_SCR:-"boot.scr"} |
ubootScript=$ubootDir/${UBOOT_SCR:-"boot.scr"} |
121 |
ubootKList=${UBOOT_KLIST:-"klist.txt"} |
ubootKList=${UBOOT_KLIST:-"klist.txt"} |
122 |
ubootDevice=/dev/${UBOOT_DEVICE:-"mmcblk0p1"} |
ubootDevice=/dev/${UBOOT_DEVICE:-"mmcblk0p1"} |
125 |
mounted="" |
mounted="" |
126 |
liloFlag="" |
liloFlag="" |
127 |
isx86="" |
isx86="" |
128 |
if [[ ${machine} == "OMAP3 Beagle Board" ]] || [[ ${machine} == "OMAP4 Panda board" ]] |
if [[ -z ${UBOOT_IMGADDR} ]] |
129 |
then |
then |
130 |
ubootAddress=0x80008000 |
machine=$(grep "^Hardware" /proc/cpuinfo | sed 's/Hardware\s*:\s*//') |
131 |
|
if [ "${machine}" == "OMAP3 Beagle Board" ] || [ "${machine}" == "OMAP4 Panda board" ] |
132 |
|
then |
133 |
|
ubootAddress=0x80008000 |
134 |
|
else |
135 |
|
ubootAddress=0x00008000 |
136 |
|
fi |
137 |
else |
else |
138 |
ubootAddress=0x00008000 |
ubootAddress="${UBOOT_IMGADDR}" |
139 |
fi |
fi |
140 |
else |
else |
141 |
# this leaves i?86 and x86_64 |
# this leaves i?86 and x86_64 |
411 |
then |
then |
412 |
tmpKList=$(mktemp ${ubootDir}/${ubootKList}.XXXX) |
tmpKList=$(mktemp ${ubootDir}/${ubootKList}.XXXX) |
413 |
curversion=$(tail -n1 ${ubootDir}/${ubootKList}) |
curversion=$(tail -n1 ${ubootDir}/${ubootKList}) |
414 |
sed "/${version}/d" ${ubootDir}/${ubootKList} > ${tmpKList} |
sed "/$version$/d" ${ubootDir}/${ubootKList} > ${tmpKList} |
415 |
newversion=$(tail -n1 ${tmpKList}) |
newversion=$(tail -n1 ${tmpKList}) |
416 |
if [ -f ${ubootDir}/uImage-${newversion} ] && [ -f ${ubootDir}/uInitrd-${newversion} ] |
if [ -f ${ubootDir}/uImage-${newversion} ] && [ -f ${ubootDir}/uInitrd-${newversion} ] |
417 |
then |
then |