yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #43974
[Bug 1499204] Re: wrong check for physical function in pci utils
Reviewed: https://review.openstack.org/227160
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=2ba4644f91aa523c2a14e32a168b853cf0b8c4e1
Submitter: Jenkins
Branch: master
commit 2ba4644f91aa523c2a14e32a168b853cf0b8c4e1
Author: Moshe Levi <moshele@xxxxxxxxxxxx>
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
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.
Closes-Bug: #1499204
Change-Id: I8990c36fb1d6c66093a465930ff3f0948dd64986
** Changed in: nova
Status: In Progress => Fix Released
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1499204
Title:
wrong check for physical function in pci utils
Status in OpenStack Compute (nova):
Fix Released
Bug description:
in pci utils the is_physical_function function check it based on existing virtfn* symbolic link. The check is incorrect because
if the PF doen't enable SR-IOV meaning sriov_numvfs is set to zero there are no virtfn* ljnks and the nova-compute recognize it as VF.
see:
root@r-ufm160:/opt/stack/logs# ls /sys/bus/pci/devices/0000\:03\:00.0/
broken_parity_status d3cold_allowed enable iommu_group modalias pools reset sriov_numvfs uevent
class device infiniband irq msi_bus power resource sriov_totalvfs vendor
commands_cache dma_mask_bits infiniband_cm local_cpulist msi_irqs real_miss resource0 subsystem vpd
config driver infiniband_mad local_cpus net remove resource0_wc subsystem_device
consistent_dma_mask_bits driver_override infiniband_verbs mlx5_num_vfs numa_node rescan sriov subsystem_vendor
root@r-ufm160:/opt/stack/logs# cat /sys/bus/pci/devices/0000\:03\:00.0/sriov_numvfs
0
root@r-ufm160:/opt/stack/logs# echo 4 > /sys/bus/pci/devices/0000\:03\:00.0/sriov_numvfs
root@r-ufm160:/opt/stack/logs# ls /sys/bus/pci/devices/0000\:03\:00.0/
broken_parity_status d3cold_allowed enable iommu_group modalias pools reset sriov_numvfs uevent virtfn3
class device infiniband irq msi_bus power resource sriov_totalvfs vendor vpd
commands_cache dma_mask_bits infiniband_cm local_cpulist msi_irqs real_miss resource0 subsystem virtfn0
config driver infiniband_mad local_cpus net remove resource0_wc subsystem_device virtfn1
consistent_dma_mask_bits driver_override infiniband_verbs mlx5_num_vfs numa_node rescan sriov subsystem_vendor virtfn2
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1499204/+subscriptions
References