Subject: Re: drivers for 5380/9224 on KA410/KA43 (rather long)
To: None <port-vax@NetBSD.ORG>
From: Allison J Parent <allisonp@world.std.com>
List: port-vax
Date: 03/03/1998 08:36:28
<- At the time these drivers were written, I had access to an 2000 and
<  an 3100/76. Thus I tried to make it work on these machines.

>From what I know they are the most different from each other of any 3100
and 2000.  Owing to the 3100m76 is not supported by ultrix I suspect it is 
also different from the rest of the 3100s.

<have to be mutually exclusive. In the meantime and according to the 
<discussions on port-vax to me it looks like there are two DMA controller
<on KA410, one internal to the HDC9224 and one external somehow combined
<with NCR5380. The problems arising from two DMA logics accessing the sam
<buffer would explain most of the KA410's limitations in DMA.

Or one controller shared by both.

<BTW: From the docs I have it seems that HDC9224 is at the same address
<     for all VAXen, same holds for NCR-1 and NCR-2, for SCSI-DMA and for
<     interrupt-registers. Thus at least some parts of the existing driver
<     should be usable for other models 3100...
<------------------------------

No surprize as the vms and ultrix engineering gang tend to get real upset 
if the same device is moved around by vax hardware engineering.  It's 
(was?) also an internal design spec point.

<------------------------------
<The NCR driver is a completely different beast, since machine-independen

You can say that again!


<         * VS2000 implements DMA-Count-Register (dcreg) as 16-bit registe

VS2k dmas to a fixed buffer.

<         * while VS3100 implements this as 31-bit register (17 bit effect

3100 dma is to 128k buffer in main ram areas.

<         * VS2000's DMA area is 16K, DMA Address register (dareg) is a
<         * 8-bit register, offset into DMA area is written as two bytes.
<         * VS3100's DMA area is 128K, DMA Address register is a 32-bit
<         * register, offset into DMA area is written as one longword.
<         * (Since currently we're using offset 0x00 only, it somehow work

AS a hardware person this is dangerous as it likely works due to default 
zeros or ones loded and not an explicit operation.

It also suggests differences in the hardware that could lead to other 
problems.  The off by one problem is likely linked to this.

<PS: In the meantime I think it could have been better to have to differen
<    implementations for NCR-drivers, one for KA410 and one for KA43. But
<    due to lack of spare time I never tried that. Also I have to say tha
<    because of my lack of knowledge/experience/time I can't rewrite thes
<    drivers esp. since I don't have my 2000 anymore. If I can be of any
<    help to the one rewriting these drivers I'm willing to help.

Generally I'd consider this advisable.  Smaller and specific is always 
better than larger more general.  Tackling this would be more than I could 
do as all my C expereices are on machines with 8bit word lengths(read 
small and subset of C).  The upside is I do have a 3100m76, VS2000, and 
MV-II systems and the VAX C compiler.


Allison