Skip to content

Commit

Permalink
[media] marvell-cam: Don't signal multiple frame completions in scatt…
Browse files Browse the repository at this point in the history
…er/gather mode

There is only one frame known to the DMA engine in scatter/gather mode, but
it still tells us that any or all of frames 1-3 are done at each completion
interrupt.  Avoid the creation of junk frames by being sure to only
"complete" one on each interrupt.

Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
  • Loading branch information
Jonathan Corbet authored and Mauro Carvalho Chehab committed Mar 20, 2012
1 parent 121bbe2 commit f2354dd
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/media/video/marvell-ccic/mcam-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1697,6 +1697,8 @@ int mccic_irq(struct mcam_camera *cam, unsigned int irqs)
if (irqs & (IRQ_EOF0 << frame)) {
mcam_frame_complete(cam, frame);
handled = 1;
if (cam->buffer_mode == B_DMA_sg)
break;
}
/*
* If a frame starts, note that we have DMA active. This
Expand Down

0 comments on commit f2354dd

Please sign in to comment.