Commit 6f15d0c0 authored by Chad Dupuis's avatar Chad Dupuis Committed by Martin K. Petersen

scsi: qedf: Add missing return in qedf_scsi_done()

On completions where we do not have a bad scsi_cmnd pointer we should
return before the the label lest we do a double kref_put.
Signed-off-by: default avatarChad Dupuis <cdupuis@marvell.com>
Signed-off-by: default avatarSaurav Kashyap <skashyap@marvell.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent a66c6cd2
...@@ -1392,6 +1392,7 @@ void qedf_scsi_done(struct qedf_ctx *qedf, struct qedf_ioreq *io_req, ...@@ -1392,6 +1392,7 @@ void qedf_scsi_done(struct qedf_ctx *qedf, struct qedf_ioreq *io_req,
sc_cmd->SCp.ptr = NULL; sc_cmd->SCp.ptr = NULL;
sc_cmd->scsi_done(sc_cmd); sc_cmd->scsi_done(sc_cmd);
kref_put(&io_req->refcount, qedf_release_cmd); kref_put(&io_req->refcount, qedf_release_cmd);
return;
bad_scsi_ptr: bad_scsi_ptr:
/* /*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment