The partitioning functionality extends the use of "pci_db", "pci_hw", and namespace node
to provide separation between multiple single pci-server instances and
allows some of the benefits afforded by multiple resource managers.
You can partition to separate the four segment hierarchies of the example system shown in
Figure 3 in the Terminology section and enable the
use of multiple pci-server instances.
Note: It is important to understand that the partitioning and segmentation functionality is
facilitated entirely by the hardware module for the platform. If the hardware module
does not support this functionality, it will not be possible to use it. Starting
multiple pci-server instances in separate partitions will result
in undefined behavior.
You can use partitioning to separate one of the segments from the other three in systems such
as the ones shown in Figure 2 and Figure 3 in Terminology. You can use the PCI_PARTITION_NAME environment
variable is used to create and associate with a specific partition.
Assume there is a hardware module that supports partitioning and the four root ports are
identified by the hardware module as PCIe0 through
PCIe3 respectively. For explicitly creating partitions, you must
make sure that each of these partitions is named uniquely such that "pci_db", "pci_hw"
and the namespace node for the pci-server instance are all located at
a unique location within the namespace.
Note: You have to decide the partitioning scheme and ensure that the
pci-server instances managing the segments within those separate
partitions are properly configured.
As an example the hierarchy is partitioned as follows:
- Partition 1
- Name: “pcie_0_2_part”
- Number of pci-server instances: 1
- Description: The three segment hierarchies rooted at PCI controllers
PCIe0 through PCIe2 will be
associated with the same partition and share a global BDF space
specified by B[255..0]:D[31..0]:F[7..0]. However, the
use of this space will be sparse.
- Partition 2
- Name: “pcie_3_part”
- Number of pci-server instances: 1
- Description: The segment hierarchy rooted at PCIe3 will
be associated with its own partition and have its own BDF space
specified by B[255..0]:D[31..0]:F[7..0].
In a single partition, single pci-server instance configuration, the
BDF space is necessarily global. To accommodate this across multiple segments, hardware
modules will typically assign a BDF or routing identifier to each of the root ports.
The value of this BDF is typically selected to accommodate a “realistic” topology below
each of the root ports. For example, a realistic assignment of a BDF to each of the four
example root ports could be as follows:
- Root Port #1: B0:D0:F0
- Root Port #2: B8:D0:F0
- Root Port #3: B16:D0:F0
- Root Port #4: B24:D0:F0
In this example, each segment hierarchy supports seven downstream bus numbers to
accommodate a hierarchy consisting of a couple of switch depths to fan out for multiple
endpoints. The actual assignments will be based on the system design. In embedded
systems in which the segment hierarchies may be fixed, the stride between root port BDF
assignments can be tightened to compress the BDF space to only what is necessary.
In the case of partitioning, because the BDF space is partition global, it is possible to
reuse BDF in other partitions. This is effectively like adding another identifier to the
BDF tuple. Even though this expansion of the PCI Domain BDF space exists with
partitioning, it does not mean that the hardware module is required to support this.
Because the entire partitioning and segmentation functionality is facilitated by the
hardware module, the hardware module continues to provide the means, whether fixed or
configurable, on how BDF assignments to root ports will be done. If it chooses, it can
always ensure that these assignments are unique regardless of whether partitioning is
being used or not. The details of this BDF assignment are outside the scope of this
document and will be documented in the user information of each hardware module which
supports the partitioning and segmentation functionality.
As for the two partition example, the figure below illustrates the relationship between
the segment hierarchies and the
pci-server instances which manage
them. Each
pci-server instance creates the 'pci_db', 'pci_hw' and the
namespace node names in their own unique portion of the name space based on the assigned
partition names. This allows for process separation between the two
pci-server instances.
Figure 1. Relationship between segment hierarchies and the pci-server instances
This example could be further extended to allow for each of the four segments to
be associated with its own partition with a single
pci-server
instance per partition.