[PATCH 3/3] transport-mmio: VIRTIO_F_SHM_PAGE_SIZE

Sergio Lopez
2025-02-17T11:52:38Z

Introduce VIRTIO_F_SHM_PAGE_SIZE by adding a the new register
"SHMPageShift" to hold the value that can be used to derive the page
size value supported by the device.

Signed-off-by: Sergio Lopez <slp@redhat.com>
---
transport-mmio.tex | 8 ++++++++
1 file changed, 8 insertions(+)

diff --git a/transport-mmio.tex b/transport-mmio.tex
index 94a93a1..28d1594 100644
--- a/transport-mmio.tex
+++ b/transport-mmio.tex
@@ -242,6 +242,14 @@ \subsection{MMIO Device Register Layout}\label{sec:Virtio Transport Options / Vi
apply to the queue selected by writing to \field{QueueSel}.
}
\hline
+ \mmioreg{SHMPageShift}{Shared memory region page shift 8 bit long}{0x0c4}{R}{%
+ If VIRTIO_F_SHM_PAGE_SIZE has been negotiated, this register returns
+ the page shift derived from the supported page size for this shared
+ memory region. The page shift is derived from the page size by using
+ this formula: $page size = 1 << (page shift + 12)$.
+ See also \ref {sec:Basic Facilities of a Virtio Device / Shared Memory Regions / Page alignment restrictions}.
+ }
+ \hline
\mmioreg{ConfigGeneration}{Configuration atomicity value}{0x0fc}{R}{
Reading from this register returns a value describing a version of the device-specific configuration space (see \field{Config}).
The driver can then access the configuration space and, when finished, read \field{ConfigGeneration} again.
--
2.48.1