ice: Fix promiscuous mode not turning off
authorMichal Wilczynski <michal.wilczynski@intel.com>
Mon, 4 Jul 2022 13:12:27 +0000 (15:12 +0200)
committerTony Nguyen <anthony.l.nguyen@intel.com>
Thu, 28 Jul 2022 18:44:40 +0000 (11:44 -0700)
commita419526de6079e4b8a001bcbb8ac7370ba581963
tree3c464d6a8314e356f7d6eb07c7ac0d600e94c2bb
parentd7393425e7c8819ac4a6dbc03f061954665f62ee
ice: Fix promiscuous mode not turning off

When trust is turned off for the VF, the expectation is that promiscuous
and allmulticast filters are removed. Currently default VSI filter is not
getting cleared in this flow.

Example:

ip link set enp236s0f0 vf 0 trust on
ip link set enp236s0f0v0 promisc on
ip link set enp236s0f0 vf 0 trust off
/* promiscuous mode is still enabled on VF0 */

Remove switch filters for both cases.
This commit fixes above behavior by removing default VSI filters and
allmulticast filters when vf-true-promisc-support is OFF.

Signed-off-by: Michal Wilczynski <michal.wilczynski@intel.com>
Tested-by: Marek Szlosek <marek.szlosek@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
drivers/net/ethernet/intel/ice/ice_vf_lib.c
drivers/net/ethernet/intel/ice/ice_vf_lib.h
drivers/net/ethernet/intel/ice/ice_virtchnl.c