summaryrefslogtreecommitdiffstats
path: root/sys/kern/subr_busdma_bufalloc.c
Commit message (Collapse)AuthorAgeFilesLines
* Create an architecture-agnostic buffer pool manager that uses uma(9) tocognet2012-12-201-0/+174
manage a set of power-of-2 sized buffers for bus_dmamem_alloc(). This allows the caller to provide the back-end allocator uma allocator, allowing full control of the memory pages backing the pool. For convenience, it provides an optional builtin allocator that provides pages allocated with the VM_MEMATTR_UNCACHEABLE attribute, for managing pools of DMA buffers for BUS_DMA_COHERENT or BUS_DMA_NOCACHE. This also allows the caller to specify a minimum alignment, and it ensures that all buffers start on a boundary and have a length that's a multiple of that value, to avoid using buffers that trigger partial cache line flushes. Submitted by: Ian Lepore <freebsd@damnhippie.dyndns.org>
OpenPOWER on IntegriCloud