qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1 0/5] virtio: Add the virtio-msg transport
@ 2025-10-28 15:23 Edgar E. Iglesias
  2025-10-28 15:23 ` [PATCH v1 1/5] virtio: Introduce notify_queue Edgar E. Iglesias
                   ` (5 more replies)
  0 siblings, 6 replies; 11+ messages in thread
From: Edgar E. Iglesias @ 2025-10-28 15:23 UTC (permalink / raw)
  To: qemu-devel; +Cc: mst, alex.bennee, bill.mills, edgar.iglesias

From: "Edgar E. Iglesias" <edgar.iglesias@amd.com>

This adds virtio-msg, a new virtio transport. Virtio-msg works by
exchanging messages over a bus and doesn't rely on trapping and emulation
making it a good fit for a number of applications such as AMP, real-time
and safety applications.

Together with the new transport, this series adds a PCI device that
implements an AMP setup much like it could look if two SoC's would
use virtio-msg across a PCI link.

Current gaps and limitations:
Shared memory FIFO layout likely to change in the future.
Temporarily uses PCI Vendor Xilinx / Device 0x9039.
Documentation.

The virtio-msg draft spec:
https://github.com/Linaro/virtio-msg-spec/

QEMU with these patches:
https://github.com/edgarigl/qemu/tree/edgar/virtio-msg-rfc

Linux with virtio-msg support:
https://github.com/edgarigl/linux/tree/edgari/virtio-msg-6.17

To try it, first build Linux with the following enabled:
CONFIG_VIRTIO_MSG=y
CONFIG_VIRTIO_MSG_AMP=y
CONFIG_VIRTIO_MSG_AMP_PCI=y

Boot linux on QEMU with a virtio-msg-amp-pci device, in this example
with a virtio-net device attached to it:

 -device virtio-msg-amp-pci
 -device virtio-net-device,netdev=n0
 -netdev user,id=n0

If you're running on a QEMU machine that has virtio-mmio enabled, e.g 
ARM virt, you'll need to specify the virtio-bus for the device, otherwise
QEMU will connect it to virtio-mmio. For ARM virt machines:

 -device virtio-msg-amp-pci
 -device virtio-net-device,netdev=n0,bus=/gpex-pcihost/pcie.0/virtio-msg-amp-pci/fifo0/virtio-msg/bus0/virtio-msg-dev
 -netdev user,id=n0

Cheers,
Edgar

Edgar E. Iglesias (5):
  virtio: Introduce notify_queue
  virtio: Add virtio_queue_get_rings
  virtio: Add the virtio-msg transport
  hw/misc: Add generic virtio-msg AMP PCI device
  docs: Describe virtio-msg-amp-pci

 .../devices/virtio/virtio-msg-amp-pci.rst     |  70 ++
 hw/misc/Kconfig                               |   7 +
 hw/misc/meson.build                           |   1 +
 hw/misc/virtio-msg-amp-pci.c                  | 328 +++++++
 hw/virtio/Kconfig                             |   4 +
 hw/virtio/meson.build                         |   5 +
 hw/virtio/virtio-msg-bus.c                    |  89 ++
 hw/virtio/virtio-msg.c                        | 695 ++++++++++++++
 hw/virtio/virtio.c                            |  23 +
 include/hw/virtio/spsc_queue.h                | 213 +++++
 include/hw/virtio/virtio-bus.h                |   1 +
 include/hw/virtio/virtio-msg-bus.h            |  95 ++
 include/hw/virtio/virtio-msg-prot.h           | 846 ++++++++++++++++++
 include/hw/virtio/virtio-msg.h                |  56 ++
 include/hw/virtio/virtio.h                    |   2 +
 15 files changed, 2435 insertions(+)
 create mode 100644 docs/system/devices/virtio/virtio-msg-amp-pci.rst
 create mode 100644 hw/misc/virtio-msg-amp-pci.c
 create mode 100644 hw/virtio/virtio-msg-bus.c
 create mode 100644 hw/virtio/virtio-msg.c
 create mode 100644 include/hw/virtio/spsc_queue.h
 create mode 100644 include/hw/virtio/virtio-msg-bus.h
 create mode 100644 include/hw/virtio/virtio-msg-prot.h
 create mode 100644 include/hw/virtio/virtio-msg.h

-- 
2.43.0



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

end of thread, other threads:[~2025-11-13 20:56 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-28 15:23 [PATCH v1 0/5] virtio: Add the virtio-msg transport Edgar E. Iglesias
2025-10-28 15:23 ` [PATCH v1 1/5] virtio: Introduce notify_queue Edgar E. Iglesias
2025-11-05 12:38   ` Alex Bennée
2025-11-13 20:43     ` Edgar E. Iglesias
2025-10-28 15:23 ` [PATCH v1 2/5] virtio: Add virtio_queue_get_rings Edgar E. Iglesias
2025-11-05 12:39   ` Alex Bennée
2025-10-28 15:23 ` [PATCH v1 3/5] virtio: Add the virtio-msg transport Edgar E. Iglesias
2025-10-28 15:23 ` [PATCH v1 4/5] hw/misc: Add generic virtio-msg AMP PCI device Edgar E. Iglesias
2025-10-28 15:23 ` [PATCH v1 5/5] docs: Describe virtio-msg-amp-pci Edgar E. Iglesias
2025-11-05 19:52   ` Alex Bennée
2025-10-28 15:30 ` [PATCH v1 0/5] virtio: Add the virtio-msg transport Edgar E. Iglesias

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).