diff options
Diffstat (limited to 'drivers/scsi')
-rw-r--r-- | drivers/scsi/bnx2i/bnx2i_hwi.c | 1 | ||||
-rw-r--r-- | drivers/scsi/bnx2i/bnx2i_iscsi.c | 3 |
2 files changed, 4 insertions, 0 deletions
diff --git a/drivers/scsi/bnx2i/bnx2i_hwi.c b/drivers/scsi/bnx2i/bnx2i_hwi.c index f0b89513faed..a8a2b6b65a3c 100644 --- a/drivers/scsi/bnx2i/bnx2i_hwi.c +++ b/drivers/scsi/bnx2i/bnx2i_hwi.c | |||
@@ -1274,6 +1274,7 @@ int bnx2i_send_fw_iscsi_init_msg(struct bnx2i_hba *hba) | |||
1274 | iscsi_init.dummy_buffer_addr_hi = | 1274 | iscsi_init.dummy_buffer_addr_hi = |
1275 | (u32) ((u64) hba->dummy_buf_dma >> 32); | 1275 | (u32) ((u64) hba->dummy_buf_dma >> 32); |
1276 | 1276 | ||
1277 | hba->num_ccell = hba->max_sqes >> 1; | ||
1277 | hba->ctx_ccell_tasks = | 1278 | hba->ctx_ccell_tasks = |
1278 | ((hba->num_ccell & 0xFFFF) | (hba->max_sqes << 16)); | 1279 | ((hba->num_ccell & 0xFFFF) | (hba->max_sqes << 16)); |
1279 | iscsi_init.num_ccells_per_conn = hba->num_ccell; | 1280 | iscsi_init.num_ccells_per_conn = hba->num_ccell; |
diff --git a/drivers/scsi/bnx2i/bnx2i_iscsi.c b/drivers/scsi/bnx2i/bnx2i_iscsi.c index 1809f9ccc4ce..7b4d1d041e2e 100644 --- a/drivers/scsi/bnx2i/bnx2i_iscsi.c +++ b/drivers/scsi/bnx2i/bnx2i_iscsi.c | |||
@@ -1208,6 +1208,9 @@ static int bnx2i_task_xmit(struct iscsi_task *task) | |||
1208 | struct bnx2i_cmd *cmd = task->dd_data; | 1208 | struct bnx2i_cmd *cmd = task->dd_data; |
1209 | struct iscsi_cmd *hdr = (struct iscsi_cmd *) task->hdr; | 1209 | struct iscsi_cmd *hdr = (struct iscsi_cmd *) task->hdr; |
1210 | 1210 | ||
1211 | if (bnx2i_conn->ep->num_active_cmds + 1 > hba->max_sqes) | ||
1212 | return -ENOMEM; | ||
1213 | |||
1211 | /* | 1214 | /* |
1212 | * If there is no scsi_cmnd this must be a mgmt task | 1215 | * If there is no scsi_cmnd this must be a mgmt task |
1213 | */ | 1216 | */ |