Subject: SA110 DMA buffer problem
To: None <port-arm32@netbsd.org>
From: Bjorn Roth <bjorn.roth@netinsight.se>
List: port-arm32
Date: 02/11/2000 17:26:07
Hi,

I recently posted about problems when using the DC21285 as PCI DMA
master. Well, I've scrapped that idea for now. The DMA controller in the
in-house ASIC I'm writing the driver for is much simpler, but it works,
and its register readouts makes sense.

However, I have some problems with the bus_dma routines in NetBSD 1.4.1.
I've set up my DMA buffers with the bus_dma calls (alloc, map, create,
load). Doing DMA to these buffers works, but when I then try to write
from the CPU to a buffer, I get a page fault because the page is
non-writable (!). Then the fault handler itself faults, and a nice loop
is created which effectively locks the kernel.

The strange thing is, if I do some writing to the buffers before the
first DMA transfer, it works fine... almost. No page faults, but when I
enter DDB after a couple of DMA transfers, I get a load of "userret: spl
level=11 on entry" and the kernel locks up, hard.

I'm grateful for any hints!

/BR

--
Björn Roth, M.Sc                 bjorn.roth@softronic.se
Softronic Konsult AB             +46-(0)708-813146