FROMLIST: dma-buf: dma-heap: Keep track of the heap device struct

Keep track of the heap device struct.

This will be useful for special DMA allocations
and actions.

Signed-off-by: John Stultz <john.stultz@linaro.org>
Link: https://lore.kernel.org/lkml/20201110034934.70898-7-john.stultz@linaro.org/
Bug: 170887642
Change-Id: I55b8df5fd9fd46795a8f0171318895297d2dd379
This commit is contained in:
John Stultz
2020-05-07 20:08:13 +00:00
parent a54c7055d9
commit c8bdd32555
2 changed files with 35 additions and 9 deletions

View File

@@ -50,6 +50,15 @@ struct dma_heap_export_info {
*/
void *dma_heap_get_drvdata(struct dma_heap *heap);
/**
* dma_heap_get_dev() - get device struct for the heap
* @heap: DMA-Heap to retrieve device struct from
*
* Returns:
* The device struct for the heap.
*/
struct device *dma_heap_get_dev(struct dma_heap *heap);
/**
* dma_heap_add - adds a heap to dmabuf heaps
* @exp_info: information needed to register this heap