PCI-PT : SRIOV enabled interface dev_name in pci whitelist does not give the product_id of PF for the direct-physical_network , it always take the VF's product_id

Bug #1582822 reported by prabhu murthy on 2016-05-17
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Low
Chen Fan

Bug Description

I wanted to Boot direct-physical port on sriov enabled device and use it as PCI device rather than sriov device

Steps to reproduce :
1) Create a direct-physical port and Boot a VM
        neutron port-create n5 --binding:vnic-type direct-physical

Nova.conf

pci_passthrough_whitelist = {"devname":"em49","physical_network":"physnet1","dev_type": "type-PF"}
pci_passthrough_whitelist = {"devname":"em50","physical_network":"physnet2","dev_type": "type-VF"}

n-cpu.log

pci_stats details

[PciDevicePool(count=7,numa_node=None,product_id='10ed',tags={dev_type='type-VF',physical_network='physnet2'},vendor_id='8086'), PciDevicePool(count=1,numa_node=None,product_id='10ed',tags={dev_type='type-PF',physical_network='physnet1'},vendor_id='8086')]

stack@ubuntu:/opt/stack/logs$ lspci -nn | grep Eth
02:00.0 Ethernet controller [0200]: Broadcom Corporation NetXtreme BCM5719 Gigabit Ethernet PCIe [14e4:1657] (rev 01)
02:00.1 Ethernet controller [0200]: Broadcom Corporation NetXtreme BCM5719 Gigabit Ethernet PCIe [14e4:1657] (rev 01)
02:00.2 Ethernet controller [0200]: Broadcom Corporation NetXtreme BCM5719 Gigabit Ethernet PCIe [14e4:1657] (rev 01)
02:00.3 Ethernet controller [0200]: Broadcom Corporation NetXtreme BCM5719 Gigabit Ethernet PCIe [14e4:1657] (rev 01)
04:00.0 Ethernet controller [0200]: Intel Corporation 82599ES 10-Gigabit SFI/SFP+ Network Connection [8086:10fb] (rev 01)
04:00.1 Ethernet controller [0200]: Intel Corporation 82599ES 10-Gigabit SFI/SFP+ Network Connection [8086:10fb] (rev 01)
04:10.0 Ethernet controller [0200]: Intel Corporation 82599 Ethernet Controller Virtual Function [8086:10ed] (rev 01)
04:10.1 Ethernet controller [0200]: Intel Corporation 82599 Ethernet Controller Virtual Function [8086:10ed] (rev 01)
04:10.2 Ethernet controller [0200]: Intel Corporation 82599 Ethernet Controller Virtual Function [8086:10ed] (rev 01)
04:10.3 Ethernet controller [0200]: Intel Corporation 82599 Ethernet Controller Virtual Function [8086:10ed] (rev 01)
04:10.4 Ethernet controller [0200]: Intel Corporation 82599 Ethernet Controller Virtual Function [8086:10ed] (rev 01)
04:10.5 Ethernet controller [0200]: Intel Corporation 82599 Ethernet Controller Virtual Function [8086:10ed] (rev 01)
04:10.6 Ethernet controller [0200]: Intel Corporation 82599 Ethernet Controller Virtual Function [8086:10ed] (rev 01)
04:10.7 Ethernet controller [0200]: Intel Corporation 82599 Ethernet Controller Virtual Function [8086:10ed] (rev 01)
04:11.0 Ethernet controller [0200]: Intel Corporation 82599 Ethernet Controller Virtual Function [8086:10ed] (rev 01)
04:11.1 Ethernet controller [0200]: Intel Corporation 82599 Ethernet Controller Virtual Function [8086:10ed] (rev 01)
04:11.2 Ethernet controller [0200]: Intel Corporation 82599 Ethernet Controller Virtual Function [8086:10ed] (rev 01)
04:11.3 Ethernet controller [0200]: Intel Corporation 82599 Ethernet Controller Virtual Function [8086:10ed] (rev 01)
04:11.4 Ethernet controller [0200]: Intel Corporation 82599 Ethernet Controller Virtual Function [8086:10ed] (rev 01)
04:11.5 Ethernet controller [0200]: Intel Corporation 82599 Ethernet Controller Virtual Function [8086:10ed] (rev 01)

