How to emulate Sifive_u machine model in qemu?
Is there any particular steps to follow?
Please let us know.
Thank you
How to emulate Sifive_u machine model in qemu?
Is there any particular steps to follow?
Please let us know.
Thank you
Hi Coder,
Here are the steps (overview) or running sifive_u machine model in QEMU:
dd if=/dev/zero of=sifive_u.img bs=1M count=10240
qemu-system-riscv64 -machine sifive_u -nographic -m 8192 -smp 5 -kernel <kernel_image> -initrd <rootfs_image>
Replace <kernel_image>
with the path to the Linux kernel image you want to run, and replace <rootfs_image>
with the path to the root filesystem image for the SiFive_u machine model.
qemu-system-riscv64 -machine sifive_u -nographic -m 8192 -smp 5 -kernel <u-boot_image> -drive file=<rootfs_image>,format=raw,if=none
Replace <u-boot_image>
with the path to the prebuilt U-Boot image, and replace <rootfs_image>
with the path to the root filesystem image for the SiFive_u machine model.
Please note that the Sifive_u machine model does not support PCI or VirtIO buses. Therefore, you will need to use a root filesystem image that does not rely on these devices.
Regards,
Shree