libvirt: report pci Type-PF type even when VFs are disabled
libvirt < 1.3 reports virt_functions capability only when pf has
VFs enabled. This workaround patch updates the is_physical_function
function to read the sriov_totalvfs if exists and check it is
greater than 0. The sriov_totalvfs is the number for the
maximum possible VF for this PF. _get_pcidev_info in libvirt driver
is updated to get the correct pci device type using this function.
Reviewed: https:/ /review. openstack. org/227160 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=2ba4644f91a a523c2a14e32a16 8b853cf0b8c4e1
Committed: https:/
Submitter: Jenkins
Branch: master
commit 2ba4644f91aa523 c2a14e32a168b85 3cf0b8c4e1
Author: Moshe Levi <email address hidden>
Date: Wed Sep 23 02:49:28 2015 +0300
libvirt: report pci Type-PF type even when VFs are disabled
libvirt < 1.3 reports virt_functions capability only when pf has function
VFs enabled. This workaround patch updates the is_physical_
function to read the sriov_totalvfs if exists and check it is
greater than 0. The sriov_totalvfs is the number for the
maximum possible VF for this PF. _get_pcidev_info in libvirt driver
is updated to get the correct pci device type using this function.
Closes-Bug: #1499204 6093a465930ff3f 0948dd64986
Change-Id: I8990c36fb1d6c6