Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dmaengine: pxa_dma: remove redundant irqsave and irqrestore in hardIRQ

Running in hardIRQ, disabling IRQ is redundant since hardIRQ has disabled
IRQ. This patch removes the irqsave and irqstore to save some instruction
cycles.

Signed-off-by: Barry Song <song.bao.hua@hisilicon.com>
Acked-by: Robert Jarzmik <robert.jarzmik@free.fr>
Cc: Daniel Mack <daniel@zonque.org>
Cc: Haojian Zhuang <haojian.zhuang@gmail.com>
Link: https://lore.kernel.org/r/20201027215252.25820-11-song.bao.hua@hisilicon.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>

authored by

Barry Song and committed by
Vinod Koul
0e15ca5f 618a8e38

+2 -3
+2 -3
drivers/dma/pxa_dma.c
··· 606 606 struct pxad_chan *chan = phy->vchan; 607 607 struct virt_dma_desc *vd, *tmp; 608 608 unsigned int dcsr; 609 - unsigned long flags; 610 609 bool vd_completed; 611 610 dma_cookie_t last_started = 0; 612 611 ··· 615 616 if (dcsr & PXA_DCSR_RUN) 616 617 return IRQ_NONE; 617 618 618 - spin_lock_irqsave(&chan->vc.lock, flags); 619 + spin_lock(&chan->vc.lock); 619 620 list_for_each_entry_safe(vd, tmp, &chan->vc.desc_issued, node) { 620 621 vd_completed = is_desc_completed(vd); 621 622 dev_dbg(&chan->vc.chan.dev->device, ··· 657 658 pxad_launch_chan(chan, to_pxad_sw_desc(vd)); 658 659 } 659 660 } 660 - spin_unlock_irqrestore(&chan->vc.lock, flags); 661 + spin_unlock(&chan->vc.lock); 661 662 wake_up(&chan->wq_state); 662 663 663 664 return IRQ_HANDLED;