README 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. This is intended to be used with LEDE project to provide image for use with
  2. QEMU ARM virt machine.
  3. Run with qemu-system-arm
  4. # boot with initramfs embedded in
  5. qemu-system-arm -nographic -M virt -m 64 -kernel openwrt-armvirt-32-zImage-initramfs
  6. # boot with accel=kvm
  7. qemu-system-arm -nographic -M virt,accel=kvm -cpu host -m 64 -kernel
  8. openwrt-armvirt-32-zImage-initramfs
  9. # boot with a separate rootfs
  10. qemu-system-arm -nographic -M virt -m 64 -kernel openwrt-armvirt-32-zImage \
  11. -drive file=openwrt-armvirt-32-root.ext4,format=raw,if=virtio -append 'root=/dev/vda rootwait'
  12. # boot with local dir as rootfs
  13. qemu-system-arm -nographic -M virt -m 64 -kernel openwrt-armvirt-32-zImage \
  14. -fsdev local,id=rootdev,path=root-armvirt/,security_model=none \
  15. -device virtio-9p-pci,fsdev=rootdev,mount_tag=/dev/root \
  16. -append 'rootflags=trans=virtio,version=9p2000.L,cache=loose rootfstype=9p'
  17. Run with kvmtool
  18. # start a named machine
  19. lkvm run -k openwrt-armvirt-32-zImage -i openwrt-armvirt-32-rootfs.cpio --name armvirt0
  20. # start with virtio-9p rootfs
  21. lkvm run -k openwrt-armvirt-32-zImage -d root-armvirt/
  22. # stop "armvirt0"
  23. lkvm stop --name armvirt0
  24. # stop all
  25. lkvm stop --all
  26. The multi-platform ARMv8 target can be used with QEMU:
  27. qemu-system-aarch64 -machine virt -cpu cortex-a57 -nographic \
  28. -kernel openwrt-armvirt-64-Image-initramfs \