diff options
author | Andy Walls <awalls@radix.net> | 2008-11-23 17:16:44 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2008-12-30 06:39:08 -0500 |
commit | 50b86bac6ae6dda00faa14f7d73ae2412eacc240 (patch) | |
tree | a34b376d559982e6ce97ddb7e0899e90ad371235 /drivers/media/video/cx18/cx18-streams.c | |
parent | f6b181ac3bda7aab227e9ee3148bc9b7f1889c57 (diff) |
V4L/DVB (9894): cx18: Use a known open task handle when setting stream CX2341x parameters
cx18: Use a known open task handle when setting stream CX2341x parameters
Sometimes, we might only have VBI or YUV stream open instead of an MPEG stream.
Let's make sure we use a valid task handle to perform the CX2341x control
settings.
Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/cx18/cx18-streams.c')
-rw-r--r-- | drivers/media/video/cx18/cx18-streams.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/media/video/cx18/cx18-streams.c b/drivers/media/video/cx18/cx18-streams.c index 600a5fcac3d0..63c336c95ff5 100644 --- a/drivers/media/video/cx18/cx18-streams.c +++ b/drivers/media/video/cx18/cx18-streams.c | |||
@@ -494,6 +494,8 @@ int cx18_start_v4l2_encode_stream(struct cx18_stream *s) | |||
494 | cx18_vapi(cx, CX18_CPU_SET_CHANNEL_TYPE, 2, s->handle, captype); | 494 | cx18_vapi(cx, CX18_CPU_SET_CHANNEL_TYPE, 2, s->handle, captype); |
495 | 495 | ||
496 | if (atomic_read(&cx->ana_capturing) == 0 && !ts) { | 496 | if (atomic_read(&cx->ana_capturing) == 0 && !ts) { |
497 | struct cx18_api_func_private priv; | ||
498 | |||
497 | /* Stuff from Windows, we don't know what it is */ | 499 | /* Stuff from Windows, we don't know what it is */ |
498 | cx18_vapi(cx, CX18_CPU_SET_VER_CROP_LINE, 2, s->handle, 0); | 500 | cx18_vapi(cx, CX18_CPU_SET_VER_CROP_LINE, 2, s->handle, 0); |
499 | cx18_vapi(cx, CX18_CPU_SET_MISC_PARAMETERS, 3, s->handle, 3, 1); | 501 | cx18_vapi(cx, CX18_CPU_SET_MISC_PARAMETERS, 3, s->handle, 3, 1); |
@@ -513,7 +515,9 @@ int cx18_start_v4l2_encode_stream(struct cx18_stream *s) | |||
513 | cx18_vapi_result(cx, data, CX18_CPU_SET_INDEXTABLE, 1, 0); | 515 | cx18_vapi_result(cx, data, CX18_CPU_SET_INDEXTABLE, 1, 0); |
514 | 516 | ||
515 | /* Setup API for Stream */ | 517 | /* Setup API for Stream */ |
516 | cx2341x_update(cx, cx18_api_func, NULL, &cx->params); | 518 | priv.cx = cx; |
519 | priv.s = s; | ||
520 | cx2341x_update(&priv, cx18_api_func, NULL, &cx->params); | ||
517 | } | 521 | } |
518 | 522 | ||
519 | if (atomic_read(&cx->tot_capturing) == 0) { | 523 | if (atomic_read(&cx->tot_capturing) == 0) { |