Test;
1. add kernel patch:
https://patchew.org/linux/[email protected]/

2. run script with '-cpu max,msgint=on' and virt,dmsi=on.
'
./build/qemu-system-loongarch64 -accel kvm \
     -bios /usr/share/edk2/loongarch64/QEMU_EFI-silent-pflash.raw \
     -cpu max,msgint=on\
     -smp 4 \
     -machine virt,dmsi=on,kernel_irqchip=on\
     -m 16G \
     -netdev 
tap,id=net0,ifname=tap0,script=/root/net.sh,downscript=no,vhost=on,queues=4 \
    -device virtio-net-pci,netdev=net0,mq=on,vectors=128,mac=52:54:00:12:34:56 \
     -monitor telnet:localhost:4418,server,nowait \
    -device virtio-gpu-pci \
    -drive if=none,id=disk0,file=/home/kvm/lns23.qcow2,format=qcow2 \
    -device virtio-blk-pci,drive=disk0,id=virtio_disk0 \
    --nographic
'
3  the vm can work well with with net test, such as netperf or iperf test.

Thanks.
Song Gao.

Song Gao (2):
  target/loongarch: Add kvm support dintc
  add avec irqchip in kernel support

 hw/intc/loongarch_dintc.c         | 14 +++++++
 hw/intc/loongarch_dintc_kvm.c     | 50 ++++++++++++++++++++++
 hw/intc/meson.build               |  2 +
 include/hw/intc/loongarch_dintc.h |  9 ++++
 linux-headers/asm-loongarch/kvm.h |  4 ++
 linux-headers/linux/kvm.h         |  2 +
 target/loongarch/cpu.c            |  4 +-
 target/loongarch/cpu.h            |  1 +
 target/loongarch/kvm/kvm.c        | 69 +++++++++++++++++++++++++++++++
 9 files changed, 153 insertions(+), 2 deletions(-)
 create mode 100644 hw/intc/loongarch_dintc_kvm.c

-- 
2.51.0


Reply via email to