On Wed, Jan 10, 2018 at 05:02:30PM +, Robin Murphy wrote:
>>>
>>> Aren't we leaking the pages here?
>>
>> Yes, that free_pages got lost somewhere in the rebases, I've added
>> it back.
>
> Cool.
FYI, here is the fixed version, I don't want to re-send the whole
series for this fix:
On 10/01/18 15:46, Christoph Hellwig wrote:
On Wed, Jan 10, 2018 at 12:22:18PM +, Robin Murphy wrote:
+ if (phys_addr == SWIOTLB_MAP_ERROR)
+ goto out_warn;
-/* Confirm address can be DMA'd by device */
- if (dev_addr + size - 1 > dma_mask) {
On Wed, Jan 10, 2018 at 12:22:18PM +, Robin Murphy wrote:
>> +if (phys_addr == SWIOTLB_MAP_ERROR)
>> +goto out_warn;
>> - /* Confirm address can be DMA'd by device */
>> -if (dev_addr + size - 1 > dma_mask) {
>> -printk("hwdev DMA mask
On 10/01/18 08:09, Christoph Hellwig wrote:
Factor out a new swiotlb_alloc_buffer helper that allocates DMA coherent
memory from the swiotlb bounce buffer.
This allows to simplify the swiotlb_alloc implemenation that uses
dma_direct_alloc to try to allocate a reachable buffer first.
Factor out a new swiotlb_alloc_buffer helper that allocates DMA coherent
memory from the swiotlb bounce buffer.
This allows to simplify the swiotlb_alloc implemenation that uses
dma_direct_alloc to try to allocate a reachable buffer first.
Signed-off-by: Christoph Hellwig
---