aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c')
-rw-r--r--drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c32
1 files changed, 22 insertions, 10 deletions
diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c
index 21054987257a..0875ecfe3372 100644
--- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c
+++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c
@@ -7561,8 +7561,14 @@ int bnx2x_set_mac_one(struct bnx2x *bp, u8 *mac,
7561 } 7561 }
7562 7562
7563 rc = bnx2x_config_vlan_mac(bp, &ramrod_param); 7563 rc = bnx2x_config_vlan_mac(bp, &ramrod_param);
7564 if (rc < 0) 7564
7565 if (rc == -EEXIST) {
7566 DP(BNX2X_MSG_SP, "Failed to schedule ADD operations: %d\n", rc);
7567 /* do not treat adding same MAC as error */
7568 rc = 0;
7569 } else if (rc < 0)
7565 BNX2X_ERR("%s MAC failed\n", (set ? "Set" : "Del")); 7570 BNX2X_ERR("%s MAC failed\n", (set ? "Set" : "Del"));
7571
7566 return rc; 7572 return rc;
7567} 7573}
7568 7574
@@ -9825,12 +9831,13 @@ static void __devinit bnx2x_get_igu_cam_info(struct bnx2x *bp)
9825 } 9831 }
9826 9832
9827#ifdef CONFIG_PCI_MSI 9833#ifdef CONFIG_PCI_MSI
9828 /* 9834 /* Due to new PF resource allocation by MFW T7.4 and above, it's
9829 * It's expected that number of CAM entries for this functions is equal 9835 * optional that number of CAM entries will not be equal to the value
9830 * to the number evaluated based on the MSI-X table size. We want a 9836 * advertised in PCI.
9831 * harsh warning if these values are different! 9837 * Driver should use the minimal value of both as the actual status
9838 * block count
9832 */ 9839 */
9833 WARN_ON(bp->igu_sb_cnt != igu_sb_cnt); 9840 bp->igu_sb_cnt = min_t(int, bp->igu_sb_cnt, igu_sb_cnt);
9834#endif 9841#endif
9835 9842
9836 if (igu_sb_cnt == 0) 9843 if (igu_sb_cnt == 0)
@@ -10294,13 +10301,11 @@ static void __devinit bnx2x_get_fcoe_info(struct bnx2x *bp)
10294 dev_info.port_hw_config[port]. 10301 dev_info.port_hw_config[port].
10295 fcoe_wwn_node_name_lower); 10302 fcoe_wwn_node_name_lower);
10296 } else if (!IS_MF_SD(bp)) { 10303 } else if (!IS_MF_SD(bp)) {
10297 u32 cfg = MF_CFG_RD(bp, func_ext_config[func].func_cfg);
10298
10299 /* 10304 /*
10300 * Read the WWN info only if the FCoE feature is enabled for 10305 * Read the WWN info only if the FCoE feature is enabled for
10301 * this function. 10306 * this function.
10302 */ 10307 */
10303 if (cfg & MACP_FUNC_CFG_FLAGS_FCOE_OFFLOAD) 10308 if (BNX2X_MF_EXT_PROTOCOL_FCOE(bp) && !CHIP_IS_E1x(bp))
10304 bnx2x_get_ext_wwn_info(bp, func); 10309 bnx2x_get_ext_wwn_info(bp, func);
10305 10310
10306 } else if (IS_MF_FCOE_SD(bp)) 10311 } else if (IS_MF_FCOE_SD(bp))
@@ -11073,7 +11078,14 @@ static int bnx2x_set_uc_list(struct bnx2x *bp)
11073 netdev_for_each_uc_addr(ha, dev) { 11078 netdev_for_each_uc_addr(ha, dev) {
11074 rc = bnx2x_set_mac_one(bp, bnx2x_uc_addr(ha), mac_obj, true, 11079 rc = bnx2x_set_mac_one(bp, bnx2x_uc_addr(ha), mac_obj, true,
11075 BNX2X_UC_LIST_MAC, &ramrod_flags); 11080 BNX2X_UC_LIST_MAC, &ramrod_flags);
11076 if (rc < 0) { 11081 if (rc == -EEXIST) {
11082 DP(BNX2X_MSG_SP,
11083 "Failed to schedule ADD operations: %d\n", rc);
11084 /* do not treat adding same MAC as error */
11085 rc = 0;
11086
11087 } else if (rc < 0) {
11088
11077 BNX2X_ERR("Failed to schedule ADD operations: %d\n", 11089 BNX2X_ERR("Failed to schedule ADD operations: %d\n",
11078 rc); 11090 rc);
11079 return rc; 11091 return rc;