Thread (37 messages) 37 messages, 9 authors, 2019-07-08

use exact allocation for dma coherent memory

From: Christoph Hellwig <hch@lst.de>
Date: 2019-06-14 13:47:47
Also in: dri-devel, intel-gfx, linux-arm-kernel, linux-iommu, linux-media, linux-mm, linux-rdma, linux-s390, linux-wireless, lkml

Hi all,

various architectures have used exact memory allocations for dma
allocations for a long time, but x86 and thus the common code based
on it kept using our normal power of two allocator, which tends to
waste a lot of memory for certain allocations.

Switching to a slightly cleaned up alloc_pages_exact is pretty easy,
but it turns out that because we didn't filter valid gfp_t flags
on the DMA allocator, a bunch of drivers were passing __GFP_COMP
to it, which is rather bogus in too many ways to explain.  Arm has
been filtering it for a while, but this series instead tries to fix
the drivers and warn when __GFP_COMP is passed, which makes it much
larger than just adding the functionality.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help