Skip to content

Commit 9b872fa

Browse files
committed
scsi: qedf: Use scsi_cmd_to_rq() instead of scsi_cmnd.request
JIRA: https://issues.redhat.com/browse/RHEL-72637 Prepare for removal of the request pointer by using scsi_cmd_to_rq() instead. This patch does not change any functionality. Link: https://lore.kernel.org/r/20210809230355.8186-36-bvanassche@acm.org Signed-off-by: Bart Van Assche <bvanassche@acm.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> (cherry picked from commit d995da6) Signed-off-by: John Meneghini <jmeneghi@redhat.com>
1 parent bad5fea commit 9b872fa

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

drivers/scsi/qedf/qedf_io.c

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1164,13 +1164,7 @@ void qedf_scsi_completion(struct qedf_ctx *qedf, struct fcoe_cqe *cqe,
11641164
return;
11651165
}
11661166

1167-
if (!sc_cmd->request) {
1168-
QEDF_WARN(&(qedf->dbg_ctx), "sc_cmd->request is NULL, "
1169-
"sc_cmd=%p.\n", sc_cmd);
1170-
return;
1171-
}
1172-
1173-
if (!sc_cmd->request->q) {
1167+
if (!scsi_cmd_to_rq(sc_cmd)->q) {
11741168
QEDF_WARN(&(qedf->dbg_ctx), "request->q is NULL so request "
11751169
"is not valid, sc_cmd=%p.\n", sc_cmd);
11761170
return;

0 commit comments

Comments
 (0)