[SCSI] lpfc 8.3.42: Fix random errors using first burst
Signed-off-by: James Smart <james.smart@emulex.com> Signed-off-by: James Bottomley <JBottomley@Parallels.com>
This commit is contained in:
parent
716d3bc503
commit
98bbf5f77f
1 changed files with 7 additions and 2 deletions
|
@ -4342,6 +4342,7 @@ lpfc_scsi_prep_cmnd(struct lpfc_vport *vport, struct lpfc_scsi_buf *lpfc_cmd,
|
||||||
char tag[2];
|
char tag[2];
|
||||||
uint8_t *ptr;
|
uint8_t *ptr;
|
||||||
bool sli4;
|
bool sli4;
|
||||||
|
uint32_t fcpdl;
|
||||||
|
|
||||||
if (!pnode || !NLP_CHK_NODE_ACT(pnode))
|
if (!pnode || !NLP_CHK_NODE_ACT(pnode))
|
||||||
return;
|
return;
|
||||||
|
@ -4389,8 +4390,12 @@ lpfc_scsi_prep_cmnd(struct lpfc_vport *vport, struct lpfc_scsi_buf *lpfc_cmd,
|
||||||
iocb_cmd->ulpPU = PARM_READ_CHECK;
|
iocb_cmd->ulpPU = PARM_READ_CHECK;
|
||||||
if (vport->cfg_first_burst_size &&
|
if (vport->cfg_first_burst_size &&
|
||||||
(pnode->nlp_flag & NLP_FIRSTBURST)) {
|
(pnode->nlp_flag & NLP_FIRSTBURST)) {
|
||||||
piocbq->iocb.un.fcpi.fcpi_XRdy =
|
fcpdl = scsi_bufflen(scsi_cmnd);
|
||||||
vport->cfg_first_burst_size;
|
if (fcpdl < vport->cfg_first_burst_size)
|
||||||
|
piocbq->iocb.un.fcpi.fcpi_XRdy = fcpdl;
|
||||||
|
else
|
||||||
|
piocbq->iocb.un.fcpi.fcpi_XRdy =
|
||||||
|
vport->cfg_first_burst_size;
|
||||||
}
|
}
|
||||||
fcp_cmnd->fcpCntl3 = WRITE_DATA;
|
fcp_cmnd->fcpCntl3 = WRITE_DATA;
|
||||||
phba->fc4OutputRequests++;
|
phba->fc4OutputRequests++;
|
||||||
|
|
Loading…
Add table
Reference in a new issue