Commit Graph

88 Commits

Author SHA1 Message Date
jdolecek 08733c9d51 add NCR_VARIANT_NCR53C90_86C01 "NCR53C90 (86C01)"
treat exactly like NCR_VARIANT_ESP100
2001-12-03 23:27:31 +00:00
lukem 2565646230 don't need <sys/types.h> when including <sys/param.h> 2001-11-15 09:47:59 +00:00
lukem a4bae8b066 add/cleanup RCSID 2001-11-13 13:14:31 +00:00
tsutsui 064be15283 Use common macro to check message length. 2001-11-04 12:03:41 +00:00
tsutsui 5309850228 Fix timeout overflow caused by "scsictl format" on machines HZ==100. 2001-07-26 15:51:04 +00:00
chs 864f123d5a add a missing newline in a printf. 2001-07-10 00:36:36 +00:00
thorpej 0884f20bf7 bzero -> memset 2001-07-07 16:13:44 +00:00
thorpej 7711ad565b bcopy -> memcpy 2001-07-07 15:53:13 +00:00
petrov 9d59ae231c adjust fas register fields names 2001-05-23 18:32:26 +00:00
bouyer 8aa2f73d43 Enable tagged queuing again; should work now with scsipi_base rev 1.42 2001-05-18 12:57:42 +00:00
bouyer 19b0c05827 Ops, don't forget to increment li->used for each tagged command. 2001-04-30 13:58:32 +00:00
bouyer 1346d56311 - don't wait when called from interrupt context (basically this means we
can't sleep in HBA drivers)
- pool_get can fail, so return XS_RESOURCE_SHORTAGE instead of panic()
- don't try to bzero() a NULL pointer
2001-04-28 15:09:42 +00:00
bouyer 856411129e Disable tagged queuing for now, it causes commands timeouts.
Note that it's not worse since thorpej_scsipi integration: tagged queuing
was not used before, because of a tag message rejected at probe time.
2001-04-26 17:09:39 +00:00
bouyer 937a7a3ed9 Pull up the thorpej_scsipi branch to main branch.
This is a completely rewritten scsipi_xfer execution engine, and the
associated changes to HBA drivers. Overview of changes & features:
- All xfers are queued in the mid-layer, rather than doing so in an
  ad-hoc fashion in individual adapter drivers.
- Adapter/channel resource management in the mid-layer, avoids even trying
  to start running an xfer if the adapter/channel doesn't have the resources.
- Better communication between the mid-layer and the adapters.
- Asynchronous event notification mechanism from adapter to mid-layer and
  peripherals.
- Better peripheral queue management: freeze/thaw, sorted requeueing during
  recovery, etc.
- Clean separation of peripherals, adapters, and adapter channels (no more
  scsipi_link).
- Kernel thread for each scsipi_channel makes error recovery much easier
  (no more dealing with interrupt context when recovering from an error).
- Mid-layer support for tagged queueing: commands can have the tag type
  set explicitly, tag IDs are allocated in the mid-layer (thus eliminating
  the need to use buggy tag ID allocation schemes in many adapter drivers).
- support for QUEUE FULL and CHECK CONDITION status in mid-layer; the command
  will be requeued, or a REQUEST SENSE will be sent as appropriate.

Just before the merge syssrc has been tagged with thorpej_scsipi_beforemerge
2001-04-25 17:53:04 +00:00
tsutsui f39a68828d Make sure to check SC_ACCEL_TAGS in ncr53c9x_ioctl()
even if sync transfer is disabled or not supported.
2001-04-21 07:28:22 +00:00
tsutsui 64eed5859d Clean up ncr53c9x_select():
- Define NCR_F_SELATN3 for sc_features and use it to check if the chip
  supports SELATN3 command
