diff options
Diffstat (limited to 'drivers/scsi/scsi.c')
-rw-r--r-- | drivers/scsi/scsi.c | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/drivers/scsi/scsi.c b/drivers/scsi/scsi.c index 3e90ba797df2..2ab7df0dcfe8 100644 --- a/drivers/scsi/scsi.c +++ b/drivers/scsi/scsi.c | |||
@@ -579,6 +579,24 @@ int scsi_dispatch_cmd(struct scsi_cmnd *cmd) | |||
579 | static DEFINE_PER_CPU(struct list_head, scsi_done_q); | 579 | static DEFINE_PER_CPU(struct list_head, scsi_done_q); |
580 | 580 | ||
581 | /** | 581 | /** |
582 | * scsi_req_abort_cmd -- Request command recovery for the specified command | ||
583 | * cmd: pointer to the SCSI command of interest | ||
584 | * | ||
585 | * This function requests that SCSI Core start recovery for the | ||
586 | * command by deleting the timer and adding the command to the eh | ||
587 | * queue. It can be called by either LLDDs or SCSI Core. LLDDs who | ||
588 | * implement their own error recovery MAY ignore the timeout event if | ||
589 | * they generated scsi_req_abort_cmd. | ||
590 | */ | ||
591 | void scsi_req_abort_cmd(struct scsi_cmnd *cmd) | ||
592 | { | ||
593 | if (!scsi_delete_timer(cmd)) | ||
594 | return; | ||
595 | scsi_times_out(cmd); | ||
596 | } | ||
597 | EXPORT_SYMBOL(scsi_req_abort_cmd); | ||
598 | |||
599 | /** | ||
582 | * scsi_done - Enqueue the finished SCSI command into the done queue. | 600 | * scsi_done - Enqueue the finished SCSI command into the done queue. |
583 | * @cmd: The SCSI Command for which a low-level device driver (LLDD) gives | 601 | * @cmd: The SCSI Command for which a low-level device driver (LLDD) gives |
584 | * ownership back to SCSI Core -- i.e. the LLDD has finished with it. | 602 | * ownership back to SCSI Core -- i.e. the LLDD has finished with it. |