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

[media] media: rc: nuvoton: replace usage of spin_lock_irqsave in ISR

Kernel takes care that interrupts from one source are serialized.
So there's no need to use spinlock_irq_save.

Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>

authored by

Heiner Kallweit and committed by
Mauro Carvalho Chehab
c044170f 73d4576d

+4 -5
+4 -5
drivers/media/rc/nuvoton-cir.c
··· 840 840 { 841 841 struct nvt_dev *nvt = data; 842 842 u8 status, iren; 843 - unsigned long flags; 844 843 845 844 nvt_dbg_verbose("%s firing", __func__); 846 845 847 - spin_lock_irqsave(&nvt->lock, flags); 846 + spin_lock(&nvt->lock); 848 847 849 848 /* 850 849 * Get IR Status register contents. Write 1 to ack/clear ··· 865 866 * logical device is being disabled. 866 867 */ 867 868 if (status == 0xff && iren == 0xff) { 868 - spin_unlock_irqrestore(&nvt->lock, flags); 869 + spin_unlock(&nvt->lock); 869 870 nvt_dbg_verbose("Spurious interrupt detected"); 870 871 return IRQ_HANDLED; 871 872 } ··· 874 875 * status bit whether the related interrupt source is enabled 875 876 */ 876 877 if (!(status & iren)) { 877 - spin_unlock_irqrestore(&nvt->lock, flags); 878 + spin_unlock(&nvt->lock); 878 879 nvt_dbg_verbose("%s exiting, IRSTS 0x0", __func__); 879 880 return IRQ_NONE; 880 881 } ··· 922 923 } 923 924 } 924 925 925 - spin_unlock_irqrestore(&nvt->lock, flags); 926 + spin_unlock(&nvt->lock); 926 927 927 928 nvt_dbg_verbose("%s done", __func__); 928 929 return IRQ_HANDLED;