scsi: scsi_debug: Drop scsi_debug_abort() NULL pointer checks
authorJohn Garry <john.g.garry@oracle.com>
Mon, 13 Mar 2023 09:31:06 +0000 (09:31 +0000)
committerMartin K. Petersen <martin.petersen@oracle.com>
Fri, 17 Mar 2023 03:25:36 +0000 (23:25 -0400)
commit06be9fbebb1beb6a885c95fbe3bb2f05f3463a70
tree56f03d4da70228acb61be9c582bbeacadfd120b4
parentd280a4ef229c0def06f6641183fb92100b410c63
scsi: scsi_debug: Drop scsi_debug_abort() NULL pointer checks

The SCSI cmnd pointer arg would never be NULL, so drop the check. In
addition, its SCSI device pointer would never be NULL.

The only caller is scsi_send_eh_cmnd() -> scsi_abort_eh_cmnd() ->
scsi_try_to_abort_cmd() -> scsi_try_to_abort_cmd(), and in the origin of
that chain those pointers cannot be NULL.

Signed-off-by: John Garry <john.g.garry@oracle.com>
Acked-by: Douglas Gilbert <dgilbert@interlog.com>
Link: https://lore.kernel.org/r/20230313093114.1498305-4-john.g.garry@oracle.com
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/scsi_debug.c