X-Git-Url: http://ftp.safe.ca/?a=blobdiff_plain;f=drivers%2Fmedia%2Fvideo%2Fpvrusb2%2Fpvrusb2-io.h;h=afb7e87c0394dd90fae97ed0bbe06c698f546318;hb=be4f4aecf8df39444535c9d9be2b74a8f34649b2;hp=96285ad234a6ba1e20a4ebe7285bbcce14dd8570;hpb=07e337eeab3660559cbe1fee6907d1092037aea7;p=safe%2Fjmp%2Flinux-2.6 diff --git a/drivers/media/video/pvrusb2/pvrusb2-io.h b/drivers/media/video/pvrusb2/pvrusb2-io.h index 96285ad..afb7e87 100644 --- a/drivers/media/video/pvrusb2/pvrusb2-io.h +++ b/drivers/media/video/pvrusb2/pvrusb2-io.h @@ -1,6 +1,5 @@ /* * - * $Id$ * * Copyright (C) 2005 Mike Isely * @@ -36,6 +35,15 @@ enum pvr2_buffer_state { struct pvr2_stream; struct pvr2_buffer; +struct pvr2_stream_stats { + unsigned int buffers_in_queue; + unsigned int buffers_in_idle; + unsigned int buffers_in_ready; + unsigned int buffers_processed; + unsigned int buffers_failed; + unsigned int bytes_processed; +}; + /* Initialize / tear down stream structure */ struct pvr2_stream *pvr2_stream_create(void); void pvr2_stream_destroy(struct pvr2_stream *); @@ -45,8 +53,12 @@ void pvr2_stream_setup(struct pvr2_stream *, void pvr2_stream_set_callback(struct pvr2_stream *, pvr2_stream_callback func, void *data); +void pvr2_stream_get_stats(struct pvr2_stream *, + struct pvr2_stream_stats *, + int zero_counts); /* Query / set the nominal buffer count */ +int pvr2_stream_get_buffer_count(struct pvr2_stream *); int pvr2_stream_set_buffer_count(struct pvr2_stream *,unsigned int); /* Get a pointer to a buffer that is either idle, ready, or is specified @@ -58,6 +70,7 @@ struct pvr2_buffer *pvr2_stream_get_buffer(struct pvr2_stream *sp,int id); /* Find out how many buffers are idle or ready */ int pvr2_stream_get_ready_count(struct pvr2_stream *); + /* Kill all pending buffers and throw away any ready buffers as well */ void pvr2_stream_kill(struct pvr2_stream *);