All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stephen Warren <swarren@wwwdotorg.org>
To: Dmitry Osipenko <digetx@gmail.com>, ldewangan@nvidia.com
Cc: vinod.koul@intel.com, linux-tegra@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH V2] dma: tegra: avoid channel lock up after free
Date: Tue, 30 Oct 2012 12:05:27 -0600	[thread overview]
Message-ID: <509016E7.800@wwwdotorg.org> (raw)
In-Reply-To: <1351552833-4132-1-git-send-email-digetx@gmail.com>

On 10/29/2012 05:20 PM, Dmitry Osipenko wrote:
> Fixed channel "lock up" after free.
> 
> Lock scenario: Channel 1 was allocated and prepared as slave_sg, used and freed.
> Now preparation of cyclic dma on channel 1 will fail with err "DMA configuration
> conflict" because tdc->isr_handler still selected to handle_once_dma_done.
> 
> This happens because tegra_dma_abort_all() won't be called on channel freeing
> if pending list is empty or channel not busy. We need to clear isr_handler
> on channel freeing to avoid locking. Also I added small optimization to prepare
> functions, so current channel type checked before making allocations.

Reviewed-by: Stephen Warren <swarren@nvidia.com>

I believe this looks OK. However, I would like Laxman to also ack/review
this since he wrote the driver.

  parent reply	other threads:[~2012-10-30 18:05 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-28 14:17 [PATCH 2/2] dma: tegra20-apbdma: channel freeing correction Dmitry Osipenko
2012-10-28 14:17 ` Dmitry Osipenko
2012-10-29 15:27 ` Stephen Warren
2012-10-29 23:20   ` [PATCH V2] dma: tegra: avoid channel lock up after free Dmitry Osipenko
2012-10-29 23:28     ` Dmitry Osipenko
2012-10-30 18:05     ` Stephen Warren [this message]
2012-10-31 14:58     ` Laxman Dewangan
     [not found] ` <1351433873-14082-1-git-send-email-digetx-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2012-10-31 14:48   ` [PATCH 2/2] dma: tegra20-apbdma: channel freeing correction Laxman Dewangan
2012-10-31 14:48     ` Laxman Dewangan
2012-10-31 14:48   ` Laxman Dewangan
2012-10-31 14:48     ` Laxman Dewangan

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=509016E7.800@wwwdotorg.org \
    --to=swarren@wwwdotorg.org \
    --cc=digetx@gmail.com \
    --cc=ldewangan@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=vinod.koul@intel.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.