aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJavier Martin <javier.martin@vista-silicon.com>2012-02-13 08:51:53 -0500
committerMauro Carvalho Chehab <mchehab@redhat.com>2012-03-08 07:45:06 -0500
commit665ad8af8f93ed9b54e99f37e24def6f623698c6 (patch)
tree975c10084299a302ed1888e221353273a1bf435a
parent8636ead8b2d738b5b1b9a0c2e6070e3458a47d14 (diff)
[media] media: i.MX27 camera: return IRQ_NONE if no IRQ status bit is set
If active_bufs() list is empty and no IRQ status bit is set we are probably dealing with a share IRQ. Return IRQ_NONE in this case. Signed-off-by: Javier Martin <javier.martin@vista-silicon.com> Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
-rw-r--r--drivers/media/video/mx2_camera.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/media/video/mx2_camera.c b/drivers/media/video/mx2_camera.c
index d555b6eccb82..1a8e4676c8a7 100644
--- a/drivers/media/video/mx2_camera.c
+++ b/drivers/media/video/mx2_camera.c
@@ -1292,7 +1292,11 @@ static irqreturn_t mx27_camera_emma_irq(int irq_emma, void *data)
1292 if (list_empty(&pcdev->active_bufs)) { 1292 if (list_empty(&pcdev->active_bufs)) {
1293 dev_warn(pcdev->dev, "%s: called while active list is empty\n", 1293 dev_warn(pcdev->dev, "%s: called while active list is empty\n",
1294 __func__); 1294 __func__);
1295 goto irq_ok; 1295
1296 if (!status) {
1297 spin_unlock(&pcdev->lock);
1298 return IRQ_NONE;
1299 }
1296 } 1300 }
1297 1301
1298 if (status & (1 << 7)) { /* overflow */ 1302 if (status & (1 << 7)) { /* overflow */
@@ -1323,7 +1327,6 @@ static irqreturn_t mx27_camera_emma_irq(int irq_emma, void *data)
1323 mx27_camera_frame_done_emma(pcdev, 1, false); 1327 mx27_camera_frame_done_emma(pcdev, 1, false);
1324 } 1328 }
1325 1329
1326irq_ok:
1327 spin_unlock(&pcdev->lock); 1330 spin_unlock(&pcdev->lock);
1328 writel(status, pcdev->base_emma + PRP_INTRSTATUS); 1331 writel(status, pcdev->base_emma + PRP_INTRSTATUS);
1329 1332