Skip to content

Commit

Permalink
Set vlan filter only when vrouter physical interface is a VF.
Browse files Browse the repository at this point in the history
Change-Id: Iad9a60ba9fa737167a650cd80997ff149cc8c9cf
Closes-bug: 1573255
  • Loading branch information
srajag committed May 19, 2016
1 parent fbf7525 commit a03c7c5
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion dpdk/vr_dpdk_interface.c
Expand Up @@ -174,7 +174,11 @@ dpdk_set_hw_vlan_filter_strip(uint32_t port_id, struct vr_interface *vif)
&ethdev->ethdev_port_id:ethdev->ethdev_slaves;

do {
if (vr_dpdk.vlan_tag != VLAN_ID_INVALID) {
/*
* TODO: vf_lcore_id check for SR-IOV VF should be a per-interface
* check to handle the case where a bond has a VF and a PF in it.
*/
if ((vr_dpdk.vlan_tag != VLAN_ID_INVALID) && vr_dpdk.vf_lcore_id) {
ret = rte_eth_dev_set_vlan_offload(*port_id_ptr, ETH_VLAN_FILTER_OFFLOAD);
if (ret) {
RTE_LOG(INFO, VROUTER, "Error %d enabling vlan offload on port %d\n",
Expand Down

0 comments on commit a03c7c5

Please sign in to comment.