From: Laine Stump
Date: Fri, 4 Mar 2016 15:26:23 +0000 (-0500)
Subject: conf: new pci controller model pci-expander-bus
X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=52f3d0a4d2de2f3a633bd49b4ebc46a31329a04c;p=libvirt.git
conf: new pci controller model pci-expander-bus
This is a standard PCI root bus (not a bridge) that can be added to a
440fx-based domain. Although it uses a PCI slot, this is *not* how it
is connected into the PCI bus hierarchy, but is only used for
control. Each pci-expander-bus provides 32 slots (0-31) that can
accept hotplug of standard PCI devices.
The usefulness of pci-expander-bus relative to a pci-bridge is that
the NUMA node of the bus can be specified with the subelement
of . This gives guest-side visibility to the NUMA node of
attached devices (presuming that management apps only assign a device
to a bus that has a NUMA node number matching the node number of the
device on the host).
Each pci-expander-bus also has a "busNr" attribute. The expander-bus
itself will take the busNr specified, and all buses that are connected
to this bus (including the pci-bridge that is automatically added to
any expander bus of model "pxb" (see the next commit)) will use
busNr+1, busNr+2, etc, and the pci-root (or the expander-bus with next
lower busNr) will use bus numbers lower than busNr.
---
diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in
index e3307eb049..43102c8d11 100644
--- a/docs/formatdomain.html.in
+++ b/docs/formatdomain.html.in
@@ -3102,12 +3102,13 @@
PCI controllers have an optional model attribute with
possible values pci-root, pcie-root,
pcie-root-port, pci-bridge,
- dmi-to-pci-bridge, pcie-switch-upstream-port, or
- pcie-switch-downstream-port.
+ dmi-to-pci-bridge, pcie-switch-upstream-port,
+ pcie-switch-downstream-port, or pci-expander-bus.
(pci-root and pci-bridge since 1.0.5,
pcie-root and dmi-to-pci-bridge since
- 1.1.2, pcie-root-port, pcie-switch-upstream-port, and
- pcie-switch-downstream-port since 1.2.19)
+ 1.1.2, pcie-root-port, pcie-switch-upstream-port,
+ pcie-switch-downstream-port since 1.2.19,
+ and pci-expander-bus since 1.3.4)
The root controllers (pci-root and pcie-root)
have an optional pcihole64 element specifying how big
(in kilobytes, or in the unit specified by pcihole64's
@@ -3131,9 +3132,9 @@
PCI controllers also have an optional
- subelement <target> with the attributes
- listed below. These are configurable items that 1) are visible
- to the guest OS so must be preserved for guest ABI
+ subelement <target> with the attributes and
+ subelements listed below. These are configurable items that 1)
+ are visible to the guest OS so must be preserved for guest ABI
compatibility, and 2) are usually left to default values or
derived automatically by libvirt. In almost all cases, you
should not manually add a <target> subelement
@@ -3170,6 +3171,35 @@
which is visible to the virtual machine. If set, port must be
between 0 and 255.
+
busNr
+
+ pci-expander-bus controllers can have an
+ optional busNr attribute (1-254). This will be
+ the bus number of the new bus; All bus numbers between that
+ specified and 255 will be available only for assignment to
+ PCI/PCIe controllers plugged into the hierarchy starting with
+ this expander bus, and bus numbers less than the specified
+ value will be available to the next lower expander-bus (or the
+ root-bus if there are no lower expander buses). If you do not
+ specify a busNumber, libvirt will find the lowest existing
+ busNumber in all other expander buses (or use 256 if there are
+ no others) and auto-assign the busNr of that found bus - 2,
+ which provides one bus number for the pci-expander-bus and one
+ for the pci-bridge that is automatically attached to it (if
+ you plan on adding more pci-bridges to the hierarchy of the
+ bus, you should manually set busNr to a lower value).
+
+
<node>
+
+ pci-expander-bus controllers can have an
+ optional <node> subelement within
+ the <target> subelement, which is used to
+ set the NUMA node reported to the guest OS for that bus - the
+ guest OS will then know that all devices on that bus are a
+ part of the specified NUMA node (it is up to the user of the
+ libvirt API to attach host devices to the correct
+ pci-expander-bus when assigning them to the domain).
+