public inbox for virtio-comment@lists.linux.dev
 help / color / mirror / Atom feed
From: "Edgar E. Iglesias" <edgar.iglesias@amd.com>
To: Demi Marie Obenour <demiobenour@gmail.com>
Cc: Bill Mills <bill.mills@linaro.org>,
	<virtio-comment@lists.linux.dev>,
	Bertrand Marquis <bertrand.marquis@arm.com>,
	Arnaud Pouliquen <arnaud.pouliquen@foss.st.com>,
	Viresh Kumar <viresh.kumar@linaro.org>,
	Alex Bennee <alex.bennee@linaro.org>,
	Armelle Laine <armellel@google.com>, Alyssa Ross <hi@alyssa.is>
Subject: Re: [PATCH v1 2/4] virtio-msg: Add virtio-msg, a message based virtio transport layer
Date: Tue, 24 Feb 2026 18:36:47 +0100	[thread overview]
Message-ID: <aZ3hJoolYGzZY7nG@zapote> (raw)
In-Reply-To: <c0e37ee7-9631-4611-ace2-43609dc11ab2@gmail.com>

On Tue, Feb 24, 2026 at 10:41:59AM -0500, Demi Marie Obenour wrote:
> On 1/26/26 11:32, Bill Mills wrote:
> > Add a new transport layer that is based on messages.
> > 
> > This transport layer still uses virtqueues as the other transport layers do
> > but implements transport layer operations by sending and receiving messages
> > instead of the "MMR" reads and writes used in virtio-mmio and virtio-pci.
> > 
> > This transport is useful when the device and driver are both implemented in
> > software but the trap and emulate operations of virtio-mmio and virtio-pci
> > can not be used.
> 
> Is it possible to map a virtio-mmio or virtio-pci device to virtio-msg?
> For instance, can a VMM present a virtio-mmio or virtio-pci device
> to its VM, while using virtio-msg to communicate with its backend?

Hi Demi,

Yes, that is possible. One of the first implementations of virtio-msg
was using a generic proxy in QEMU that translated virtio-mmio and
virtio-pci to virtio-msg, at the time there was no virtio-msg Linux
driver so this served as a stepping stone. I haven't kept the proxy
up to date though.

https://github.com/edgarigl/qemu/blob/edgar/virtio-msg/hw/virtio/virtio-msg-proxy-driver.c


We also have a proxy for Xen that translates a slightly modified version
of virtio-mmio to virtio-msg.

https://github.com/Xilinx/xen/tree/xlnx_rebase_4.20/xen/common/virtio

Best regards,
Edgar

