qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/6] libqos, riscv: libqos fixes, add riscv machine
@ 2024-02-13 19:17 Daniel Henrique Barboza
  2024-02-13 19:17 ` [PATCH 1/6] libqos/virtio.c: init all elems in qvring_indirect_desc_setup() Daniel Henrique Barboza
                   ` (5 more replies)
  0 siblings, 6 replies; 16+ messages in thread
From: Daniel Henrique Barboza @ 2024-02-13 19:17 UTC (permalink / raw)
  To: qemu-devel
  Cc: qemu-riscv, alistair.francis, bmeng, liwei1518, zhiwei_liu,
	palmer, thuth, lvivier, pbonzini, ajones, alex.bennee,
	Daniel Henrique Barboza

Hi,

This series adds a RISC-V 'virt' libqos machine. It's copied from the
existing ARM machine in arm-virt-machine.c.

Due to the increase of test coverage I found out 2 bugs in the virtio
layer of libqos. Patch 1 is a bug related to unintialized guest pages
from guest_alloc() being used, patch 2 is an error in an offset of a
struct. My educated guess on why other boards don't fail these tests
is that either their guest pages happens to be zeroed or happens to have
a certain value that doesn't affect the tests. 

Patches 3, 4 and 5 are changes in the RISC-V 'virt' machine required to
make all tests pass.

Patch 6 adds the RISC-V virt machine nodes. As I said, it's a declared
copy of arm-virt-machine.c with extra steps. One of them is to edit the
attributes of the generic-pcihost liqos driver to fit RISC-V needs,
since some of its attributes (ecam, pio_base and so on) are hardcoded to
the values that the ARM 'virt' machine uses. If desired, we can change
generic-pcihost to be more flexible and not hardcode any machine/arch
specific value.
 

Alex: I'm CCing you because I noticed that you reviewed bug fixes in
libqos/virtio in the past, figured you have some expertise to share
here.


Patches based on master.


Daniel Henrique Barboza (6):
  libqos/virtio.c: init all elems in qvring_indirect_desc_setup()
  libqos/virtio.c: fix 'avail_event' offset in qvring_init()
  hw/riscv/virt.c: create '/soc/pci@...' fdt node earlier
  hw/riscv/virt.c: add virtio-iommu-pci hotplug support
  hw/riscv/virt.c: make aclint compatible with 'qtest' accel
  tests/libqos: add riscv/virt machine nodes

 hw/riscv/virt.c                         |  97 ++++++++++++-----
 tests/qtest/libqos/meson.build          |   1 +
 tests/qtest/libqos/riscv-virt-machine.c | 137 ++++++++++++++++++++++++
 tests/qtest/libqos/virtio.c             |  27 +++--
 4 files changed, 228 insertions(+), 34 deletions(-)
 create mode 100644 tests/qtest/libqos/riscv-virt-machine.c

-- 
2.43.0



^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2024-02-16 10:58 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-13 19:17 [PATCH 0/6] libqos, riscv: libqos fixes, add riscv machine Daniel Henrique Barboza
2024-02-13 19:17 ` [PATCH 1/6] libqos/virtio.c: init all elems in qvring_indirect_desc_setup() Daniel Henrique Barboza
2024-02-15  5:02   ` Alistair Francis
2024-02-16 10:23   ` Thomas Huth
2024-02-13 19:17 ` [PATCH 2/6] libqos/virtio.c: fix 'avail_event' offset in qvring_init() Daniel Henrique Barboza
2024-02-15  5:06   ` Alistair Francis
2024-02-16 10:47   ` Thomas Huth
2024-02-13 19:17 ` [PATCH 3/6] hw/riscv/virt.c: create '/soc/pci@...' fdt node earlier Daniel Henrique Barboza
2024-02-15  5:08   ` Alistair Francis
2024-02-13 19:17 ` [PATCH 4/6] hw/riscv/virt.c: add virtio-iommu-pci hotplug support Daniel Henrique Barboza
2024-02-15  5:11   ` Alistair Francis
2024-02-13 19:17 ` [PATCH 5/6] hw/riscv/virt.c: make aclint compatible with 'qtest' accel Daniel Henrique Barboza
2024-02-15  5:14   ` Alistair Francis
2024-02-13 19:17 ` [PATCH 6/6] tests/libqos: add riscv/virt machine nodes Daniel Henrique Barboza
2024-02-15  5:35   ` Alistair Francis
2024-02-16 10:58   ` Thomas Huth

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).