[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20201007155533.GZ2968@vkoul-mobl>
Date: Wed, 7 Oct 2020 21:25:33 +0530
From: Vinod Koul <vkoul@...nel.org>
To: Peter Ujfalusi <peter.ujfalusi@...com>
Cc: nm@...com, ssantosh@...nel.org, robh+dt@...nel.org,
vigneshr@...com, dan.j.williams@...el.com, t-kristo@...com,
lokeshvutla@...com, linux-arm-kernel@...ts.infradead.org,
linux-kernel@...r.kernel.org, devicetree@...r.kernel.org,
dmaengine@...r.kernel.org
Subject: Re: [PATCH 01/18] dmaengine: of-dma: Add support for optional router
configuration callback
On 07-10-20, 11:08, Peter Ujfalusi wrote:
> Not really. In DT an event triggered channel can be requested via router
> (when this is used) for example:
>
> dmas = <&inta_l2g a b c>;
> a - the input number of the DMA request in l2g
> b - edge or level trigger to be selected
> c - ASEL number for the channel for coherency
>
> The l2g router driver then translate this to:
> <&main_bcdma 1 0 c>
> 1 - Global trigger 0 is used by the DMA
> 0 - ignored
> c - ASEL number.
>
> The router needs to send an event which is going to be received by the
> channel we have picked up, this event number can only be known when we
> do have the channel.
>
> So the flow in this case:
> router converts the dma_spec for the DMA, but it does not yet know what
> is the event number it has to use.
> The BCDMA driver will pick an available bchan and notes that the
> transfers will be triggered by global event 0.
> When we have the channel, the core saves the router information and
> calls the device_router_config of BCDMA.
> In there we call back to the router and give the event number it has to
> use to send the trigger for the channel.
Ah that is intresting, so you would call router driver foo_set_event()
and would send the event number, why not call that API from alloc
channel or even xlate? Why do you need new callback?
Or did i miss something..
--
~Vinod
Powered by blists - more mailing lists