Adding support for WC (write-combining) memory to bus_dma

Peter Jeremy peter at rulingia.com
Thu Jul 12 23:20:27 UTC 2012


On 2012-Jul-12 10:40:27 -0400, John Baldwin <jhb at freebsd.org> wrote:
>contigmalloc().  In fact, even better is to call kmem_alloc_contig() directly
>rather than using contigmalloc().
...
>Peter, this is somewhat orthognal (but related) to your bus_dma patch which is
>what prompted me to post this.

Overall, the change seems good to me.  My sole thought on the API was
whether the actual attribute should be passed, rather than having a
couple of new BUS_DMA_ flags but you've addressed that in a followup.

One change is that previously allocated memory was all charged to
M_DEVBUF via the malloc_type_allocated() call in contigmalloc()
whereas now only small allocations are counted.  This would seem to
indicate that large bus_dmamem_alloc() allocations won't be visible in
(eg) "vmstat -m".

-- 
Peter Jeremy
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-current/attachments/20120712/01208e46/attachment.pgp


More information about the freebsd-current mailing list