Re: [RFC PATCH 0/3] prerequisites for device reserved local mem rework
From: Christoph Hellwig
Date: Fri May 10 2019 - 11:55:19 EST
On Fri, May 10, 2019 at 04:03:37PM +0100, Robin Murphy wrote:
> Hi Laurentiu,
>
> On 10/05/2019 15:56, wrote:
>> From: Laurentiu Tudor <laurentiu.tudor@xxxxxxx>
>>
>> For HCs that have local memory, replace the current DMA API usage
>> with a genalloc generic allocator to manage the mappings for these
>> devices.
>> This is in preparation for dropping the existing "coherent" dma
>> mem declaration APIs. Current implementation was relying on a short
>> circuit in the DMA API that in the end, was acting as an allocator
>> for these type of devices.
>>
>> Only compiled tested, so any volunteers willing to test are most welcome.
>
> Based on my diggings into this in the past, I would expect that you need to
> do something about hcd_alloc_coherent() as well.
Yep. And it might make sense to share the code for that and the
ohci internal allocations with a helper.