]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/commitdiff
iavf: Fix failure to exit out from last all-multicast mode
authorPiotr Marczak <piotr.marczak@intel.com>
Fri, 4 Jun 2021 16:48:56 +0000 (09:48 -0700)
committerKleber Sacilotto de Souza <kleber.souza@canonical.com>
Thu, 13 Jan 2022 17:42:59 +0000 (18:42 +0100)
BugLink: https://bugs.launchpad.net/bugs/1954834
[ Upstream commit 8905072a192fffe9389255489db250c73ecab008 ]

The driver could only quit allmulti when allmulti and promisc modes are
turn on at the same time. If promisc had been off there was no way to turn
off allmulti mode.
The patch corrects this behavior. Switching allmulti does not depends on
promisc state mode anymore

Fixes: f42a5c74da99 ("i40e: Add allmulti support for the VF")
Signed-off-by: Piotr Marczak <piotr.marczak@intel.com>
Tested-by: Tony Brelinski <tony.brelinski@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
drivers/net/ethernet/intel/iavf/iavf_main.c

index c7e365267bc0f162a1943930cf08a04c737a3a63..43afe887cac9e62839775f723226b3dd611830cd 100644 (file)
@@ -1626,8 +1626,7 @@ static int iavf_process_aq_command(struct iavf_adapter *adapter)
                iavf_set_promiscuous(adapter, FLAG_VF_MULTICAST_PROMISC);
                return 0;
        }
-
-       if ((adapter->aq_required & IAVF_FLAG_AQ_RELEASE_PROMISC) &&
+       if ((adapter->aq_required & IAVF_FLAG_AQ_RELEASE_PROMISC) ||
            (adapter->aq_required & IAVF_FLAG_AQ_RELEASE_ALLMULTI)) {
                iavf_set_promiscuous(adapter, 0);
                return 0;