igb: Fix removal of unicast MAC filters of VFs
authorKaren Sornek <karen.sornek@intel.com>
Tue, 31 Aug 2021 11:16:35 +0000 (13:16 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 22 Dec 2021 08:30:55 +0000 (09:30 +0100)
commitddac50d04f348d880386d6f6f7639da6935ab907
tree50a55433c81534a86b94cbcc37e2bec0b7b314b9
parent12c1938870dcc0fc7906492b8f44d9bc54fda0b5
igb: Fix removal of unicast MAC filters of VFs

[ Upstream commit 584af82154f56e6b2740160fcc84a2966d969e15 ]

Move checking condition of VF MAC filter before clearing
or adding MAC filter to VF to prevent potential blackout caused
by removal of necessary and working VF's MAC filter.

Fixes: 1b8b062a99dc ("igb: add VF trust infrastructure")
Signed-off-by: Karen Sornek <karen.sornek@intel.com>
Tested-by: Konrad Jankowski <konrad0.jankowski@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/intel/igb/igb_main.c