Re: [PATCH] staging: android: ion: Set the length of the DMA sg entries in buffer

2016-01-22 Thread Jon Medhurst (Tixy)
On Thu, 2016-01-21 at 16:58 -0800, Laura Abbott wrote: > On 01/21/2016 12:19 PM, Jon Medhurst (Tixy) wrote: [...] > > If sg_dma_len() is correct or acceptable then it seems to me that the > > ION code should set that length. Especially as the comment in the code > > impli

[PATCH] staging: android: ion: Set the length of the DMA sg entries in buffer

2016-01-21 Thread Jon Medhurst (Tixy)
From: Liviu Dudau ion_buffer_create() will allocate a buffer and then create a DMA mapping for it, but it forgot to set the length of the page entries. Signed-off-by: Liviu Dudau Signed-off-by: Jon Medhurst ---

Re: [PATCH] staging: android: ion: Set the length of the DMA sg entries in buffer

2016-01-21 Thread Jon Medhurst (Tixy)
On Thu, 2016-01-21 at 09:39 -0800, Laura Abbott wrote: > On 01/21/2016 03:57 AM, Jon Medhurst (Tixy) wrote: > > From: Liviu Dudau <liviu.du...@arm.com> > > > > ion_buffer_create() will allocate a buffer and then create a DMA > > mapping for it, but it forgot to s

Re: [PATCH] staging: ion: ion_cma_heap: Don't directly use dma_common_get_sgtable

2015-07-17 Thread Jon Medhurst (Tixy)
On Fri, 2015-07-17 at 16:21 +0100, Robin Murphy wrote: This also begs the question as to what happens if the memory region _is_ contiguous but is in highmem or an ioremapped region. Should a device always provide dma_ops for that case? Because I believe the current implementation of

[PATCH] staging: ion: ion_cma_heap: Don't directly use dma_common_get_sgtable

2015-07-17 Thread Jon Medhurst (Tixy)
Use dma_get_sgtable rather than dma_common_get_sgtable so a device's dma_ops aren't bypassed. This is essential in situations where a device uses an IOMMU and the physical memory is not contiguous (as the common function assumes). Signed-off-by: Jon Medhurst t...@linaro.org --- This also begs