Commit 42b03fe1 authored by Ian Armstrong's avatar Ian Armstrong Committed by Mauro Carvalho Chehab

V4L/DVB (8090): ivtv: yuv decoder lock fix (2)

The IVTV_IOC_DMA_FRAME ioctl fails to correctly 'start' the decoder. Although
yuv output will be correct, some functions which should be disabled while the
decoder is in use remain enabled. This can result in hardware registers being
corrupted, causing problems with the mpeg decoder. This patch ensures the
decoder 'start' sequence is called, disabling these functions until the
device is closed.
Signed-off-by: default avatarIan Armstrong <ian@iarmst.demon.co.uk>
Signed-off-by: default avatarHans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@infradead.org>
parent 03c28085
...@@ -1539,7 +1539,7 @@ static int ivtv_decoder_ioctls(struct file *filp, unsigned int cmd, void *arg) ...@@ -1539,7 +1539,7 @@ static int ivtv_decoder_ioctls(struct file *filp, unsigned int cmd, void *arg)
return -EINVAL; return -EINVAL;
if (itv->output_mode == OUT_UDMA_YUV && args->y_source == NULL) if (itv->output_mode == OUT_UDMA_YUV && args->y_source == NULL)
return 0; return 0;
if (ivtv_claim_stream(id, id->type)) { if (ivtv_start_decoding(id, id->type)) {
return -EBUSY; return -EBUSY;
} }
if (ivtv_set_output_mode(itv, OUT_UDMA_YUV) != OUT_UDMA_YUV) { if (ivtv_set_output_mode(itv, OUT_UDMA_YUV) != OUT_UDMA_YUV) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment