···400static void scsi_run_queue(struct request_queue *q)401{402 struct scsi_device *sdev = q->queuedata;403+ struct Scsi_Host *shost;404 LIST_HEAD(starved_list);405 unsigned long flags;406407+ /* if the device is dead, sdev will be NULL, so no queue to run */408+ if (!sdev)409+ return;410+411+ shost = sdev->host;412 if (scsi_target(sdev)->single_lun)413 scsi_single_lun_run(sdev);414