summaryrefslogtreecommitdiffstats
path: root/drivers/char/bttv.h
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>1998-09-19 19:15:08 +0000
committerRalf Baechle <ralf@linux-mips.org>1998-09-19 19:15:08 +0000
commit03ba4131783cc9e872f8bb26a03f15bc11f27564 (patch)
tree88db8dba75ae06ba3bad08e42c5e52efc162535c /drivers/char/bttv.h
parent257730f99381dd26e10b832fce4c94cae7ac1176 (diff)
- Merge with Linux 2.1.121.
- Bugfixes.
Diffstat (limited to 'drivers/char/bttv.h')
-rw-r--r--drivers/char/bttv.h51
1 files changed, 35 insertions, 16 deletions
diff --git a/drivers/char/bttv.h b/drivers/char/bttv.h
index e1e21f595..f8da6c6d0 100644
--- a/drivers/char/bttv.h
+++ b/drivers/char/bttv.h
@@ -32,17 +32,11 @@
#include <linux/videodev.h>
#define MAX_CLIPRECS 100
+#define MAX_GBUFFERS 2
#define RISCMEM_LEN (32744*2)
-#define BTTV_MAX_FBUF 0x144000
-
-
-/* clipping rectangle */
-struct cliprec
-{
- int x, y, x2, y2;
- struct cliprec *next;
-};
+/* maximum needed buffer size for extended VBI frame mode capturing */
+#define BTTV_MAX_FBUF 0x151000
#ifdef __KERNEL__
@@ -63,6 +57,12 @@ struct bttv_window
};
+struct bttv_pll_info {
+ unsigned int pll_ifreq; /* PLL input frequency */
+ unsigned int pll_ofreq; /* PLL output frequency */
+ unsigned int pll_crystal; /* Crystal used for input */
+};
+
struct bttv
{
struct video_device video_dev;
@@ -75,9 +75,14 @@ struct bttv
int have_msp3400;
int have_tuner;
int tuner_type;
-
+ int channel;
+
+ unsigned int nr;
unsigned short id;
+ unsigned char bus; /* PCI bus the Bt848 is on */
+ unsigned char devfn;
struct pci_dev *dev;
+ unsigned char irq; /* IRQ used by Bt848 card */
unsigned char revision;
unsigned int bt848_adr; /* bus address of IO mem returned by PCI BIOS */
unsigned char *bt848_mem; /* pointer to mapped IO memory */
@@ -106,26 +111,38 @@ struct bttv
u32 *risc_odd;
u32 *risc_even;
int cap;
- struct cliprec *cliprecs;
- int ncr; /* number of clipping rectangles */
+ struct video_clip *cliprecs;
struct gbuffer *ogbuffers;
struct gbuffer *egbuffers;
u16 gwidth, gheight, gfmt;
u32 *grisc;
+
unsigned long gro;
unsigned long gre;
unsigned long gro_next;
unsigned long gre_next;
- char *fbuffer;
+
+ int grf,grf_next; /* frame numbers in grab queue */
+ int frame_stat[MAX_GBUFFERS];
+#define GBUFFER_UNUSED 0
+#define GBUFFER_GRABBING 1
+#define GBUFFER_DONE 2
+
+ char *fbuffer;
int gmode;
int grabbing;
int lastgrab;
int grab;
int grabcount;
- int pll;
-};
+ struct bttv_pll_info pll;
+ unsigned int Fsc;
+ unsigned int field;
+ unsigned int last_field; /* number of last grabbed field */
+ int i2c_command;
+ int triton1;
+};
#endif
/*The following should be done in more portable way. It depends on define
@@ -148,6 +165,8 @@ struct bttv
#define BTTV_READEE _IOW('v', BASE_VIDIOCPRIVATE+0, char [256])
#define BTTV_WRITEE _IOR('v', BASE_VIDIOCPRIVATE+1, char [256])
#define BTTV_GRAB _IOR('v' , BASE_VIDIOCPRIVATE+2, struct gbuf)
+#define BTTV_FIELDNR _IOR('v' , BASE_VIDIOCPRIVATE+2, unsigned int)
+#define BTTV_PLLSET _IOW('v' , BASE_VIDIOCPRIVATE+3, struct bttv_pll_info)
#define BTTV_UNKNOWN 0x00
@@ -159,6 +178,7 @@ struct bttv
#define BTTV_AVERMEDIA 0x06
#define BTTV_MATRIX_VISION 0x07
#define BTTV_FLYVIDEO 0x08
+#define BTTV_HAUPPAUGE878 0x09
#define AUDIO_TUNER 0x00
#define AUDIO_RADIO 0x01
@@ -186,7 +206,6 @@ struct bttv
#define TDA9850_ALI2 0x09
#define TDA9850_ALI3 0x0a
-
#define TDA8425_VL 0x00
#define TDA8425_VR 0x01
#define TDA8425_BA 0x02