> 
> > This transport is intended to be used in many situations, including:
> > * between a host processor and its co-processors
> > * between two different systems (not SMP) connected via PCIe
> > * between normal and secure worlds
> > * host to vm
> 
> How does this map to the vhost-user protocol [1]?  Vhost-user is a very
> common way to implement devices and it would be nice for virtio-msg
> to cleanly map to it.  Requiring a separate AF_UNIX transport could
> be quite disruptive.
> 
> [1]: https://www.qemu.org/docs/master/interop/vhost-user.html
> 
> > * vm to vm
> 
> This requires a method for VMs to implement devices, not just drivers.
> For Xen and FF-A this is easy, provided that there is an out-of-band
> means to enumerate which devices should be implemented.  However,
> these mechanisms are not hypervisor-agnostic.
> 
> It would be much better to have a standard virtio device that backends
> could use to implement virtio-msg devices.  There have been multiple
> attempts at a virtio vhost-user device backend [2], but it was never
> widely deployed.
> 
> [2]: https://stefanha.github.io/virtio/vhost-user-slave.html
> 
> > Signed-off-by: Bill Mills <bill.mills@linaro.org>
> > Signed-off-by: Bertrand Marquis <bertrand.marquis@arm.com>
> > Signed-off-by: Edgar E. Iglesias <edgar.iglesias@amd.com>
> > Signed-off-by: Arnaud Pouliquen <arnaud.pouliquen@foss.st.com>
> > ---
> >  transport-msg.tex | 1640 +++++++++++++++++++++++++++++++++++++++++++++
> >  1 file changed, 1640 insertions(+)
> >  create mode 100644 transport-msg.tex
> > 
> > diff --git a/transport-msg.tex b/transport-msg.tex
> > new file mode 100644
> > index 0000000..d4e31d7
> > --- /dev/null
> > +++ b/transport-msg.tex
> > @@ -0,0 +1,1640 @@
> > +\section{Virtio Over Messages}\label{sec:Virtio Transport Options / Virtio Over Messages}
> > +
> > +\newcommand{\conceptref}[1]{\hyperref[sec:Virtio Transport Options / Virtio Over Messages / Basic Concepts / #1]{#1}}
> > +\newcommand{\msgref}[1]{\hyperref[sec:Virtio Transport Options / Virtio Over Messages / Transport Messages / VIRTIO_MSG_#1]{VIRTIO_MSG_#1}}
> > +\newcommand{\busref}[1]{\hyperref[sec:Virtio Transport Options / Virtio Over Messages / Bus Messages / BUS_MSG_#1]{BUS_MSG_#1}}
> > +\newcommand{\msgdef}[1]{\subsubsection{VIRTIO_MSG_#1}\label{sec:Virtio Transport Options / Virtio Over Messages / Transport Messages / VIRTIO_MSG_#1}}
> > +\newcommand{\busdef}[1]{\subsubsection{BUS_MSG_#1}\label{sec:Virtio Transport Options / Virtio Over Messages / Bus Messages / BUS_MSG_#1}}
> > +
> > +This section defines \textbf{virtio-msg}, a transport mechanism that encapsulates
> > +virtio operations as discrete message exchanges rather than relying on PCI or
> > +memory-mapped I/O regions. It separates bus-level functionality (e.g., device
> > +enumeration, hotplug events) from device-specific operations (e.g., feature
> > +negotiation, virtqueue setup), ensuring that a single, generic transport layer
> > +can be reused across multiple bus implementations.
> > +
> > +virtio-msg addresses several key objectives:
> > +
> > +\begin{itemize}
> > +  \item \textbf{Support multiple bus implementations:}
> > +  Systems can rely on various communication methods such as hypercalls, local
> > +  IPC, network channels, or device trees for enumerating devices. virtio-msg
> > +  defines a common transport interface suitable for any of these mechanisms.
> > +
> > +  \item \textbf{Reduce per-bus complexity:}
> > +  Buses can implement a fully message-based workflow (including optional
> > +  enumeration via \busref{GET_DEVICES} and hotplug via \busref{EVENT_DEVICE})
> > +  or they can discover and manage devices through
> > +  alternative means such as platform firmware data. In either case, they
> > +  forward transport messages to and from each device.
> > +
> > +  \item \textbf{Preserve virtio semantics:}
> > +  The transport leverages standard virtio concepts (features, configuration
> > +  space, virtqueues), so existing virtio drivers and device implementations can
> > +  integrate smoothly once a device is discovered and registered.
> > +\end{itemize}
> 
> I see that there is support for device enumeration by drivers.
> What about driver enumeration by devices?  An FF-A endpoint or Xen VM
> needs to know which devices it should implement.  In embedded systems,
> this can be obtained from the device tree or ACPI.  However, dynamic
> systems need to create and destroy devices at runtime.
> -- 
> Sincerely,
> Demi Marie Obenour (she/her/hers)






  parent reply	other threads:[~2026-02-24 17:36 UTC|newest]

Thread overview: 105+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-26 16:32 [PATCH v1 0/4] virtio-msg transport layer Bill Mills
2026-01-26 16:32 ` [PATCH v1 1/4] virtio-msg: add new command for bus normative Bill Mills
2026-02-03 19:42   ` Edgar E. Iglesias
2026-01-26 16:32 ` [PATCH v1 2/4] virtio-msg: Add virtio-msg, a message based virtio transport layer Bill Mills
2026-02-06 16:28   ` Peter Hilber
2026-02-10  9:39     ` Bertrand Marquis
2026-02-12 11:16       ` Peter Hilber
2026-02-20  8:23         ` Bertrand Marquis
2026-02-26 13:53           ` Peter Hilber
2026-02-13 19:09   ` Demi Marie Obenour
2026-02-20  8:52     ` Bertrand Marquis
2026-02-21  2:04       ` Demi Marie Obenour
2026-02-23  7:44         ` Bertrand Marquis
2026-02-24 15:41   ` Demi Marie Obenour
2026-02-24 16:14     ` Bertrand Marquis
2026-02-24 17:36     ` Edgar E. Iglesias [this message]
2026-02-24 17:14   ` Demi Marie Obenour
2026-02-24 17:20     ` Bertrand Marquis
2026-02-24 17:46       ` Demi Marie Obenour
2026-02-25  7:26         ` Bertrand Marquis
2026-02-25 12:36   ` Demi Marie Obenour
2026-02-25 12:46     ` Bertrand Marquis
2026-01-26 16:32 ` [PATCH v1 3/4] virtio-msg: link virtio-msg content Bill Mills
2026-02-03 19:43   ` Edgar E. Iglesias
2026-01-26 16:32 ` [PATCH v1 4/4] virtio-msg: add conformance entries in conformance chapter Bill Mills
2026-02-03 19:43   ` Edgar E. Iglesias
2026-01-26 21:47 ` [PATCH v1 0/4] virtio-msg transport layer Demi Marie Obenour
2026-02-03 13:21 ` Michael S. Tsirkin
2026-02-03 19:48   ` Edgar E. Iglesias
2026-02-03 19:55     ` Michael S. Tsirkin
2026-02-04  8:33   ` Bertrand Marquis
2026-02-04 13:50   ` Arnaud POULIQUEN
2026-02-04  3:29 ` Viresh Kumar
2026-02-04  5:34 ` Manivannan Sadhasivam
2026-02-13 13:52 ` Parav Pandit
2026-02-13 19:45   ` Demi Marie Obenour
2026-02-19 17:31     ` Armelle Laine
2026-02-20  8:55     ` Bertrand Marquis
2026-02-19 23:54   ` Michael S. Tsirkin
2026-02-20  6:13     ` Parav Pandit
2026-02-20  9:02       ` Bertrand Marquis
2026-02-25  7:45         ` Manivannan Sadhasivam
2026-02-25  8:03           ` Bertrand Marquis
2026-02-25  8:12             ` Michael S. Tsirkin
2026-02-25 10:06             ` Manivannan Sadhasivam
2026-02-25 10:10               ` Michael S. Tsirkin
2026-02-25 10:14               ` Bertrand Marquis
2026-02-25 10:22               ` Michael S. Tsirkin
2026-02-25 10:53                 ` Manivannan Sadhasivam
2026-02-25 10:24               ` Parav Pandit
2026-02-25 10:35                 ` Bertrand Marquis
2026-02-25 10:52                   ` Michael S. Tsirkin
2026-02-25 10:55                     ` Bertrand Marquis
2026-02-25 10:58                       ` Michael S. Tsirkin
2026-02-25 14:45                   ` Parav Pandit
2026-02-25 14:49                     ` Michael S. Tsirkin
2026-02-25 14:53                       ` Bertrand Marquis
2026-02-25 15:00                         ` Parav Pandit
2026-02-25 15:07                           ` Parav Pandit
2026-02-25 15:12                             ` Bertrand Marquis
2026-02-25 15:15                               ` Michael S. Tsirkin
2026-02-25 15:36                               ` Demi Marie Obenour
2026-02-25 15:40                                 ` Bertrand Marquis
2026-02-25 15:48                                   ` Demi Marie Obenour
2026-02-25 15:51                                     ` Bertrand Marquis
2026-02-25 16:15                                       ` Demi Marie Obenour
2026-02-26  5:40                               ` Manivannan Sadhasivam
2026-02-26  7:05                                 ` Bertrand Marquis
2026-02-25 15:11                           ` Manivannan Sadhasivam
2026-02-25 15:15                             ` Parav Pandit
2026-02-26  5:36                               ` Manivannan Sadhasivam
2026-02-26  5:59                                 ` Parav Pandit
2026-02-26  6:19                                   ` Manivannan Sadhasivam
2026-02-26  7:01                                 ` Bertrand Marquis
2026-02-26  7:28                                   ` Manivannan Sadhasivam
2026-02-26 19:20                                 ` Demi Marie Obenour
2026-02-26 22:08                                   ` Edgar E. Iglesias
2026-02-25 15:23                           ` Demi Marie Obenour
2026-02-25 16:42                         ` Edgar E. Iglesias
2026-02-25 12:53           ` Demi Marie Obenour
2026-02-25 13:09             ` Manivannan Sadhasivam
2026-02-25 13:12               ` Demi Marie Obenour
2026-02-25 13:29                 ` Bertrand Marquis
2026-02-25 15:19                   ` Demi Marie Obenour
2026-02-25 15:27                     ` Bertrand Marquis
2026-02-20 10:03       ` Michael S. Tsirkin
2026-02-25  5:09         ` Parav Pandit
2026-02-25  7:25           ` Michael S. Tsirkin
2026-02-25  9:18             ` Parav Pandit
2026-02-25  9:22               ` Michael S. Tsirkin
2026-02-25  9:35                 ` Bertrand Marquis
2026-02-25  9:54                   ` Michael S. Tsirkin
2026-02-25 10:01                     ` Bertrand Marquis
2026-02-25 10:08                       ` Michael S. Tsirkin
2026-02-20  8:58     ` Bertrand Marquis
2026-02-20  8:40   ` Bertrand Marquis
2026-02-25  4:58     ` Parav Pandit
2026-02-25  7:52       ` Bertrand Marquis
2026-02-25 12:46         ` Demi Marie Obenour
2026-02-25 13:05           ` Bertrand Marquis
2026-02-25 13:09             ` Demi Marie Obenour
2026-02-25 15:17         ` Bertrand Marquis
2026-02-24 17:57 ` Demi Marie Obenour
2026-02-25 15:21   ` Alex Bennée
2026-02-25 15:46     ` Demi Marie Obenour

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=aZ3hJoolYGzZY7nG@zapote \
    --to=edgar.iglesias@amd.com \
    --cc=alex.bennee@linaro.org \
    --cc=armellel@google.com \
    --cc=arnaud.pouliquen@foss.st.com \
    --cc=bertrand.marquis@arm.com \
    --cc=bill.mills@linaro.org \
    --cc=demiobenour@gmail.com \
    --cc=hi@alyssa.is \
    --cc=viresh.kumar@linaro.org \
    --cc=virtio-comment@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox