diff options
| author | James Smart <jsmart2021@gmail.com> | 2019-05-06 20:26:49 -0400 |
|---|---|---|
| committer | Martin K. Petersen <martin.petersen@oracle.com> | 2019-05-13 20:32:50 -0400 |
| commit | c8cb261a072c88ca1aff0e804a30db4c7606521b (patch) | |
| tree | 879826d51503f1baac4820d09bea6e062cd5279b | |
| parent | 79080d349f7f58a2e86c56043a3d04184d5f294a (diff) | |
scsi: lpfc: add check for loss of ndlp when sending RRQ
There was a missing qualification of a valid ndlp structure when calling to
send an RRQ for an abort. Add the check.
Signed-off-by: Dick Kennedy <dick.kennedy@broadcom.com>
Signed-off-by: James Smart <jsmart2021@gmail.com>
Tested-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
| -rw-r--r-- | drivers/scsi/lpfc/lpfc_els.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/scsi/lpfc/lpfc_els.c b/drivers/scsi/lpfc/lpfc_els.c index c8fb0b455f2a..5ac4f8d76b91 100644 --- a/drivers/scsi/lpfc/lpfc_els.c +++ b/drivers/scsi/lpfc/lpfc_els.c | |||
| @@ -7334,7 +7334,10 @@ int | |||
| 7334 | lpfc_send_rrq(struct lpfc_hba *phba, struct lpfc_node_rrq *rrq) | 7334 | lpfc_send_rrq(struct lpfc_hba *phba, struct lpfc_node_rrq *rrq) |
| 7335 | { | 7335 | { |
| 7336 | struct lpfc_nodelist *ndlp = lpfc_findnode_did(rrq->vport, | 7336 | struct lpfc_nodelist *ndlp = lpfc_findnode_did(rrq->vport, |
| 7337 | rrq->nlp_DID); | 7337 | rrq->nlp_DID); |
| 7338 | if (!ndlp) | ||
| 7339 | return 1; | ||
| 7340 | |||
| 7338 | if (lpfc_test_rrq_active(phba, ndlp, rrq->xritag)) | 7341 | if (lpfc_test_rrq_active(phba, ndlp, rrq->xritag)) |
| 7339 | return lpfc_issue_els_rrq(rrq->vport, ndlp, | 7342 | return lpfc_issue_els_rrq(rrq->vport, ndlp, |
| 7340 | rrq->nlp_DID, rrq); | 7343 | rrq->nlp_DID, rrq); |
