lkml.org 
[lkml]   [2013]   [Jun]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH v2 3/6] dma: Add a jz4740 dmaengine driver
    On 05/30/2013 08:46 PM, Lars-Peter Clausen wrote:
    >>> +static int jz4740_dma_alloc_chan_resources(struct dma_chan *c)
    >>> +{
    >>> + struct jz4740_dmaengine_chan *chan = to_jz4740_dma_chan(c);
    >>> +
    >>> + chan->jz_chan = jz4740_dma_request(chan, NULL);
    >>> + if (!chan->jz_chan)
    >>> + return -EBUSY;
    >>> +
    >>> + jz4740_dma_set_complete_cb(chan->jz_chan, jz4740_dma_complete_cb);
    >>> +
    >>> + return 0;
    >> Sorry, I didnt reply on this one. The API expects you to allocate a pool of
    >> descriptors. These descriptors are to be used in .device_prep_xxx calls later.
    >
    > The size of the descriptor is not fixed, so they can not be pre-allocated. And
    > this is nothing new either, most of the more recently added dmaengine drivers
    > allocate their descriptors on demand.

    Vinod, are you ok with this explanation?

    - Lars


    \
     
     \ /
      Last update: 2013-06-10 19:41    [W:3.918 / U:0.120 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site