lkml.org 
[lkml]   [2010]   [Aug]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: dmaengine questions
From
On Thu, Aug 12, 2010 at 8:00 AM, Sascha Hauer <s.hauer@pengutronix.de> wrote:
> Hi,
>
> I am currently looking into implementing the Freescale i.MX SDMA engine
> into the dmaengine API. The SDMA engine can handle sg transfers from/to
> devices. During implementation some questions came up.
>
> On the i.MX we already have a DMA engine which can do slave dma
> transfers, the IPU (drivers/dma/ipu/), which is exclusively used for
> image operations. My problem is that I found no way for the clients
> to select which DMA engine to use as both have the same capabilities
> (DMA_SLAVE).

Yes, if you need finer grained matching of channels, beyond simple
capability matching, this is the intended purpose of the
'dma_filter_fn' and 'filter_param' arguments to dma_request_channel.
Dmaengine will pass all available channels that match the base
capability to the filter function for further, usually architecture
specific, discrimination.

> For the SDMA engine the clients have to pass some platform specific data
> to the SDMA engine (dma request line, word width and the like). The
> current mechanism is to pass this data through the dma_chan->private
> field, which seems more like tunneling instead of passing the data as we
> lose type safety. Are there any ideas to improve this?

Hopefully dma_chan->private can eventually be phased out in favor of
Linus' dma_slave_config scheme [1].

--
Dan

[1]: http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=c156d0a5


\
 
 \ /
  Last update: 2010-08-12 21:17    [W:0.088 / U:0.140 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site