diff options
author | Andrey Utkin <andrey.utkin@corp.bluecherry.net> | 2016-08-24 20:17:18 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@s-opensource.com> | 2016-09-06 16:45:48 -0300 |
commit | 350649cc24358ab0cfff7179c06818d0cfef698b (patch) | |
tree | 26018ea4c24eb007520da7300efec35923253780 /drivers/media/pci/tw5864 | |
parent | e5872251cdf59ad284eb7ebb5960208d1753d9d8 (diff) | |
download | linux-stable-350649cc24358ab0cfff7179c06818d0cfef698b.tar.gz linux-stable-350649cc24358ab0cfff7179c06818d0cfef698b.tar.bz2 linux-stable-350649cc24358ab0cfff7179c06818d0cfef698b.zip |
[media] tw5864-core: remove excessive irqsave
As warned by smatch:
drivers/media/pci/tw5864/tw5864-core.c:160 tw5864_h264_isr() error: double lock 'irqsave:flags'
drivers/media/pci/tw5864/tw5864-core.c:174 tw5864_h264_isr() error: double unlock 'irqsave:flags'
Two different spinlocks are obtained, so having two calls is correct,
but second irqsave is superfluous, and using same "flags" variable is
just wrong.
Reported-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Signed-off-by: Andrey Utkin <andrey.utkin@corp.bluecherry.net>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'drivers/media/pci/tw5864')
-rw-r--r-- | drivers/media/pci/tw5864/tw5864-core.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/media/pci/tw5864/tw5864-core.c b/drivers/media/pci/tw5864/tw5864-core.c index 440cd7bb8d04..1d43b96958ea 100644 --- a/drivers/media/pci/tw5864/tw5864-core.c +++ b/drivers/media/pci/tw5864/tw5864-core.c @@ -157,12 +157,12 @@ static void tw5864_h264_isr(struct tw5864_dev *dev) cur_frame = next_frame; - spin_lock_irqsave(&input->slock, flags); + spin_lock(&input->slock); input->frame_seqno++; input->frame_gop_seqno++; if (input->frame_gop_seqno >= input->gop) input->frame_gop_seqno = 0; - spin_unlock_irqrestore(&input->slock, flags); + spin_unlock(&input->slock); } else { dev_err(&dev->pci->dev, "Skipped frame on input %d because all buffers busy\n", |