]> code.ossystems Code Review - openembedded-core.git/commitdiff
runqemu-internal: set mutual exclusiveness for serial and nographic options
authorJagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
Tue, 16 Jun 2015 10:48:30 +0000 (16:18 +0530)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Sun, 28 Jun 2015 08:42:04 +0000 (09:42 +0100)
Use "-nographic" option only if "serial" option is not
specified. Otherwise we get below error when
'runqemu <kernel_image> <rootfs_image> serial' is executed,

(snip)
QEMU 2.2.0 monitor - type 'help' for more information
(qemu) qemu-system-aarch64: -serial stdio: cannot use stdio by multiple
character devices
-- CUT --

(From OE-Core rev: 8b0527951ab71c4a4dc4d1238cd9e9e60a6eb5ee)

Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
scripts/runqemu-internal

index fb51754fc69466815c8ed6b1e34d297f53b29c96..e346c64f51153a168a362b8c0df96c6baf25e5e7 100755 (executable)
@@ -275,9 +275,6 @@ else
 
         KERNCMDLINE="mem=$QEMU_MEMORY"
         QEMU_UI_OPTIONS="-show-cursor -usb -usbdevice wacom-tablet"
-        if [ $MACHINE = 'qemuarm64' ]; then
-            QEMU_UI_OPTIONS="-nographic"
-        fi
 
         NFS_INSTANCE=`echo $TAP | sed 's/tap//'`
         export NFS_INSTANCE
@@ -383,7 +380,11 @@ if [ "$MACHINE" = "qemuarm64" ]; then
     QEMU=qemu-system-aarch64
 
     export QEMU_AUDIO_DRV="none"
-    QEMU_UI_OPTIONS="$QEMU_UI_OPTIONS"
+    if [ "x$SERIALSTDIO" = "x" ] ; then
+        QEMU_UI_OPTIONS="-nographic"
+    else
+        QEMU_UI_OPTIONS=""
+    fi
     if [ "${FSTYPE:0:3}" = "ext" -o "$FSTYPE" = "btrfs" ]; then
         KERNCMDLINE="root=/dev/vda rw console=ttyAMA0,38400 mem=$QEMU_MEMORY highres=off $KERNEL_NETWORK_CMD"
         # qemu-system-aarch64 only support '-machine virt -cpu cortex-a57' for now