summaryrefslogtreecommitdiff
path: root/linux/drivers
diff options
context:
space:
mode:
authorPatrick Boettcher <devnull@localhost>2005-04-29 11:57:12 +0000
committerPatrick Boettcher <devnull@localhost>2005-04-29 11:57:12 +0000
commitd3760654aa8e4cfd1ab6fc2f2efa3928171a59cb (patch)
tree8ad96b35cbe575fc8622e0767692be9eb8c2f21d /linux/drivers
parentba9471648385c55140fff4f67c2de8822c3c9678 (diff)
downloadmediapointer-dvb-s2-d3760654aa8e4cfd1ab6fc2f2efa3928171a59cb.tar.gz
mediapointer-dvb-s2-d3760654aa8e4cfd1ab6fc2f2efa3928171a59cb.tar.bz2
never test any change you make with old drivers, never
Diffstat (limited to 'linux/drivers')
-rw-r--r--linux/drivers/media/dvb/dvb-usb/a800.c1
-rw-r--r--linux/drivers/media/dvb/dvb-usb/dibusb-mb.c3
-rw-r--r--linux/drivers/media/dvb/dvb-usb/dibusb-mc.c1
-rw-r--r--linux/drivers/media/dvb/dvb-usb/digitv.c1
-rw-r--r--linux/drivers/media/dvb/dvb-usb/dtt200u.c1
-rw-r--r--linux/drivers/media/dvb/dvb-usb/dvb-usb-remote.c9
-rw-r--r--linux/drivers/media/dvb/dvb-usb/dvb-usb.h1
-rw-r--r--linux/drivers/media/dvb/dvb-usb/nova-t-usb2.c6
-rw-r--r--linux/drivers/media/dvb/dvb-usb/vp7045.c1
9 files changed, 20 insertions, 4 deletions
diff --git a/linux/drivers/media/dvb/dvb-usb/a800.c b/linux/drivers/media/dvb/dvb-usb/a800.c
index 4c9a62320..a0e24d223 100644
--- a/linux/drivers/media/dvb/dvb-usb/a800.c
+++ b/linux/drivers/media/dvb/dvb-usb/a800.c
@@ -124,6 +124,7 @@ static struct dvb_usb_properties a800_properties = {
.rc_interval = DEFAULT_RC_INTERVAL,
.rc_key_map = a800_rc_keys,
+ .rc_key_map_size = ARRAY_SIZE(a800_rc_keys),
.query_rc = a800_rc_query,
.i2c_algo = &dibusb_i2c_algo,
diff --git a/linux/drivers/media/dvb/dvb-usb/dibusb-mb.c b/linux/drivers/media/dvb/dvb-usb/dibusb-mb.c
index 42da4cb72..87819aed6 100644
--- a/linux/drivers/media/dvb/dvb-usb/dibusb-mb.c
+++ b/linux/drivers/media/dvb/dvb-usb/dibusb-mb.c
@@ -135,6 +135,7 @@ static struct dvb_usb_properties dibusb1_1_properties = {
.rc_interval = DEFAULT_RC_INTERVAL,
.rc_key_map = dibusb_rc_keys,
+ .rc_key_map_size = 63, /* wow, that is ugly ... I want to load it to the driver dynamically */
.query_rc = dibusb_rc_query,
.i2c_algo = &dibusb_i2c_algo,
@@ -206,6 +207,7 @@ static struct dvb_usb_properties dibusb1_1_an2235_properties = {
.rc_interval = DEFAULT_RC_INTERVAL,
.rc_key_map = dibusb_rc_keys,
+ .rc_key_map_size = 63, /* wow, that is ugly ... I want to load it to the driver dynamically */
.query_rc = dibusb_rc_query,
.i2c_algo = &dibusb_i2c_algo,
@@ -249,6 +251,7 @@ static struct dvb_usb_properties dibusb2_0b_properties = {
.rc_interval = DEFAULT_RC_INTERVAL,
.rc_key_map = dibusb_rc_keys,
+ .rc_key_map_size = 63, /* wow, that is ugly ... I want to load it to the driver dynamically */
.query_rc = dibusb_rc_query,
.i2c_algo = &dibusb_i2c_algo,
diff --git a/linux/drivers/media/dvb/dvb-usb/dibusb-mc.c b/linux/drivers/media/dvb/dvb-usb/dibusb-mc.c
index e434029f1..f680b9aa7 100644
--- a/linux/drivers/media/dvb/dvb-usb/dibusb-mc.c
+++ b/linux/drivers/media/dvb/dvb-usb/dibusb-mc.c
@@ -50,6 +50,7 @@ static struct dvb_usb_properties dibusb_mc_properties = {
.rc_interval = DEFAULT_RC_INTERVAL,
.rc_key_map = dibusb_rc_keys,
+ .rc_key_map_size = 63, /* FIXME */
.query_rc = dibusb_rc_query,
.i2c_algo = &dibusb_i2c_algo,
diff --git a/linux/drivers/media/dvb/dvb-usb/digitv.c b/linux/drivers/media/dvb/dvb-usb/digitv.c
index 9846ed272..5dc95fc7f 100644
--- a/linux/drivers/media/dvb/dvb-usb/digitv.c
+++ b/linux/drivers/media/dvb/dvb-usb/digitv.c
@@ -231,6 +231,7 @@ static struct dvb_usb_properties digitv_properties = {
.rc_interval = 1000,
.rc_key_map = digitv_rc_keys,
+ .rc_key_map_size = ARRAY_SIZE(digitv_rc_keys),
.query_rc = digitv_rc_query,
.identify_state = digitv_identify_state,
diff --git a/linux/drivers/media/dvb/dvb-usb/dtt200u.c b/linux/drivers/media/dvb/dvb-usb/dtt200u.c
index 75bd054d2..459112667 100644
--- a/linux/drivers/media/dvb/dvb-usb/dtt200u.c
+++ b/linux/drivers/media/dvb/dvb-usb/dtt200u.c
@@ -108,6 +108,7 @@ static struct dvb_usb_properties dtt200u_properties = {
.rc_interval = 200,
.rc_key_map = dtt200u_rc_keys,
+ .rc_key_map_size = ARRAY_SIZE(dtt200u_rc_keys),
.query_rc = dtt200u_rc_query,
.generic_bulk_ctrl_endpoint = 0x01,
diff --git a/linux/drivers/media/dvb/dvb-usb/dvb-usb-remote.c b/linux/drivers/media/dvb/dvb-usb/dvb-usb-remote.c
index b3c65224f..70d133076 100644
--- a/linux/drivers/media/dvb/dvb-usb/dvb-usb-remote.c
+++ b/linux/drivers/media/dvb/dvb-usb/dvb-usb-remote.c
@@ -31,8 +31,10 @@ static void dvb_usb_read_remote_control(void *data)
case REMOTE_NO_KEY_PRESSED:
break;
case REMOTE_KEY_PRESSED:
+ deb_rc("key pressed\n");
d->last_event = event;
case REMOTE_KEY_REPEAT:
+ deb_rc("key repeated\n");
input_event(&d->rc_input_dev, EV_KEY, event, 1);
input_event(&d->rc_input_dev, EV_KEY, d->last_event, 0);
input_sync(&d->rc_input_dev);
@@ -92,11 +94,14 @@ int dvb_usb_remote_init(struct dvb_usb_device *d)
d->rc_input_dev.evbit[0] = BIT(EV_KEY);
d->rc_input_dev.keycodesize = sizeof(unsigned char);
d->rc_input_dev.keycodemax = KEY_MAX;
- d->rc_input_dev.name = "Remote control inside an USB DVB receiver";
+ d->rc_input_dev.name = "IR-receiver inside an USB DVB receiver";
/* set the bits for the keys */
- for (i = 0; i < sizeof(d->props.rc_key_map)/sizeof(struct dvb_usb_rc_key); i++)
+ deb_rc("key map size: %d\n",d->props.rc_key_map_size);
+ for (i = 0; i < d->props.rc_key_map_size; i++) {
+ deb_rc("setting bit for event %d item %d\n",d->props.rc_key_map[i].event, i);
set_bit(d->props.rc_key_map[i].event, d->rc_input_dev.keybit);
+ }
/* Start the remote-control polling. */
if (d->props.rc_interval < 40)
diff --git a/linux/drivers/media/dvb/dvb-usb/dvb-usb.h b/linux/drivers/media/dvb/dvb-usb/dvb-usb.h
index ae779b659..1b02ee001 100644
--- a/linux/drivers/media/dvb/dvb-usb/dvb-usb.h
+++ b/linux/drivers/media/dvb/dvb-usb/dvb-usb.h
@@ -103,6 +103,7 @@ struct dvb_usb_properties {
#define REMOTE_KEY_PRESSED 0x01
#define REMOTE_KEY_REPEAT 0x02
struct dvb_usb_rc_key *rc_key_map;
+ int rc_key_map_size;
int (*query_rc) (struct dvb_usb_device *, u32 *, int *); /* remote query callback - NULL no ir-receiver */
int rc_interval;
diff --git a/linux/drivers/media/dvb/dvb-usb/nova-t-usb2.c b/linux/drivers/media/dvb/dvb-usb/nova-t-usb2.c
index 3198db391..575c85b4e 100644
--- a/linux/drivers/media/dvb/dvb-usb/nova-t-usb2.c
+++ b/linux/drivers/media/dvb/dvb-usb/nova-t-usb2.c
@@ -87,9 +87,10 @@ static int nova_t_rc_query(struct dvb_usb_device *d, u32 *event, int *state)
data = raw & 0x3f;
custom = (raw >> 6) & 0x1f;
- deb_rc("raw key code 0x%02x, 0x%02x, 0x%02x to %02x toggle: %d\n",key[1],key[2],key[3],data,toggle);
+ deb_rc("raw key code 0x%02x, 0x%02x, 0x%02x to c: %02x d: %02x toggle: %d\n",key[1],key[2],key[3],custom,data,toggle);
- for (i = 0; i < sizeof(haupp_rc_keys)/sizeof(haupp_rc_keys[0]); i++) {
+ for (i = 0; i < ARRAY_SIZE(haupp_rc_keys); i++) {
+ deb_rc("c: %x, d: %x\n",haupp_rc_keys[i].data,haupp_rc_keys[i].custom);
if (haupp_rc_keys[i].data == data &&
haupp_rc_keys[i].custom == custom) {
*event = haupp_rc_keys[i].event;
@@ -173,6 +174,7 @@ static struct dvb_usb_properties nova_t_properties = {
.rc_interval = 100,
.rc_key_map = haupp_rc_keys,
+ .rc_key_map_size = ARRAY_SIZE(haupp_rc_keys),
.query_rc = nova_t_rc_query,
.i2c_algo = &dibusb_i2c_algo,
diff --git a/linux/drivers/media/dvb/dvb-usb/vp7045.c b/linux/drivers/media/dvb/dvb-usb/vp7045.c
index e385bdbc0..a7885ef7e 100644
--- a/linux/drivers/media/dvb/dvb-usb/vp7045.c
+++ b/linux/drivers/media/dvb/dvb-usb/vp7045.c
@@ -198,6 +198,7 @@ static struct dvb_usb_properties vp7045_properties = {
.rc_interval = 400,
.rc_key_map = vp7045_rc_keys,
+ .rc_key_map_size = ARRAY_SIZE(vp7045_rc_keys),
.query_rc = vp7045_rc_query,
/* parameter for the MPEG2-data transfer */