aboutsummaryrefslogtreecommitdiffstats
path: root/include/scsi
diff options
context:
space:
mode:
authorJames Smart <James.Smart@Emulex.Com>2006-03-13 08:28:57 -0500
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>2006-03-13 09:58:58 -0500
commitc829c394165f981d49f05a9be228404d7a9398d4 (patch)
tree649ca326052a4a35d31f150f274347ca9d38c678 /include/scsi
parentce313db240862d809c736c5b1dfc759817fc7ca9 (diff)
[SCSI] FC transport : Avoid device offline cases by stalling aborts until device unblocked
This moves the eh_timed_out functionality from the scsi_host_template to the transport_template. Given that this is now a transport function, the EH_RESET_TIMER case no longer caps the timer reschedulings. The transport guarantees that this is not an infinite condition. Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'include/scsi')
-rw-r--r--include/scsi/scsi_host.h14
-rw-r--r--include/scsi/scsi_transport.h11
2 files changed, 11 insertions, 14 deletions
diff --git a/include/scsi/scsi_host.h b/include/scsi/scsi_host.h
index 827992949c4b..a6cf3e535c0b 100644
--- a/include/scsi/scsi_host.h
+++ b/include/scsi/scsi_host.h
@@ -147,20 +147,6 @@ struct scsi_host_template {
147 int (* eh_host_reset_handler)(struct scsi_cmnd *); 147 int (* eh_host_reset_handler)(struct scsi_cmnd *);
148 148
149 /* 149 /*
150 * This is an optional routine to notify the host that the scsi
151 * timer just fired. The returns tell the timer routine what to
152 * do about this:
153 *
154 * EH_HANDLED: I fixed the error, please complete the command
155 * EH_RESET_TIMER: I need more time, reset the timer and
156 * begin counting again
157 * EH_NOT_HANDLED Begin normal error recovery
158 *
159 * Status: OPTIONAL
160 */
161 enum scsi_eh_timer_return (* eh_timed_out)(struct scsi_cmnd *);
162
163 /*
164 * Before the mid layer attempts to scan for a new device where none 150 * Before the mid layer attempts to scan for a new device where none
165 * currently exists, it will call this entry in your driver. Should 151 * currently exists, it will call this entry in your driver. Should
166 * your driver need to allocate any structs or perform any other init 152 * your driver need to allocate any structs or perform any other init
diff --git a/include/scsi/scsi_transport.h b/include/scsi/scsi_transport.h
index e7b1054adf86..b3657f111937 100644
--- a/include/scsi/scsi_transport.h
+++ b/include/scsi/scsi_transport.h
@@ -48,6 +48,17 @@ struct scsi_transport_template {
48 * True if the transport wants to use a host-based work-queue 48 * True if the transport wants to use a host-based work-queue
49 */ 49 */
50 unsigned int create_work_queue : 1; 50 unsigned int create_work_queue : 1;
51
52 /*
53 * This is an optional routine that allows the transport to become
54 * involved when a scsi io timer fires. The return value tells the
55 * timer routine how to finish the io timeout handling:
56 * EH_HANDLED: I fixed the error, please complete the command
57 * EH_RESET_TIMER: I need more time, reset the timer and
58 * begin counting again
59 * EH_NOT_HANDLED Begin normal error recovery
60 */
61 enum scsi_eh_timer_return (* eh_timed_out)(struct scsi_cmnd *);
51}; 62};
52 63
53#define transport_class_to_shost(tc) \ 64#define transport_class_to_shost(tc) \