All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Alex Bennée" <alex.bennee@linaro.org>
To: "Edgar E. Iglesias" <edgar.iglesias@gmail.com>
Cc: qemu-devel@nongnu.org,  mst@redhat.com,  bill.mills@linaro.org,
	edgar.iglesias@amd.com
Subject: Re: [PATCH v1 5/5] docs: Describe virtio-msg-amp-pci
Date: Wed, 05 Nov 2025 19:52:25 +0000	[thread overview]
Message-ID: <87tsz8tfye.fsf@draig.linaro.org> (raw)
In-Reply-To: <20251028152351.1247812-6-edgar.iglesias@gmail.com> (Edgar E. Iglesias's message of "Tue, 28 Oct 2025 16:23:50 +0100")

"Edgar E. Iglesias" <edgar.iglesias@gmail.com> writes:

> From: "Edgar E. Iglesias" <edgar.iglesias@amd.com>
>
> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@amd.com>
> ---
>  .../devices/virtio/virtio-msg-amp-pci.rst     | 70
> +++++++++++++++++++

You also need to add this to index.rst otherwise the docs build will
fail.


>  1 file changed, 70 insertions(+)
>  create mode 100644 docs/system/devices/virtio/virtio-msg-amp-pci.rst
>
> diff --git a/docs/system/devices/virtio/virtio-msg-amp-pci.rst b/docs/system/devices/virtio/virtio-msg-amp-pci.rst
> new file mode 100644
> index 0000000000..c73f7a878b
> --- /dev/null
> +++ b/docs/system/devices/virtio/virtio-msg-amp-pci.rst
> @@ -0,0 +1,70 @@
> +Virtio-msg AMP PCI
> +==================
> +
> +This document explains the setup and usage of the virtio-msg-amp-pci device..
> +The virtio-msg-amp-pci, is an emulated PCI device that provides a small
> +set of features to enable virtio-msg over shared-memory queue's.
> +
> +Usecase
> +-------
> +
> +Virtio-msg is a virtio transport where driver and device communicate over
> +messages rather than using memory accesses that get trapped and emulated.
> +Virtio-msg depends on a lower lever virtio-msg-bus responsible for delivering
> +these messages. In this case, we're using the Virtio-msg AMP bus which moves
> +messages back and forth using a FIFO on top of shared-memory and interrupts.
> +
> +The virtio-msg-amp-pci device exposes a BAR with RAM and doorbell registers
> +so guests can implement the shared-memory FIFO protocol and QEMU implements
> +the backend side of it.
> +
> +Virtio pmem allows to bypass the guest page cache and directly use
> +host page cache. This reduces guest memory footprint as the host can
> +make efficient memory reclaim decisions under memory pressure.
> +
> +Virtio-msg-amp-pci PCI device
> +-----------------------------
> +
> +The virtio-msg-amp-pci device has the following layout:
> +
> +- BAR 0: Registers (Version, features and notification/doorbell regs)
> +- BAR 1: RAM for FIFOs
> +
> +Each FIFO gets an MSI-X interrupt reserved for it and a dedicated doorbell
> +register::
> +
> +        REG32(VERSION,  0x00)
> +        REG32(FEATURES, 0x04)
> +        REG32(NOTIFY0,  0x20)
> +        REG32(NOTIFY1,  0x24)
> +        REG32(NOTIFY2,  0x28)
> +        And so on.
> +
> +How does virtio-msg-amp-pci compare to virtio-pci emulation?
> +------------------------------------------------------------
> +
> +Both virtio-msg-amp-pci and virtio-pci emulate PCI devices and allow users
> +to plug virtio devices behind them. The main difference is in how the
> +guest uses virtio-msg vs virtio-pci to discover and configure the virtio dev.
> +
> +virtio pmem usage
> +-----------------
> +
> +A virtio-msg-amp-pci can be greated by adding the following to the QEMU
> +command-line::
> +
> +    -device virtio-msg-amp-pci
> +
> +Virtio devices can then be attached to the virtio-msg bus with for example
> +the following::
> +
> +    -device virtio-rng-device,bus=/gpex-pcihost/pcie.0/virtio-msg-amp-pci/fifo0/virtio-msg/bus0/virtio-msg-dev
> +
> +Multiple virtio devices can be connected by using bus1, bus2 and so on.
> +
> +Device properties
> +-----------------
> +
> +The virtio-msg-amp-pci  device can be configured with the following properties:
> +
> + * ``num-fifos`` number of fifos (default 2).

-- 
Alex Bennée
Virtualisation Tech Lead @ Linaro


  reply	other threads:[~2025-11-05 19:53 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
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 [this message]
2025-10-28 15:30 ` [PATCH v1 0/5] virtio: Add the virtio-msg transport Edgar E. Iglesias
2026-02-03 13:22 ` Michael S. Tsirkin
2026-02-03 17:09   ` Edgar E. Iglesias

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=87tsz8tfye.fsf@draig.linaro.org \
    --to=alex.bennee@linaro.org \
    --cc=bill.mills@linaro.org \
    --cc=edgar.iglesias@amd.com \
    --cc=edgar.iglesias@gmail.com \
    --cc=mst@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.