Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

scsi: scsi_debug: Drop NULL scsi_cmnd check in sdebug_q_cmd_complete()

The scp pointer cannot be NULL, as it is evaluated from container_of()
and pointer offsets (so remove the check in sdebug_q_cmd_complete()).

Signed-off-by: John Garry <john.g.garry@oracle.com>
Link: https://patch.msgid.link/20251113133645.2898748-4-john.g.garry@oracle.com
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>

authored by

John Garry and committed by
Martin K. Petersen
a8cf5c1b 559ae7a2

-5
-5
drivers/scsi/scsi_debug.c
··· 6396 6396 atomic_inc(&sdebug_miss_cpus); 6397 6397 } 6398 6398 6399 - if (!scp) { 6400 - pr_err("scmd=NULL\n"); 6401 - return; 6402 - } 6403 - 6404 6399 spin_lock_irqsave(&sdsc->lock, flags); 6405 6400 aborted = sd_dp->aborted; 6406 6401 if (unlikely(aborted))