SCSI (Re: Inits, CDEVs and A/UX 2.0)

Matthias Urlichs urlichs at smurf.sub.org
Wed Apr 3 06:56:27 AEST 1991


In comp.unix.aux, article <12852 at goofy.Apple.COM>,
  ksand at Apple.COM (Kent Sandvik) writes:
< 
< The _SCSIDispatch trap is not implemented, so anything that tries to
< use this trap would have problems.
< 
So you write an INIT which implements _SCSIDispatch. The trap then opens the
appropriate device and translates your command into meaningful ioctl calls.
Not really difficult if you concentrate on a 95% solution (which in the real
world is sufficient for 99.5% of all existing drivers).

< I'm curious to know what traps and parameter blocks you used.
< 
Standard Inside Mac IV, except that there's no SCSIstatus, the timeout is
calculated from the command, and TIBs must contain one data transfer and one
optional loop command. (No driver I tested did anything else anyway.)

The notable exception is SilverLining, which even in its present form insists
on directly accessing SCSI hardware to test the bus status instead of using
the appropriate SCSIDispatch call. Not good.
I had to set the appropriate bit in the HWConf flags because too many
applications test that bit when they really want to test whether
_SCSIDispatch exists.

< >Debugging SCSI without an appropriate analyzer (and also no terminal to use
< >with the kernel debugger, if necessary) is next to impossible.
< >I'd like some help from anybody with the appropriate facilities and/or
< >expertise, in order to get that bug out...
< 
< Try to use the kernel debugger available in A/UX 2.0. Information
< about using the debugger should be in the A/UX Dev Driver's manual.

The problem is that the kernel debugger needs a second Mac with the
appropriate sources available, and a serial connection. I don't have kernel
sources (the dev driver stuff is not really sufficient for that kind of
hangup problem -- the most common case is that the A/UX itself still runs
without problems, but the SCSI subsystem hangs) and a second Mac is also not
available either.
A related problem is that I don't know how to prevent my driver and another
SCSI driver (eg. the standard A/UX SCSI stuff) to access the same drive at
the same time without locking the entire bus.

As I said, knowledgeable help with this would be appreciated.

-- 
Matthias Urlichs -- urlichs at smurf.sub.org -- urlichs at smurf.ira.uka.de     /(o\
Humboldtstrasse 7 - 7500 Karlsruhe 1 - FRG -- +49-721-621127(0700-2330)   \o)/



More information about the Comp.unix.aux mailing list