linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: vinod.koul@intel.com (Vinod Koul)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v7 2/2] dma: Add Xilinx AXI Video Direct Memory Access Engine driver support
Date: Wed, 16 Apr 2014 15:56:57 +0530	[thread overview]
Message-ID: <20140416102657.GS32284@intel.com> (raw)
In-Reply-To: <CA+mB=1LDGCY3sN5sL1giOwwqHjD8gG74Yy0dXRS8s+MtDOvxHw@mail.gmail.com>

On Wed, Apr 16, 2014 at 03:41:34PM +0530, Srikanth Thokala wrote:
> On Wed, Apr 16, 2014 at 2:36 PM, Vinod Koul <vinod.koul@intel.com> wrote:
> > On Fri, Mar 28, 2014 at 05:33:42PM +0530, Srikanth Thokala wrote:
> >> This is the driver for the AXI Video Direct Memory Access (AXI
> >> VDMA) core, which is a soft Xilinx IP core that provides high-
> >> bandwidth direct memory access between memory and AXI4-Stream
> >> type video target peripherals. The core provides efficient two
> >> dimensional DMA operations with independent asynchronous read
> >> and write channel operation.
> >>
> >> This module works on Zynq (ARM Based SoC) and Microblaze platforms.
> >
> > Okay the series is fine and was going to apply it BUT
> > 1) need ack on DT patch..
> > 2) issues below on managing the descriptor and resetting the cookie :(
> 
> Ok.
> 
> >
> >> +
> >> +/**
> >> + * xilinx_vdma_tx_descriptor - Allocate transaction descriptor
> >> + * @chan: Driver specific VDMA channel
> >> + *
> >> + * Return: The allocated descriptor on success and NULL on failure.
> >> + */
> >> +static struct xilinx_vdma_tx_descriptor *
> >> +xilinx_vdma_alloc_tx_descriptor(struct xilinx_vdma_chan *chan)
> >> +{
> >> +     struct xilinx_vdma_tx_descriptor *desc;
> >> +     unsigned long flags;
> >> +
> >> +     if (chan->allocated_desc)
> >> +             return chan->allocated_desc;
> > ??
> >
> >> +
> >> +     desc = kzalloc(sizeof(*desc), GFP_KERNEL);
> >> +     if (!desc)
> >> +             return NULL;
> >> +
> >> +     spin_lock_irqsave(&chan->lock, flags);
> >> +     chan->allocated_desc = desc;
> > ah why do you need this?
> >
> > So this essentailly prevents you from preparing two trasactions at same time as
> > you would overwrite??
> 
> This will allow to queue up multiple segments on to a single
> transaction descriptor.
> User will submit this single desc and in the issue_pending() we decode multiple
> segments and submit to SG HW engine.  We free up the allocated_desc when it is
> submitted to the HW.  This is added after my discussion with Jaswinder, to best
> utilize HW SG engine.

I think best utilization of HW SG engine would happen if we collate the pending
list when you start dma....

-- 
~Vinod

  reply	other threads:[~2014-04-16 10:26 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-28 12:03 [PATCH v7 0/2] Add Xilinx AXI Video DMA Engine driver Srikanth Thokala
2014-03-28 12:03 ` [PATCH v7 1/2] dma: Add Xilinx Video DMA DT Binding Documentation Srikanth Thokala
2014-04-02 11:39   ` Michal Simek
2014-03-28 12:03 ` [PATCH v7 2/2] dma: Add Xilinx AXI Video Direct Memory Access Engine driver support Srikanth Thokala
2014-04-16  9:06   ` Vinod Koul
2014-04-16 10:11     ` Srikanth Thokala
2014-04-16 10:26       ` Vinod Koul [this message]
2014-04-16 11:31         ` Srikanth Thokala

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20140416102657.GS32284@intel.com \
    --to=vinod.koul@intel.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).