diff options
author | Jacob Keller <jacob.e.keller@intel.com> | 2017-06-23 04:24:51 -0400 |
---|---|---|
committer | Jeff Kirsher <jeffrey.t.kirsher@intel.com> | 2017-08-25 14:46:45 -0700 |
commit | fcf6cfc8a695bd82d123166aeedab9fa12720b57 (patch) | |
tree | bdd299c1a8e02edd5c9abb3c9cfd31ecdc978c4d /drivers/net/ethernet/intel/i40evf/i40evf_main.c | |
parent | 841c950d67c6facde32a8644ced20c04aebb7dd8 (diff) | |
download | linux-fcf6cfc8a695bd82d123166aeedab9fa12720b57.tar.gz linux-fcf6cfc8a695bd82d123166aeedab9fa12720b57.tar.bz2 linux-fcf6cfc8a695bd82d123166aeedab9fa12720b57.zip |
i40e: move check for avoiding VID=0 filters into i40e_vsi_add_vlan
In i40e_vsi_add_vlan we treat attempting to add VID=0 as an error,
because it does not do what the caller might expect. We already special
case VID=0 in i40e_vlan_rx_add_vid so that we avoid this error when
adding the VLAN.
This special casing is necessary so that we do not add the VLAN=0 filter
since we don't want to stop receiving untagged traffic. Unfortunately,
not all callers of i40e_vsi_add_vlan are aware of this, including when
we add VLANs from a VF device.
Rather than special casing every single caller of i40e_vsi_add_vlan,
lets just move this check internally. This makes the code simpler
because the caller does not need to be aware of how VLAN=0 is special,
and we don't forget to add this check in new places.
This fixes a harmless error message displaying when adding a VLAN from
within a VF. The message was meaningless but there is no reason to
confuse end users and system administrators, and this is now avoided.
Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Diffstat (limited to 'drivers/net/ethernet/intel/i40evf/i40evf_main.c')
0 files changed, 0 insertions, 0 deletions