In some cases, you might want to split virtual functions (VFs) from the same physical function (PF) into multiple resource pools.
For example, you might want some of the VFs to load with the default driver and the remaining VFs load with the
In such a deployment, the
pfNames selector in your SriovNetworkNodePolicy custom resource (CR) can be used to specify a range of VFs for a pool using the following format:
For example, the following YAML shows the selector for an interface named
netpf0 with VF
netpf0 is the PF interface name.
2 is the first VF index (0-based) that is included in the range.
7 is the last VF index (0-based) that is included in the range.
You can select VFs from the same PF by using different policy CRs if the following requirements are met:
numVfs value must be identical for policies that select the same PF.
The VF index must be in the range of
<numVfs>-1. For example, if you have a policy with
numVfs set to
8, then the
<first_vf> value must not be smaller than
0, and the
<last_vf> must not be larger than
The VFs ranges in different policies must not overlap.
<first_vf> must not be larger than the
The following example illustrates NIC partitioning for an SR-IOV device.
policy-net-1 defines a resource pool
net-1 that contains the VF
0 of PF
netpf0 with the default VF driver.
policy-net-1-dpdk defines a resource pool
net-1-dpdk that contains the VF
15 of PF
netpf0 with the
vfio VF driver.