[media] omap3isp: preview: Shorten shadow update delay
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Mon, 26 Mar 2012 13:24:50 +0000 (10:24 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Tue, 8 May 2012 17:08:53 +0000 (14:08 -0300)
commitb0b29e1e29ee5357f36f27411b5881e470484da5
tree70a2b1cf6c6e61b0ab8af8d6a3d59a9a05d69582
parentbac387efbb88cf0e8df6f46a38387897cea464ee
[media] omap3isp: preview: Shorten shadow update delay

When applications modify preview engine parameters, the new values are
applied to the hardware by the preview engine interrupt handler during
vertical blanking. If the parameters are being changed when the
interrupt handler is called, it just delays applying the parameters
until the next frame.

If an application modifies the parameters for every frame, and the
preview engine interrupt is triggerred synchronously, the parameters are
never applied to the hardware.

Fix this by storing new parameters in a shadow copy, and switch the
active parameters with the shadow values atomically.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/video/omap3isp/isppreview.c
drivers/media/video/omap3isp/isppreview.h