diff options
author | Kai Kang <kai.kang@windriver.com> | 2014-12-18 16:51:09 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2014-12-23 10:18:18 +0000 |
commit | f78f9d7adb25d1c422b6e6f3371f1092c16157e3 (patch) | |
tree | b1bece854a590e0cd34e7f833b181b1d9a7303a0 /scripts/runqemu-internal | |
parent | b6663eb107bf59ce8783eebde46ab3558a38b1a3 (diff) | |
download | poky-f78f9d7adb25d1c422b6e6f3371f1092c16157e3.tar.gz |
runqemu: add qemuarm64 support.
Update scripts runqemu and runqemu-internal to support to boot
qemuarm64.
(From OE-Core rev: 2f020b53bdb8c262e432bc4df35101fa990c460c)
Signed-off-by: Kai Kang <kai.kang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/runqemu-internal')
-rwxr-xr-x | scripts/runqemu-internal | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/scripts/runqemu-internal b/scripts/runqemu-internal index 38745dd126..c219419014 100755 --- a/scripts/runqemu-internal +++ b/scripts/runqemu-internal | |||
@@ -50,6 +50,9 @@ else | |||
50 | "qemuarm") | 50 | "qemuarm") |
51 | mem_size=128 | 51 | mem_size=128 |
52 | ;; | 52 | ;; |
53 | "qemuarm64") | ||
54 | mem_size=128 | ||
55 | ;; | ||
53 | "qemumicroblaze") | 56 | "qemumicroblaze") |
54 | mem_size=64 | 57 | mem_size=64 |
55 | ;; | 58 | ;; |
@@ -260,8 +263,17 @@ else | |||
260 | DROOT="/dev/hda" | 263 | DROOT="/dev/hda" |
261 | ROOTFS_OPTIONS="-hda $ROOTFS" | 264 | ROOTFS_OPTIONS="-hda $ROOTFS" |
262 | fi | 265 | fi |
266 | if [ "$MACHINE" = "qemuarm64" ]; then | ||
267 | QEMU_NETWORK_CMD="-netdev user,id=net0 -device virtio-net-device,netdev=net0" | ||
268 | DROOT="/dev/vda" | ||
269 | ROOTFS_OPTIONS="-drive id=disk0,file=$ROOTFS -device virtio-blk-device,drive=disk0" | ||
270 | fi | ||
271 | |||
263 | KERNCMDLINE="mem=$QEMU_MEMORY" | 272 | KERNCMDLINE="mem=$QEMU_MEMORY" |
264 | QEMU_UI_OPTIONS="-show-cursor -usb -usbdevice wacom-tablet" | 273 | QEMU_UI_OPTIONS="-show-cursor -usb -usbdevice wacom-tablet" |
274 | if [ $MACHINE = 'qemuarm64' ]; then | ||
275 | QEMU_UI_OPTIONS="-nographic" | ||
276 | fi | ||
265 | 277 | ||
266 | NFS_INSTANCE=`echo $TAP | sed 's/tap//'` | 278 | NFS_INSTANCE=`echo $TAP | sed 's/tap//'` |
267 | export NFS_INSTANCE | 279 | export NFS_INSTANCE |
@@ -274,6 +286,7 @@ fi | |||
274 | 286 | ||
275 | case "$MACHINE" in | 287 | case "$MACHINE" in |
276 | "qemuarm") ;; | 288 | "qemuarm") ;; |
289 | "qemuarm64") ;; | ||
277 | "qemumicroblaze") ;; | 290 | "qemumicroblaze") ;; |
278 | "qemumips") ;; | 291 | "qemumips") ;; |
279 | "qemumipsel") ;; | 292 | "qemumipsel") ;; |
@@ -362,6 +375,19 @@ if [ "$MACHINE" = "qemuarm" -o "$MACHINE" = "qemuarmv6" -o "$MACHINE" = "qemuarm | |||
362 | fi | 375 | fi |
363 | fi | 376 | fi |
364 | 377 | ||
378 | if [ "$MACHINE" = "qemuarm64" ]; then | ||
379 | QEMU=qemu-system-aarch64 | ||
380 | |||
381 | export QEMU_AUDIO_DRV="none" | ||
382 | QEMU_UI_OPTIONS="$QEMU_UI_OPTIONS" | ||
383 | if [ "${FSTYPE:0:3}" = "ext" -o "$FSTYPE" = "btrfs" ]; then | ||
384 | KERNCMDLINE="root=/dev/vda rw console=ttyAMA0,38400 mem=$QEMU_MEMORY highres=off" | ||
385 | # qemu-system-aarch64 only support '-machine virt -cpu cortex-a57' for now | ||
386 | QEMUOPTIONS="$QEMU_NETWORK_CMD -machine virt -cpu cortex-a57 $ROOTFS_OPTIONS $QEMU_UI_OPTIONS" | ||
387 | fi | ||
388 | fi | ||
389 | |||
390 | |||
365 | if [ "$MACHINE" = "qemux86" ]; then | 391 | if [ "$MACHINE" = "qemux86" ]; then |
366 | QEMU=qemu-system-i386 | 392 | QEMU=qemu-system-i386 |
367 | if [ "$KVM_ACTIVE" = "yes" ]; then | 393 | if [ "$KVM_ACTIVE" = "yes" ]; then |