Skip to content

Commit

Permalink
dmaengine: idma64: replace spin_lock_irqsave with spin_lock
Browse files Browse the repository at this point in the history
idma64_chan_irq() is invoked in hardirq handle function, it is unnecessary
to call spin_lock_irqsave.

Signed-off-by: Zhaoxiong Yuan <yuanzhx326@gmail.com>
Signed-off-by: Vinod Koul <vkoul@kernel.org>
  • Loading branch information
Zhaoxiong Yuan authored and Vinod Koul committed Sep 11, 2018
1 parent 5b394b2 commit 7645d26
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions drivers/dma/idma64.c
Original file line number Diff line number Diff line change
Expand Up @@ -142,9 +142,8 @@ static void idma64_chan_irq(struct idma64 *idma64, unsigned short c,
{
struct idma64_chan *idma64c = &idma64->chan[c];
struct idma64_desc *desc;
unsigned long flags;

spin_lock_irqsave(&idma64c->vchan.lock, flags);
spin_lock(&idma64c->vchan.lock);
desc = idma64c->desc;
if (desc) {
if (status_err & (1 << c)) {
Expand All @@ -161,7 +160,7 @@ static void idma64_chan_irq(struct idma64 *idma64, unsigned short c,
if (idma64c->desc == NULL || desc->status == DMA_ERROR)
idma64_stop_transfer(idma64c);
}
spin_unlock_irqrestore(&idma64c->vchan.lock, flags);
spin_unlock(&idma64c->vchan.lock);
}

static irqreturn_t idma64_irq(int irq, void *dev)
Expand Down

0 comments on commit 7645d26

Please sign in to comment.