1fas(7D) Devices fas(7D)
2
3
4
6 fas - FAS SCSI Host Bus Adapter Driver
7
9 fas@sbus-slot,0x8800000
10
11
13 The fas Host Bus Adapter driver is a SCSA compliant nexus driver that
14 supports the Qlogic FAS366 SCSI chip.
15
16
17 The fas driver supports the standard functions provided by the SCSA
18 interface. The driver supports tagged and untagged queuing, wide and
19 fast SCSI, almost unlimited transfer size (using a moving DVMA window
20 approach), and auto request sense; but it does not support linked com‐
21 mands.
22
23 Driver Configuration
24 The fas driver can be configured by defining properties in fas.conf
25 which override the global SCSI settings. Supported properties are:
26 scsi-options, target<n>-scsi-options, scsi-reset-delay, scsi-watchdog-
27 tick, scsi-tag-age-limit, scsi-initiator-id.
28
29
30 target<n>-scsi-options overrides the scsi-options property value for
31 target<n>. <n> can vary from decimal 0 to 15. The supported scsi-
32 options are: SCSI_OPTIONS_DR, SCSI_OPTIONS_SYNC, SCSI_OPTIONS_TAG,
33 SCSI_OPTIONS_FAST, and SCSI_OPTIONS_WIDE.
34
35
36 After periodic interval scsi-watchdog-tick, the fas driver searches all
37 current and disconnected commands for timeouts.
38
39
40 scsi-tag-age-limit is the number of times that the fas driver attempts
41 to allocate a particular tag ID that is currently in use after going
42 through all tag IDs in a circular fashion. After finding the same tag
43 ID in use scsi-tag-age-limit times, no more commands will be submitted
44 to this target until all outstanding commands complete or timeout.
45
46
47 Refer to scsi_hba_attach(9F) for details.
48
50 Example 1 A sample of fas configuration file
51
52
53 Create a file called /kernel/drv/fas.conf and add this line:
54
55
56
57 scsi-options=0x78;
58
59
60
61 This disables tagged queuing, Fast SCSI, and Wide mode for all fas
62 instances. The following example disables an option for one specific
63 fas (refer to driver.conf(4) for more details):
64
65
66 name="fas" parent="/iommu@f,e0000000/sbus@f,e0001000"
67 reg=3,0x8800000,0x10,3,0x8810000,0x40
68 target1-scsi-options=0x58
69 scsi-options=0x178 scsi-initiator-id=6;
70
71
72
73 Note that the default initiator ID in OBP is 7 and that the change to
74 ID 6 will occur at attach time. It may be preferable to change the
75 initiator ID in OBP.
76
77
78
79 The example above sets scsi-options for target 1 to 0x58 and all other
80 targets on this SCSI bus to 0x178.
81
82
83
84 The physical pathname of the parent can be determined using the
85 /devices tree or following the link of the logical device name:
86
87
88 # ls -l /dev/rdsk/c1t3d0s0
89 lrwxrwxrwx 1 root other 78 Aug 28 16:05 /dev/rdsk/c1t3d0s0 ->
90
91 ../../devices/iommu@f,e0000000 sbus@f,e0001000/SUNW,fas@3,8800000/sd@3,0:a,raw
92
93
94
95 Determine the register property values using the output from prt‐
96 conf(1M) (with the -v option):
97
98
99 SUNW,fas, instance #0
100 ....
101 Register Specifications:
102 Bus Type=0x3, Address=0x8800000, Size=10
103 Bus Type=0x3, Address=0x8810000, Size=40
104
105
106
107 scsi-options can also be specified per device type using the device
108 inquiry string. All the devices with the same inquiry string will have
109 the same scsi-options set. This can be used to disable some scsi-
110 options on all the devices of the same type.
111
112
113 device-type-scsi-options-list=
114 "TOSHIBA XM5701TASUN12XCD", "cd-scsi-options";
115 cd-scsi-options = 0x0;
116
117
118
119 The above entry in /kernel/drv/fas.conf sets the scsi-options for all
120 devices with inquiry string TOSHIBA XM5701TASUN12XCD to cd-scsi-
121 options. To get the inquiry string, run the probe-scsi or probe-scsi-
122 all command at the ok prompt before booting the system.
123
124
125
126 To set scsi-options more specifically per target:
127
128
129 target1-scsi-options=0x78;
130 device-type-scsi-options-list =
131 "SEAGATE ST32550W", "seagate-scsi-options" ;
132 seagate-scsi-options = 0x58;
133 scsi-options=0x3f8;
134
135
136
137 The above sets scsi-options for target 1 to 0x78 and for all other tar‐
138 gets on this SCSI bus to 0x3f8 except for one specific disk type which
139 will have scsi-options set to 0x58.
140
141
142
143 scsi-options specified per target ID have the highest precedence, fol‐
144 lowed by scsi-options per device type. Global fas scsi-options (effect‐
145 ing all instances) per bus have the lowest precedence.
146
147
148
149 The system needs to be rebooted before the specified scsi-options take
150 effect.
151
152
153 Driver Capabilities
154 The target driver needs to set capabilities in the fas driver in order
155 to enable some driver features. The target driver can query and modify
156 these capabilities: synchronous, tagged-qing, wide-xfer, auto-rqsense,
157 qfull-retries, qfull-retry-interval. All other capabilities can only be
158 queried.
159
160
161 By default, tagged-qing, auto-rqsense, and wide-xfer capabilities are
162 disabled, while disconnect, synchronous, and untagged-qing are enabled.
163 These capabilities can only have binary values (0 or 1). The default
164 value for qfull-retries is 10 and the default value for qfull-retry-
165 interval is 100. The qfull-retries capability is a uchar_t (0 to 255)
166 while qfull-retry-interval is a ushort_t (0 to 65535).
167
168
169 The target driver needs to enable tagged-qing and wide-xfer explic‐
170 itly. The untagged-qing capability is always enabled and its value
171 cannot be modified, because fas can queue commands even when tagged-
172 qing is disabled.
173
174
175 Whenever there is a conflict between the value of scsi-options and a
176 capability, the value set in scsi-options prevails. Only whom != 0 is
177 supported in the scsi_ifsetcap(9F) call.
178
179
180 Refer to scsi_ifsetcap(9F) and scsi_ifgetcap(9F) for details.
181
183 /kernel/drv/fas ELF Kernel Module
184
185
186 /kernel/drv/fas.conf Optional configuration file
187
188
190 See attributes(5) for descriptions of the following attributes:
191
192
193
194
195 ┌────────────────────────┬──────────────────────────────────┐
196 │ ATTRIBUTE TYPE │ ATTRIBUTE VALUE │
197 ├────────────────────────┼──────────────────────────────────┤
198 │Architecture │Limited to Sparc SBus-based sys‐ │
199 │ │tems with FAS366-based SCSI port │
200 │ │and SunSWIFT SBus SCSI Host │
201 │ │Adapter/Fast Ethernet option. │
202 └────────────────────────┴──────────────────────────────────┘
203
205 prtconf(1M), driver.conf(4), attributes(5), scsi_abort(9F),
206 scsi_hba_attach(9F), scsi_ifgetcap(9F), scsi_ifsetcap(9F),
207 scsi_reset(9F), scsi_sync_pkt(9F), scsi_transport(9F), scsi_device(9S),
208 scsi_extended_sense(9S), scsi_inquiry(9S), scsi_pkt(9S)
209
210
211 Writing Device Drivers
212
213
214 ANSI Small Computer System Interface-2 (SCSI-2)
215
216
217 QLogic Corporation, FAS366 Technical Manuals.
218
220 The messages described below are some that may appear on the system
221 console, as well as being logged.
222
223
224 The first five messages may be displayed while the fas driver is try‐
225 ing to attach; these messages mean that the fas driver was unable to
226 attach. All of these messages are preceded by "fas%d", where "%d" is
227 the instance number of the fas controller.
228
229 Device in slave-only slot
230
231 The SBus device has been placed in a slave-only slot and will not
232 be accessible; move to non-slave-only SBus slot.
233
234
235 Device is using a hilevel intr
236
237 The device was configured with an interrupt level that cannot be
238 used with this fas driver. Check the SBus device.
239
240
241 Cannot alloc dma handle
242
243 Driver was unable to allocate memory for a DMA controller.
244
245
246 Cannot alloc cmd area
247
248 Driver was unable to allocate memory for a command address.
249
250
251 Cannot create kmem_cache
252
253 Driver was unable to allocate memory for internal data structures.
254
255
256 Unable to map FAS366 registers
257
258 Driver was unable to map device registers; check for bad hardware.
259 Driver did not attach to device; SCSI devices will be inaccessible.
260
261
262 Cannot add intr
263
264 Driver could not add its interrupt service routine to the kernel.
265
266
267 Cannot map dma
268
269 Driver was unable to locate a DMA controller. This is an auto-con‐
270 figuration error.
271
272
273 Cannot bind cmdarea
274
275 Driver was unable to bind the DMA handle to an address.
276
277
278 Cannot create devctl minor node
279
280 Driver is unable to create a minor node for the controller.
281
282
283 Cannot attach
284
285 The driver was unable to attach; usually follows another warning
286 that indicates why attach failed.
287
288
289 Disabled TQ since disconnects are disabled
290
291 Tagged queuing was disabled because disconnects were disabled in
292 scsi-options.
293
294
295 Bad clock frequency
296
297 Check for bad hardware.
298
299
300 Sync of pkt (<address>) failed
301
302 Syncing a SCSI packet failed. Refer to scsi_sync_pkt(9F).
303
304
305 All tags in use!
306
307 The driver could not allocate another tag number. The target
308 devices do not properly support tagged queuing.
309
310
311 Gross error in FAS366 status
312
313 The driver experienced severe SCSI bus problems. Check cables and
314 terminator.
315
316
317 Spurious interrupt
318
319 The driver received an interrupt while the hardware was not inter‐
320 rupting.
321
322
323 Lost state in phasemanage
324
325 The driver is confused about the state of the SCSI bus.
326
327
328 Unrecoverable DMA error during selection
329
330 The DMA controller experienced host SBus problems. Check for bad
331 hardware.
332
333
334 Bad sequence step (<step number>) in selection
335
336 The FAS366 hardware reported a bad sequence step. Check for bad
337 hardware.
338
339
340 Undetermined selection failure
341
342 The selection of a target failed unexpectedly. Check for bad hard‐
343 ware.
344
345
346 Target <n>: failed reselection (bad reselect bytes)
347
348 A reconnect failed, target sent incorrect number of message bytes.
349 Check for bad hardware.
350
351
352 Target <n>: failed reselection (bad identify message)
353
354 A reconnect failed, target didn't send identify message or it got
355 corrupted. Check for bad hardware.
356
357
358 Target <n>: failed reselection (not in msgin phase)
359
360 Incorrect SCSI bus phase after reconnection. Check for bad hard‐
361 ware.
362
363
364 Target <n>: failed reselection (unexpected bus free)
365
366 Incorrect SCSI bus phase after reconnection. Check for bad hard‐
367 ware.
368
369
370 Target <n>: failed reselection (timeout on receiving tag msg)
371
372 A reconnect failed; target failed to send tag bytes. Check for bad
373 hardware.
374
375
376 Target <n>: failed reselection (botched tag)
377
378 A reconnect failed; target failed to send tag bytes. Check for bad
379 hardware.
380
381
382 Target <n>: failed reselection (invalid tag)
383
384 A reconnect failed; target sent incorrect tag bytes. Check for bad
385 hardware.
386
387
388 Target <n>: failed reselection (Parity error in reconnect msg's)
389
390 A reconnect failed; parity error detected. Check for bad hardware.
391
392
393 Target <n>: failed reselection (no command)
394
395 A reconnect failed; target accepted abort or reset, but still tries
396 to reconnect. Check for bad hardware.
397
398
399 Unexpected bus free
400
401 Target disconnected from the bus without notice. Check for bad
402 hardware.
403
404
405 Target <n> didn't disconnect after sending <message>
406
407 The target unexpectedly did not disconnect after sending <message>.
408
409
410 Bad sequence step (0x?) in selection
411
412 The sequence step register shows an improper value. The target
413 might be misbehaving.
414
415
416 Illegal dma boundary?
417
418 An attempt was made to cross a boundary that the driver could not
419 handle.
420
421
422 Unwanted data xfer direction for Target <n>
423
424 The target went into an unexpected phase.
425
426
427 Unrecoverable DMA error on dma <send/receive>
428
429 There is a DMA error while sending/receiving data. The host DMA
430 controller is experiencing some problems.
431
432
433 SCSI bus DATA IN phase parity error
434
435 The driver detected parity errors on the SCSI bus.
436
437
438 SCSI bus MESSAGE IN phase parity error
439
440 The driver detected parity errors on the SCSI bus.
441
442
443 SCSI bus STATUS phase parity error
444
445 The driver detected parity errors on the SCSI bus.
446
447
448 Premature end of extended message
449
450 An extended SCSI bus message did not complete. Suspect a target
451 firmware problem.
452
453
454 Premature end of input message
455
456 A multibyte input message was truncated. Suspect a target firmware
457 problem.
458
459
460 Input message botch
461
462 The driver is confused about messages coming from the target.
463
464
465 Extended message <n> is too long
466
467 The extended message sent by the target is longer than expected.
468
469
470 <name> message <n> from Target <m> garbled
471
472 Target <m> sent message <name> of value <n> which the driver did
473 not understand.
474
475
476 Target <n> rejects our message <name>
477
478 Target <n> rejected a message sent by the driver.
479
480
481 Rejecting message <name> from Target <n>
482
483 The driver rejected a message received from target <n>.
484
485
486 Cmd transmission error
487
488 The driver was unable to send out command bytes.
489
490
491 Target <n> refused message resend
492
493 The target did not accept a message resend.
494
495
496 MESSAGE OUT phase parity error
497
498 The driver detected parity errors on the SCSI bus.
499
500
501 Two byte message <name> <value> rejected
502
503 The driver does not accept this two byte message.
504
505
506 Gross error in fas status <stat>
507
508 The fas chip has indicated a gross error like FIFO overflow.
509
510
511 Polled cmd failed (target busy)
512
513 A polled command failed because the target did not complete out‐
514 standing commands within a reasonable time.
515
516
517 Polled cmd failed
518
519 A polled command failed because of timeouts or bus errors.
520
521
522 Auto request sense failed
523
524 Driver is unable to get request sense from the target.
525
526
527 Disconnected command timeout for Target <id>.<lun>
528
529 A timeout occurred while target id/lun was disconnected. This is
530 usually a target firmware problem. For tagged queuing targets, <n>
531 commands were outstanding when the timeout was detected.
532
533
534 Disconnected tagged cmds (<n>) timeout for Target <id>.<lun>
535
536 A timeout occurred while target id/lun was disconnected. This is
537 usually a target firmware problem. For tagged queuing targets, <n>
538 commands were outstanding when the timeout was detected.
539
540
541 Connected command timeout for Target <id>.<lun>
542
543 This is usually a SCSI bus problem. Check cables and termination.
544
545
546 Target <id>.<lun> reverting to async. mode
547
548 A data transfer hang was detected. The driver attempts to eliminate
549 this problem by reducing the data transfer rate.
550
551
552 Target <id>.<lun> reducing sync. transfer rate
553
554 A data transfer hang was detected. The driver attempts to eliminate
555 this problem by reducing the data transfer rate.
556
557
558 Reverting to slow SCSI cable mode
559
560 A data transfer hang was detected. The driver attempts to eliminate
561 this problem by reducing the data transfer rate.
562
563
564 Target <id> reducing sync. transfer rate
565
566 A data transfer hang was detected. The driver attempts to eliminate
567 this problem by reducing the data transfer rate.
568
569
570 Target <id> reverting to async. mode
571
572 A data transfer hang was detected. The driver attempts to eliminate
573 this problem by reducing the data transfer rate.
574
575
576 Target <id> disabled wide SCSI mode
577
578 Due to problems on the SCSI bus, the driver goes into more conser‐
579 vative mode of operation to avoid further problems.
580
581
582 Reset SCSI bus failed
583
584 An attempt to reset the SCSI bus failed.
585
586
587 External SCSI bus reset
588
589 Another initiator reset the SCSI bus.
590
591
593 The fas hardware (FAS366) supports both Wide and Fast SCSI mode, but
594 fast20 is not supported. The maximum SCSI bandwidth is 20 MB/sec. Ini‐
595 tiator mode block sequence (IBS) is not supported.
596
598 The fas driver exports properties indicating per target the negotiated
599 transfer speed (target<n>-sync-speed), whether wide bus is supported
600 (target<n>-wide), scsi-options for that particular target (tar‐
601 get<n>-scsi-options), and whether tagged queuing has been enabled (tar‐
602 get<n>-TQ). The sync-speed property value is the data transfer rate in
603 KB/sec. The target<n>-TQ and the target<n>-wide property have value 1
604 to indicate that the corresponding capability is enabled, or 0 to indi‐
605 cate that the capability is disabled for that target. Refer to prt‐
606 conf(1M) (verbose option) for viewing the fas properties.
607
608 SUNW,fas,instance #1
609 Driver software properties:
610 name <target3-TQ> length <4>
611 value <0x00000001>.
612 name <target3-wide> length <4>
613 value <0x00000000>.
614 name <target3-sync-speed> length <4>
615 value <0x00002710>.
616 name <target3-scsi-options> length <4>
617 value <0x000003f8>.
618 name <target0-TQ> length <4>
619 value <0x00000001>.
620 name <pm_norm_pwr> length <4>
621 value <0x00000001>.
622 name <pm_timestamp> length <4>
623 value <0x30040346>.
624 name <scsi-options> length <4>
625 value <0x000003f8>.
626 name <scsi-watchdog-tick> length <4>
627 value <0x0000000a>.
628 name <scsi-tag-age-limit> length <4>
629 value <0x00000002>.
630 name <scsi-reset-delay> length <4>
631 value <0x00000bb8>.
632 Register Specifications:
633 Bus Type=0x3, Address=0x8800000, Size=10
634 Bus Type=0x3, Address=0x8810000, Size=40
635 Interrupt Specifications:
636 Interrupt Priority=0x35 (ipl 5)
637
638
639
640
641SunOS 5.11 20 Jun 1997 fas(7D)