summaryrefslogtreecommitdiffstats
path: root/drivers/net/cnic.c
diff options
context:
space:
mode:
authorMichael Chan2011-07-20 16:55:22 +0200
committerDavid S. Miller2011-07-21 21:38:32 +0200
commitb37a41e390310429d4171b0f7b6c6eab04512dc0 (patch)
tree9ed5dcbfb441a022580eb2838078a74dca4bee6a /drivers/net/cnic.c
parenttg3: Fix NVRAM selftest failures for 5720 devs (diff)
downloadkernel-qcow2-linux-b37a41e390310429d4171b0f7b6c6eab04512dc0.tar.gz
kernel-qcow2-linux-b37a41e390310429d4171b0f7b6c6eab04512dc0.tar.xz
kernel-qcow2-linux-b37a41e390310429d4171b0f7b6c6eab04512dc0.zip
cnic: Fix Context ID space calculation
Include FCoE CID space only for E2_PLUS devices. Remove old CID offset adjustments that are no longer needed. Signed-off-by: Michael Chan <mchan@broadcom.com> Reviewed-by: Bhanu Prakash Gollapudi <bprakash@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/cnic.c')
-rw-r--r--drivers/net/cnic.c10
1 files changed, 1 insertions, 9 deletions
diff --git a/drivers/net/cnic.c b/drivers/net/cnic.c
index ea75f65a179c..455fd0dacb38 100644
--- a/drivers/net/cnic.c
+++ b/drivers/net/cnic.c
@@ -1172,7 +1172,7 @@ static int cnic_alloc_bnx2x_resc(struct cnic_dev *dev)
cp->iro_arr = ethdev->iro_arr;
- cp->max_cid_space = MAX_ISCSI_TBL_SZ + BNX2X_FCOE_NUM_CONNECTIONS;
+ cp->max_cid_space = MAX_ISCSI_TBL_SZ;
cp->iscsi_start_cid = start_cid;
cp->fcoe_start_cid = start_cid + MAX_ISCSI_TBL_SZ;
@@ -1183,14 +1183,6 @@ static int cnic_alloc_bnx2x_resc(struct cnic_dev *dev)
cp->fcoe_init_cid = 0x10;
}
- if (start_cid < BNX2X_ISCSI_START_CID) {
- u32 delta = BNX2X_ISCSI_START_CID - start_cid;
-
- cp->iscsi_start_cid = BNX2X_ISCSI_START_CID;
- cp->fcoe_start_cid += delta;
- cp->max_cid_space += delta;
- }
-
cp->iscsi_tbl = kzalloc(sizeof(struct cnic_iscsi) * MAX_ISCSI_TBL_SZ,
GFP_KERNEL);
if (!cp->iscsi_tbl)