Difference between revisions of "PCI passthrough SRIOV support"
(→group the devices) |
(→tracking device allocated to alias) |
||
Line 36: | Line 36: | ||
* limited support to 3 keys grouping for algorithm simplicity. | * limited support to 3 keys grouping for algorithm simplicity. | ||
− | === tracking device allocated to alias=== | + | === Implement tracking device allocated to alias=== |
here is the idea how user can identify which device allocated for the pci alias. | here is the idea how user can identify which device allocated for the pci alias. | ||
− | * while allocated such device, user put a marker into the device ( | + | *while allocated such device, user put a marker into the device ( into the pci device extra_info fileds) |
− | *after | + | *after finished allocation, user can seach a instance's pci devices to find the specific marker |
the way marker data transfer from user to device utilize the pci_request, which convert from the pci alias. | the way marker data transfer from user to device utilize the pci_request, which convert from the pci alias. |
Revision as of 06:26, 5 December 2013
Contents
background
PCI devices has not only PCI standard property like BDF, vendor_id etc, it also has some extra information which may be application specific. For example, attached network switch for NIC, or resolution for GPU etc.These information can't be achieved through hypervisor, and may be provided externally through like configuration file.
Currently nova PCI support has basic support for such extra information in database and object layer. But we need more effort to it, including: get such information from configuration file, group devices with same extra information value etc.
this design based on this discsstion docs: https://docs.google.com/document/d/1EMwDg9J8zOxzvTnQJ9HwZdiotaVstFWKIuKrPse6JOs/edit?pli=1#heading=h.30de7p6sgoxp
Requements from SRIOV
- group device
for SRIOV, all VFs belong to same PF share same physical network reachability. so if you want, say, deploy a vlan network, you need choose the right PF's VF, otherwise network does not work for you.
- tracking device alloced to the NIC
networking or other special deive is not as simple as pass though to the VM, there is need more configration. to acheive this, SRIOV must know the device infomation allocation to the specific NIC.
Implement the grouping
spec: a filter defined by (k,v) paris extra_spec: the filter defined by (k, v) and k not in the pci object fileds.
pci utils/objects support grouping
* pci utils k,v match support the list values * objects provide a class level extrac interface to extract base spec and extra spec
white list import address set
* white list support 'address':[bdf1, ....] * white list support any other (k,v) pair to group or store special infomation * object extrac specs and extra_info, specs use as whitelist spec, extra info will be updated to device's extra_info fields
enable alias request extra property
* alis can specify extra (k,v) pairs * pci manager use extrac method extrac the specs and extra_specs, match them agains the pci object object.extra_info.
pci stats grouping device on demand
* pci_grouping_key configration option define a set of key name which will used to group the device to stats * default value is [vendor_id, product_id], this current implemtation * limited support to 3 keys grouping for algorithm simplicity.
Implement tracking device allocated to alias
here is the idea how user can identify which device allocated for the pci alias.
*while allocated such device, user put a marker into the device ( into the pci device extra_info fileds) *after finished allocation, user can seach a instance's pci devices to find the specific marker
the way marker data transfer from user to device utilize the pci_request, which convert from the pci alias.