Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7a85a302 authored by Rohit Vaswani's avatar Rohit Vaswani Committed by Sathish Ambley
Browse files

common: DMA-mapping: add NO_DELAYED_UNMAP attribute



DMA_ATTR_NO_DELAYED_UNMAP specifies to the msm lazy mapping
driver that this buffer should be immediately unmapped once
it is freed.

Change-Id: I43e6a6058705502cf91bf5f0c530c3099cba06ae
Signed-off-by: default avatarRohit Vaswani <rvaswani@codeaurora.org>
parent d4bc64ea
Loading
Loading
Loading
Loading
+10 −0
Original line number Diff line number Diff line
@@ -109,3 +109,13 @@ of mapping (no unaligned accesses, no re-ordering, no write merging, no
buffering, no pre-fetching). This has severe performance penalties and
should not be used for general purpose DMA allocations. It should only
be used if one of the restrictions on strongly ordered memory is required.

DMA_ATTR_NO_DELAYED_UNMAP
-------------------------

DMA_ATTR_NO_DELAYED_UNMAP is used only by the msm specific lazy mapping
feature. By default, the lazy mapping and unmapping holds an additional
reference so that when the buffer is freed, the mapping is not destroyed
and can be re-used. By specifying this attribute, an additional reference
will NOT be held by the lazy mapping code and it will be released as soon
as the buffer is freed.
+1 −0
Original line number Diff line number Diff line
@@ -20,6 +20,7 @@ enum dma_attr {
	DMA_ATTR_FORCE_CONTIGUOUS,
	DMA_ATTR_STRONGLY_ORDERED,
	DMA_ATTR_SKIP_ZEROING,
	DMA_ATTR_NO_DELAYED_UNMAP,
	DMA_ATTR_MAX,
};