bnx2x: Do storage mac address validation for SF mode.
Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com> Signed-off-by: Eilon Greenstein <eilong@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
committed by
David S. Miller
parent
f9a3ebbe65
commit
426b924150
@@ -8560,15 +8560,6 @@ static void __devinit bnx2x_get_mac_hwinfo(struct bnx2x *bp)
|
|||||||
BNX2X_DEV_INFO("Read iSCSI MAC: "
|
BNX2X_DEV_INFO("Read iSCSI MAC: "
|
||||||
"0x%x:0x%04x\n", val2, val);
|
"0x%x:0x%04x\n", val2, val);
|
||||||
bnx2x_set_mac_buf(iscsi_mac, val, val2);
|
bnx2x_set_mac_buf(iscsi_mac, val, val2);
|
||||||
|
|
||||||
/* Disable iSCSI OOO if MAC configuration is
|
|
||||||
* invalid.
|
|
||||||
*/
|
|
||||||
if (!is_valid_ether_addr(iscsi_mac)) {
|
|
||||||
bp->flags |= NO_ISCSI_OOO_FLAG |
|
|
||||||
NO_ISCSI_FLAG;
|
|
||||||
memset(iscsi_mac, 0, ETH_ALEN);
|
|
||||||
}
|
|
||||||
} else
|
} else
|
||||||
bp->flags |= NO_ISCSI_OOO_FLAG | NO_ISCSI_FLAG;
|
bp->flags |= NO_ISCSI_OOO_FLAG | NO_ISCSI_FLAG;
|
||||||
|
|
||||||
@@ -8581,13 +8572,6 @@ static void __devinit bnx2x_get_mac_hwinfo(struct bnx2x *bp)
|
|||||||
"0x%x:0x%04x\n", val2, val);
|
"0x%x:0x%04x\n", val2, val);
|
||||||
bnx2x_set_mac_buf(fip_mac, val, val2);
|
bnx2x_set_mac_buf(fip_mac, val, val2);
|
||||||
|
|
||||||
/* Disable FCoE if MAC configuration is
|
|
||||||
* invalid.
|
|
||||||
*/
|
|
||||||
if (!is_valid_ether_addr(fip_mac)) {
|
|
||||||
bp->flags |= NO_FCOE_FLAG;
|
|
||||||
memset(bp->fip_mac, 0, ETH_ALEN);
|
|
||||||
}
|
|
||||||
} else
|
} else
|
||||||
bp->flags |= NO_FCOE_FLAG;
|
bp->flags |= NO_FCOE_FLAG;
|
||||||
}
|
}
|
||||||
@@ -8618,6 +8602,22 @@ static void __devinit bnx2x_get_mac_hwinfo(struct bnx2x *bp)
|
|||||||
else if (!IS_MF(bp))
|
else if (!IS_MF(bp))
|
||||||
memcpy(fip_mac, iscsi_mac, ETH_ALEN);
|
memcpy(fip_mac, iscsi_mac, ETH_ALEN);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Disable iSCSI if MAC configuration is
|
||||||
|
* invalid.
|
||||||
|
*/
|
||||||
|
if (!is_valid_ether_addr(iscsi_mac)) {
|
||||||
|
bp->flags |= NO_ISCSI_FLAG;
|
||||||
|
memset(iscsi_mac, 0, ETH_ALEN);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Disable FCoE if MAC configuration is
|
||||||
|
* invalid.
|
||||||
|
*/
|
||||||
|
if (!is_valid_ether_addr(fip_mac)) {
|
||||||
|
bp->flags |= NO_FCOE_FLAG;
|
||||||
|
memset(bp->fip_mac, 0, ETH_ALEN);
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user