From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 59FDDA00C5; Tue, 4 Jan 2022 09:19:26 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 135114114E; Tue, 4 Jan 2022 09:19:15 +0100 (CET) Received: from relay.smtp-ext.broadcom.com (relay.smtp-ext.broadcom.com [192.19.166.231]) by mails.dpdk.org (Postfix) with ESMTP id 9072E41145 for ; Tue, 4 Jan 2022 09:19:13 +0100 (CET) Received: from dhcp-10-123-153-22.dhcp.broadcom.net (bgccx-dev-host-lnx2.bec.broadcom.net [10.123.153.22]) by relay.smtp-ext.broadcom.com (Postfix) with ESMTP id DB75DC0000F1; Tue, 4 Jan 2022 00:19:11 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.11.0 relay.smtp-ext.broadcom.com DB75DC0000F1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=broadcom.com; s=dkimrelay; t=1641284353; bh=4OuIMgrcEfQbdCTB3PWaubxJAXQyEoxLr/g3gBev5cM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=km8EWUsFs/ucCawLOkQj4VgWjVUtZFQvlZ1Wk1++2Hb6OwwC+qYFVOQaan2w7LHBA 11nO6qv+mHFUaZmHuMhIaL1zikkdFirmY+t4hPObNoQ6kgbiB6WWNKuP59qX2yGdbJ QqrembHcDRz7tayg8r68M98n/lk2ZGZzhW3ZR51Q= From: Kalesh A P To: dev@dpdk.org Cc: ferruh.yigit@intel.com, ajit.khaparde@broadcom.com Subject: [dpdk-dev] [PATCH 02/18] net/bnxt: fix to restore mcast macs during reset recovery Date: Tue, 4 Jan 2022 14:08:08 +0530 Message-Id: <20220104083824.23001-3-kalesh-anakkur.purayil@broadcom.com> X-Mailer: git-send-email 2.10.1 In-Reply-To: <20220104083824.23001-1-kalesh-anakkur.purayil@broadcom.com> References: <20220104083824.23001-1-kalesh-anakkur.purayil@broadcom.com> X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org From: Kalesh AP During reset recovery, driver is not restoring the multicast mac addresses. Added code to restore them during reset recovery. Fixes: b02f1573cd07 ("net/bnxt: restore MAC filters during reset recovery") Cc: stable@dpdk.org Signed-off-by: Kalesh AP Reviewed-by: Ajit Khaparde Reviewed-by: Somnath Kotur --- drivers/net/bnxt/bnxt_ethdev.c | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/drivers/net/bnxt/bnxt_ethdev.c b/drivers/net/bnxt/bnxt_ethdev.c index 50ffa30..bac9600 100644 --- a/drivers/net/bnxt/bnxt_ethdev.c +++ b/drivers/net/bnxt/bnxt_ethdev.c @@ -4261,6 +4261,18 @@ static int bnxt_restore_mac_filters(struct bnxt *bp) return 0; } +static int bnxt_restore_mcast_mac_filters(struct bnxt *bp) +{ + int ret = 0; + + ret = bnxt_dev_set_mc_addr_list_op(bp->eth_dev, bp->mcast_addr_list, + bp->nb_mc_addr); + if (ret) + PMD_DRV_LOG(ERR, "Failed to restore multicast MAC addreeses\n"); + + return ret; +} + static int bnxt_restore_filters(struct bnxt *bp) { struct rte_eth_dev *dev = bp->eth_dev; @@ -4282,7 +4294,13 @@ static int bnxt_restore_filters(struct bnxt *bp) return ret; ret = bnxt_restore_vlan_filters(bp); - /* TODO restore other filters as well */ + if (ret) + return ret; + + ret = bnxt_restore_mcast_mac_filters(bp); + if (ret) + return ret; + return ret; } -- 2.10.1