aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/scsi/scsi_device.h30
-rw-r--r--include/scsi/scsi_host.h3
2 files changed, 18 insertions, 15 deletions
diff --git a/include/scsi/scsi_device.h b/include/scsi/scsi_device.h
index b401c82036be..ebf31b16dc49 100644
--- a/include/scsi/scsi_device.h
+++ b/include/scsi/scsi_device.h
@@ -223,13 +223,13 @@ extern struct scsi_device *__scsi_iterate_devices(struct Scsi_Host *,
223 struct scsi_device *); 223 struct scsi_device *);
224 224
225/** 225/**
226 * shost_for_each_device - iterate over all devices of a host 226 * shost_for_each_device - iterate over all devices of a host
227 * @sdev: iterator 227 * @sdev: the &struct scsi_device to use as a cursor
228 * @host: host whiches devices we want to iterate over 228 * @shost: the &struct scsi_host to iterate over
229 * 229 *
230 * This traverses over each devices of @shost. The devices have 230 * Iterator that returns each device attached to @shost. This loop
231 * a reference that must be released by scsi_host_put when breaking 231 * takes a reference on each device and releases it at the end. If
232 * out of the loop. 232 * you break out of the loop, you must call scsi_device_put(sdev).
233 */ 233 */
234#define shost_for_each_device(sdev, shost) \ 234#define shost_for_each_device(sdev, shost) \
235 for ((sdev) = __scsi_iterate_devices((shost), NULL); \ 235 for ((sdev) = __scsi_iterate_devices((shost), NULL); \
@@ -237,17 +237,17 @@ extern struct scsi_device *__scsi_iterate_devices(struct Scsi_Host *,
237 (sdev) = __scsi_iterate_devices((shost), (sdev))) 237 (sdev) = __scsi_iterate_devices((shost), (sdev)))
238 238
239/** 239/**
240 * __shost_for_each_device - iterate over all devices of a host (UNLOCKED) 240 * __shost_for_each_device - iterate over all devices of a host (UNLOCKED)
241 * @sdev: iterator 241 * @sdev: the &struct scsi_device to use as a cursor
242 * @host: host whiches devices we want to iterate over 242 * @shost: the &struct scsi_host to iterate over
243 * 243 *
244 * This traverses over each devices of @shost. It does _not_ take a 244 * Iterator that returns each device attached to @shost. It does _not_
245 * reference on the scsi_device, thus it the whole loop must be protected 245 * take a reference on the scsi_device, so the whole loop must be
246 * by shost->host_lock. 246 * protected by shost->host_lock.
247 * 247 *
248 * Note: The only reason why drivers would want to use this is because 248 * Note: The only reason to use this is because you need to access the
249 * they're need to access the device list in irq context. Otherwise you 249 * device list in interrupt context. Otherwise you really want to use
250 * really want to use shost_for_each_device instead. 250 * shost_for_each_device instead.
251 */ 251 */
252#define __shost_for_each_device(sdev, shost) \ 252#define __shost_for_each_device(sdev, shost) \
253 list_for_each_entry((sdev), &((shost)->__devices), siblings) 253 list_for_each_entry((sdev), &((shost)->__devices), siblings)
diff --git a/include/scsi/scsi_host.h b/include/scsi/scsi_host.h
index 39c6f8cc20c3..ba5b3eb6b43f 100644
--- a/include/scsi/scsi_host.h
+++ b/include/scsi/scsi_host.h
@@ -552,6 +552,9 @@ struct Scsi_Host {
552 /* task mgmt function in progress */ 552 /* task mgmt function in progress */
553 unsigned tmf_in_progress:1; 553 unsigned tmf_in_progress:1;
554 554
555 /* Asynchronous scan in progress */
556 unsigned async_scan:1;
557
555 /* 558 /*
556 * Optional work queue to be utilized by the transport 559 * Optional work queue to be utilized by the transport
557 */ 560 */