Lines Matching refs:scmd
15 [1-2] How do scmd's get completed?
16 [1-2-1] Completing a scmd w/ scsi_done
17 [1-2-2] Completing a scmd w/ timeout
36 Each SCSI command is represented with struct scsi_cmnd (== scmd). A
37 scmd has two list_head's to link itself into lists. The two are
38 scmd->list and scmd->eh_entry. The former is used for free list or
39 per-device allocated scmd list and not of much interest to this EH
41 otherwise stated scmds are always linked using scmd->eh_entry in this
45 1.2 How do scmd's get completed?
48 Once LLDD gets hold of a scmd, either the LLDD will complete the
53 1.2.1 Completing a scmd w/ scsi_done
62 scsi_decide_disposition() looks at the scmd->result value and sense
79 scmd is requeued to blk queue.
83 scsi_eh_scmd_add(scmd) is invoked for the command. See
87 1.2.2 Completing a scmd w/ timeout
107 issue a retry scmd->allowed + 1 times. Asynchronous aborts are not invoked
113 3. scsi_eh_scmd_add(scmd) is invoked for the
132 1. Links scmd->eh_entry to shost->eh_cmd_q
140 As can be seen above, once any scmd is added to shost->eh_cmd_q,
142 scmd to be issued from blk queue to the host; eventually, all scmds on
153 completed a scmd with error status, the LLDD and lower layers are
154 assumed to forget about the scmd at that point. However, if a scmd
156 about the scmd, which currently no LLDD does, the command is still
205 commands. A scmd is said to be recovered if the scmd is forgotten by
206 lower layers and lower layers are ready to process or fail the scmd
230 eh_work_q. If a recovery action succeeds for a scmd, recovered
233 Note that single recovery action on a scmd can recover multiple
241 timed-out scmds, SCSI EH ensures that LLDD forgets about a scmd
244 When a scmd is recovered, the scmd is moved from eh_work_q to EH
251 EH), REQ_FAILFAST is not set and ++scmd->retries is less than
252 scmd->allowed.
260 :ACTION: scsi_eh_scmd_add() is invoked for scmd
262 - add scmd to shost->eh_cmd_q
276 3. scmd recovered
278 :ACTION: scsi_eh_finish_cmd() is invoked to EH-finish scmd
294 - scmd is removed from eh_done_q and scmd->eh_entry is cleared
295 - if retry is necessary, scmd is requeued using
297 - otherwise, scsi_finish_command() is invoked for scmd
325 Note that if autosense is not supported, scmd->sense_buffer
326 contains invalid sense data when error-completing the scmd
328 FAILED in such cases thus invoking SCSI EH. When the scmd
334 causes higher-severity recovery to be taken for the scmd.
336 2. Invoke scsi_decide_disposition() on the scmd
339 scmd->retries is set to scmd->allowed preventing
340 scsi_eh_flush_done_q() from retrying the scmd and
364 that lower layers have forgotten about the scmd and we can
377 a sdev has no timed out scmd.
440 - Each failed scmd's eh_flags field is set appropriately.
442 - Each failed scmd is linked on scmd->eh_cmd_q by scmd->eh_entry.
458 - Each scmd->eh_entry is cleared.
461 each scmd. Note that the handler is free to use scmd->retries and