tack@ubuntu:/opt/stack/logs$ neutron port-show 449f818e-b909-48fe-9c91-9216f518f379
+-----------------------+----------------------------------------------------------------------------------------------+
| Field | Value |
+-----------------------+----------------------------------------------------------------------------------------------+
| admin_state_up | True |
| allowed_address_pairs | |
| binding:host_id | ubuntu |
| binding:profile | {"pci_slot": "0000:04:11.4", "physical_network": "physnet1", "pci_vendor_info": "8086:10ed"} |
| binding:vif_details | {"port_filter": false, "vlan": "1412"} |
| binding:vif_type | hostdev_physical |
| binding:vnic_type | direct-physical |
| created_at | 2016-05-17T14:20:57 |
| description | |
| device_id | bb147b1c-7f8f-420c-8d4c-5b61ff1213ec |
| device_owner | compute:nova |
| dns_name | klil |
| extra_dhcp_opts | |
| fixed_ips | {"subnet_id": "51b9f497-59e2-4ad5-aa71-29c46ffb6737", "ip_address": "4.4.4.67"} |
| id | 449f818e-b909-48fe-9c91-9216f518f379 |
| mac_address | fa:16:3e:9d:1e:ed |
| name | |
| network_id | 5018d1a8-1637-4162-beeb-f23bb4fd3aac |
| port_security_enabled | True |
| security_groups | f75bedb9-5d33-478b-9b94-c0d588ef2e9c |
| status | ACTIVE |
| tenant_id | 3e45f4ba4e9b42f992d32f945ef45153 |
| updated_at | 2016-05-17T14:21:17 |
+-----------------------+----------------------------------------------------------------------------------------------+

prabhu murthy (prabhm) wrote :

if a device type is type_PF it should always give PF product id .

product_id=10fb rather than VF 10ed

[PciDevicePool(count=7,numa_node=None,product_id='10ed',tags={dev_type='type-VF',physical_network='physnet2'},vendor_id='8086'), PciDevicePool(count=1,numa_node=None,product_id='10fb',tags={dev_type='type-PF',physical_network='physnet1'},vendor_id='8086')]

prabhu murthy (prabhm) wrote :

if i send product_id as part of whitelist in nova, below is the logs

pci_passthrough_whitelist = {"devname":"em49","physical_network":"physnet1","dev_type": "type-PF","product_id": "10fb"}

Nova compute logs :
Pci_stats

PciDevicePool(count=7,numa_node=None,product_id='10fb',tags={dev_type='type-PF',physical_network='physnet1',product_id='10ed'},vendor_id='8086')]

Matt Riedemann (mriedem) on 2016-05-17
tags: added: nfv pci sriov
Chen Fan (fan-chen) on 2016-06-29
Changed in nova:
assignee: nobody → Chen Fan (fan-chen)
Moshe Levi (moshele) wrote :

The "pci_vendor_info": "8086:10ed" is used only on the neutron side for validation
https://github.com/openstack/neutron/blob/master/neutron/plugins/ml2/drivers/mech_sriov/mech_driver/mech_driver.py#L175-L189
I am planning to deprecate it anyway see https://review.openstack.org/#/c/352812/
but anyway we should fix it.

Changed in nova:
importance: Undecided → Low
Robin Naundorf (senk) on 2016-08-21
Changed in nova:
status: New → In Progress

Change abandoned by Vladik Romanovsky (<email address hidden>) on branch: master
Review: https://review.openstack.org/372728
Reason: Looks like https://review.openstack.org/#/c/363884 resolves this already.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers