Subject: Re: Questions about NCR53C9X driver
To: None <tech-kern@netbsd.org>
From: Markus Baeurle <emw4maba@gp.fht-esslingen.de>
List: tech-kern
Date: 08/06/1998 02:15:10
Hi Michael!
In message <199808040136.TAA10473@terra.oscs.montana.edu>
"Michael L. Hitch" <osymh@terra.oscs.montana.edu> wrote:
> The 53c9x can only do synchronous transfers using DMA mode, so you
> have to disable synchronous negotiations by setting sc_minsync to 0.
Hmm, this was never done for the Cumana card AFAICT.
> The DMA transfer command that the MI driver writes to the 53c9x command
> register needs to be converted to a non-DMA command.
Only for NCRCMD_TRANS or for all commands? The Mac and Amiga drivers do the
first thing, the Cumana driver does the latter.
The problem is probably related to this.
Remember the two code snippets I posted? The one in ncr53c9x_msgout() never
seems to be executed anyway so I'm ignoring it for now.
If I suppress the sending of the command in ncr53c9x_intr() as done by the
checking of NCR_NODMA, everything is fine.
If I let it be sent, the kernel goes crazy while probing the devices. The
NCRCMD_DMA flag should have been removed in csc_write_reg, though. I haven't
had the time yet to remove it by hand to see if this makes any difference.
> The mac68k has a PIO-only driver in mac68k/obio/esp.c, which I used
> as the starting point for the Amiga driver.
Allen Briggs has pointed this out to. Thanks to both of you.
> The current Amiga driver does a combination of PIO and DMA transfers. The
> flsc driver was particularly nasty because I could not get DMA transfers to
> work when the driver was running a polled operation (during autoconf and
> when dumping). I had to do some trickery to delay the actual synchronous
> negotion until the driver started a non-polled operation. Even more fun
> and games was when the driver switches back to polled mode when writing
> a kernel dump. The target had to be switched back to asynchronous mode
> so it could use PIO transfers.
Sounds awful to me.
I hope it will be more straightforward for me after all.
--
So long, Markus
PGP key available on request or from
my homepage at http://www.gp.fht-esslingen.de/students/emw4maba