tech-net archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: rbuf starvation in the iwn driver
On Wed, Apr 07, 2010 at 08:30:00PM -0600, Sverre Froyen wrote:
> > If you want memory you can DMA to/from, I think you need to use
> > bus_dmamem_alloc().
>
> Yes, reading the man page for bus_dmamap_load etc. I see that is required. Is
> this a requirement for NetBSD but not for OpenBSD? Look at this code fragment
> from the OpenBSD iwn driver:
it's not required in NetBSD if the proper bus_dma operations are used
on the memory, but it can improve performances.
bus_dmamem_alloc() return dma-safe memory, in the sense that it should
not require e.g. bounce buffers.
If you're doing the dma to arbitrary memory, the bus_dma call will check if
it's dma_safe and if it's not, will allocate bounce buffers and
copy data from/to it.
--
Manuel Bouyer <bouyer%antioche.eu.org@localhost>
NetBSD: 26 ans d'experience feront toujours la difference
--
Home |
Main Index |
Thread Index |
Old Index