aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/ivtv
diff options
context:
space:
mode:
authorIan Armstrong <ian@iarmst.demon.co.uk>2010-03-06 19:37:04 -0500
committerMauro Carvalho Chehab <mchehab@redhat.com>2010-05-17 23:46:43 -0400
commit9a766d55b72a439b2e16ecf2ac3eb831ab25e0d3 (patch)
treecd52518a35d2acf9496e1267bf5753ab777a7699 /drivers/media/video/ivtv
parent283328c29db4463c31ee59f9ab418449cfa376b3 (diff)
V4L/DVB: ivtv: Really stop capture on device close
When a capture is started, the firmware also appears to start a secondary stream. Unless this secondary stream is also stopped, the encoder will remain active and not reinitialise for the next capture. Unfortunately, setting up the video source can glitch the encoder and result in undesirable effects that this initialisation will clear. Signed-off-by: Ian Armstrong <ian@iarmst.demon.co.uk> Signed-off-by: Andy Walls <awalls@radix.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/ivtv')
-rw-r--r--drivers/media/video/ivtv/ivtv-streams.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/media/video/ivtv/ivtv-streams.c b/drivers/media/video/ivtv/ivtv-streams.c
index a994b0adb444..6917c497fb7e 100644
--- a/drivers/media/video/ivtv/ivtv-streams.c
+++ b/drivers/media/video/ivtv/ivtv-streams.c
@@ -829,6 +829,10 @@ int ivtv_stop_v4l2_encode_stream(struct ivtv_stream *s, int gop_end)
829 ivtv_set_irq_mask(itv, IVTV_IRQ_ENC_VIM_RST); 829 ivtv_set_irq_mask(itv, IVTV_IRQ_ENC_VIM_RST);
830 } 830 }
831 831
832 /* Raw-passthrough is implied on start. Make sure it's stopped so
833 the encoder will re-initialize when next started */
834 ivtv_vapi(itv, CX2341X_ENC_STOP_CAPTURE, 3, 1, 2, 7);
835
832 wake_up(&s->waitq); 836 wake_up(&s->waitq);
833 837
834 return 0; 838 return 0;