]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - share/man/man4/ahc.4
This commit was generated by cvs2svn to compensate for changes in r52746,
[FreeBSD/FreeBSD.git] / share / man / man4 / ahc.4
1 .\"
2 .\" Copyright (c) 1995, 1996, 1997, 1998
3 .\"     Justin T. Gibbs.  All rights reserved.
4 .\"
5 .\" Redistribution and use in source and binary forms, with or without
6 .\" modification, are permitted provided that the following conditions
7 .\" are met:
8 .\" 1. Redistributions of source code must retain the above copyright
9 .\"    notice, this list of conditions and the following disclaimer.
10 .\" 2. Redistributions in binary form must reproduce the above copyright
11 .\"    notice, this list of conditions and the following disclaimer in the
12 .\"    documentation and/or other materials provided with the distribution.
13 .\" 3. The name of the author may not be used to endorse or promote products
14 .\"    derived from this software without specific prior written permission.
15 .\"
16 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
17 .\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
18 .\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
19 .\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
20 .\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
21 .\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
22 .\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
23 .\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24 .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
25 .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 .\"
27 .\" $FreeBSD$
28 .\"
29 .Dd October 15, 1998
30 .Dt AHC 4 i386
31 .Os FreeBSD
32 .Sh NAME
33 .Nm ahc
34 .Nd Adaptec VL/EISA/PCI SCSI host adapter driver
35 .Sh SYNOPSIS
36 For one or more VL/EISA cards:
37 .Cd controller eisa0
38 .Cd controller ahc0
39 .Pp
40 For one or more PCI cards:
41 .Cd controller pci0
42 .Cd controller ahc0
43 .Pp
44 To allow PCI adapters to use memory mapped I/O if enabled:
45 .Cd options AHC_ALLOW_MEMIO
46 .Pp
47 For one or more SCSI busses:
48 .Cd controller scbus0 at ahc0
49 .Sh DESCRIPTION
50 This driver provides access to the
51 .Tn SCSI
52 bus(es) connected to Adaptec
53 .Tn AIC7770,
54 .Tn AIC7850,
55 .Tn AIC7860,
56 .Tn AIC7870,
57 .Tn AIC7880,
58 .Tn AIC7890,
59 .Tn AIC7891,
60 .Tn AIC7895,
61 .Tn AIC7896,
62 or
63 .Tn AIC7897
64 host adapter chips.
65 These chips are found on many motherboards as well as the following
66 Adaptec SCSI controller cards:
67 .Tn 274X(W),
68 .Tn 274X(T),
69 .Tn 284X,
70 .Tn 2920C,
71 .Tn 2930U2,
72 .Tn 2940,
73 .Tn 2940U,
74 .Tn 2940AU,
75 .Tn 2940UW,
76 .Tn 2940UW Dual,
77 .Tn 2940U2W,
78 .Tn 2940U2B,
79 .Tn 2950U2W,
80 .Tn 2950U2B,
81 .Tn 3940,
82 .Tn 3940U,
83 .Tn 3940AU,
84 .Tn 3940UW,
85 .Tn 3940AUW,
86 .Tn 3940U2W,
87 .Tn 3950U2,
88 and
89 .Tn 3985.
90 .Pp
91 Driver features include support for twin and wide busses,
92 fast, ultra and ultra2 synchronous transfers depending on controller type,
93 tagged queuing,
94 and SCB paging.
95 .Pp
96 Memory mapped I/O can be enabled for PCI devices with the
97 .Dq Dv AHC_ALLOW_MEMIO
98 configuration option.
99 Memory mapped I/O is more efficient than the alternative, programmed I/O.
100 Most PCI BIOSes will map devices so that either technique for communicating
101 with the card is available.
102 In some cases,
103 usually when the PCI device is sitting behind a PCI->PCI bridge,
104 the BIOS fails to properly initialize the chip for memory mapped I/O.
105 The symptom of this problem is usually a system hang if memory mapped I/O
106 is attempted.
107 Most modern motherboards perform the initialization correctly and work fine
108 with this option enabled.
109 .Pp
110 Per target configuration performed in the 
111 .Tn SCSI-Select
112 menu, accessible at boot
113 in 
114 .No non- Ns Tn EISA
115 models,
116 or through an 
117 .Tn EISA
118 configuration utility for 
119 .Tn EISA
120 models,
121 is honored by this driver with the stipulation that the 
122 .Tn BIOS
123 must be enabled for 
124 .Tn EISA
125 adaptors.  This includes synchronous/asynchronous transfers,
126 maximum synchronous negotiation rate,
127 disconnection,
128 the host adapter's SCSI ID,
129 and,
130 in the case of
131 .Tn EISA
132 Twin Channel controllers,
133 the primary channel selection.
134 .Pp
135 Note that I/O addresses are determined automatically by the probe routines,
136 but care should be taken when using a 284x
137 .Pq Tn VESA No local bus controller
138 in an
139 .Tn EISA 
140 system.  Ensure that the jumpers setting the I/O area for the 284x match the 
141 .Tn EISA
142 slot into which the card is inserted to prevent conflicts with other
143 .Tn EISA
144 cards.
145 .Pp
146 Performance and feature sets vary throughout the aic7xxx product line.
147 The following table provides a comparison of the different chips supported
148 by the
149 .Nm
150 driver.  Note that wide and twin channel features, although always supported
151 by a particular chip, may be disabled in a particular motherboard or card
152 design.
153 .Pp
154 .Bd -filled -offset indent
155 .Bl -column "aic7770 " "10 " "EISA/VL  " "10MHz " "16bit " "SCBs " Features
156 .Em "Chip       MIPS    Bus      MaxSync   MaxWidth  SCBs  Features"
157 aic7770     10    EISA/VL    10MHz     16Bit     4    1
158 aic7850     10    PCI/32     10MHz      8Bit     3
159 aic7860     10    PCI/32     20MHz      8Bit     3
160 aic7870     10    PCI/32     10MHz     16Bit    16
161 aic7880     10    PCI/32     20MHz     16Bit    16 
162 aic7890     20    PCI/32     40MHz     16Bit    16        3 4 5 6 7
163 aic7891     20    PCI/64     40MHz     16Bit    16        3 4 5 6 7
164 aic7895     15    PCI/32     20MHz     16Bit    16      2 3 4 5
165 aic7896     20    PCI/32     40MHz     16Bit    16      2 3 4 5 6 7
166 aic7897     20    PCI/64     40MHz     16Bit    16      2 3 4 5 6 7
167 .El 
168 .Pp
169 .Bl -enum -compact
170 .It
171 Multiplexed Twin Channel Device - One controller servicing two busses.
172 .It
173 Multi-function Twin Channel Device - Two controllers on one chip.
174 .It
175 Command Channel Secondary DMA Engine - Allows scatter gather list and
176 SCB prefetch.
177 .It
178 64 Byte SCB Support - SCSI CDB is embedded in the SCB to eliminate an extra DMA.
179 .It
180 Block Move Instruction Support - Doubles the speed of certain sequencer
181 operations.
182 .It
183 .Sq Bayonet
184 style Scatter Gather Engine - Improves S/G prefetch performance.
185 .It
186 Queuing Registers - Allows queuing of new transactions without pausing the
187 sequencer.
188 .El
189 .Ed
190 .Pp
191
192 .Sh SCSI CONTROL BLOCKS (SCBs)
193 Every transaction sent to a device on the SCSI bus is assigned a
194 .Sq SCSI Control Block
195 (SCB).  The SCB contains all of the information required by the
196 controller to process a transaction.  The chip feature table lists
197 the number of SCBs that can be stored in on chip memory.  All chips
198 with model numbers greater than or equal to 7870 allow for the on chip
199 SCB space to be augmented with external SRAM up to a maximum of 255 SCBs.
200 Very few Adaptec controller have external SRAM.
201
202 If external SRAM is not available, SCBs are a limited resource and
203 using them in a straight forward manner would only allow us to
204 keep as many transactions as there are SCBs outstanding at a time.
205 This would not allow enough concurrency to fully utilize the SCSI
206 bus and it's devices. The solution to this problem is
207 .Em SCB Paging ,
208 a concept similar to memory paging.  SCB paging takes advantage of
209 the fact that devices usually disconnect from the SCSI bus for long
210 periods of time without talking to the controller.  The SCBs
211 for disconnected transactions are only of use to the controller
212 when the transfer is resumed.  When the host queues another transaction
213 for the controller to execute, the controller firmware will use a
214 free SCB if one is available.  Otherwise, the state of the most recently
215 disconnected (and therefor most likely to stay disconnected) SCB is
216 saved, via dma, to host memory, and the local SCB reused to start
217 the new transaction.  This allows the controller to queue up to
218 255 transactions regardless of the amount of SCB space.  Since the
219 local SCB space serves as a cache for disconnected transactions, the
220 more SCB space available, the less host bus traffic consumed saving
221 and restoring SCB data.
222 .Sh BUGS
223 Some Quantum drives (at least the Empire 2100 and 1080s) will not run on an
224 .Tn AIC7870
225 Rev B in synchronous mode at 10MHz.  Controllers with this problem have a
226 42 MHz clock crystal on them and run slightly above 10MHz.  This confuses
227 the drive and hangs the bus.  Setting a maximum synchronous negotiation rate
228 of 8MHz in the 
229 .Tn SCSI-Select
230 utility
231 will allow normal operation.
232 .Sh SEE ALSO
233 .Xr aha 4 ,
234 .Xr ahb 4 ,
235 .Xr cd 4 ,
236 .Xr da 4 ,
237 .Xr sa 4 ,
238 .Xr scsi 4
239 .Sh AUTHORS
240 The
241 .Nm
242 driver, the
243 .Tn AIC7xxx
244 sequencer-code assembler,
245 and the firmware running on the aic7xxx chips was written by
246 .An Justin T. Gibbs .
247 .Sh HISTORY
248 The
249 .Nm
250 driver appeared in
251 .Fx 2.0 .