Lines Matching refs:SCSI
2 SCSI mid_level - lower_level driver interface
7 This document outlines the interface between the Linux SCSI mid level and
8 SCSI lower level drivers. Lower level drivers (LLDs) are variously called
11 single SCSI initiator port on a SCSI transport. An "initiator" port
12 (SCSI terminology, see SAM-3 at http://www.t10.org) sends SCSI commands
13 to "target" SCSI ports (e.g. disks). There can be many LLDs in a running
15 SCSI HBAs. Some HBAs contain multiple hosts.
17 In some cases the SCSI transport is an external bus that already has
19 SCSI subsystem LLD is a software bridge to the other driver subsystem.
24 For example, the aic7xxx LLD controls Adaptec SCSI parallel interface
32 a SCSI host and a PCI device is common but not required (e.g. with
35 The SCSI mid level isolates an LLD from other layers such as the SCSI
42 There is a SCSI documentation directory within the kernel source tree,
47 Many LLDs are documented there (e.g. aic7xxx.txt). The SCSI mid-level is
49 describing the SCSI subsystem in the lk 2.4 series. Two upper level
50 drivers have documents in that directory: st.txt (SCSI tape driver) and
60 Traditionally an LLD for the SCSI subsystem has been at least two files in
81 preferred as it can handle both traditional SCSI equipment that is
82 permanently connected as well as modern "SCSI" devices (e.g. USB or
86 An LLD interfaces to the SCSI subsystem several ways:
124 In this model an LLD controls when SCSI hosts are introduced and removed
125 from the SCSI subsystem. Hosts can be introduced as early as driver
130 with the SCSI mid level.
136 registered with sysfs at this point. The SCSI mid level first becomes
144 HBA PROBE: assume 2 SCSI devices found in scan
173 HBA REMOVE: assume 2 SCSI devices attached
188 Hot unplugging an HBA that controls a disk which is processing SCSI
194 The hotplug concept may be extended to SCSI devices. Currently, when an
195 HBA is added, the scsi_scan_host() function causes a scan for SCSI devices
196 attached to the HBA's SCSI transport. On newer SCSI transports the HBA
197 may become aware of a new SCSI device _after_ the scan has completed.
198 An LLD can use this sequence to make the mid level aware of a SCSI device:
200 SCSI DEVICE hotplug
209 In a similar fashion, an LLD may become aware that a SCSI device has been
211 existing SCSI transports (e.g. SPI) may not become aware that a SCSI
212 device has been removed until a subsequent SCSI command fails which will
214 detects the removal of a SCSI device can instigate its removal from
217 SCSI DEVICE hot unplug
251 detected (so detect() returns 2) and the SCSI bus scan on each host
252 finds 1 SCSI device (and a second device does not respond).
308 across the various SCSI layers which use them. Previously such instances
324 across the various SCSI layers which use them. Previously such instances
342 struct tags. Both can be still found in the SCSI subsystem, but
361 These functions are supplied by the SCSI mid level for use by LLDs.
364 arrange for the SCSI mid level to be loaded and initialized before any LLD
371 scsi_change_queue_depth - change the queue depth on a SCSI device
379 scsi_remove_device - detach and remove a SCSI device
380 scsi_remove_host - detach and remove all SCSI devices owned by host
382 scsi_scan_host - scan SCSI bus
439 * scsi_change_queue_depth - allow LLD to change queue depth on a SCSI device
440 * @sdev: pointer to SCSI device to change queue depth on
449 * Notes: Can be invoked any time on a SCSI device controlled by this
502 * Notes: When this call returns to the LLD, the SCSI bus scan on
580 * Notes: When this call returns to the LLD, the SCSI bus scan on
592 * scsi_remove_device - detach and remove a SCSI device
611 * scsi_remove_host - detach and remove all SCSI devices owned by host
648 * scsi_scan_host - scan SCSI bus
664 * @sdev: pointer to SCSI device instance
665 * @depth: Current number of outstanding SCSI commands on this device,
744 eh_bus_reset_handler - issue SCSI bus reset
745 eh_device_reset_handler - issue SCSI device reset
798 * Notes: First function called from the SCSI mid level on this
857 * eh_bus_reset_handler - issue SCSI bus reset
858 * @scp: SCSI bus that contains this device should be reset
875 * eh_device_reset_handler - issue SCSI device reset
876 * @scp: identifies SCSI device to be reset
894 * @scp: SCSI host that contains this device should be reset
960 * Notes: The SCSI subsystem uses a "trickle down" ioctl model.
963 * the 'cmd' then it is passed to the SCSI mid level. If the SCSI
1061 * response to a SCSI INQUIRY) the scp->scsi_done callback may be
1063 * callback is not invoked within a certain period the SCSI mid
1185 SCSI commands into an LLD.
1209 in a single SCSI command. The default value of 0 leads
1221 use_clustering - 1=>SCSI commands in mid level's queue can be merged,
1222 0=>disallow SCSI command merging
1247 Generally, there is one instance of this structure for each SCSI logical unit
1254 Instances of this structure convey SCSI commands to the LLD and responses
1255 back to the mid level. The SCSI mid level will ensure that no more SCSI
1258 be at least one instance of struct scsi_cmnd available for each SCSI device.
1260 cmnd - array containing SCSI command
1261 cmnd_len - length (in bytes) of SCSI command
1274 SCSI command is completed (successfully or otherwise).
1281 data (if any) has been transferred to or from the SCSI
1283 can be viewed as 4 related bytes. The SCSI status value is
1288 should be written when the SCSI status (LSB of 'result')
1292 contains a valid SCSI sense buffer; otherwise the mid
1293 level will issue a REQUEST_SENSE SCSI command to
1305 interesting case is data transfers from a SCSI target
1314 It is recommended that a LLD set 'resid' on data transfers from a SCSI
1344 with the completion of a SCSI command" when a status of CHECK CONDITION
1347 a) instructing the SCSI protocol (e.g. SCSI Parallel Interface (SPI))
1368 one per SCSI host.
1374 In the 2.4 series the SCSI subsystem configuration descriptions were
1377 the SCSI subsystem now has its own (much smaller) drivers/scsi/Kconfig