Specifying a PF passthrough device in the pci_passthrough_whitelist using its
fully qualified PCI address (no wildcard) causes the device to not be
properly loaded. The PCI device is then not available to be assigned to any
guest.
In this case, the hypervisor reports the PF device without a 'parent_addr'.
But in the PciAddress, match() is using it when doing the comparison to its
own address.
This commit changes the logic of the address matching method in PciDevSpec to
only try to match the address with a physical function device when a
'parent_addr' is reported by the hypervisor.
Reviewed: https:/ /review. openstack. org/363884 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=d38d5767d15 b24df455b1844df e53ada2ebf9751
Committed: https:/
Submitter: Jenkins
Branch: master
commit d38d5767d15b24d f455b1844dfe53a da2ebf9751
Author: Ludovic Beliveau <email address hidden>
Date: Wed Aug 31 14:27:43 2016 -0400
PCI: Fix PCI with fully qualified address
Specifying a PF passthrough device in the pci_passthrough _whitelist using its
fully qualified PCI address (no wildcard) causes the device to not be
properly loaded. The PCI device is then not available to be assigned to any
guest.
In this case, the hypervisor reports the PF device without a 'parent_addr'.
But in the PciAddress, match() is using it when doing the comparison to its
own address.
This commit changes the logic of the address matching method in PciDevSpec to
only try to match the address with a physical function device when a
'parent_addr' is reported by the hypervisor.
Change-Id: I5255240871d8ad 5c216500f395203 39efe46e84b
Closes-Bug: #1613434