提交 dd2e4dbc 编写于 作者: M Michael Chan 提交者: David S. Miller

cnic: Fix bogus iSCSI MAC address

Fix code to read the proper iSCSI MAC address for bnx2x devices.
Signed-off-by: NMichael Chan <mchan@broadcom.com>
Signed-off-by: NBenjamin Li <benli@broadcom.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 8b065b67
......@@ -3997,15 +3997,19 @@ static void cnic_get_bnx2x_iscsi_info(struct cnic_dev *dev)
if (base < 0xa0000 || base >= 0xc0000)
return;
val = BNX2X_SHMEM_ADDR(base,
addr = BNX2X_SHMEM_ADDR(base,
dev_info.port_hw_config[port].iscsi_mac_upper);
val = CNIC_RD(dev, addr);
dev->mac_addr[0] = (u8) (val >> 8);
dev->mac_addr[1] = (u8) val;
val = BNX2X_SHMEM_ADDR(base,
addr = BNX2X_SHMEM_ADDR(base,
dev_info.port_hw_config[port].iscsi_mac_lower);
val = CNIC_RD(dev, addr);
dev->mac_addr[2] = (u8) (val >> 24);
dev->mac_addr[3] = (u8) (val >> 16);
dev->mac_addr[4] = (u8) (val >> 8);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册