Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/distrib/utils/embedded/conf support beaglebone and beagleboa...
details: https://anonhg.NetBSD.org/src/rev/395c25322f46
branches: trunk
changeset: 789353:395c25322f46
user: jmcneill <jmcneill%NetBSD.org@localhost>
date: Fri Aug 16 00:03:01 2013 +0000
description:
support beaglebone and beagleboard with the same image
diffstat:
distrib/utils/embedded/conf/beagleboard.conf | 38 ++++++++++++++++++++-------
1 files changed, 28 insertions(+), 10 deletions(-)
diffs (66 lines):
diff -r 24495c7384d7 -r 395c25322f46 distrib/utils/embedded/conf/beagleboard.conf
--- a/distrib/utils/embedded/conf/beagleboard.conf Thu Aug 15 22:42:50 2013 +0000
+++ b/distrib/utils/embedded/conf/beagleboard.conf Fri Aug 16 00:03:01 2013 +0000
@@ -1,13 +1,17 @@
-# $NetBSD: beagleboard.conf,v 1.11 2013/02/20 18:33:37 riz Exp $
+# $NetBSD: beagleboard.conf,v 1.12 2013/08/16 00:03:01 jmcneill Exp $
# BeagleBoard customization script used by mkimage
#
board=beagleboard
-kernel="$src/sys/arch/evbarm/compile/obj/BEAGLEBOARD/netbsd.ub"
+
+bboard_kernel="$src/sys/arch/evbarm/compile/obj/BEAGLEBOARD/netbsd.ub"
+bbone_kernel="$src/sys/arch/evbarm/compile/obj/BEAGLEBONE/netbsd.ub"
. ${DIR}/conf/evbarm.conf
-kernelimg=netbsd.ub
-loadaddr=81000000
+bboard_kernelimg=bboard.ub
+bboard_loadaddr=81000000
+bbone_kernelimg=bbone.ub
+bbone_loadaddr=82000000
make_filesystems() {
make_filesystems_evbarm
@@ -30,20 +34,34 @@
populate() {
cat > ${mnt}/boot/uEnv.txt << EOF
-loaduimage=fatload mmc 0 ${loadaddr} ${kernelimg}; bootm ${loadaddr} root=ld0a
+loaduimage=if test $board = am335x; then fatload mmc 0 ${bbone_loadaddr} ${bbone_kernelimg}; bootm ${bbone_loadaddr} root=ld0a; else fatload mmc 0 ${bboard_loadaddr} ${bboard_kernelimg}; bootm
${bboard_loadaddr} root=ld0a; fi
EOF
- if [ ! -f "${kernel}" ]; then
- echo ${PROG}: Missing ${kernel} 1>&2
+ if [ ! -f "${bboard_kernel}" ]; then
+ echo ${PROG}: Missing ${bboard_kernel} 1>&2
+ exit 1
+ fi
+ if [ ! -f "${bbone_kernel}" ]; then
+ echo ${PROG}: Missing ${bbone_kernel} 1>&2
exit 1
fi
echo "${bar} installing BEAGLEBOARD kernel to /boot ${bar}"
- case "${kernel}" in
+ case "${bboard_kernel}" in
*.gz)
- gzip -dc "${kernel}" > "${mnt}/boot/${kernelimg}"
+ gzip -dc "${bboard_kernel}" > "${mnt}/boot/${bboard_kernelimg}"
;;
*)
- cp "${kernel}" "${mnt}/boot/${kernelimg}"
+ cp "${bboard_kernel}" "${mnt}/boot/${bboard_kernelimg}"
+ ;;
+ esac
+
+ echo "${bar} installing BEAGLEBONE kernel to /boot ${bar}"
+ case "${bbone_kernel}" in
+ *.gz)
+ gzip -dc "${bbone_kernel}" > "${mnt}/boot/${bbone_kernelimg}"
+ ;;
+ *)
+ cp "${bbone_kernel}" "${mnt}/boot/${bbone_kernelimg}"
;;
esac
}
Home |
Main Index |
Thread Index |
Old Index