summaryrefslogtreecommitdiff
path: root/drivers/scsi/lpfc/lpfc_ct.c
diff options
context:
space:
mode:
authorJames.Smart@Emulex.Com <James.Smart@Emulex.Com>2005-10-28 20:30:02 -0400
committerJames Bottomley <jejb@mulgrave.(none)>2005-10-29 10:31:48 -0500
commit0bd4ca25ad2ace4aa717c83dbd4ed21c53c953cb (patch)
tree10ae769505f9f306ea7a312663011e95019c34ef /drivers/scsi/lpfc/lpfc_ct.c
parent4a0dfcdefb1cc81c0920dc98fbb82bb57326b16d (diff)
[SCSI] lpfc: Fix eh_ return codes for commands
Return FAILED from eh_ routines if command(s) is(are) not completed There were scenarios where we may have returned from the error handlers prior to all affected commands being flushed to the midlayer. Add changes to ensure this doesn't happen. Signed-off-by: James Smart <James.Smart@emulex.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/lpfc/lpfc_ct.c')
-rw-r--r--drivers/scsi/lpfc/lpfc_ct.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/scsi/lpfc/lpfc_ct.c b/drivers/scsi/lpfc/lpfc_ct.c
index 40c34a30a94a..7f427f9c4688 100644
--- a/drivers/scsi/lpfc/lpfc_ct.c
+++ b/drivers/scsi/lpfc/lpfc_ct.c
@@ -224,13 +224,12 @@ lpfc_gen_req(struct lpfc_hba *phba, struct lpfc_dmabuf *bmp,
struct lpfc_sli *psli = &phba->sli;
struct lpfc_sli_ring *pring = &psli->ring[LPFC_ELS_RING];
- struct list_head *lpfc_iocb_list = &phba->lpfc_iocb_list;
IOCB_t *icmd;
- struct lpfc_iocbq *geniocb = NULL;
+ struct lpfc_iocbq *geniocb;
/* Allocate buffer for command iocb */
spin_lock_irq(phba->host->host_lock);
- list_remove_head(lpfc_iocb_list, geniocb, struct lpfc_iocbq, list);
+ geniocb = lpfc_sli_get_iocbq(phba);
spin_unlock_irq(phba->host->host_lock);
if (geniocb == NULL)