Linux Scsi Documentation
Total Page:16
File Type:pdf, Size:1020Kb
Linux Scsi Documentation The kernel development community Jul 14, 2020 CONTENTS i ii CHAPTER ONE THE 53C700 DRIVER NOTES 1.1 General Description This driver supports the 53c700 and 53c700-66 chips. It also supports the 53c710 but only in 53c700 emulation mode. It is full featured and does sync (-66 and 710 only), disconnects and tag command queueing. Since the 53c700 must be interfaced to a bus, you need to wrapper the card de- tector around this driver. For an example, see the NCR_D700.[ch] or lasi700.[ch] files. The comments in the 53c700.[ch] files tell you which parts you need to fillinto get the driver working. 1.2 Compile Time Flags A compile time flag is: CONFIG_53C700_LE_ON_BE define if the chipset must be supported in little endian mode on a bigendianar- chitecture (used for the 700 on parisc). 1.3 Using the Chip Core Driver In order to plumb the 53c700 chip core driver into a working SCSI driver, you need to know three things about the way the chip is wired into your system (or expansion card). 1. The clock speed of the SCSI core 2. The interrupt line used 3. The memory (or io space) location of the 53c700 registers. Optionally, you may also need to know other things, like how to read the SCSI Id from the card bios or whether the chip is wired for differential operation. Usually you can find items 2. and 3. from general spec. documents or evenby examining the configuration of a working driver under another operating system. 1 Linux Scsi Documentation The clock speed is usually buried deep in the technical literature. It is required because it is used to set up both the synchronous and asynchronous dividers for the chip. As a general rule of thumb, manufacturers set the clock speed at the lowest possible setting consistent with the best operation of the chip (although some choose to drive it off the CPU or bus clock rather than going to the expense of an extra clock chip). The best operation clock speeds are: 53c700 25MHz 53c700-66 50MHz 53c710 40Mhz 1.4 Writing Your Glue Driver This will be a standard SCSI driver (I don’t know of a good document describing this, just copy from some other driver) with at least a detect and release entry. In the detect routine, you need to allocate a struct NCR_700_Host_Parameters sized memory area and clear it (so that the default values for everything are 0). Then you must fill in the parameters that matter to you (see below), plumb the NCR_700_intr routine into the interrupt line and call NCR_700_detect with the host template and the new parameters as arguments. You should also call the relevant request_*_region function and place the register base address into the ‘base’pointer of the host parameters. In the release routine, you must free the NCR_700_Host_Parameters that you al- located, call the corresponding release_*_region and free the interrupt. 1.4.1 Handling Interrupts In general, you should just plumb the card’s interrupt line in with request_irq(irq, NCR_700_intr, <irq flags>, <driver name>, host); where host is the return from the relevant NCR_700_detect() routine. You may also write your own interrupt handling routine which calls NCR_700_intr() directly. However, you should only really do this if you have a card with more than one chip on it and you can read a register to tell which set of chips wants the interrupt. 1.4.2 Settable NCR_700_Host_Parameters The following are a list of the user settable parameters: clock: (MANDATORY) Set to the clock speed of the chip in MHz. base: (MANDATORY) Set to the base of the io or mem region for the register set. On 64 bit architectures this is only 32 bits wide, so the registers must be mapped into the low 32 bits of memory. pci_dev: (OPTIONAL) Set to the PCI board device. Leave NULL for a non-pci board. This is used for the pci_alloc_consistent() and pci_map_*() functions. 2 Chapter 1. The 53c700 Driver Notes Linux Scsi Documentation dmode_extra: (OPTIONAL, 53c710 only) Extra flags for the DMODE register. These are used to control bus output pins on the 710. The settings should be a combination of DMODE_FC1 and DMODE_FC2. What these pins actually do is entirely up to the board designer. Usually it is safe to ignore this setting. differential: (OPTIONAL) Set to 1 if the chip drives a differential bus. force_le_on_be: (OPTIONAL, only if CONFIG_53C700_LE_ON_BE is set) Set to 1 if the chip is operating in little endian mode on a big endian architecture. chip710: (OPTIONAL) Set to 1 if the chip is a 53c710. burst_disable: (OPTIONAL, 53c710 only) Disable 8 byte bursting for DMA transfers. 1.4. Writing Your Glue Driver 3 Linux Scsi Documentation 4 Chapter 1. The 53c700 Driver Notes CHAPTER TWO AACRAID DRIVER FOR LINUX (TAKE TWO) 2.1 Introduction The aacraid driver adds support for Adaptec (http://www.adaptec.com) RAID con- trollers. This is a major rewrite from the original Adaptec supplied driver. It has significantly cleaned up both the code and the running binary size (the moduleis less than half the size of the original). 2.2 Supported Cards/Chipsets PCI ID (pci.ids) OEM Product 9005:0285:9005:0285 Adaptec 2200S (Vulcan) 9005:0285:9005:0286 Adaptec 2120S (Crusader) 9005:0285:9005:0287 Adaptec 2200S (Vulcan-2m) 9005:0285:9005:0288 Adaptec 3230S (Harrier) 9005:0285:9005:0289 Adaptec 3240S (Tornado) 9005:0285:9005:028a Adaptec 2020ZCR (Skyhawk) 9005:0285:9005:028b Adaptec 2025ZCR (Terminator) 9005:0286:9005:028c Adaptec 2230S (Lancer) 9005:0286:9005:028c Adaptec 2230SLP (Lancer) 9005:0286:9005:028d Adaptec 2130S (Lancer) 9005:0285:9005:028e Adaptec 2020SA (Skyhawk) 9005:0285:9005:028f Adaptec 2025SA (Terminator) 9005:0285:9005:0290 Adaptec 2410SA (Jaguar) 9005:0285:103c:3227 Adaptec 2610SA (Bearcat HP release) 9005:0285:9005:0293 Adaptec 21610SA (Corsair-16) 9005:0285:9005:0296 Adaptec 2240S (SabreExpress) 9005:0285:9005:0292 Adaptec 2810SA (Corsair-8) 9005:0285:9005:0297 Adaptec 4005 (AvonPark) 9005:0285:9005:0298 Adaptec 4000 (BlackBird) 9005:0285:9005:0299 Adaptec 4800SAS (Marauder-X) 9005:0285:9005:029a Adaptec 4805SAS (Marauder-E) 9005:0286:9005:029b Adaptec 2820SA (Intruder) 9005:0286:9005:029c Adaptec 2620SA (Intruder) 9005:0286:9005:029d Adaptec 2420SA (Intruder HP release) 9005:0286:9005:02ac Adaptec 1800 (Typhoon44) Continued on next page 5 Linux Scsi Documentation Table 1 – continued from previous page PCI ID (pci.ids) OEM Product 9005:0285:9005:02b5 Adaptec 5445 (Voodoo44) 9005:0285:15d9:02b5 SMC AOC-USAS-S4i 9005:0285:9005:02b6 Adaptec 5805 (Voodoo80) 9005:0285:15d9:02b6 SMC AOC-USAS-S8i 9005:0285:9005:02b7 Adaptec 5085 (Voodoo08) 9005:0285:9005:02bb Adaptec 3405 (Marauder40LP) 9005:0285:9005:02bc Adaptec 3805 (Marauder80LP) 9005:0285:9005:02c7 Adaptec 3085 (Marauder08ELP) 9005:0285:9005:02bd Adaptec 31205 (Marauder120) 9005:0285:9005:02be Adaptec 31605 (Marauder160) 9005:0285:9005:02c3 Adaptec 51205 (Voodoo120) 9005:0285:9005:02c4 Adaptec 51605 (Voodoo160) 9005:0285:15d9:02c9 SMC AOC-USAS-S4iR 9005:0285:15d9:02ca SMC AOC-USAS-S8iR 9005:0285:9005:02ce Adaptec 51245 (Voodoo124) 9005:0285:9005:02cf Adaptec 51645 (Voodoo164) 9005:0285:9005:02d0 Adaptec 52445 (Voodoo244) 9005:0285:9005:02d1 Adaptec 5405 (Voodoo40) 9005:0285:15d9:02d2 SMC AOC-USAS-S8i-LP 9005:0285:15d9:02d3 SMC AOC-USAS-S8iR-LP 9005:0285:9005:02d4 Adaptec ASR-2045 (Voodoo04 Lite) 9005:0285:9005:02d5 Adaptec ASR-2405 (Voodoo40 Lite) 9005:0285:9005:02d6 Adaptec ASR-2445 (Voodoo44 Lite) 9005:0285:9005:02d7 Adaptec ASR-2805 (Voodoo80 Lite) 9005:0285:9005:02d8 Adaptec 5405Z (Voodoo40 BLBU) 9005:0285:9005:02d9 Adaptec 5445Z (Voodoo44 BLBU) 9005:0285:9005:02da Adaptec 5805Z (Voodoo80 BLBU) 1011:0046:9005:0364 Adaptec 5400S (Mustang) 1011:0046:9005:0365 Adaptec 5400S (Mustang) 9005:0287:9005:0800 Adaptec Themisto (Jupiter) 9005:0200:9005:0200 Adaptec Themisto (Jupiter) 9005:0286:9005:0800 Adaptec Callisto (Jupiter) 1011:0046:9005:1364 Dell PERC 2/QC (Quad Channel, Mustang) 1011:0046:9005:1365 Dell PERC 2/QC (Quad Channel, Mustang) 1028:0001:1028:0001 Dell PERC 2/Si (Iguana) 1028:0003:1028:0003 Dell PERC 3/Si (SlimFast) 1028:0002:1028:0002 Dell PERC 3/Di (Opal) 1028:0004:1028:0004 Dell PERC 3/SiF (Iguana) 1028:0004:1028:00d0 Dell PERC 3/DiF (Iguana) 1028:0002:1028:00d1 Dell PERC 3/DiV (Viper) 1028:0002:1028:00d9 Dell PERC 3/DiL (Lexus) 1028:000a:1028:0106 Dell PERC 3/DiJ (Jaguar) 1028:000a:1028:011b Dell PERC 3/DiD (Dagger) 1028:000a:1028:0121 Dell PERC 3/DiB (Boxster) 9005:0285:1028:0287 Dell PERC 320/DC (Vulcan) 9005:0285:1028:0291 Dell CERC 2 (DellCorsair) 1011:0046:103c:10c2 HP NetRAID-4M (Mustang) Continued on next page 6 Chapter 2. AACRAID Driver for Linux (take two) Linux Scsi Documentation Table 1 – continued from previous page PCI ID (pci.ids) OEM Product 9005:0285:17aa:0286 Legend S220 (Crusader) 9005:0285:17aa:0287 Legend S230 (Vulcan) 9005:0285:9005:0290 IBM ServeRAID 7t (Jaguar) 9005:0285:1014:02F2 IBM ServeRAID 8i (AvonPark) 9005:0286:1014:9540 IBM ServeRAID 8k/8k-l4 (AuroraLite) 9005:0286:1014:9580 IBM ServeRAID 8k/8k-l8 (Aurora) 9005:0285:1014:034d IBM ServeRAID 8s (Marauder-E) 9005:0286:9005:029e ICP ICP9024RO (Lancer) 9005:0286:9005:029f ICP ICP9014RO (Lancer) 9005:0286:9005:02a0 ICP ICP9047MA (Lancer) 9005:0286:9005:02a1 ICP ICP9087MA (Lancer) 9005:0285:9005:02a4 ICP ICP9085LI (Marauder-X) 9005:0285:9005:02a5 ICP ICP5085BR (Marauder-E) 9005:0286:9005:02a6 ICP ICP9067MA (Intruder-6) 9005:0285:9005:02b2 ICP (Voodoo 8 internal 8 external) 9005:0285:9005:02b8 ICP ICP5445SL (Voodoo44) 9005:0285:9005:02b9 ICP ICP5085SL (Voodoo80) 9005:0285:9005:02ba ICP ICP5805SL (Voodoo08) 9005:0285:9005:02bf ICP ICP5045BL (Marauder40LP) 9005:0285:9005:02c0 ICP ICP5085BL