]> git.baikalelectronics.ru Git - kernel.git/commit
gpu: ion: add CMA heap
authorBenjamin Gaignard <benjamin.gaignard@linaro.org>
Fri, 13 Dec 2013 22:24:44 +0000 (14:24 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 14 Dec 2013 16:57:17 +0000 (08:57 -0800)
commit0e526e5a77ed97356cc5ec0ac25e4ab781f5eba7
tree73f79c4602efcda4fd35de98d29c6eb68e43e98c
parent3031f7e1a105430c984ca38af39fac770495fa6d
gpu: ion: add CMA heap

New heap type ION_HEAP_TYPE_DMA where allocation is done with dma_alloc_coherent API.
device coherent_dma_mask must be set to DMA_BIT_MASK(32).
ion_platform_heap private field is used to retrieve the device linked to CMA,
if NULL the default CMA area is used.
ion_cma_get_sgtable is a copy of dma_common_get_sgtable function which should
be in kernel 3.5

Signed-off-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
[jstultz: modified patch to apply to staging directory]
Signed-off-by: John Stultz <john.stultz@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/android/ion/Makefile
drivers/staging/android/ion/ion.h
drivers/staging/android/ion/ion_cma_heap.c [new file with mode: 0644]
drivers/staging/android/ion/ion_heap.c
drivers/staging/android/ion/ion_priv.h