1*60202365SMauro Carvalho Chehab===================== 2*60202365SMauro Carvalho ChehabSCSI Interfaces Guide 3*60202365SMauro Carvalho Chehab===================== 4*60202365SMauro Carvalho Chehab 5*60202365SMauro Carvalho Chehab:Author: James Bottomley 6*60202365SMauro Carvalho Chehab:Author: Rob Landley 7*60202365SMauro Carvalho Chehab 8*60202365SMauro Carvalho ChehabIntroduction 9*60202365SMauro Carvalho Chehab============ 10*60202365SMauro Carvalho Chehab 11*60202365SMauro Carvalho ChehabProtocol vs bus 12*60202365SMauro Carvalho Chehab--------------- 13*60202365SMauro Carvalho Chehab 14*60202365SMauro Carvalho ChehabOnce upon a time, the Small Computer Systems Interface defined both a 15*60202365SMauro Carvalho Chehabparallel I/O bus and a data protocol to connect a wide variety of 16*60202365SMauro Carvalho Chehabperipherals (disk drives, tape drives, modems, printers, scanners, 17*60202365SMauro Carvalho Chehaboptical drives, test equipment, and medical devices) to a host computer. 18*60202365SMauro Carvalho Chehab 19*60202365SMauro Carvalho ChehabAlthough the old parallel (fast/wide/ultra) SCSI bus has largely fallen 20*60202365SMauro Carvalho Chehabout of use, the SCSI command set is more widely used than ever to 21*60202365SMauro Carvalho Chehabcommunicate with devices over a number of different busses. 22*60202365SMauro Carvalho Chehab 23*60202365SMauro Carvalho ChehabThe `SCSI protocol <http://www.t10.org/scsi-3.htm>`__ is a big-endian 24*60202365SMauro Carvalho Chehabpeer-to-peer packet based protocol. SCSI commands are 6, 10, 12, or 16 25*60202365SMauro Carvalho Chehabbytes long, often followed by an associated data payload. 26*60202365SMauro Carvalho Chehab 27*60202365SMauro Carvalho ChehabSCSI commands can be transported over just about any kind of bus, and 28*60202365SMauro Carvalho Chehabare the default protocol for storage devices attached to USB, SATA, SAS, 29*60202365SMauro Carvalho ChehabFibre Channel, FireWire, and ATAPI devices. SCSI packets are also 30*60202365SMauro Carvalho Chehabcommonly exchanged over Infiniband, 31*60202365SMauro Carvalho Chehab`I20 <http://i2o.shadowconnect.com/faq.php>`__, TCP/IP 32*60202365SMauro Carvalho Chehab(`iSCSI <https://en.wikipedia.org/wiki/ISCSI>`__), even `Parallel 33*60202365SMauro Carvalho Chehabports <http://cyberelk.net/tim/parport/parscsi.html>`__. 34*60202365SMauro Carvalho Chehab 35*60202365SMauro Carvalho ChehabDesign of the Linux SCSI subsystem 36*60202365SMauro Carvalho Chehab---------------------------------- 37*60202365SMauro Carvalho Chehab 38*60202365SMauro Carvalho ChehabThe SCSI subsystem uses a three layer design, with upper, mid, and low 39*60202365SMauro Carvalho Chehablayers. Every operation involving the SCSI subsystem (such as reading a 40*60202365SMauro Carvalho Chehabsector from a disk) uses one driver at each of the 3 levels: one upper 41*60202365SMauro Carvalho Chehablayer driver, one lower layer driver, and the SCSI midlayer. 42*60202365SMauro Carvalho Chehab 43*60202365SMauro Carvalho ChehabThe SCSI upper layer provides the interface between userspace and the 44*60202365SMauro Carvalho Chehabkernel, in the form of block and char device nodes for I/O and ioctl(). 45*60202365SMauro Carvalho ChehabThe SCSI lower layer contains drivers for specific hardware devices. 46*60202365SMauro Carvalho Chehab 47*60202365SMauro Carvalho ChehabIn between is the SCSI mid-layer, analogous to a network routing layer 48*60202365SMauro Carvalho Chehabsuch as the IPv4 stack. The SCSI mid-layer routes a packet based data 49*60202365SMauro Carvalho Chehabprotocol between the upper layer's /dev nodes and the corresponding 50*60202365SMauro Carvalho Chehabdevices in the lower layer. It manages command queues, provides error 51*60202365SMauro Carvalho Chehabhandling and power management functions, and responds to ioctl() 52*60202365SMauro Carvalho Chehabrequests. 53*60202365SMauro Carvalho Chehab 54*60202365SMauro Carvalho ChehabSCSI upper layer 55*60202365SMauro Carvalho Chehab================ 56*60202365SMauro Carvalho Chehab 57*60202365SMauro Carvalho ChehabThe upper layer supports the user-kernel interface by providing device 58*60202365SMauro Carvalho Chehabnodes. 59*60202365SMauro Carvalho Chehab 60*60202365SMauro Carvalho Chehabsd (SCSI Disk) 61*60202365SMauro Carvalho Chehab-------------- 62*60202365SMauro Carvalho Chehab 63*60202365SMauro Carvalho Chehabsd (sd_mod.o) 64*60202365SMauro Carvalho Chehab 65*60202365SMauro Carvalho Chehabsr (SCSI CD-ROM) 66*60202365SMauro Carvalho Chehab---------------- 67*60202365SMauro Carvalho Chehab 68*60202365SMauro Carvalho Chehabsr (sr_mod.o) 69*60202365SMauro Carvalho Chehab 70*60202365SMauro Carvalho Chehabst (SCSI Tape) 71*60202365SMauro Carvalho Chehab-------------- 72*60202365SMauro Carvalho Chehab 73*60202365SMauro Carvalho Chehabst (st.o) 74*60202365SMauro Carvalho Chehab 75*60202365SMauro Carvalho Chehabsg (SCSI Generic) 76*60202365SMauro Carvalho Chehab----------------- 77*60202365SMauro Carvalho Chehab 78*60202365SMauro Carvalho Chehabsg (sg.o) 79*60202365SMauro Carvalho Chehab 80*60202365SMauro Carvalho Chehabch (SCSI Media Changer) 81*60202365SMauro Carvalho Chehab----------------------- 82*60202365SMauro Carvalho Chehab 83*60202365SMauro Carvalho Chehabch (ch.c) 84*60202365SMauro Carvalho Chehab 85*60202365SMauro Carvalho ChehabSCSI mid layer 86*60202365SMauro Carvalho Chehab============== 87*60202365SMauro Carvalho Chehab 88*60202365SMauro Carvalho ChehabSCSI midlayer implementation 89*60202365SMauro Carvalho Chehab---------------------------- 90*60202365SMauro Carvalho Chehab 91*60202365SMauro Carvalho Chehabinclude/scsi/scsi_device.h 92*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~~~~ 93*60202365SMauro Carvalho Chehab 94*60202365SMauro Carvalho Chehab.. kernel-doc:: include/scsi/scsi_device.h 95*60202365SMauro Carvalho Chehab :internal: 96*60202365SMauro Carvalho Chehab 97*60202365SMauro Carvalho Chehabdrivers/scsi/scsi.c 98*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~ 99*60202365SMauro Carvalho Chehab 100*60202365SMauro Carvalho ChehabMain file for the SCSI midlayer. 101*60202365SMauro Carvalho Chehab 102*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsi.c 103*60202365SMauro Carvalho Chehab :export: 104*60202365SMauro Carvalho Chehab 105*60202365SMauro Carvalho Chehabdrivers/scsi/scsicam.c 106*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~ 107*60202365SMauro Carvalho Chehab 108*60202365SMauro Carvalho Chehab`SCSI Common Access 109*60202365SMauro Carvalho ChehabMethod <http://www.t10.org/ftp/t10/drafts/cam/cam-r12b.pdf>`__ support 110*60202365SMauro Carvalho Chehabfunctions, for use with HDIO_GETGEO, etc. 111*60202365SMauro Carvalho Chehab 112*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsicam.c 113*60202365SMauro Carvalho Chehab :export: 114*60202365SMauro Carvalho Chehab 115*60202365SMauro Carvalho Chehabdrivers/scsi/scsi_error.c 116*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~~~ 117*60202365SMauro Carvalho Chehab 118*60202365SMauro Carvalho ChehabCommon SCSI error/timeout handling routines. 119*60202365SMauro Carvalho Chehab 120*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsi_error.c 121*60202365SMauro Carvalho Chehab :export: 122*60202365SMauro Carvalho Chehab 123*60202365SMauro Carvalho Chehabdrivers/scsi/scsi_devinfo.c 124*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 125*60202365SMauro Carvalho Chehab 126*60202365SMauro Carvalho ChehabManage scsi_dev_info_list, which tracks blacklisted and whitelisted 127*60202365SMauro Carvalho Chehabdevices. 128*60202365SMauro Carvalho Chehab 129*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsi_devinfo.c 130*60202365SMauro Carvalho Chehab :internal: 131*60202365SMauro Carvalho Chehab 132*60202365SMauro Carvalho Chehabdrivers/scsi/scsi_ioctl.c 133*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~~~ 134*60202365SMauro Carvalho Chehab 135*60202365SMauro Carvalho ChehabHandle ioctl() calls for SCSI devices. 136*60202365SMauro Carvalho Chehab 137*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsi_ioctl.c 138*60202365SMauro Carvalho Chehab :export: 139*60202365SMauro Carvalho Chehab 140*60202365SMauro Carvalho Chehabdrivers/scsi/scsi_lib.c 141*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~ 142*60202365SMauro Carvalho Chehab 143*60202365SMauro Carvalho ChehabSCSI queuing library. 144*60202365SMauro Carvalho Chehab 145*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsi_lib.c 146*60202365SMauro Carvalho Chehab :export: 147*60202365SMauro Carvalho Chehab 148*60202365SMauro Carvalho Chehabdrivers/scsi/scsi_lib_dma.c 149*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 150*60202365SMauro Carvalho Chehab 151*60202365SMauro Carvalho ChehabSCSI library functions depending on DMA (map and unmap scatter-gather 152*60202365SMauro Carvalho Chehablists). 153*60202365SMauro Carvalho Chehab 154*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsi_lib_dma.c 155*60202365SMauro Carvalho Chehab :export: 156*60202365SMauro Carvalho Chehab 157*60202365SMauro Carvalho Chehabdrivers/scsi/scsi_module.c 158*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~~~~ 159*60202365SMauro Carvalho Chehab 160*60202365SMauro Carvalho ChehabThe file drivers/scsi/scsi_module.c contains legacy support for 161*60202365SMauro Carvalho Chehabold-style host templates. It should never be used by any new driver. 162*60202365SMauro Carvalho Chehab 163*60202365SMauro Carvalho Chehabdrivers/scsi/scsi_proc.c 164*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~~ 165*60202365SMauro Carvalho Chehab 166*60202365SMauro Carvalho ChehabThe functions in this file provide an interface between the PROC file 167*60202365SMauro Carvalho Chehabsystem and the SCSI device drivers It is mainly used for debugging, 168*60202365SMauro Carvalho Chehabstatistics and to pass information directly to the lowlevel driver. I.E. 169*60202365SMauro Carvalho Chehabplumbing to manage /proc/scsi/\* 170*60202365SMauro Carvalho Chehab 171*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsi_proc.c 172*60202365SMauro Carvalho Chehab :internal: 173*60202365SMauro Carvalho Chehab 174*60202365SMauro Carvalho Chehabdrivers/scsi/scsi_netlink.c 175*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 176*60202365SMauro Carvalho Chehab 177*60202365SMauro Carvalho ChehabInfrastructure to provide async events from transports to userspace via 178*60202365SMauro Carvalho Chehabnetlink, using a single NETLINK_SCSITRANSPORT protocol for all 179*60202365SMauro Carvalho Chehabtransports. See `the original patch 180*60202365SMauro Carvalho Chehabsubmission <http://marc.info/?l=linux-scsi&m=115507374832500&w=2>`__ for 181*60202365SMauro Carvalho Chehabmore details. 182*60202365SMauro Carvalho Chehab 183*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsi_netlink.c 184*60202365SMauro Carvalho Chehab :internal: 185*60202365SMauro Carvalho Chehab 186*60202365SMauro Carvalho Chehabdrivers/scsi/scsi_scan.c 187*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~~ 188*60202365SMauro Carvalho Chehab 189*60202365SMauro Carvalho ChehabScan a host to determine which (if any) devices are attached. The 190*60202365SMauro Carvalho Chehabgeneral scanning/probing algorithm is as follows, exceptions are made to 191*60202365SMauro Carvalho Chehabit depending on device specific flags, compilation options, and global 192*60202365SMauro Carvalho Chehabvariable (boot or module load time) settings. A specific LUN is scanned 193*60202365SMauro Carvalho Chehabvia an INQUIRY command; if the LUN has a device attached, a scsi_device 194*60202365SMauro Carvalho Chehabis allocated and setup for it. For every id of every channel on the 195*60202365SMauro Carvalho Chehabgiven host, start by scanning LUN 0. Skip hosts that don't respond at 196*60202365SMauro Carvalho Chehaball to a scan of LUN 0. Otherwise, if LUN 0 has a device attached, 197*60202365SMauro Carvalho Chehaballocate and setup a scsi_device for it. If target is SCSI-3 or up, 198*60202365SMauro Carvalho Chehabissue a REPORT LUN, and scan all of the LUNs returned by the REPORT LUN; 199*60202365SMauro Carvalho Chehabelse, sequentially scan LUNs up until some maximum is reached, or a LUN 200*60202365SMauro Carvalho Chehabis seen that cannot have a device attached to it. 201*60202365SMauro Carvalho Chehab 202*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsi_scan.c 203*60202365SMauro Carvalho Chehab :internal: 204*60202365SMauro Carvalho Chehab 205*60202365SMauro Carvalho Chehabdrivers/scsi/scsi_sysctl.c 206*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~~~~ 207*60202365SMauro Carvalho Chehab 208*60202365SMauro Carvalho ChehabSet up the sysctl entry: "/dev/scsi/logging_level" 209*60202365SMauro Carvalho Chehab(DEV_SCSI_LOGGING_LEVEL) which sets/returns scsi_logging_level. 210*60202365SMauro Carvalho Chehab 211*60202365SMauro Carvalho Chehabdrivers/scsi/scsi_sysfs.c 212*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~~~ 213*60202365SMauro Carvalho Chehab 214*60202365SMauro Carvalho ChehabSCSI sysfs interface routines. 215*60202365SMauro Carvalho Chehab 216*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsi_sysfs.c 217*60202365SMauro Carvalho Chehab :export: 218*60202365SMauro Carvalho Chehab 219*60202365SMauro Carvalho Chehabdrivers/scsi/hosts.c 220*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~ 221*60202365SMauro Carvalho Chehab 222*60202365SMauro Carvalho Chehabmid to lowlevel SCSI driver interface 223*60202365SMauro Carvalho Chehab 224*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/hosts.c 225*60202365SMauro Carvalho Chehab :export: 226*60202365SMauro Carvalho Chehab 227*60202365SMauro Carvalho Chehabdrivers/scsi/constants.c 228*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~ 229*60202365SMauro Carvalho Chehab 230*60202365SMauro Carvalho Chehabmid to lowlevel SCSI driver interface 231*60202365SMauro Carvalho Chehab 232*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/constants.c 233*60202365SMauro Carvalho Chehab :export: 234*60202365SMauro Carvalho Chehab 235*60202365SMauro Carvalho ChehabTransport classes 236*60202365SMauro Carvalho Chehab----------------- 237*60202365SMauro Carvalho Chehab 238*60202365SMauro Carvalho ChehabTransport classes are service libraries for drivers in the SCSI lower 239*60202365SMauro Carvalho Chehablayer, which expose transport attributes in sysfs. 240*60202365SMauro Carvalho Chehab 241*60202365SMauro Carvalho ChehabFibre Channel transport 242*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~ 243*60202365SMauro Carvalho Chehab 244*60202365SMauro Carvalho ChehabThe file drivers/scsi/scsi_transport_fc.c defines transport attributes 245*60202365SMauro Carvalho Chehabfor Fibre Channel. 246*60202365SMauro Carvalho Chehab 247*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsi_transport_fc.c 248*60202365SMauro Carvalho Chehab :export: 249*60202365SMauro Carvalho Chehab 250*60202365SMauro Carvalho ChehabiSCSI transport class 251*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~ 252*60202365SMauro Carvalho Chehab 253*60202365SMauro Carvalho ChehabThe file drivers/scsi/scsi_transport_iscsi.c defines transport 254*60202365SMauro Carvalho Chehabattributes for the iSCSI class, which sends SCSI packets over TCP/IP 255*60202365SMauro Carvalho Chehabconnections. 256*60202365SMauro Carvalho Chehab 257*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsi_transport_iscsi.c 258*60202365SMauro Carvalho Chehab :export: 259*60202365SMauro Carvalho Chehab 260*60202365SMauro Carvalho ChehabSerial Attached SCSI (SAS) transport class 261*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 262*60202365SMauro Carvalho Chehab 263*60202365SMauro Carvalho ChehabThe file drivers/scsi/scsi_transport_sas.c defines transport 264*60202365SMauro Carvalho Chehabattributes for Serial Attached SCSI, a variant of SATA aimed at large 265*60202365SMauro Carvalho Chehabhigh-end systems. 266*60202365SMauro Carvalho Chehab 267*60202365SMauro Carvalho ChehabThe SAS transport class contains common code to deal with SAS HBAs, an 268*60202365SMauro Carvalho Chehabaproximated representation of SAS topologies in the driver model, and 269*60202365SMauro Carvalho Chehabvarious sysfs attributes to expose these topologies and management 270*60202365SMauro Carvalho Chehabinterfaces to userspace. 271*60202365SMauro Carvalho Chehab 272*60202365SMauro Carvalho ChehabIn addition to the basic SCSI core objects this transport class 273*60202365SMauro Carvalho Chehabintroduces two additional intermediate objects: The SAS PHY as 274*60202365SMauro Carvalho Chehabrepresented by struct sas_phy defines an "outgoing" PHY on a SAS HBA or 275*60202365SMauro Carvalho ChehabExpander, and the SAS remote PHY represented by struct sas_rphy defines 276*60202365SMauro Carvalho Chehaban "incoming" PHY on a SAS Expander or end device. Note that this is 277*60202365SMauro Carvalho Chehabpurely a software concept, the underlying hardware for a PHY and a 278*60202365SMauro Carvalho Chehabremote PHY is the exactly the same. 279*60202365SMauro Carvalho Chehab 280*60202365SMauro Carvalho ChehabThere is no concept of a SAS port in this code, users can see what PHYs 281*60202365SMauro Carvalho Chehabform a wide port based on the port_identifier attribute, which is the 282*60202365SMauro Carvalho Chehabsame for all PHYs in a port. 283*60202365SMauro Carvalho Chehab 284*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsi_transport_sas.c 285*60202365SMauro Carvalho Chehab :export: 286*60202365SMauro Carvalho Chehab 287*60202365SMauro Carvalho ChehabSATA transport class 288*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~ 289*60202365SMauro Carvalho Chehab 290*60202365SMauro Carvalho ChehabThe SATA transport is handled by libata, which has its own book of 291*60202365SMauro Carvalho Chehabdocumentation in this directory. 292*60202365SMauro Carvalho Chehab 293*60202365SMauro Carvalho ChehabParallel SCSI (SPI) transport class 294*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 295*60202365SMauro Carvalho Chehab 296*60202365SMauro Carvalho ChehabThe file drivers/scsi/scsi_transport_spi.c defines transport 297*60202365SMauro Carvalho Chehabattributes for traditional (fast/wide/ultra) SCSI busses. 298*60202365SMauro Carvalho Chehab 299*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsi_transport_spi.c 300*60202365SMauro Carvalho Chehab :export: 301*60202365SMauro Carvalho Chehab 302*60202365SMauro Carvalho ChehabSCSI RDMA (SRP) transport class 303*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 304*60202365SMauro Carvalho Chehab 305*60202365SMauro Carvalho ChehabThe file drivers/scsi/scsi_transport_srp.c defines transport 306*60202365SMauro Carvalho Chehabattributes for SCSI over Remote Direct Memory Access. 307*60202365SMauro Carvalho Chehab 308*60202365SMauro Carvalho Chehab.. kernel-doc:: drivers/scsi/scsi_transport_srp.c 309*60202365SMauro Carvalho Chehab :export: 310*60202365SMauro Carvalho Chehab 311*60202365SMauro Carvalho ChehabSCSI lower layer 312*60202365SMauro Carvalho Chehab================ 313*60202365SMauro Carvalho Chehab 314*60202365SMauro Carvalho ChehabHost Bus Adapter transport types 315*60202365SMauro Carvalho Chehab-------------------------------- 316*60202365SMauro Carvalho Chehab 317*60202365SMauro Carvalho ChehabMany modern device controllers use the SCSI command set as a protocol to 318*60202365SMauro Carvalho Chehabcommunicate with their devices through many different types of physical 319*60202365SMauro Carvalho Chehabconnections. 320*60202365SMauro Carvalho Chehab 321*60202365SMauro Carvalho ChehabIn SCSI language a bus capable of carrying SCSI commands is called a 322*60202365SMauro Carvalho Chehab"transport", and a controller connecting to such a bus is called a "host 323*60202365SMauro Carvalho Chehabbus adapter" (HBA). 324*60202365SMauro Carvalho Chehab 325*60202365SMauro Carvalho ChehabDebug transport 326*60202365SMauro Carvalho Chehab~~~~~~~~~~~~~~~ 327*60202365SMauro Carvalho Chehab 328*60202365SMauro Carvalho ChehabThe file drivers/scsi/scsi_debug.c simulates a host adapter with a 329*60202365SMauro Carvalho Chehabvariable number of disks (or disk like devices) attached, sharing a 330*60202365SMauro Carvalho Chehabcommon amount of RAM. Does a lot of checking to make sure that we are 331*60202365SMauro Carvalho Chehabnot getting blocks mixed up, and panics the kernel if anything out of 332*60202365SMauro Carvalho Chehabthe ordinary is seen. 333*60202365SMauro Carvalho Chehab 334*60202365SMauro Carvalho ChehabTo be more realistic, the simulated devices have the transport 335*60202365SMauro Carvalho Chehabattributes of SAS disks. 336*60202365SMauro Carvalho Chehab 337*60202365SMauro Carvalho ChehabFor documentation see http://sg.danny.cz/sg/sdebug26.html 338*60202365SMauro Carvalho Chehab 339*60202365SMauro Carvalho Chehabtodo 340*60202365SMauro Carvalho Chehab~~~~ 341*60202365SMauro Carvalho Chehab 342*60202365SMauro Carvalho ChehabParallel (fast/wide/ultra) SCSI, USB, SATA, SAS, Fibre Channel, 343*60202365SMauro Carvalho ChehabFireWire, ATAPI devices, Infiniband, I20, iSCSI, Parallel ports, 344*60202365SMauro Carvalho Chehabnetlink... 345