run: time before env to use bash builtin and get decent format, runqemu: remove spaces from cmd to make copy and paste on SO easier

This commit is contained in:
Ciro Santilli
2017-10-18 14:45:44 +01:00
parent 7988dfb60a
commit d67626255e
2 changed files with 40 additions and 40 deletions

76
runqemu
View File

@@ -62,59 +62,59 @@ case "$arch" in
extra_append="$extra_append kgdboc=ttyS0,115200"
fi
cmd="$qemu_common \
-M pc \
-append 'root=/dev/vda nopat $extra_append' \
-device edu \
-device lkmc_pci_min \
-drive file=${images_dir}/rootfs.ext2,if=virtio,format=raw \
-kernel ${images_dir}/bzImage \
-net nic,model=virtio \
$extra_flags
"
-M pc \
-append 'root=/dev/vda nopat $extra_append' \
-device edu \
-device lkmc_pci_min \
-drive file=${images_dir}/rootfs.ext2,if=virtio,format=raw \
-kernel ${images_dir}/bzImage \
-net nic,model=virtio \
$extra_flags \
"
;;
'arm')
if $kgdb; then
extra_append="$extra_append kgdboc=ttyAMA0,115200"
fi
cmd="$qemu_common \
-M versatilepb \
-append 'root=/dev/sda $extra_append' \
-drive file=${images_dir}/rootfs.ext2,if=scsi,format=raw \
-dtb ${images_dir}/versatile-pb.dtb \
-kernel ${images_dir}/zImage \
-net nic,model=rtl8139 \
-serial stdio \
$extra_flags
"
-M versatilepb \
-append 'root=/dev/sda $extra_append' \
-drive file=${images_dir}/rootfs.ext2,if=scsi,format=raw \
-dtb ${images_dir}/versatile-pb.dtb \
-kernel ${images_dir}/zImage \
-net nic,model=rtl8139 \
-serial stdio \
$extra_flags \
"
;;
'aarch64')
if $kgdb; then
extra_append="$extra_append kgdboc=ttyAMA0,115200"
fi
cmd="$qemu_common \
-M virt \
-append 'root=/dev/sda $extra_append' \
-cpu cortex-a57 \
-device virtio-net-device,netdev=eth0 \
-drive file=${images_dir}/rootfs.cpio,if=scsi,format=raw \
-kernel ${images_dir}/Image \
-netdev user,id=eth0 \
-nographic \
-serial stdio \
$extra_flags
"
-M virt \
-append 'root=/dev/sda $extra_append' \
-cpu cortex-a57 \
-device virtio-net-device,netdev=eth0 \
-drive file=${images_dir}/rootfs.cpio,if=scsi,format=raw \
-kernel ${images_dir}/Image \
-netdev user,id=eth0 \
-nographic \
-serial stdio \
$extra_flags \
"
;;
'mips64')
cmd="$qemu_common \
-M malta \
-append 'root=/dev/hda $extra_append' \
-cpu I6400 \
-drive file=${images_dir}/rootfs.ext2,format=raw \
-kernel ${images_dir}/vmlinux \
-nographic \
-net nic,model=pcnet \
$extra_flags
"
-M malta \
-append 'root=/dev/hda $extra_append' \
-cpu I6400 \
-drive file=${images_dir}/rootfs.ext2,format=raw \
-kernel ${images_dir}/vmlinux \
-nographic \
-net nic,model=pcnet \
$extra_flags \
"
;;
esac
echo "$cmd"