[PATCH v3 1/3] docs: refactor mdev_types into new paragraph

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



To prevent copying the mdev_types description multiple times
it is refactored into a new paragraph for easy reuse.

Signed-off-by: Boris Fiuczynski <fiuczy@xxxxxxxxxxxxx>
Reviewed-by: Bjoern Walk <bwalk@xxxxxxxxxxxxx>
Reviewed-by: Erik Skultety <eskultet@xxxxxxxxxx>
---
 docs/drvnodedev.html.in |  2 +-
 docs/formatnode.html.in | 69 ++++++++++++++++++++++++-----------------
 2 files changed, 41 insertions(+), 30 deletions(-)

diff --git a/docs/drvnodedev.html.in b/docs/drvnodedev.html.in
index 0823c1888d..639f58d8ce 100644
--- a/docs/drvnodedev.html.in
+++ b/docs/drvnodedev.html.in
@@ -144,7 +144,7 @@
       types on the physical device, along with the type attributes available
       through sysfs. A detailed description of the XML format for the
       <code>mdev_types</code> capability can be found
-      <a href="formatnode.html#MDEVCap">here</a>.
+      <a href="formatnode.html#MDEVTypesCap">here</a>.
     </p>
     <p>
       The following example shows how we might represent an NVIDIA GPU device
diff --git a/docs/formatnode.html.in b/docs/formatnode.html.in
index 6928bdd69c..3fad842c53 100644
--- a/docs/formatnode.html.in
+++ b/docs/formatnode.html.in
@@ -159,35 +159,10 @@
                   </dd>
                   <dt><code><a id="MDEVCap">mdev_types</a></code></dt>
                   <dd>
-                    This device is capable of creating mediated devices, and
-                    the capability will contain a list of <code>type</code>
-                    elements, which list all mdev types supported on the
-                    physical device. <span class="since">Since 3.4.0</span>
-                    Each <code>type</code> element has a single <code>id</code>
-                    attribute that holds an official vendor-supplied identifier
-                    for the type. It supports the following sub-elements:
-                      <dl>
-                        <dt><code>name</code></dt>
-                        <dd>
-                          The <code>name</code> element holds a vendor-supplied
-                          code name for the given mediated device type. This is
-                          an optional element.
-                      </dd>
-                      <dt><code>deviceAPI</code></dt>
-                      <dd>
-                        The value of this element describes how an instance of
-                        the given type will be presented to the guest by the
-                        VFIO framework.
-                      </dd>
-                      <dt><code>availableInstances</code></dt>
-                      <dd>
-                        This element reports the current state of resource
-                        allocation. In other words, how many instances of the
-                        given type can still be successfully created on the
-                        physical device.
-                    </dd>
-                  </dl>
-                </dd>
+                    This device is capable of creating mediated devices.
+                    The sub-elements are summarized in
+                    <a href="#MDEVTypesCap">mdev_types capability</a>.
+                 </dd>
                 </dl>
               </dd>
 
@@ -445,6 +420,42 @@
       </dd>
     </dl>
 
+    <h3><a id="MDEVTypesCap">mdev_types capability</a></h3>
+
+    <p>
+      <a href="#MDEVCap">PCI</a> devices can be capable of
+      creating mediated devices. If they indeed are capable,
+      then the parent <code>capability</code> element for
+      <code>mdev_types</code> type will contain a list of
+      <code>type</code> elements, which list all mdev types supported
+      on the physical device. <span class="since">Since 3.4.0</span>
+      Each <code>type</code> element has a single <code>id</code>
+      attribute that holds an official vendor-supplied identifier
+      for the type. It supports the following sub-elements:
+      <dl>
+        <dt><code>name</code></dt>
+        <dd>
+          The <code>name</code> element holds a vendor-supplied
+          code name for the given mediated device type. This is
+          an optional element.
+        </dd>
+        <dt><code>deviceAPI</code></dt>
+        <dd>
+          The value of this element describes how an instance of
+          the given type will be presented to the guest by the
+          VFIO framework.
+        </dd>
+        <dt><code>availableInstances</code></dt>
+        <dd>
+          This element reports the current state of resource
+          allocation. In other words, how many instances of the
+          given type can still be successfully created on the
+          physical device.
+        </dd>
+      </dl>
+    </p>
+
+
     <h2><a id="nodeExample">Examples</a></h2>
 
     <p>The following are some example node device XML outputs:</p>
-- 
2.26.2




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux