summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h
diff options
context:
space:
mode:
Diffstat (limited to 'linux/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h')
-rw-r--r--linux/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h31
1 files changed, 22 insertions, 9 deletions
diff --git a/linux/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h b/linux/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h
index 0d527abb5..cfec4d37c 100644
--- a/linux/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h
+++ b/linux/drivers/media/video/pvrusb2/pvrusb2-hdw-internal.h
@@ -44,6 +44,7 @@
#endif
#include "pvrusb2-hdw.h"
#include "pvrusb2-io.h"
+#include <media/cx2341x.h>
/* Legal values for the SRATE state variable */
#define PVR2_CVAL_SRATE_48 0
@@ -98,6 +99,7 @@ typedef int (*pvr2_ctlf_val_to_sym)(struct pvr2_ctrl *,int msk,int val,
typedef int (*pvr2_ctlf_sym_to_val)(struct pvr2_ctrl *,
const char *,unsigned int,
int *mskp,int *valp);
+typedef unsigned int (*pvr2_ctlf_get_v4lflags)(struct pvr2_ctrl *);
/* This structure describes a specific control. A table of these is set up
in pvrusb2-hdw.c. */
@@ -115,6 +117,7 @@ struct pvr2_ctl_info {
pvr2_ctlf_sym_to_val sym_to_val; /* Custom convert symbol->value */
pvr2_ctlf_is_dirty is_dirty; /* Return true if dirty */
pvr2_ctlf_clear_dirty clear_dirty; /* Clear dirty state */
+ pvr2_ctlf_get_v4lflags get_v4lflags;/* Retrieve v4l flags */
/* Control's type (int, enum, bitmask) */
enum pvr2_ctl_type type;
@@ -149,6 +152,13 @@ struct pvr2_ctl_info {
};
+/* Same as pvr2_ctl_info, but includes storage for the control description */
+#define PVR2_CTLD_INFO_DESC_SIZE 32
+struct pvr2_ctld_info {
+ struct pvr2_ctl_info info;
+ char desc[PVR2_CTLD_INFO_DESC_SIZE];
+};
+
struct pvr2_ctrl {
const struct pvr2_ctl_info *info;
struct pvr2_hdw *hdw;
@@ -329,6 +339,14 @@ struct pvr2_hdw {
int flag_bilingual;
struct pvr2_audio_stat *audio_stat;
+ /* Control state needed for cx2341x module */
+ struct cx2341x_mpeg_params enc_cur_state;
+ struct cx2341x_mpeg_params enc_ctl_state;
+ /* True if an encoder attribute has changed */
+ int enc_stale;
+ /* True if enc_cur_state is valid */
+ int enc_cur_valid;
+
/* Control state */
#define VCREATE_DATA(lab) int lab##_val; int lab##_dirty
VCREATE_DATA(brightness);
@@ -340,22 +358,17 @@ struct pvr2_hdw {
VCREATE_DATA(bass);
VCREATE_DATA(treble);
VCREATE_DATA(mute);
- VCREATE_DATA(srate);
- VCREATE_DATA(audiobitrate);
- VCREATE_DATA(audiocrc);
- VCREATE_DATA(audioemphasis);
- VCREATE_DATA(vbr);
- VCREATE_DATA(videobitrate);
- VCREATE_DATA(videopeak);
VCREATE_DATA(input);
VCREATE_DATA(audiomode);
VCREATE_DATA(res_hor);
VCREATE_DATA(res_ver);
- VCREATE_DATA(interlace);
- VCREATE_DATA(audiolayer);
+ VCREATE_DATA(srate);
#undef VCREATE_DATA
+ struct pvr2_ctld_info *mpeg_ctrl_info;
+
struct pvr2_ctrl *controls;
+ unsigned int control_cnt;
};
int pvr2_hdw_commit_ctl_internal(struct pvr2_hdw *hdw);