net/bnxt: fix return code in MAC address set
authorAjit Khaparde <ajit.khaparde@broadcom.com>
Wed, 7 Feb 2018 01:16:16 +0000 (17:16 -0800)
committerFerruh Yigit <ferruh.yigit@intel.com>
Thu, 8 Feb 2018 17:42:14 +0000 (18:42 +0100)
There is no need to return an error if an existing MAC is added.

Fixes: 778b759ba10e ("net/bnxt: add MAC address")
Cc: stable@dpdk.org
Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
drivers/net/bnxt/bnxt_ethdev.c

index 2268aba..21c46f8 100644 (file)
@@ -727,7 +727,7 @@ static int bnxt_mac_addr_add_op(struct rte_eth_dev *eth_dev,
                if (filter->mac_index == index) {
                        PMD_DRV_LOG(ERR,
                                "MAC addr already existed for pool %d\n", pool);
-                       return -EINVAL;
+                       return 0;
                }
        }
        filter = bnxt_alloc_filter(bp);