diff options
Diffstat (limited to 'linux/drivers/media/video/bttv.h')
-rw-r--r-- | linux/drivers/media/video/bttv.h | 38 |
1 files changed, 35 insertions, 3 deletions
diff --git a/linux/drivers/media/video/bttv.h b/linux/drivers/media/video/bttv.h index 2126504da..dec77cd0a 100644 --- a/linux/drivers/media/video/bttv.h +++ b/linux/drivers/media/video/bttv.h @@ -1,5 +1,5 @@ /* - * $Id: bttv.h,v 1.35 2005/11/25 21:37:36 mchehab Exp $ + * $Id: bttv.h,v 1.36 2005/12/10 17:51:31 rmcc Exp $ * * bttv - Bt848 frame grabber driver * @@ -18,6 +18,8 @@ #include "compat.h" #include <linux/videodev.h> #include <linux/i2c.h> +#include <media/ir-common.h> +#include <media/ir-kbd-i2c.h> /* ---------------------------------------------------------- */ /* exported by bttv-cards.c */ @@ -213,6 +215,34 @@ struct bttv_core { struct bttv; + +struct bttv_ir { + struct input_dev *dev; + struct ir_input_state ir; + char name[32]; + char phys[32]; + + /* Usual gpio signalling */ + + u32 mask_keycode; + u32 mask_keydown; + u32 mask_keyup; + u32 polling; + u32 last_gpio; + struct work_struct work; + struct timer_list timer; + + /* RC5 gpio */ + u32 rc5_gpio; + struct timer_list timer_end; /* timer_end for code completion */ + struct timer_list timer_keyup; /* timer_end for key release */ + u32 last_rc5; /* last good rc5 code */ + u32 last_bit; /* last raw bit seen */ + u32 code; /* raw code under construction */ + struct timeval base_time; /* time of last seen code */ + int active; /* building raw code */ +}; + struct tvcard { char *name; @@ -238,7 +268,6 @@ struct tvcard unsigned int has_dvb:1; unsigned int has_remote:1; unsigned int no_gpioirq:1; - unsigned int any_irq:1; /* other settings */ unsigned int pll; @@ -345,7 +374,6 @@ struct bttv_sub_driver { struct device_driver drv; char wanted[BUS_ID_SIZE]; void (*gpio_irq)(struct bttv_sub_device *sub); - int (*any_irq)(struct bttv_sub_device *sub); }; #define to_bttv_sub_drv(x) container_of((x), struct bttv_sub_driver, drv) @@ -381,6 +409,10 @@ extern int bttv_I2CWrite(struct bttv *btv, unsigned char addr, unsigned char b1, unsigned char b2, int both); extern void bttv_readee(struct bttv *btv, unsigned char *eedata, int addr); +extern int bttv_input_init(struct bttv *dev); +extern void bttv_input_fini(struct bttv *dev); +extern void bttv_input_irq(struct bttv *dev); + #endif /* _BTTV_H_ */ /* * Local variables: |