diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-04-28 19:45:20 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-04-28 19:45:20 -0300 |
commit | b254ef22ff520250431995106e98ce08a9cd0af2 (patch) | |
tree | 4e730e629127c5ceaef2f24c45f4d2857289c3a0 /linux/drivers/media/video/cx18/cx18-streams.h | |
parent | 931c58dd0134b10194c570d8e5d47f774dd6fb5d (diff) | |
parent | ba369d468ab5439d1b514a0c52eca6b6e3186211 (diff) | |
download | mediapointer-dvb-s2-b254ef22ff520250431995106e98ce08a9cd0af2.tar.gz mediapointer-dvb-s2-b254ef22ff520250431995106e98ce08a9cd0af2.tar.bz2 |
merge: http://linuxtv.org/hg/~dheitmueller/v4l-dvb-dvicofix
From: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'linux/drivers/media/video/cx18/cx18-streams.h')
-rw-r--r-- | linux/drivers/media/video/cx18/cx18-streams.h | 24 |
1 files changed, 21 insertions, 3 deletions
diff --git a/linux/drivers/media/video/cx18/cx18-streams.h b/linux/drivers/media/video/cx18/cx18-streams.h index 420e0a172..b51a014b5 100644 --- a/linux/drivers/media/video/cx18/cx18-streams.h +++ b/linux/drivers/media/video/cx18/cx18-streams.h @@ -28,10 +28,28 @@ int cx18_streams_setup(struct cx18 *cx); int cx18_streams_register(struct cx18 *cx); void cx18_streams_cleanup(struct cx18 *cx, int unregister); +/* Related to submission of buffers to firmware */ +static inline void cx18_stream_load_fw_queue(struct cx18_stream *s) +{ + struct cx18 *cx = s->cx; + queue_work(cx->out_work_queue, &s->out_work_order); +} + +static inline void cx18_stream_put_buf_fw(struct cx18_stream *s, + struct cx18_buffer *buf) +{ + /* Put buf on q_free; the out work handler will move buf(s) to q_busy */ + cx18_enqueue(s, buf, &s->q_free); + cx18_stream_load_fw_queue(s); +} + +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 20) +void cx18_out_work_handler(struct work_struct *work); +#else +void cx18_out_work_handler(void *arg); +#endif + /* Capture related */ -void cx18_stream_load_fw_queue(struct cx18_stream *s); -struct cx18_queue *cx18_stream_put_buf_fw(struct cx18_stream *s, - struct cx18_buffer *buf); int cx18_start_v4l2_encode_stream(struct cx18_stream *s); int cx18_stop_v4l2_encode_stream(struct cx18_stream *s, int gop_end); |