- Make conditions of sending messages a bit simpler.
2001-04-21 05:35:20 +00:00
tsutsui f2e3f6d5d4 Cosmetics. (tab/space etc.) 2001-04-20 17:32:33 +00:00
petrov b0605f71d5 fas support added 2001-03-29 02:58:38 +00:00
eeh 905ef1b7fa Use the SCSIACCEL ioctl() to turn on TAG QUEUEs. 2001-01-19 23:04:23 +00:00
briggs 9a73f8b22b Make _sure_ that we do not use selatn3 when it is not present. Fixes a
problem on pmax reported by Izumi Tsutsui.  Tested also on alpha and mac68k.
2000-12-20 15:49:03 +00:00
eeh d1ab475964 Make the driver negotiate sync again and remove some (hopefully) superfluous
DELAY()s.
2000-12-20 03:19:34 +00:00
pk c6bd81f8a6 Fix reversed logic when setting setting sync-negotiation ability flag 2000-12-19 14:08:17 +00:00
briggs 7ea0edc288 If the target rejects a tag message, turn off tagged transfers for that target.
Also, adjust message/command construction in ncr53c9x_select() to work no
matter how the structure alignment works out (needed at least for m68k).
Tested by me on mac68k & alpha, and sanity-checked by eeh.
2000-12-18 23:39:44 +00:00
briggs d25ab824c8 Back out previous change. It appears to be in error. There is something
else that is causing the esp driver on the mac68k to fail miserably.
2000-12-17 04:38:29 +00:00
briggs 0debc0e91e At least the 53c96 does not work with the selatn3 command. Disable it
for both the 53c94 and 53c96.  This also addresses PR port-mac68k/11716.
2000-12-17 03:29:03 +00:00
eeh af770220fa Fix for chips that don't grok NCRCMD_SELATN3. 2000-12-10 19:25:07 +00:00
fvdl d26269e0a6 'error' was not initialized in the _ioctl function, potentially returning
!= 0 values in the non-error case.
2000-12-04 11:18:49 +00:00
eeh 03e0f9950a Fix bug in non-dma select code i added. 2000-12-03 23:25:24 +00:00
augustss a51ea43fd6 Make this compile again (on i386). 2000-12-01 04:37:54 +00:00
pk d736ce5086 We don't need <sys/proc.h>, <sys/user.h> and <machine/cpu.h>. 2000-11-30 23:21:39 +00:00
pk 55fa60c3e5 De-__P(). 2000-11-30 23:12:43 +00:00
pk 03903e1da8 KNF patrol. 2000-11-30 23:01:03 +00:00
thorpej 64222ad03a Fix some printf formats, and remove SPARC-specific debugging stuff. 2000-11-30 14:41:46 +00:00
pk 7006bcd449 Fix two cases of reversed arguments to printf(); 2000-11-30 09:58:03 +00:00
eeh 9e7aa98aa6 Add TAG QUEUE support to the ncr53c9x driver. 2000-11-30 00:19:25 +00:00
pk 4c54ce2034 Define ncr53c9x_ioctl() and use it to start sync negotiation. 2000-11-13 15:24:22 +00:00
nisimura 0c92b006c6 Fix negative timeout symptoms caused by integer multiply overflow,
which is revealed with larger HZ systems like NetBSD/pmax (256Hz)
and NetBSD/alpha (1024Hz) as reported by PR#8645.  Polled tape
drive access is done with maximum 6 hour timeout which ended up
with negative time and then confused SCSI bus severely.
2000-07-04 01:10:18 +00:00
tsutsui a12331c461 Oops, struct scsipi_adapter was changed recently. 2000-06-05 15:19:42 +00:00
nisimura 4371d91433 Have MI ncr53c9x_attach() the 2nd and 3rd arguments for scsipi_adater
and scsipi_device respectively, with size reduction of ncr53c9x_softc.
Specifying NULL instructs the driver to use default adapter and default
device codes. Every target port has ncr53c9x_attach(sc, NULL, NULL) anyway.
2000-06-05 07:59:50 +00:00
tsutsui c693409acb Nuke register declarations. 2000-03-29 13:57:51 +00:00
thorpej fc96443d15 New callout mechanism with two major improvements over the old
timeout()/untimeout() API:
- Clients supply callout handle storage, thus eliminating problems of
  resource allocation.
- Insertion and removal of callouts is constant time, important as
  this facility is used quite a lot in the kernel.

The old timeout()/untimeout() API has been removed from the kernel.
2000-03-23 07:01:25 +00:00
mycroft b58a073f39 There's no need to frob cfg4/cfg5 in _attach(), since _reset() does it. 2000-03-22 03:27:56 +00:00
tsutsui 979d79d931 Use sc_cfg4 for the Am53c974. 2000-03-20 05:48:28 +00:00
mycroft 41cd6b4fc9 Reset CFG4 and CFG5 correctly in the reset routine. 2000-03-20 00:49:42 +00:00
mycroft b8e1812629 For the ESP406/FAS408, add sc_cfg4 and sc_cfg5.
Add a detach routine, and do the addref/delref.
2000-03-19 21:25:49 +00:00
mycroft 744ccf496c Expose ncr53c9x_init(). 2000-03-18 22:18:57 +00:00
mycroft c0b35f72c2 Adjust ncr53c9x_intr() prototype. 2000-03-18 22:09:32 +00:00
matt 9f86839658 change Mb/s to MB/s (Megabit to megabyte). 2000-03-09 23:19:26 +00:00
pk 855fe23671 Prevent possible wayward loop. 2000-01-25 09:30:00 +00:00
mycroft f8934aa2f6 Modification to the previous:
We still have to preload the command, when selecting without ATN.  (We could
probably avoid this by being more careful in the interrupt handler...)
1999-11-10 05:02:53 +00:00