]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - share/man/man4/ahc.4
This commit was generated by cvs2svn to compensate for changes in r146309,
[FreeBSD/FreeBSD.git] / share / man / man4 / ahc.4
1 .\"
2 .\" Copyright (c) 1995, 1996, 1997, 1998, 2000
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 July 4, 2004
30 .Dt AHC 4
31 .Os
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 device eisa
38 .Cd device ahc
39 .Pp
40 For one or more PCI cards:
41 .Cd device pci
42 .Cd device ahc
43 .Pp
44 To allow PCI adapters to use memory mapped I/O if enabled:
45 .Cd options AHC_ALLOW_MEMIO
46 .Pp
47 To configure one or more controllers to assume the target role:
48 .Cd options AHC_TMODE_ENABLE <bitmask of units>
49 .Pp
50 For one or more SCSI busses:
51 .Cd device scbus
52 .Sh DESCRIPTION
53 This driver provides access to the
54 .Tn SCSI
55 bus(es) connected to the Adaptec AIC77xx and AIC78xx
56 host adapter chips.
57 .Pp
58 Driver features include support for twin and wide busses,
59 fast, ultra or ultra2 synchronous transfers depending on controller type,
60 tagged queueing, SCB paging, and target mode.
61 .Pp
62 Memory mapped I/O can be enabled for PCI devices with the
63 .Dq Dv AHC_ALLOW_MEMIO
64 configuration option.
65 Memory mapped I/O is more efficient than the alternative, programmed I/O.
66 Most PCI BIOSes will map devices so that either technique for communicating
67 with the card is available.
68 In some cases,
69 usually when the PCI device is sitting behind a PCI->PCI bridge,
70 the BIOS may fail to properly initialize the chip for memory mapped I/O.
71 The typical symptom of this problem is a system hang if memory mapped I/O
72 is attempted.
73 Most modern motherboards perform the initialization correctly and work fine
74 with this option enabled.
75 .Pp
76 Individual controllers may be configured to operate in the target role
77 through the
78 .Dq Dv AHC_TMODE_ENABLE
79 configuration option.
80 The value assigned to this option should be a bitmap
81 of all units where target mode is desired.
82 For example, a value of 0x25, would enable target mode on units 0, 2, and 5.
83 A value of 0x8a enables it for units 1, 3, and 7.
84 .Pp
85 Per target configuration performed in the
86 .Tn SCSI-Select
87 menu, accessible at boot
88 in
89 .No non- Ns Tn EISA
90 models,
91 or through an
92 .Tn EISA
93 configuration utility for
94 .Tn EISA
95 models,
96 is honored by this driver.
97 This includes synchronous/asynchronous transfers,
98 maximum synchronous negotiation rate,
99 wide transfers,
100 disconnection,
101 the host adapter's SCSI ID,
102 and,
103 in the case of
104 .Tn EISA
105 Twin Channel controllers,
106 the primary channel selection.
107 For systems that store non-volatile settings in a system specific manner
108 rather than a serial eeprom directly connected to the aic7xxx controller,
109 the
110 .Tn BIOS
111 must be enabled for the driver to access this information.
112 This restriction applies to all
113 .Tn EISA
114 and many motherboard configurations.
115 .Pp
116 Note that I/O addresses are determined automatically by the probe routines,
117 but care should be taken when using a 284x
118 .Pq Tn VESA No local bus controller
119 in an
120 .Tn EISA
121 system.
122 The jumpers setting the I/O area for the 284x should match the
123 .Tn EISA
124 slot into which the card is inserted to prevent conflicts with other
125 .Tn EISA
126 cards.
127 .Pp
128 Performance and feature sets vary throughout the aic7xxx product line.
129 The following table provides a comparison of the different chips supported
130 by the
131 .Nm
132 driver.
133 Note that wide and twin channel features, although always supported
134 by a particular chip, may be disabled in a particular motherboard or card
135 design.
136 .Pp
137 .Bd -ragged -offset indent
138 .Bl -column "aic7770 " "10 " "EISA/VL  " "10MHz " "16bit " "SCBs " Features
139 .Em "Chip       MIPS    Bus      MaxSync   MaxWidth  SCBs  Features"
140 aic7770     10    EISA/VL    10MHz     16Bit     4    1
141 aic7850     10    PCI/32     10MHz      8Bit     3
142 aic7860     10    PCI/32     20MHz      8Bit     3
143 aic7870     10    PCI/32     10MHz     16Bit    16
144 aic7880     10    PCI/32     20MHz     16Bit    16
145 aic7890     20    PCI/32     40MHz     16Bit    16        3 4 5 6 7 8
146 aic7891     20    PCI/64     40MHz     16Bit    16        3 4 5 6 7 8
147 aic7892     20    PCI/64     80MHz     16Bit    16        3 4 5 6 7 8
148 aic7895     15    PCI/32     20MHz     16Bit    16      2 3 4 5
149 aic7895C    15    PCI/32     20MHz     16Bit    16      2 3 4 5     8
150 aic7896     20    PCI/32     40MHz     16Bit    16      2 3 4 5 6 7 8
151 aic7897     20    PCI/64     40MHz     16Bit    16      2 3 4 5 6 7 8
152 aic7899     20    PCI/64     80MHz     16Bit    16      2 3 4 5 6 7 8
153 .El
154 .Pp
155 .Bl -enum -compact
156 .It
157 Multiplexed Twin Channel Device - One controller servicing two busses.
158 .It
159 Multi-function Twin Channel Device - Two controllers on one chip.
160 .It
161 Command Channel Secondary DMA Engine - Allows scatter gather list and
162 SCB prefetch.
163 .It
164 64 Byte SCB Support - SCSI CDB is embedded in the SCB to eliminate an extra DMA.
165 .It
166 Block Move Instruction Support - Doubles the speed of certain sequencer
167 operations.
168 .It
169 .Sq Bayonet
170 style Scatter Gather Engine - Improves S/G prefetch performance.
171 .It
172 Queuing Registers - Allows queueing of new transactions without pausing the
173 sequencer.
174 .It
175 Multiple Target IDs - Allows the controller to respond to selection as a
176 target on multiple SCSI IDs.
177 .El
178 .Ed
179 .Sh HARDWARE
180 The
181 .Nm
182 driver supports the following
183 .Tn SCSI
184 host adapter chips and
185 .Tn SCSI
186 controller cards:
187 .Pp
188 .Bl -bullet -compact
189 .It
190 Adaptec
191 .Tn AIC7770
192 host adapter chip
193 .It
194 Adaptec
195 .Tn AIC7850
196 host adapter chip
197 .It
198 Adaptec
199 .Tn AIC7860
200 host adapter chip
201 .It
202 Adaptec
203 .Tn AIC7870
204 host adapter chip
205 .It
206 Adaptec
207 .Tn AIC7880
208 host adapter chip
209 .It
210 Adaptec
211 .Tn AIC7890
212 host adapter chip
213 .It
214 Adaptec
215 .Tn AIC7891
216 host adapter chip
217 .It
218 Adaptec
219 .Tn AIC7892
220 host adapter chip
221 .It
222 Adaptec
223 .Tn AIC7895
224 host adapter chip
225 .It
226 Adaptec
227 .Tn AIC7896
228 host adapter chip
229 .It
230 Adaptec
231 .Tn AIC7897
232 host adapter chip
233 .It
234 Adaptec
235 .Tn AIC7899
236 host adapter chip
237 .It
238 Adaptec
239 .Tn 274X(W)
240 .It
241 Adaptec
242 .Tn 274X(T)
243 .It
244 Adaptec
245 .Tn 284X
246 .It
247 Adaptec
248 .Tn 2910
249 .It
250 Adaptec
251 .Tn 2915
252 .It
253 Adaptec
254 .Tn 2920
255 .It
256 Adaptec
257 .Tn 2930C
258 .It
259 Adaptec
260 .Tn 2930U2
261 .It
262 Adaptec
263 .Tn 2940
264 .It
265 Adaptec
266 .Tn 2940J
267 .It
268 Adaptec
269 .Tn 2940N
270 .It
271 Adaptec
272 .Tn 2940U
273 .It
274 Adaptec
275 .Tn 2940AU
276 .It
277 Adaptec
278 .Tn 2940UW
279 .It
280 Adaptec
281 .Tn 2940UW Dual
282 .It
283 Adaptec
284 .Tn 2940UW Pro
285 .It
286 Adaptec
287 .Tn 2940U2W
288 .It
289 Adaptec
290 .Tn 2940U2B
291 .It
292 Adaptec
293 .Tn 2950U2W
294 .It
295 Adaptec
296 .Tn 2950U2B
297 .It
298 Adaptec
299 .Tn 19160B
300 .It
301 Adaptec
302 .Tn 29160B
303 .It
304 Adaptec
305 .Tn 29160N
306 .It
307 Adaptec
308 .Tn 3940
309 .It
310 Adaptec
311 .Tn 3940U
312 .It
313 Adaptec
314 .Tn 3940AU
315 .It
316 Adaptec
317 .Tn 3940UW
318 .It
319 Adaptec
320 .Tn 3940AUW
321 .It
322 Adaptec
323 .Tn 3940U2W
324 .It
325 Adaptec
326 .Tn 3950U2
327 .It
328 Adaptec
329 .Tn 3960
330 .It
331 Adaptec
332 .Tn 39160
333 .It
334 Adaptec
335 .Tn 3985
336 .It
337 Adaptec
338 .Tn 4944UW
339 .It
340 NEC PC-9821Xt13 (PC-98)
341 .It
342 NEC RvII26 (PC-98)
343 .It
344 NEC PC-9821X-B02L/B09 (PC-98)
345 .It
346 NEC SV-98/2-B03 (PC-98)
347 .It
348 Many motherboards with on-board
349 .Tn SCSI
350 support
351 .El
352 .Sh SCSI CONTROL BLOCKS (SCBs)
353 Every transaction sent to a device on the SCSI bus is assigned a
354 .Sq SCSI Control Block
355 (SCB).
356 The SCB contains all of the information required by the
357 controller to process a transaction.
358 The chip feature table lists
359 the number of SCBs that can be stored in on-chip memory.
360 All chips
361 with model numbers greater than or equal to 7870 allow for the on chip
362 SCB space to be augmented with external SRAM up to a maximum of 255 SCBs.
363 Very few Adaptec controller configurations have external SRAM.
364 .Pp
365 If external SRAM is not available, SCBs are a limited resource.
366 Using the SCBs in a straight forward manner would only allow the driver to
367 handle as many concurrent transactions as there are physical SCBs.
368 To fully utilize the SCSI bus and the devices on it,
369 requires much more concurrency.
370 The solution to this problem is
371 .Em SCB Paging ,
372 a concept similar to memory paging.
373 SCB paging takes advantage of
374 the fact that devices usually disconnect from the SCSI bus for long
375 periods of time without talking to the controller.
376 The SCBs for disconnected transactions are only of use to the controller
377 when the transfer is resumed.
378 When the host queues another transaction
379 for the controller to execute, the controller firmware will use a
380 free SCB if one is available.
381 Otherwise, the state of the most recently
382 disconnected (and therefore most likely to stay disconnected) SCB is
383 saved, via dma, to host memory, and the local SCB reused to start
384 the new transaction.
385 This allows the controller to queue up to
386 255 transactions regardless of the amount of SCB space.
387 Since the
388 local SCB space serves as a cache for disconnected transactions, the
389 more SCB space available, the less host bus traffic consumed saving
390 and restoring SCB data.
391 .Sh SEE ALSO
392 .Xr aha 4 ,
393 .Xr ahb 4 ,
394 .Xr cd 4 ,
395 .Xr da 4 ,
396 .Xr sa 4 ,
397 .Xr scsi 4
398 .Sh HISTORY
399 The
400 .Nm
401 driver appeared in
402 .Fx 2.0 .
403 .Sh AUTHORS
404 The
405 .Nm
406 driver, the
407 .Tn AIC7xxx
408 sequencer-code assembler,
409 and the firmware running on the aic7xxx chips was written by
410 .An Justin T. Gibbs .
411 .Sh BUGS
412 Some Quantum drives (at least the Empire 2100 and 1080s) will not run on an
413 .Tn AIC7870
414 Rev B in synchronous mode at 10MHz.
415 Controllers with this problem have a
416 42 MHz clock crystal on them and run slightly above 10MHz.
417 This confuses the drive and hangs the bus.
418 Setting a maximum synchronous negotiation rate of 8MHz in the
419 .Tn SCSI-Select
420 utility will allow normal operation.
421 .Pp
422 Although the Ultra2 and Ultra160 products have sufficient instruction
423 ram space to support both the initiator and target roles concurrently,
424 this configuration is disabled in favor of allowing the target role
425 to respond on multiple target ids.
426 A method for configuring dual role mode should be provided.
427 .Pp
428 Tagged Queuing is not supported in target mode.
429 .Pp
430 Reselection in target mode fails to function correctly on all high
431 voltage differential boards as shipped by Adaptec.
432 Information on
433 how to modify HVD board to work correctly in target mode is available
434 from Adaptec.