low level SCSI drivers

Frans Orsel (orsel@cs.utwente.nl)
Tue, 05 Aug 1997 09:50:02 +0200

Hi, I already posted this to the Linux-SCSI mailing list but I didn't get an
answer :-(, so I'll try it here.

I'm currently working on writing drivers for a PCI card with a number of
devices on it. One of the devices will be an Adaptec AIC-33C96A chip. (The
card isn't finished yet). I split up the driver design in two drivers, a
character driver to control the other (three) devices and a low-level scsi
driver to control the AIC-33C96A. I just finished the basics of the character
driver, i.e.
framework and detection. Now I would like to start on the low-level driver.

Questions I have:

1. Is there already a low-level driver for this SCSI controller available? I
looked at the aic7xxx driver but I think it is too different from the 33C96A.
The 33C96A uses something called Write Control Sequences, but I think they
are not the same as the sequences used in the aic7xxx driver.

2. Is there any documentation on the low-level SCSI interface other than the
source? I really liked the four articles from Alessandro Rubini in Linux
Journal about writing modularized drivers.

3. Is it possible to talk to the driver directly and not through the generic
SCSI driver, for example with IOCTLS?
The PCI card has an off-line and on-line mode. In off-line mode it should act
as a normal host adapter giving access to any devices on the SCSI bus. In
on-line mode the controller is used to stream network data to a SCSI disk. It
should not be interrupted by the computer at this time, but the controller is
still controlled by the low-level driver. What I want is to tell the low-level
driver to stop supporting the generic driver and any calls from the OS to any
device on the SCSI bus and to load a specific sequence in the controller to
enable streaming.
I have seen that the mid-level SCSI driver can receive commands through the
procfs by writing something to /proc/scsi/scsi. Is this the right way to do it?
Is it not better to let the low level SCSI driver have a major and minor so it
can be reached through the normal device interface?

4. Could you give an estimate of how much work/time it takes to write a
complete low-level driver?

That's all for now, thanks in advance,

Frans Orsel