mirror of
https://github.com/followmsi/android_kernel_google_msm.git
synced 2024-11-06 23:17:41 +00:00
common: DMA-mapping: Add strongly ordered memory attribute
Strongly ordered memory is occasionally needed for some DMA allocations for specialized use cases. Add the corresponding DMA attribute. Change-Id: Idd9e756c242ef57d6fa6700e51cc38d0863b760d Signed-off-by: Laura Abbott <lauraa@codeaurora.org> Signed-off-by: Mitchel Humpherys <mitchelh@codeaurora.org>
This commit is contained in:
parent
0f53e5abb2
commit
c1386f095a
2 changed files with 10 additions and 0 deletions
|
@ -67,3 +67,12 @@ set on each call.
|
|||
Since it is optional for platforms to implement
|
||||
DMA_ATTR_NO_KERNEL_MAPPING, those that do not will simply ignore the
|
||||
attribute and exhibit default behavior.
|
||||
|
||||
DMA_ATTR_STRONGLY_ORDERED
|
||||
-------------------------
|
||||
|
||||
DMA_ATTR_STRONGLY_ORDERED allocates memory with a very restrictive type
|
||||
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.
|
||||
|
|
|
@ -16,6 +16,7 @@ enum dma_attr {
|
|||
DMA_ATTR_WRITE_COMBINE,
|
||||
DMA_ATTR_NON_CONSISTENT,
|
||||
DMA_ATTR_NO_KERNEL_MAPPING,
|
||||
DMA_ATTR_STRONGLY_ORDERED,
|
||||
DMA_ATTR_MAX,
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue