diff options
author | Michael Chan <mchan@broadcom.com> | 2010-12-23 02:43:01 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-12-23 14:44:31 -0500 |
commit | 4aacb7afb6afd78efe26427e74fa56a5fc72fad3 (patch) | |
tree | d7c73eb50096f589921696699950e7e9e7176ac8 /drivers/net/cnic.h | |
parent | 5159fdc1e6cb4000f482faebeeba0be91611276d (diff) |
cnic: Support NIC Partition mode
Add a common function cnic_read_bnx2x_iscsi_mac() to read the iSCSI
MAC address at any specified shared memory location. In NIC Partition
mode, we need to get the MAC address from the MF_CFG area of shared
memory.
Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/cnic.h')
-rw-r--r-- | drivers/net/cnic.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/cnic.h b/drivers/net/cnic.h index 8e947b7e0700..fb3b7531ea25 100644 --- a/drivers/net/cnic.h +++ b/drivers/net/cnic.h | |||
@@ -422,6 +422,9 @@ struct bnx2x_bd_chain_next { | |||
422 | (CNIC_RD(dev, BNX2X_SHMEM2_ADDR(base, size)) > \ | 422 | (CNIC_RD(dev, BNX2X_SHMEM2_ADDR(base, size)) > \ |
423 | offsetof(struct shmem2_region, field))) | 423 | offsetof(struct shmem2_region, field))) |
424 | 424 | ||
425 | #define BNX2X_MF_CFG_ADDR(base, field) \ | ||
426 | ((base) + offsetof(struct mf_cfg, field)) | ||
427 | |||
425 | #define CNIC_PORT(cp) ((cp)->pfid & 1) | 428 | #define CNIC_PORT(cp) ((cp)->pfid & 1) |
426 | #define CNIC_FUNC(cp) ((cp)->func) | 429 | #define CNIC_FUNC(cp) ((cp)->func) |
427 | #define CNIC_PATH(cp) (!BNX2X_CHIP_IS_E2(cp->chip_id) ? 0 :\ | 430 | #define CNIC_PATH(cp) (!BNX2X_CHIP_IS_E2(cp->chip_id) ? 0 :\ |