Subject: Re: FreeBSD Bus DMA (was Re: AdvanSys board support)
To: Jonathan Stone <jonathan@DSG.Stanford.EDU>
From: Matt Thomas <email@example.com>
Date: 06/11/1998 21:46:45
>But how is the bus-dma layer supposed to get at the map itself if the
>only way to construct the map is ot call the _driver's_ callback?
>This makes no sense to me at all. It's the same issue as with the
>outboard bus TLBs (mapping registers): if you need a virtual-to-physical
>address map for every page in the DMA buffer, you need the dmamap;
>and in your design, the bus layer itself cant' get at it.
On "trivial" implementations, there is no need for the dmamap
to contain the segment list so why both. For those implementations
that are not trivial and since the dmamap *is* opaque, the
implementation can save away the segment list for its own
use. But the driver will never be able to access except for via
This to me seems to a net win since on thoses buses with simple
implementations, you get a net savings of memory. For those with
not, you haven't lost anything (except for the translucentness
The only "detail" seems to be when the callback occurs. I
personally would favor that it must occur to the call to
bus_dmamap_load unless a BUS_DMA_QUEUE is passed as a flag.
Matt Thomas Internet: firstname.lastname@example.org
3am Software Foundry WWW URL: http://www.3am-software.com/bio/matt/
Nashua, NH Disclaimer: I disavow all knowledge of this message