summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNitin A Kamble <nitin.a.kamble@intel.com>2011-06-17 00:58:39 (GMT)
committerRichard Purdie <richard.purdie@linuxfoundation.org>2011-06-30 19:56:36 (GMT)
commitd591e696b2516ab605cc829786e56f45e76c2cee (patch)
tree14cd5c05b158586d399c0799ee99689a0a49d11b
parentc9ed41a3130549f3397b5325bf2e503c2186d1a7 (diff)
downloadpoky-d591e696b2516ab605cc829786e56f45e76c2cee.tar.gz
scripts/runqemu: enable btrfs
(From OE-Core rev: 45689bbd46b0bb8e66b7c0ff7cc3321e5eef5b5f) Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rwxr-xr-xscripts/runqemu6
-rwxr-xr-xscripts/runqemu-internal12
2 files changed, 9 insertions, 9 deletions
diff --git a/scripts/runqemu b/scripts/runqemu
index aa44070..5aed25a 100755
--- a/scripts/runqemu
+++ b/scripts/runqemu
@@ -71,7 +71,7 @@ process_filename() {
71 usage 71 usage
72 fi 72 fi
73 elif [[ "x$EXT" == "xext2" || "x$EXT" == "xext3" || 73 elif [[ "x$EXT" == "xext2" || "x$EXT" == "xext3" ||
74 "x$EXT" == "xjffs2" ]]; then 74 "x$EXT" == "xjffs2" || "x$EXT" == "xbtrfs" ]]; then
75 # A file ending in a supportted fs type is a rootfs image 75 # A file ending in a supportted fs type is a rootfs image
76 if [[ -z "$FSTYPE" || "$FSTYPE" == "$EXT" ]]; then 76 if [[ -z "$FSTYPE" || "$FSTYPE" == "$EXT" ]]; then
77 FSTYPE=$EXT 77 FSTYPE=$EXT
@@ -101,7 +101,7 @@ while [ $i -le $# ]; do
101 usage 101 usage
102 fi 102 fi
103 ;; 103 ;;
104 "ext2" | "ext3" | "jffs2" | "nfs") 104 "ext2" | "ext3" | "jffs2" | "nfs" | "btrfs")
105 if [[ -z "$FSTYPE" || "$FSTYPE" == "$arg" ]]; then 105 if [[ -z "$FSTYPE" || "$FSTYPE" == "$arg" ]]; then
106 FSTYPE=$arg 106 FSTYPE=$arg
107 else 107 else
@@ -317,7 +317,7 @@ if [[ -e "$ROOTFS" && -z "$FSTYPE" ]]; then
317 # Extract the filename extension 317 # Extract the filename extension
318 EXT=`echo $ROOTFS | awk -F . '{ print \$NF }'` 318 EXT=`echo $ROOTFS | awk -F . '{ print \$NF }'`
319 if [[ "x$EXT" == "xext2" || "x$EXT" == "xext3" || 319 if [[ "x$EXT" == "xext2" || "x$EXT" == "xext3" ||
320 "x$EXT" == "xjffs2" ]]; then 320 "x$EXT" == "xjffs2" || "x$EXT" == "xbtrfs" ]]; then
321 FSTYPE=$EXT 321 FSTYPE=$EXT
322 else 322 else
323 echo "Note: Unable to determine filesystem extension for $ROOTFS" 323 echo "Note: Unable to determine filesystem extension for $ROOTFS"
diff --git a/scripts/runqemu-internal b/scripts/runqemu-internal
index ffac05e..c15632d 100755
--- a/scripts/runqemu-internal
+++ b/scripts/runqemu-internal
@@ -277,7 +277,7 @@ if [ "$MACHINE" = "qemuarm" -o "$MACHINE" = "qemuarmv6" -o "$MACHINE" = "qemuarm
277 MACHINE_SUBTYPE=versatilepb 277 MACHINE_SUBTYPE=versatilepb
278 QEMU_UI_OPTIONS="$QEMU_UI_OPTIONS" 278 QEMU_UI_OPTIONS="$QEMU_UI_OPTIONS"
279 # QEMU_UI_OPTIONS="$QEMU_UI_OPTIONS -force-pointer" 279 # QEMU_UI_OPTIONS="$QEMU_UI_OPTIONS -force-pointer"
280 if [ "$FSTYPE" = "ext3" ]; then 280 if [ "$FSTYPE" = "ext3" -o "$FSTYPE" = "btrfs" ]; then
281 KERNCMDLINE="root=/dev/sda rw console=ttyAMA0,115200 console=tty $KERNEL_NETWORK_CMD mem=$QEMU_MEMORY highres=off" 281 KERNCMDLINE="root=/dev/sda rw console=ttyAMA0,115200 console=tty $KERNEL_NETWORK_CMD mem=$QEMU_MEMORY highres=off"
282 QEMUOPTIONS="$QEMU_NETWORK_CMD -M versatilepb -hda $ROOTFS -no-reboot $QEMU_UI_OPTIONS" 282 QEMUOPTIONS="$QEMU_NETWORK_CMD -M versatilepb -hda $ROOTFS -no-reboot $QEMU_UI_OPTIONS"
283 fi 283 fi
@@ -301,7 +301,7 @@ fi
301if [ "$MACHINE" = "qemux86" ]; then 301if [ "$MACHINE" = "qemux86" ]; then
302 QEMU=qemu 302 QEMU=qemu
303 QEMU_UI_OPTIONS="$QEMU_UI_OPTIONS -vga vmware -enable-gl" 303 QEMU_UI_OPTIONS="$QEMU_UI_OPTIONS -vga vmware -enable-gl"
304 if [ "$FSTYPE" = "ext3" ]; then 304 if [ "$FSTYPE" = "ext3" -o "$FSTYPE" = "btrfs" ]; then
305 KERNCMDLINE="vga=0 root=/dev/hda rw mem=$QEMU_MEMORY $KERNEL_NETWORK_CMD" 305 KERNCMDLINE="vga=0 root=/dev/hda rw mem=$QEMU_MEMORY $KERNEL_NETWORK_CMD"
306 QEMUOPTIONS="$QEMU_NETWORK_CMD -hda $ROOTFS $QEMU_UI_OPTIONS" 306 QEMUOPTIONS="$QEMU_NETWORK_CMD -hda $ROOTFS $QEMU_UI_OPTIONS"
307 fi 307 fi
@@ -322,7 +322,7 @@ fi
322if [ "$MACHINE" = "qemux86-64" ]; then 322if [ "$MACHINE" = "qemux86-64" ]; then
323 QEMU=qemu-system-x86_64 323 QEMU=qemu-system-x86_64
324 QEMU_UI_OPTIONS="$QEMU_UI_OPTIONS -vga vmware -enable-gl" 324 QEMU_UI_OPTIONS="$QEMU_UI_OPTIONS -vga vmware -enable-gl"
325 if [ "$FSTYPE" = "ext3" ]; then 325 if [ "$FSTYPE" = "ext3" -o "$FSTYPE" = "btrfs" ]; then
326 KERNCMDLINE="vga=0 root=/dev/hda rw mem=$QEMU_MEMORY $KERNEL_NETWORK_CMD" 326 KERNCMDLINE="vga=0 root=/dev/hda rw mem=$QEMU_MEMORY $KERNEL_NETWORK_CMD"
327 QEMUOPTIONS="$QEMU_NETWORK_CMD -hda $ROOTFS $QEMU_UI_OPTIONS" 327 QEMUOPTIONS="$QEMU_NETWORK_CMD -hda $ROOTFS $QEMU_UI_OPTIONS"
328 fi 328 fi
@@ -345,7 +345,7 @@ fi
345 345
346if [ "$MACHINE" = "spitz" ]; then 346if [ "$MACHINE" = "spitz" ]; then
347 QEMU=qemu-system-arm 347 QEMU=qemu-system-arm
348 if [ "$FSTYPE" = "ext3" ]; then 348 if [ "$FSTYPE" = "ext3" -o "$FSTYPE" = "btrfs" ]; then
349 echo $ROOTFS 349 echo $ROOTFS
350 ROOTFS=`readlink -f $ROOTFS` 350 ROOTFS=`readlink -f $ROOTFS`
351 echo $ROOTFS 351 echo $ROOTFS
@@ -361,7 +361,7 @@ if [ "$MACHINE" = "qemumips" ]; then
361 QEMU=qemu-system-mips 361 QEMU=qemu-system-mips
362 MACHINE_SUBTYPE=malta 362 MACHINE_SUBTYPE=malta
363 QEMU_UI_OPTIONS="-vga cirrus $QEMU_UI_OPTIONS" 363 QEMU_UI_OPTIONS="-vga cirrus $QEMU_UI_OPTIONS"
364 if [ "$FSTYPE" = "ext3" ]; then 364 if [ "$FSTYPE" = "ext3" -o "$FSTYPE" = "btrfs" ]; then
365 #KERNCMDLINE="root=/dev/hda console=ttyS0 console=tty0 $KERNEL_NETWORK_CMD mem=$QEMU_MEMORY" 365 #KERNCMDLINE="root=/dev/hda console=ttyS0 console=tty0 $KERNEL_NETWORK_CMD mem=$QEMU_MEMORY"
366 KERNCMDLINE="root=/dev/hda rw console=ttyS0 console=tty $KERNEL_NETWORK_CMD mem=$QEMU_MEMORY" 366 KERNCMDLINE="root=/dev/hda rw console=ttyS0 console=tty $KERNEL_NETWORK_CMD mem=$QEMU_MEMORY"
367 QEMUOPTIONS="$QEMU_NETWORK_CMD -M $MACHINE_SUBTYPE -hda $ROOTFS -no-reboot $QEMU_UI_OPTIONS" 367 QEMUOPTIONS="$QEMU_NETWORK_CMD -M $MACHINE_SUBTYPE -hda $ROOTFS -no-reboot $QEMU_UI_OPTIONS"
@@ -383,7 +383,7 @@ if [ "$MACHINE" = "qemuppc" ]; then
383 CPU_SUBTYPE=603e 383 CPU_SUBTYPE=603e
384 BIOS=powerpc_rom.bin 384 BIOS=powerpc_rom.bin
385 QEMU_UI_OPTIONS="$QEMU_UI_OPTIONS -nographic" 385 QEMU_UI_OPTIONS="$QEMU_UI_OPTIONS -nographic"
386 if [ "$FSTYPE" = "ext3" ]; then 386 if [ "$FSTYPE" = "ext3" -o "$FSTYPE" = "btrfs" ]; then
387 KERNCMDLINE="root=/dev/hda rw console=ttyS0 console=tty0 $KERNEL_NETWORK_CMD mem=$QEMU_MEMORY" 387 KERNCMDLINE="root=/dev/hda rw console=ttyS0 console=tty0 $KERNEL_NETWORK_CMD mem=$QEMU_MEMORY"
388 QEMUOPTIONS="$QEMU_NETWORK_CMD -cpu $CPU_SUBTYPE -M $MACHINE_SUBTYPE -bios $BIOS -hda $ROOTFS -no-reboot $QEMU_UI_OPTIONS" 388 QEMUOPTIONS="$QEMU_NETWORK_CMD -cpu $CPU_SUBTYPE -M $MACHINE_SUBTYPE -bios $BIOS -hda $ROOTFS -no-reboot $QEMU_UI_OPTIONS"
389 fi 389 fi