[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <8b453664-13b6-430c-a865-9675edcdf369@yoseli.org>
Date: Tue, 28 Jan 2025 07:43:23 +0100
From: Jean-Michel Hautbois <jeanmichel.hautbois@...eli.org>
To: Christoph Hellwig <hch@...radead.org>
Cc: Geert Uytterhoeven <geert@...ux-m68k.org>,
Greg Ungerer <gerg@...ux-m68k.org>, linux-m68k@...ts.linux-m68k.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/2] arch: m68k: Add DMA mapping operations for Coldfire
M5441x
On 28/01/2025 07:40, Christoph Hellwig wrote:
> On Tue, Jan 28, 2025 at 07:33:37AM +0100, Jean-Michel Hautbois wrote:
>>> Arch dma code should not implement DMA OPS, but use the generic
>>> dma-direct code with the right helpes for handling coherency. This
>>> variant looks like it should be using the DMA_COHERENT_POOL allocator
>>> for dma coherent memory.
>>
>> Thanks for your answer.
>> I am not sure to understand it though :-) because I can see a few
>> dma_map_ops implementations in arch code.
>
> The last one left for the direct mapping are arm32 and parisc, and
> they should go away eventually.
>
>> I tried to let dma_direct do the
>> work, I can't remember exactly what happened but it was not great :-).
>> I can give it a second try.
>
> It really should not be hard. The dynamic mappings already work fine
> as m68k is using the generic code. So the only thing you want is
> to dip into the glonal pool for coherent allocations. For that you
> need to select the DMA_GLOBAL_POOL config option and fill the pool
> with dma_init_global_coherent().
>
Isn't it done in patch 1/2 ? Or did I miss something ?
JM
Powered by blists - more mailing lists