summaryrefslogtreecommitdiffstats
path: root/scripts/poky-qemu-internal
diff options
context:
space:
mode:
authorRichard Purdie <richard@openedhand.com>2008-04-10 09:50:54 +0000
committerRichard Purdie <richard@openedhand.com>2008-04-10 09:50:54 +0000
commitfaf55131c9b86a8646dd80ca79b44a001b88a87f (patch)
treed8127bd7dd5339145a21c1aa8c6b850f681f05b8 /scripts/poky-qemu-internal
parent5091c0bd8842b2a5f94e47c391dc6fe73eac8901 (diff)
downloadpoky-faf55131c9b86a8646dd80ca79b44a001b88a87f.tar.gz
scripts: Add support for nokia800 to runqemu
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@4226 311d38ba-8fff-0310-9ca6-ca027cbcb966
Diffstat (limited to 'scripts/poky-qemu-internal')
-rwxr-xr-xscripts/poky-qemu-internal37
1 files changed, 32 insertions, 5 deletions
diff --git a/scripts/poky-qemu-internal b/scripts/poky-qemu-internal
index 1a8fb63b35..4ddb116130 100755
--- a/scripts/poky-qemu-internal
+++ b/scripts/poky-qemu-internal
@@ -30,16 +30,16 @@
30# HDIMAGE - the disk image file to use 30# HDIMAGE - the disk image file to use
31# 31#
32 32
33if [ -z "$QEMU_MEMORY" ]; then
34 QEMU_MEMORY="64M"
35fi
36
33QEMUIFUP=`which poky-qemu-ifup` 37QEMUIFUP=`which poky-qemu-ifup`
34QEMUIFDOWN=`which poky-qemu-ifdown` 38QEMUIFDOWN=`which poky-qemu-ifdown`
35KERNEL_NETWORK_CMD="ip=192.168.7.2::192.168.7.1:255.255.255.0" 39KERNEL_NETWORK_CMD="ip=192.168.7.2::192.168.7.1:255.255.255.0"
36QEMU_NETWORK_CMD="-net nic,vlan=0 -net tap,vlan=0,ifname=tap0,script=$QEMUIFUP,downscript=$QEMUIFDOWN" 40QEMU_NETWORK_CMD="-net nic,vlan=0 -net tap,vlan=0,ifname=tap0,script=$QEMUIFUP,downscript=$QEMUIFDOWN"
37KERNCMDLINE="mem=$QEMU_MEMORY" 41KERNCMDLINE="mem=$QEMU_MEMORY"
38 42
39if [ -z "$QEMU_MEMORY" ]; then
40 QEMU_MEMORY="64M"
41fi
42
43SERIALOPTS="" 43SERIALOPTS=""
44if [ "x$SERIAL_LOGFILE" != "x" ]; then 44if [ "x$SERIAL_LOGFILE" != "x" ]; then
45 SERIALOPTS="-serial file:$SERIAL_LOGFILE" 45 SERIALOPTS="-serial file:$SERIAL_LOGFILE"
@@ -50,6 +50,7 @@ case "$MACHINE" in
50 "qemux86") ;; 50 "qemux86") ;;
51 "akita") ;; 51 "akita") ;;
52 "spitz") ;; 52 "spitz") ;;
53 "nokia800") ;;
53 *) 54 *)
54 echo "Error: Unsupported machine type $MACHINE" 55 echo "Error: Unsupported machine type $MACHINE"
55 return 56 return
@@ -130,13 +131,39 @@ if [ "$MACHINE" = "akita" ]; then
130 fi 131 fi
131fi 132fi
132 133
134if [ "$MACHINE" = "nokia800" ]; then
135 QEMU=qemu-system-arm
136 if [ "$TYPE" = "jffs2" ]; then
137 HDIMAGE=`readlink -f $HDIMAGE`
138 if [ ! -e "$HDIMAGE.qemuflash" ]; then
139 #if [ ! -e "$HDIMAGE.initfs" ]; then
140 # echo "Error, $HDIMAGE.initfs must exist!"
141 # return
142 #fi
143 #if [ ! -e "$HDIMAGE.config" ]; then
144 # echo "Error, $HDIMAGE.config must exist!"
145 # return
146 #fi
147 #echo "'Flashing' config partition, please wait..."
148 #poky-nokia800-flashutil $HDIMAGE.config $HDIMAGE.qemuflash config
149 #echo "'Flashing' initfs, please wait..."
150 #poky-nokia800-flashutil $HDIMAGE.initfs $HDIMAGE.qemuflash initfs
151 echo "'Flashing' rootfs, please wait..."
152 poky-nokia800-flashutil $HDIMAGE $HDIMAGE.qemuflash
153 fi
154 KERNCMDLINE="root=/dev/mtdblock4 rootfstype=jffs2"
155 QEMUOPTIONS="$QEMU_NETWORK_CMD -M n800 -mtdblock $HDIMAGE.qemuflash -serial vc -m 130 -serial vc -serial vc -serial vc"
156 fi
157fi
158
159
133if [ "x$QEMUOPTIONS" = "x" ]; then 160if [ "x$QEMUOPTIONS" = "x" ]; then
134 echo "Error: Unable to support this combination of options" 161 echo "Error: Unable to support this combination of options"
135 return 162 return
136fi 163fi
137 164
138SDKDIR="/usr/local/poky/eabi-glibc" 165SDKDIR="/usr/local/poky/eabi-glibc"
139if [ "$MACHINE" = "qemuarm" -o "$MACHINE" = "spitz" -o "$MACHINE" = "borzoi" -o "$MACHINE" = "akita" ]; then 166if [ "$MACHINE" = "qemuarm" -o "$MACHINE" = "spitz" -o "$MACHINE" = "borzoi" -o "$MACHINE" = "akita" -o "$MACHINE" = "nokia800" ]; then
140 SDKPATH="$SDKDIR/arm/arm-poky-linux-gnueabi/bin:$SDKDIR/arm/bin" 167 SDKPATH="$SDKDIR/arm/arm-poky-linux-gnueabi/bin:$SDKDIR/arm/bin"
141fi 168fi
142 169