* [PATCH 22/26] V4L-DVB: ir-core: remove the ancillary buffer
[not found] <cover.1270577768.git.mchehab@redhat.com>
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 24/26] V4L/DVB: ir-core: Add support for badly-implemented hardware decoders Mauro Carvalho Chehab
` (24 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
Now that the decoders are state machine, there's no need to create
an ancillary buffer while decoding the protocol. Just call the decoders
code directly, event by event.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/IR/ir-nec-decoder.c b/drivers/media/IR/ir-nec-decoder.c
index 087211c..28d7735 100644
--- a/drivers/media/IR/ir-nec-decoder.c
+++ b/drivers/media/IR/ir-nec-decoder.c
@@ -125,14 +125,14 @@ static struct attribute_group decoder_attribute_group = {
/**
- * handle_event() - Decode one NEC pulse or space
+ * ir_nec_decode() - Decode one NEC pulse or space
* @input_dev: the struct input_dev descriptor of the device
* @ev: event array with type/duration of pulse/space
*
* This function returns -EINVAL if the pulse violates the state machine
*/
-static int handle_event(struct input_dev *input_dev,
- struct ir_raw_event *ev)
+static int ir_nec_decode(struct input_dev *input_dev,
+ struct ir_raw_event *ev)
{
struct decoder_data *data;
struct ir_input_dev *ir_dev = input_get_drvdata(input_dev);
@@ -289,32 +289,6 @@ checksum_err:
return -EINVAL;
}
-/**
- * ir_nec_decode() - Decodes all NEC pulsecodes on a given array
- * @input_dev: the struct input_dev descriptor of the device
- * @evs: event array with type/duration of pulse/space
- * @len: length of the array
- * This function returns the number of decoded pulses
- */
-static int ir_nec_decode(struct input_dev *input_dev,
- struct ir_raw_event *evs,
- int len)
-{
- struct ir_input_dev *ir_dev = input_get_drvdata(input_dev);
- struct decoder_data *data;
- int pos = 0;
- int rc = 0;
-
- data = get_decoder_data(ir_dev);
- if (!data || !data->enabled)
- return 0;
-
- for (pos = 0; pos < len; pos++)
- handle_event(input_dev, &evs[pos]);
-
- return rc;
-}
-
static int ir_nec_register(struct input_dev *input_dev)
{
struct ir_input_dev *ir_dev = input_get_drvdata(input_dev);
diff --git a/drivers/media/IR/ir-raw-event.c b/drivers/media/IR/ir-raw-event.c
index 617e437..57990a3 100644
--- a/drivers/media/IR/ir-raw-event.c
+++ b/drivers/media/IR/ir-raw-event.c
@@ -138,37 +138,33 @@ int ir_raw_event_handle(struct input_dev *input_dev)
{
struct ir_input_dev *ir = input_get_drvdata(input_dev);
int rc;
- struct ir_raw_event *evs;
+ struct ir_raw_event ev;
int len, i;
/*
* Store the events into a temporary buffer. This allows calling more than
* one decoder to deal with the received data
*/
- len = kfifo_len(&ir->raw->kfifo) / sizeof(*evs);
+ len = kfifo_len(&ir->raw->kfifo) / sizeof(ev);
if (!len)
return 0;
- evs = kmalloc(len * sizeof(*evs), GFP_ATOMIC);
for (i = 0; i < len; i++) {
- rc = kfifo_out(&ir->raw->kfifo, &evs[i], sizeof(*evs));
- if (rc != sizeof(*evs)) {
+ rc = kfifo_out(&ir->raw->kfifo, &ev, sizeof(ev));
+ if (rc != sizeof(ev)) {
IR_dprintk(1, "overflow error: received %d instead of %zd\n",
- rc, sizeof(*evs));
+ rc, sizeof(ev));
return -EINVAL;
}
IR_dprintk(2, "event type %d, time before event: %07luus\n",
- evs[i].type, (evs[i].delta.tv_nsec + 500) / 1000);
+ ev.type, (ev.delta.tv_nsec + 500) / 1000);
+ rc = RUN_DECODER(decode, input_dev, &ev);
}
/*
* Call all ir decoders. This allows decoding the same event with
- * more than one protocol handler. It returns the number of keystrokes
- * sent to the event interface
+ * more than one protocol handler.
*/
- rc = RUN_DECODER(decode, input_dev, evs, len);
-
- kfree(evs);
return rc;
}
diff --git a/drivers/media/IR/ir-rc5-decoder.c b/drivers/media/IR/ir-rc5-decoder.c
index 4b7eafe..61b5839 100644
--- a/drivers/media/IR/ir-rc5-decoder.c
+++ b/drivers/media/IR/ir-rc5-decoder.c
@@ -142,7 +142,7 @@ static struct attribute_group decoder_attribute_group = {
*
* This function returns -EINVAL if the pulse violates the state machine
*/
-static int handle_event(struct input_dev *input_dev,
+static int ir_rc5_decode(struct input_dev *input_dev,
struct ir_raw_event *ev)
{
struct decoder_data *data;
@@ -273,32 +273,6 @@ err2:
return -EINVAL;
}
-/**
- * ir_rc5_decode() - Decodes all RC-5 pulsecodes on a given array
- * @input_dev: the struct input_dev descriptor of the device
- * @evs: event array with type/duration of pulse/space
- * @len: length of the array
- * This function returns the number of decoded pulses
- */
-static int ir_rc5_decode(struct input_dev *input_dev,
- struct ir_raw_event *evs,
- int len)
-{
- struct ir_input_dev *ir_dev = input_get_drvdata(input_dev);
- struct decoder_data *data;
- int pos = 0;
- int rc = 0;
-
- data = get_decoder_data(ir_dev);
- if (!data || !data->enabled)
- return 0;
-
- for (pos = 0; pos < len; pos++)
- handle_event(input_dev, &evs[pos]);
-
- return rc;
-}
-
static int ir_rc5_register(struct input_dev *input_dev)
{
struct ir_input_dev *ir_dev = input_get_drvdata(input_dev);
diff --git a/include/media/ir-core.h b/include/media/ir-core.h
index 4090073..1c1e8d9 100644
--- a/include/media/ir-core.h
+++ b/include/media/ir-core.h
@@ -101,8 +101,7 @@ struct ir_raw_handler {
struct list_head list;
int (*decode)(struct input_dev *input_dev,
- struct ir_raw_event *evs,
- int len);
+ struct ir_raw_event *ev);
int (*raw_register)(struct input_dev *input_dev);
int (*raw_unregister)(struct input_dev *input_dev);
};
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 26/26] V4L/DVB: ir-rc5-decoder: fix state machine
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (2 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 23/26] V4L/DVB: ir-core: move rc map code to rc-map.h Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 25/26] V4L/DVB: re-add enable/disable check to the IR decoders Mauro Carvalho Chehab
` (21 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
Reimplement the RC-5 decoder state machine. Code is now clear, and works
properly. It is also simpler than the previous implementations.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/IR/ir-rc5-decoder.c b/drivers/media/IR/ir-rc5-decoder.c
index 4fb3ce4..a62277b 100644
--- a/drivers/media/IR/ir-rc5-decoder.c
+++ b/drivers/media/IR/ir-rc5-decoder.c
@@ -15,19 +15,17 @@
/*
* This code only handles 14 bits RC-5 protocols. There are other variants
* that use a different number of bits. This is currently unsupported
+ * It considers a carrier of 36 kHz, with a total of 14 bits, where
+ * the first two bits are start bits, and a third one is a filing bit
*/
#include <media/ir-core.h>
+static unsigned int ir_rc5_remote_gap = 888888;
+
#define RC5_NBITS 14
-#define RC5_HALFBIT 888888 /* ns */
-#define RC5_BIT (RC5_HALFBIT * 2)
-#define RC5_DURATION (RC5_BIT * RC5_NBITS)
-
-#define is_rc5_halfbit(nsec) ((ev->delta.tv_nsec >= RC5_HALFBIT / 2) && \
- (ev->delta.tv_nsec < RC5_HALFBIT + RC5_HALFBIT / 2))
-
-#define n_half(nsec) ((ev->delta.tv_nsec + RC5_HALFBIT / 2) / RC5_HALFBIT)
+#define RC5_BIT (ir_rc5_remote_gap * 2)
+#define RC5_DURATION (ir_rc5_remote_gap * RC5_NBITS)
/* Used to register rc5_decoder clients */
static LIST_HEAD(decoder_list);
@@ -35,19 +33,8 @@ static spinlock_t decoder_lock;
enum rc5_state {
STATE_INACTIVE,
- STATE_START2_SPACE,
- STATE_START2_MARK,
STATE_MARKSPACE,
- STATE_TRAILER_MARK,
-};
-
-static char *st_name[] = {
- "Inactive",
- "start2 sapce",
- "start2 mark",
- "mark",
- "space",
- "trailer"
+ STATE_TRAILER,
};
struct rc5_code {
@@ -63,8 +50,7 @@ struct decoder_data {
/* State machine control */
enum rc5_state state;
struct rc5_code rc5_code;
- unsigned n_half;
- unsigned count;
+ unsigned code, elapsed, last_bit, last_code;
};
@@ -147,7 +133,7 @@ static int ir_rc5_decode(struct input_dev *input_dev,
{
struct decoder_data *data;
struct ir_input_dev *ir_dev = input_get_drvdata(input_dev);
- int bit, last_bit, n_half;
+ int is_pulse, scancode, delta, toggle;
data = get_decoder_data(ir_dev);
if (!data)
@@ -156,122 +142,79 @@ static int ir_rc5_decode(struct input_dev *input_dev,
if (!data->enabled)
return 0;
- /* Except for the initial event, what matters is the previous bit */
- bit = (ev->type & IR_PULSE) ? 1 : 0;
+ delta = DIV_ROUND_CLOSEST(ev->delta.tv_nsec, ir_rc5_remote_gap);
- last_bit = !bit;
-
- /* Discards spurious space last_bits when inactive */
+ /* The duration time refers to the last bit time */
+ is_pulse = (ev->type & IR_PULSE) ? 1 : 0;
/* Very long delays are considered as start events */
- if (ev->delta.tv_nsec > RC5_DURATION + RC5_HALFBIT / 2)
- data->state = STATE_INACTIVE;
-
- if (ev->type & IR_START_EVENT)
+ if (delta > RC5_DURATION || (ev->type & IR_START_EVENT))
data->state = STATE_INACTIVE;
switch (data->state) {
case STATE_INACTIVE:
-IR_dprintk(1, "currently inative. Received bit (%s) @%luus\n",
- last_bit ? "pulse" : "space",
- (ev->delta.tv_nsec + 500) / 1000);
+ IR_dprintk(2, "currently inative. Start bit (%s) @%uus\n",
+ is_pulse ? "pulse" : "space",
+ (unsigned)(ev->delta.tv_nsec + 500) / 1000);
/* Discards the initial start space */
- if (bit)
- return 0;
- data->count = 0;
- data->n_half = 0;
- memset (&data->rc5_code, 0, sizeof(data->rc5_code));
-
- data->state = STATE_START2_SPACE;
- return 0;
- case STATE_START2_SPACE:
- if (last_bit)
+ if (!is_pulse)
goto err;
- if (!is_rc5_halfbit(ev->delta.tv_nsec))
- goto err;
- data->state = STATE_START2_MARK;
- return 0;
- case STATE_START2_MARK:
- if (!last_bit)
- goto err;
-
- if (!is_rc5_halfbit(ev->delta.tv_nsec))
- goto err;
-
+ data->code = 1;
+ data->last_bit = 1;
+ data->elapsed = 0;
+ memset(&data->rc5_code, 0, sizeof(data->rc5_code));
data->state = STATE_MARKSPACE;
return 0;
case STATE_MARKSPACE:
- n_half = n_half(ev->delta.tv_nsec);
- if (n_half < 1 || n_half > 3) {
- IR_dprintk(1, "Decode failed at %d-th bit (%s) @%luus\n",
- data->count,
- last_bit ? "pulse" : "space",
- (ev->delta.tv_nsec + 500) / 1000);
-printk("%d halves\n", n_half);
- goto err2;
- }
- data->n_half += n_half;
+ if (delta != 1)
+ data->last_bit = data->last_bit ? 0 : 1;
- if (!last_bit)
+ data->elapsed += delta;
+
+ if ((data->elapsed % 2) == 1)
return 0;
- /* Got one complete mark/space cycle */
+ data->code <<= 1;
+ data->code |= data->last_bit;
- bit = ((data->count + 1) * 2)/ data->n_half;
+ /* Fill the 2 unused bits at the command with 0 */
+ if (data->elapsed / 2 == 6)
+ data->code <<= 2;
-printk("%d halves, %d bits\n", n_half, bit);
+ if (data->elapsed >= (RC5_NBITS - 1) * 2) {
+ scancode = data->code;
-#if 1 /* SANITY check - while testing the decoder */
- if (bit > 1) {
- IR_dprintk(1, "Decoder HAS failed at %d-th bit (%s) @%luus\n",
- data->count,
- last_bit ? "pulse" : "space",
- (ev->delta.tv_nsec + 500) / 1000);
+ /* Check for the start bits */
+ if ((scancode & 0xc000) != 0xc000) {
+ IR_dprintk(1, "Code 0x%04x doesn't have two start bits. It is not RC-5\n", scancode);
+ goto err;
+ }
- goto err2;
- }
-#endif
- /* Ok, we've got a valid bit. proccess it */
- if (bit) {
- int shift = data->count;
+ toggle = (scancode & 0x2000) ? 1 : 0;
- /*
- * RC-5 transmit bytes on this temporal order:
- * address | not address | command | not command
- */
- if (shift < 8) {
- data->rc5_code.address |= 1 << shift;
+ if (scancode == data->last_code) {
+ IR_dprintk(1, "RC-5 repeat\n");
+ ir_repeat(input_dev);
} else {
- data->rc5_code.command |= 1 << (shift - 8);
+ data->last_code = scancode;
+ scancode &= 0x1fff;
+ IR_dprintk(1, "RC-5 scancode 0x%04x\n", scancode);
+
+ ir_keydown(input_dev, scancode, 0);
}
- }
- IR_dprintk(1, "RC-5: bit #%d: %d (%d)\n",
- data->count, bit, data->n_half);
- if (++data->count >= RC5_NBITS) {
- u32 scancode;
- scancode = data->rc5_code.address << 8 |
- data->rc5_code.command;
- IR_dprintk(1, "RC-5 scancode 0x%04x\n", scancode);
-
- ir_keydown(input_dev, scancode, 0);
-
- data->state = STATE_TRAILER_MARK;
+ data->state = STATE_TRAILER;
}
return 0;
- case STATE_TRAILER_MARK:
- if (!last_bit)
- goto err;
+ case STATE_TRAILER:
data->state = STATE_INACTIVE;
return 0;
}
err:
- IR_dprintk(1, "RC-5 decoded failed at state %s (%s) @ %luus\n",
- st_name[data->state],
- bit ? "pulse" : "space",
+ IR_dprintk(1, "RC-5 decoded failed at %s @ %luus\n",
+ is_pulse ? "pulse" : "space",
(ev->delta.tv_nsec + 500) / 1000);
-err2:
data->state = STATE_INACTIVE;
return -EINVAL;
}
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 25/26] V4L/DVB: re-add enable/disable check to the IR decoders
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (3 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 26/26] V4L/DVB: ir-rc5-decoder: fix state machine Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 21/26] V4L/DVB: cx88: don't handle IR on Pixelview too fast Mauro Carvalho Chehab
` (20 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
A previous cleanup patch removed more than needed. Re-add the logic that
disable the decoders.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/IR/ir-nec-decoder.c b/drivers/media/IR/ir-nec-decoder.c
index 28d7735..9d1ada9 100644
--- a/drivers/media/IR/ir-nec-decoder.c
+++ b/drivers/media/IR/ir-nec-decoder.c
@@ -142,6 +142,9 @@ static int ir_nec_decode(struct input_dev *input_dev,
if (!data)
return -EINVAL;
+ if (!data->enabled)
+ return 0;
+
/* Except for the initial event, what matters is the previous bit */
bit = (ev->type & IR_PULSE) ? 1 : 0;
diff --git a/drivers/media/IR/ir-rc5-decoder.c b/drivers/media/IR/ir-rc5-decoder.c
index 61b5839..4fb3ce4 100644
--- a/drivers/media/IR/ir-rc5-decoder.c
+++ b/drivers/media/IR/ir-rc5-decoder.c
@@ -153,6 +153,9 @@ static int ir_rc5_decode(struct input_dev *input_dev,
if (!data)
return -EINVAL;
+ if (!data->enabled)
+ return 0;
+
/* Except for the initial event, what matters is the previous bit */
bit = (ev->type & IR_PULSE) ? 1 : 0;
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 23/26] V4L/DVB: ir-core: move rc map code to rc-map.h
[not found] <cover.1270577768.git.mchehab@redhat.com>
2010-04-06 18:18 ` [PATCH 22/26] V4L-DVB: ir-core: remove the ancillary buffer Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 24/26] V4L/DVB: ir-core: Add support for badly-implemented hardware decoders Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 26/26] V4L/DVB: ir-rc5-decoder: fix state machine Mauro Carvalho Chehab
` (22 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
The keymaps don't need to be recompiled every time a change at ir-core.h
happens, since it only depends on rc-map defines. By moving those
definitions to the proper header, the code became cleaner, and avoids
needing to recompile all the RC maps every time a non-related change
is introduced.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/include/media/ir-core.h b/include/media/ir-core.h
index 1c1e8d9..0f64b48 100644
--- a/include/media/ir-core.h
+++ b/include/media/ir-core.h
@@ -16,7 +16,6 @@
#ifndef _IR_CORE
#define _IR_CORE
-#include <linux/input.h>
#include <linux/spinlock.h>
#include <linux/kfifo.h>
#include <linux/time.h>
@@ -27,12 +26,6 @@ extern int ir_core_debug;
#define IR_dprintk(level, fmt, arg...) if (ir_core_debug >= level) \
printk(KERN_DEBUG "%s: " fmt , __func__, ## arg)
-#define IR_TYPE_UNKNOWN 0
-#define IR_TYPE_RC5 (1 << 0) /* Philips RC5 protocol */
-#define IR_TYPE_PD (1 << 1) /* Pulse distance encoded IR */
-#define IR_TYPE_NEC (1 << 2)
-#define IR_TYPE_OTHER (((u64)1) << 63l)
-
enum raw_event_type {
IR_SPACE = (1 << 0),
IR_PULSE = (1 << 1),
@@ -40,26 +33,6 @@ enum raw_event_type {
IR_STOP_EVENT = (1 << 3),
};
-struct ir_scancode {
- u16 scancode;
- u32 keycode;
-};
-
-struct ir_scancode_table {
- struct ir_scancode *scan;
- unsigned int size; /* Max number of entries */
- unsigned int len; /* Used number of entries */
- unsigned int alloc; /* Size of *scan in bytes */
- u64 ir_type;
- char *name;
- spinlock_t lock;
-};
-
-struct rc_keymap {
- struct list_head list;
- struct ir_scancode_table map;
-};
-
struct ir_dev_props {
unsigned long allowed_protos;
void *priv;
@@ -108,13 +81,6 @@ struct ir_raw_handler {
#define to_ir_input_dev(_attr) container_of(_attr, struct ir_input_dev, attr)
-/* Routines from rc-map.c */
-
-int ir_register_map(struct rc_keymap *map);
-void ir_unregister_map(struct rc_keymap *map);
-struct ir_scancode_table *get_rc_map(const char *name);
-void rc_map_init(void);
-
/* Routines from ir-keytable.c */
u32 ir_g_keycode_from_table(struct input_dev *input_dev,
diff --git a/include/media/rc-map.h b/include/media/rc-map.h
index 9ea0033..b10990d 100644
--- a/include/media/rc-map.h
+++ b/include/media/rc-map.h
@@ -9,7 +9,42 @@
* (at your option) any later version.
*/
-#include <media/ir-core.h>
+#include <linux/input.h>
+
+#define IR_TYPE_UNKNOWN 0
+#define IR_TYPE_RC5 (1 << 0) /* Philips RC5 protocol */
+#define IR_TYPE_PD (1 << 1) /* Pulse distance encoded IR */
+#define IR_TYPE_NEC (1 << 2)
+#define IR_TYPE_OTHER (1u << 31)
+
+struct ir_scancode {
+ u16 scancode;
+ u32 keycode;
+};
+
+struct ir_scancode_table {
+ struct ir_scancode *scan;
+ unsigned int size; /* Max number of entries */
+ unsigned int len; /* Used number of entries */
+ unsigned int alloc; /* Size of *scan in bytes */
+ u64 ir_type;
+ char *name;
+ spinlock_t lock;
+};
+
+struct rc_keymap {
+ struct list_head list;
+ struct ir_scancode_table map;
+};
+
+/* Routines from rc-map.c */
+
+int ir_register_map(struct rc_keymap *map);
+void ir_unregister_map(struct rc_keymap *map);
+struct ir_scancode_table *get_rc_map(const char *name);
+void rc_map_init(void);
+
+/* Names of the several keytables defined in-kernel */
#define RC_MAP_ADSTECH_DVB_T_PCI "rc-adstech-dvb-t-pci"
#define RC_MAP_APAC_VIEWCOMP "rc-apac-viewcomp"
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 24/26] V4L/DVB: ir-core: Add support for badly-implemented hardware decoders
[not found] <cover.1270577768.git.mchehab@redhat.com>
2010-04-06 18:18 ` [PATCH 22/26] V4L-DVB: ir-core: remove the ancillary buffer Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 23/26] V4L/DVB: ir-core: move rc map code to rc-map.h Mauro Carvalho Chehab
` (23 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
A few hardware Remote Controller decoders, even using a standard protocol,
aren't able to provide the entire scancode. Due to that, the capability
of using other IR's are limited on those hardware.
Adds a way to indicate to ir-core what are the bits that the hardware
provides, from a scancode, allowing the addition of a complete IR table
to the kernel and allowing a limited support for changing the Remote
Controller on those devices.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
create mode 100644 drivers/media/IR/keymaps/rc-pixelview-mk12.c
diff --git a/drivers/media/IR/ir-keytable.c b/drivers/media/IR/ir-keytable.c
index 39d8fcb..f509be2 100644
--- a/drivers/media/IR/ir-keytable.c
+++ b/drivers/media/IR/ir-keytable.c
@@ -88,6 +88,18 @@ static int ir_do_setkeycode(struct input_dev *dev,
{
unsigned int i;
int old_keycode = KEY_RESERVED;
+ struct ir_input_dev *ir_dev = input_get_drvdata(dev);
+
+ /*
+ * Unfortunately, some hardware-based IR decoders don't provide
+ * all bits for the complete IR code. In general, they provide only
+ * the command part of the IR code. Yet, as it is possible to replace
+ * the provided IR with another one, it is needed to allow loading
+ * IR tables from other remotes. So,
+ */
+ if (ir_dev->props && ir_dev->props->scanmask) {
+ scancode &= ir_dev->props->scanmask;
+ }
/* First check if we already have a mapping for this ir command */
for (i = 0; i < rc_tab->len; i++) {
@@ -447,6 +459,13 @@ int __ir_input_register(struct input_dev *input_dev,
sizeof(struct ir_scancode));
ir_dev->rc_tab.scan = kmalloc(ir_dev->rc_tab.alloc, GFP_KERNEL);
ir_dev->rc_tab.size = ir_dev->rc_tab.alloc / sizeof(struct ir_scancode);
+ if (props) {
+ ir_dev->props = props;
+ if (props->open)
+ input_dev->open = ir_open;
+ if (props->close)
+ input_dev->close = ir_close;
+ }
if (!ir_dev->rc_tab.scan) {
rc = -ENOMEM;
@@ -464,12 +483,6 @@ int __ir_input_register(struct input_dev *input_dev,
goto out_table;
}
- ir_dev->props = props;
- if (props && props->open)
- input_dev->open = ir_open;
- if (props && props->close)
- input_dev->close = ir_close;
-
rc = ir_register_class(input_dev);
if (rc < 0)
goto out_table;
diff --git a/drivers/media/IR/keymaps/Makefile b/drivers/media/IR/keymaps/Makefile
index 937b7db..c4d891d 100644
--- a/drivers/media/IR/keymaps/Makefile
+++ b/drivers/media/IR/keymaps/Makefile
@@ -46,6 +46,7 @@ obj-$(CONFIG_RC_MAP) += rc-adstech-dvb-t-pci.o \
rc-pinnacle-grey.o \
rc-pinnacle-pctv-hd.o \
rc-pixelview.o \
+ rc-pixelview-mk12.o \
rc-pixelview-new.o \
rc-powercolor-real-angel.o \
rc-proteus-2309.o \
diff --git a/drivers/media/IR/keymaps/rc-pixelview-mk12.c b/drivers/media/IR/keymaps/rc-pixelview-mk12.c
new file mode 100644
index 0000000..5a735d5
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-pixelview-mk12.c
@@ -0,0 +1,83 @@
+/* rc-pixelview-mk12.h - Keytable for pixelview Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/*
+ * Keytable for MK-F12 IR remote provided together with Pixelview
+ * Ultra Pro Remote Controller. Uses NEC extended format.
+ */
+static struct ir_scancode pixelview_mk12[] = {
+ { 0x866b03, KEY_TUNER }, /* Timeshift */
+ { 0x866b1e, KEY_POWER2 }, /* power */
+
+ { 0x866b01, KEY_1 },
+ { 0x866b0b, KEY_2 },
+ { 0x866b1b, KEY_3 },
+ { 0x866b05, KEY_4 },
+ { 0x866b09, KEY_5 },
+ { 0x866b15, KEY_6 },
+ { 0x866b06, KEY_7 },
+ { 0x866b0a, KEY_8 },
+ { 0x866b12, KEY_9 },
+ { 0x866b02, KEY_0 },
+
+ { 0x866b13, KEY_AGAIN }, /* loop */
+ { 0x866b10, KEY_DIGITS }, /* +100 */
+
+ { 0x866b00, KEY_MEDIA }, /* source */
+ { 0x866b18, KEY_MUTE }, /* mute */
+ { 0x866b19, KEY_CAMERA }, /* snapshot */
+ { 0x866b1a, KEY_SEARCH }, /* scan */
+
+ { 0x866b16, KEY_CHANNELUP }, /* chn + */
+ { 0x866b14, KEY_CHANNELDOWN }, /* chn - */
+ { 0x866b1f, KEY_VOLUMEUP }, /* vol + */
+ { 0x866b17, KEY_VOLUMEDOWN }, /* vol - */
+ { 0x866b1c, KEY_ZOOM }, /* zoom */
+
+ { 0x866b04, KEY_REWIND },
+ { 0x866b0e, KEY_RECORD },
+ { 0x866b0c, KEY_FORWARD },
+
+ { 0x866b1d, KEY_STOP },
+ { 0x866b08, KEY_PLAY },
+ { 0x866b0f, KEY_PAUSE },
+
+ { 0x866b0d, KEY_TV },
+ { 0x866b07, KEY_RADIO }, /* FM */
+};
+
+static struct rc_keymap pixelview_map = {
+ .map = {
+ .scan = pixelview_mk12,
+ .size = ARRAY_SIZE(pixelview_mk12),
+ .ir_type = IR_TYPE_NEC,
+ .name = RC_MAP_PIXELVIEW_MK12,
+ }
+};
+
+static int __init init_rc_map_pixelview(void)
+{
+ return ir_register_map(&pixelview_map);
+}
+
+static void __exit exit_rc_map_pixelview(void)
+{
+ ir_unregister_map(&pixelview_map);
+}
+
+module_init(init_rc_map_pixelview)
+module_exit(exit_rc_map_pixelview)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/video/cx88/cx88-input.c b/drivers/media/video/cx88/cx88-input.c
index 9dbec1c..5e60b48 100644
--- a/drivers/media/video/cx88/cx88-input.c
+++ b/drivers/media/video/cx88/cx88-input.c
@@ -247,6 +247,9 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
char *ir_codes = NULL;
u64 ir_type = IR_TYPE_OTHER;
int err = -ENOMEM;
+ u32 hardware_mask = 0; /* For devices with a hardware mask, when
+ * used with a full-code IR table
+ */
ir = kzalloc(sizeof(*ir), GFP_KERNEL);
input_dev = input_allocate_device();
@@ -313,11 +316,18 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
break;
case CX88_BOARD_PROLINK_PLAYTVPVR:
case CX88_BOARD_PIXELVIEW_PLAYTV_ULTRA_PRO:
- ir_codes = RC_MAP_PIXELVIEW;
+ /*
+ * It seems that this hardware is paired with NEC extended
+ * address 0x866b. So, unfortunately, its usage with other
+ * IR's with different address won't work. Still, there are
+ * other IR's from the same manufacturer that works, like the
+ * 002-T mini RC, provided with newer PV hardware
+ */
+ ir_codes = RC_MAP_PIXELVIEW_MK12;
ir->gpio_addr = MO_GP1_IO;
- ir->mask_keycode = 0x1f; /* Only command is retrieved */
ir->mask_keyup = 0x80;
ir->polling = 10; /* ms */
+ hardware_mask = 0x3f; /* Hardware returns only 6 bits from command part */
break;
case CX88_BOARD_PROLINK_PV_8000GT:
case CX88_BOARD_PROLINK_PV_GLOBAL_XTREME:
@@ -409,6 +419,21 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
goto err_out_free;
}
+ /*
+ * The usage of mask_keycode were very convenient, due to several
+ * reasons. Among others, the scancode tables were using the scancode
+ * as the index elements. So, the less bits it was used, the smaller
+ * the table were stored. After the input changes, the better is to use
+ * the full scancodes, since it allows replacing the IR remote by
+ * another one. Unfortunately, there are still some hardware, like
+ * Pixelview Ultra Pro, where only part of the scancode is sent via
+ * GPIO. So, there's no way to get the full scancode. Due to that,
+ * hardware_mask were introduced here: it represents those hardware
+ * that has such limits.
+ */
+ if (hardware_mask && !ir->mask_keycode)
+ ir->mask_keycode = hardware_mask;
+
/* init input device */
snprintf(ir->name, sizeof(ir->name), "cx88 IR (%s)", core->board.name);
snprintf(ir->phys, sizeof(ir->phys), "pci-%s/ir0", pci_name(pci));
@@ -436,6 +461,7 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
ir->props.priv = core;
ir->props.open = cx88_ir_open;
ir->props.close = cx88_ir_close;
+ ir->props.scanmask = hardware_mask;
/* all done */
err = ir_input_register(ir->input, ir_codes, &ir->props, MODULE_NAME);
diff --git a/include/media/ir-core.h b/include/media/ir-core.h
index 0f64b48..4397ea3 100644
--- a/include/media/ir-core.h
+++ b/include/media/ir-core.h
@@ -33,12 +33,28 @@ enum raw_event_type {
IR_STOP_EVENT = (1 << 3),
};
+/**
+ * struct ir_dev_props - Allow caller drivers to set special properties
+ * @allowed_protos: bitmask with the supported IR_TYPE_* protocols
+ * @scanmask: some hardware decoders are not capable of providing the full
+ * scancode to the application. As this is a hardware limit, we can't do
+ * anything with it. Yet, as the same keycode table can be used with other
+ * devices, a mask is provided to allow its usage. Drivers should generally
+ * leave this field in blank
+ * @priv: driver-specific data, to be used on the callbacks
+ * @change_protocol: allow changing the protocol used on hardware decoders
+ * @open: callback to allow drivers to enable polling/irq when IR input device
+ * is opened.
+ * @close: callback to allow drivers to disable polling/irq when IR input device
+ * is opened.
+ */
struct ir_dev_props {
- unsigned long allowed_protos;
+ unsigned long allowed_protos;
+ u32 scanmask;
void *priv;
- int (*change_protocol)(void *priv, u64 ir_type);
- int (*open)(void *priv);
- void (*close)(void *priv);
+ int (*change_protocol)(void *priv, u64 ir_type);
+ int (*open)(void *priv);
+ void (*close)(void *priv);
};
struct ir_raw_event {
diff --git a/include/media/rc-map.h b/include/media/rc-map.h
index b10990d..3b7fe5a 100644
--- a/include/media/rc-map.h
+++ b/include/media/rc-map.h
@@ -18,7 +18,7 @@
#define IR_TYPE_OTHER (1u << 31)
struct ir_scancode {
- u16 scancode;
+ u32 scancode;
u32 keycode;
};
@@ -95,6 +95,7 @@ void rc_map_init(void);
#define RC_MAP_PINNACLE_PCTV_HD "rc-pinnacle-pctv-hd"
#define RC_MAP_PIXELVIEW_NEW "rc-pixelview-new"
#define RC_MAP_PIXELVIEW "rc-pixelview"
+#define RC_MAP_PIXELVIEW_MK12 "rc-pixelview-mk12"
#define RC_MAP_POWERCOLOR_REAL_ANGEL "rc-powercolor-real-angel"
#define RC_MAP_PROTEUS_2309 "rc-proteus-2309"
#define RC_MAP_PURPLETV "rc-purpletv"
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 21/26] V4L/DVB: cx88: don't handle IR on Pixelview too fast
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (4 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 25/26] V4L/DVB: re-add enable/disable check to the IR decoders Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 13/26] V4L/DVB: saa7134: Add support for both positive and negative edge IRQ Mauro Carvalho Chehab
` (19 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/video/cx88/cx88-input.c b/drivers/media/video/cx88/cx88-input.c
index f5d6130..9dbec1c 100644
--- a/drivers/media/video/cx88/cx88-input.c
+++ b/drivers/media/video/cx88/cx88-input.c
@@ -315,9 +315,9 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
case CX88_BOARD_PIXELVIEW_PLAYTV_ULTRA_PRO:
ir_codes = RC_MAP_PIXELVIEW;
ir->gpio_addr = MO_GP1_IO;
- ir->mask_keycode = 0x1f;
+ ir->mask_keycode = 0x1f; /* Only command is retrieved */
ir->mask_keyup = 0x80;
- ir->polling = 1; /* ms */
+ ir->polling = 10; /* ms */
break;
case CX88_BOARD_PROLINK_PV_8000GT:
case CX88_BOARD_PROLINK_PV_GLOBAL_XTREME:
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 18/26] V4L/DVB: ir-nec-decoder: Reimplement the entire decoder
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (8 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 19/26] ir-nec-decoder: Cleanups Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 15/26] V4L/DVB: ir-core: re-add some debug functions for keytable changes Mauro Carvalho Chehab
` (15 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
Thanks to Andy Walls <awalls@md.metrocast.net> for pointing me his
code, that gave me some ideas to better implement it.
After some work with saa7134 bits, I found a way to catch both IRQ
edge pulses. By enabling it, the NEC decoder can now take both
pulse and spaces into account, making it more precise.
Instead of the old strategy of handling the events all at once,
this code implements a state machine. Due to that, it handles
individual pulse or space events, validating them against the
protocol, producing a much more reliable decoding.
With the new implementation, the protocol trailer bits are properly
handled, making possible for the repeat key to work.
Also, the code is now capable of handling both NEC and NEC extended
IR devices. With NEC, it produces a 16 bits code, while with NEC
extended, a 24 bits code is returned.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/IR/ir-nec-decoder.c b/drivers/media/IR/ir-nec-decoder.c
index 0b50060..33b260f 100644
--- a/drivers/media/IR/ir-nec-decoder.c
+++ b/drivers/media/IR/ir-nec-decoder.c
@@ -14,6 +14,14 @@
#include <media/ir-core.h>
+#define NEC_UNIT 559979 /* ns */
+#define NEC_HEADER_MARK (16 * NEC_UNIT)
+#define NEC_HEADER_SPACE (8 * NEC_UNIT)
+#define NEC_REPEAT_SPACE (4 * NEC_UNIT)
+#define NEC_MARK (NEC_UNIT)
+#define NEC_0_SYMBOL (NEC_UNIT)
+#define NEC_1_SYMBOL (3 * NEC_UNIT)
+
/* Start time: 4.5 ms + 560 us of the next pulse */
#define MIN_START_TIME (3900000 + 560000)
#define MAX_START_TIME (5100000 + 560000)
@@ -43,10 +51,32 @@
static LIST_HEAD(decoder_list);
static spinlock_t decoder_lock;
+enum nec_state {
+ STATE_INACTIVE,
+ STATE_HEADER_MARK,
+ STATE_HEADER_SPACE,
+ STATE_MARK,
+ STATE_SPACE,
+ STATE_TRAILER_MARK,
+ STATE_TRAILER_SPACE,
+};
+
+struct nec_code {
+ u8 address;
+ u8 not_address;
+ u8 command;
+ u8 not_command;
+};
+
struct decoder_data {
struct list_head list;
struct ir_input_dev *ir_dev;
int enabled:1;
+
+ /* State machine control */
+ enum nec_state state;
+ struct nec_code nec_code;
+ unsigned count;
};
@@ -118,139 +148,173 @@ static struct attribute_group decoder_attribute_group = {
};
-/** is_repeat - Check if it is a NEC repeat event
- * @input_dev: the struct input_dev descriptor of the device
- * @pos: the position of the first event
- * @len: the length of the buffer
- */
-static int is_repeat(struct ir_raw_event *evs, int len, int pos)
-{
- if ((evs[pos].delta.tv_nsec < MIN_REPEAT_START_TIME) ||
- (evs[pos].delta.tv_nsec > MAX_REPEAT_START_TIME))
- return 0;
-
- if (++pos >= len)
- return 0;
-
- if ((evs[pos].delta.tv_nsec < MIN_REPEAT_TIME) ||
- (evs[pos].delta.tv_nsec > MAX_REPEAT_TIME))
- return 0;
-
- return 1;
-}
-
/**
- * __ir_nec_decode() - Decode one NEC pulsecode
+ * handle_event() - Decode one NEC pulse or space
* @input_dev: the struct input_dev descriptor of the device
- * @evs: event array with type/duration of pulse/space
- * @len: length of the array
- * @pos: position to start seeking for a code
- * This function returns -EINVAL if no pulse got decoded,
- * 0 if buffer is empty and 1 if one keycode were handled.
+ * @ev: event array with type/duration of pulse/space
+ *
+ * This function returns -EINVAL if the pulse violates the state machine
*/
-static int __ir_nec_decode(struct input_dev *input_dev,
- struct ir_raw_event *evs,
- int len, int *pos)
+static int handle_event(struct input_dev *input_dev,
+ struct ir_raw_event *ev)
{
- struct ir_input_dev *ir = input_get_drvdata(input_dev);
- int count = -1;
- int ircode = 0, not_code = 0;
-
- /* Be sure that the first event is an start one and is a pulse */
- for (; *pos < len; (*pos)++) {
- /* Very long delays are considered as start events */
- if (evs[*pos].delta.tv_nsec > MAX_NEC_TIME)
- break;
- if (evs[*pos].type & IR_START_EVENT)
- break;
- IR_dprintk(1, "%luus: Spurious NEC %s\n",
- (evs[*pos].delta.tv_nsec + 500) / 1000,
- (evs[*pos].type & IR_SPACE) ? "space" : "pulse");
-
- }
- if (*pos >= len)
- return 0;
+ struct decoder_data *data;
+ struct ir_input_dev *ir_dev = input_get_drvdata(input_dev);
+ int bit, last_bit;
+
+ data = get_decoder_data(ir_dev);
+ if (!data)
+ return -EINVAL;
+
+ /* Except for the initial event, what matters is the previous bit */
+ bit = (ev->type & IR_PULSE) ? 1 : 0;
+
+ last_bit = !bit;
+
+ /* Discards spurious space last_bits when inactive */
- (*pos)++; /* First event doesn't contain data */
+ /* Very long delays are considered as start events */
+ if (ev->delta.tv_nsec > NEC_HEADER_MARK + NEC_HEADER_SPACE - NEC_UNIT / 2)
+ data->state = STATE_INACTIVE;
- if (evs[*pos].type != IR_PULSE)
- goto err;
+ if (ev->type & IR_START_EVENT)
+ data->state = STATE_INACTIVE;
+
+ switch (data->state) {
+ case STATE_INACTIVE:
+ if (!bit) /* PULSE marks the start event */
+ return 0;
+
+ data->count = 0;
+ data->state = STATE_HEADER_MARK;
+ memset (&data->nec_code, 0, sizeof(data->nec_code));
+ return 0;
+ case STATE_HEADER_MARK:
+ if (!last_bit)
+ goto err;
+ if (ev->delta.tv_nsec < NEC_HEADER_MARK - 6 * NEC_UNIT)
+ goto err;
+ data->state = STATE_HEADER_SPACE;
+ return 0;
+ case STATE_HEADER_SPACE:
+ if (last_bit)
+ goto err;
+ if (ev->delta.tv_nsec >= NEC_HEADER_SPACE - NEC_UNIT / 2) {
+ data->state = STATE_MARK;
+ return 0;
+ }
- /* Check if it is a NEC repeat event */
- if (is_repeat(evs, len, *pos)) {
- *pos += 2;
- if (ir->keypressed) {
+ if (ev->delta.tv_nsec >= NEC_REPEAT_SPACE - NEC_UNIT / 2) {
ir_repeat(input_dev);
- IR_dprintk(1, "NEC repeat event\n");
- return 1;
- } else {
- IR_dprintk(1, "missing NEC repeat event\n");
+ IR_dprintk(1, "Repeat last key\n");
+ data->state = STATE_TRAILER_MARK;
return 0;
}
- }
-
- /* First space should have 4.5 ms otherwise is not NEC protocol */
- if ((evs[*pos].delta.tv_nsec < MIN_START_TIME) ||
- (evs[*pos].delta.tv_nsec > MAX_START_TIME))
goto err;
+ case STATE_MARK:
+ if (!last_bit)
+ goto err;
+ if ((ev->delta.tv_nsec > NEC_MARK + NEC_UNIT / 2) ||
+ (ev->delta.tv_nsec < NEC_MARK - NEC_UNIT / 2))
+ goto err;
+ data->state = STATE_SPACE;
+ return 0;
+ case STATE_SPACE:
+ if (last_bit)
+ goto err;
- count = 0;
- for ((*pos)++; *pos < len; (*pos)++) {
- int bit;
- if ((evs[*pos].delta.tv_nsec > MIN_BIT1_TIME) &&
- (evs[*pos].delta.tv_nsec < MAX_BIT1_TIME))
- bit = 1;
- else if ((evs[*pos].delta.tv_nsec > MIN_BIT0_TIME) &&
- (evs[*pos].delta.tv_nsec < MAX_BIT0_TIME))
+ if ((ev->delta.tv_nsec >= NEC_0_SYMBOL - NEC_UNIT / 2) &&
+ (ev->delta.tv_nsec < NEC_0_SYMBOL + NEC_UNIT / 2))
bit = 0;
- else
- goto err;
+ else if ((ev->delta.tv_nsec >= NEC_1_SYMBOL - NEC_UNIT / 2) &&
+ (ev->delta.tv_nsec < NEC_1_SYMBOL + NEC_UNIT / 2))
+ bit = 1;
+ else {
+ IR_dprintk(1, "Decode failed at %d-th bit (%s) @%luus\n",
+ data->count,
+ last_bit ? "pulse" : "space",
+ (ev->delta.tv_nsec + 500) / 1000);
+ goto err2;
+ }
+
+ /* Ok, we've got a valid bit. proccess it */
if (bit) {
- int shift = count;
- /* Address first, then command */
+ int shift = data->count;
+
+ /*
+ * NEC transmit bytes on this temporal order:
+ * address | not address | command | not command
+ */
if (shift < 8) {
- shift += 8;
- ircode |= 1 << shift;
+ data->nec_code.address |= 1 << shift;
} else if (shift < 16) {
- not_code |= 1 << shift;
+ data->nec_code.not_address |= 1 << (shift - 8);
} else if (shift < 24) {
- shift -= 16;
- ircode |= 1 << shift;
+ data->nec_code.command |= 1 << (shift - 16);
} else {
- shift -= 24;
- not_code |= 1 << shift;
+ data->nec_code.not_command |= 1 << (shift - 24);
}
}
- if (++count == 32)
- break;
- }
- (*pos)++;
+ if (++data->count == 32) {
+ u32 scancode;
+ /*
+ * Fixme: may need to accept Extended NEC protocol?
+ */
+ if ((data->nec_code.command ^ data->nec_code.not_command) != 0xff)
+ goto checksum_err;
- /*
- * Fixme: may need to accept Extended NEC protocol?
- */
- if ((ircode & ~not_code) != ircode) {
- IR_dprintk(1, "NEC checksum error: code 0x%04x, not-code 0x%04x\n",
- ircode, not_code);
- return -EINVAL;
- }
+ if ((data->nec_code.address ^ data->nec_code.not_address) != 0xff) {
+ /* Extended NEC */
+ scancode = data->nec_code.address << 16 |
+ data->nec_code.not_address << 8 |
+ data->nec_code.command;
+ IR_dprintk(1, "NEC scancode 0x%06x\n", scancode);
+ } else {
+ /* normal NEC */
+ scancode = data->nec_code.address << 8 |
+ data->nec_code.command;
+ IR_dprintk(1, "NEC scancode 0x%04x\n", scancode);
+ }
+ ir_keydown(input_dev, scancode, 0);
- IR_dprintk(1, "NEC scancode 0x%04x\n", ircode);
- ir_keydown(input_dev, ircode, 0);
+ data->state = STATE_TRAILER_MARK;
+ } else
+ data->state = STATE_MARK;
+ return 0;
+ case STATE_TRAILER_MARK:
+ if (!last_bit)
+ goto err;
+ data->state = STATE_TRAILER_SPACE;
+ return 0;
+ case STATE_TRAILER_SPACE:
+ if (last_bit)
+ goto err;
+ data->state = STATE_INACTIVE;
+ return 0;
+ }
- return 1;
err:
- IR_dprintk(1, "NEC decoded failed at bit %d (%s) while decoding %luus time\n",
- count,
- (evs[*pos].type & IR_SPACE) ? "space" : "pulse",
- (evs[*pos].delta.tv_nsec + 500) / 1000);
+ IR_dprintk(1, "NEC decoded failed at state %d (%s) @ %luus\n",
+ data->state,
+ bit ? "pulse" : "space",
+ (ev->delta.tv_nsec + 500) / 1000);
+err2:
+ data->state = STATE_INACTIVE;
+ return -EINVAL;
+checksum_err:
+ data->state = STATE_INACTIVE;
+ IR_dprintk(1, "NEC checksum error: received 0x%02x%02x%02x%02x\n",
+ data->nec_code.address,
+ data->nec_code.not_address,
+ data->nec_code.command,
+ data->nec_code.not_command);
return -EINVAL;
}
/**
- * __ir_nec_decode() - Decodes all NEC pulsecodes on a given array
+ * ir_nec_decode() - Decodes all NEC pulsecodes on a given array
* @input_dev: the struct input_dev descriptor of the device
* @evs: event array with type/duration of pulse/space
* @len: length of the array
@@ -269,10 +333,9 @@ static int ir_nec_decode(struct input_dev *input_dev,
if (!data || !data->enabled)
return 0;
- while (pos < len) {
- if (__ir_nec_decode(input_dev, evs, len, &pos) > 0)
- rc++;
- }
+ for (pos = 0; pos < len; pos++)
+ handle_event(input_dev, &evs[pos]);
+
return rc;
}
diff --git a/drivers/media/video/saa7134/saa7134-input.c b/drivers/media/video/saa7134/saa7134-input.c
index fd3225c..5dac6b7 100644
--- a/drivers/media/video/saa7134/saa7134-input.c
+++ b/drivers/media/video/saa7134/saa7134-input.c
@@ -658,7 +658,8 @@ int saa7134_input_init1(struct saa7134_dev *dev)
break;
case SAA7134_BOARD_AVERMEDIA_M135A:
ir_codes = RC_MAP_AVERMEDIA_M135A_RM_JX;
- mask_keydown = 0x0040000;
+ mask_keydown = 0x0040000; /* Enable GPIO18 line on both edges */
+ mask_keyup = 0x0040000;
mask_keycode = 0xffff;
raw_decode = 1;
break;
@@ -1014,13 +1015,13 @@ static int saa7134_raw_decode_irq(struct saa7134_dev *dev)
{
struct card_ir *ir = dev->remote;
unsigned long timeout;
- int pulse;
+ int space;
/* Generate initial event */
saa_clearb(SAA7134_GPIO_GPMODE3, SAA7134_GPIO_GPRESCAN);
saa_setb(SAA7134_GPIO_GPMODE3, SAA7134_GPIO_GPRESCAN);
- pulse = saa_readl(SAA7134_GPIO_GPSTATUS0 >> 2) & ir->mask_keydown;
- ir_raw_event_store(dev->remote->dev, pulse ? IR_PULSE : IR_SPACE);
+ space = saa_readl(SAA7134_GPIO_GPSTATUS0 >> 2) & ir->mask_keydown;
+ ir_raw_event_store(dev->remote->dev, space ? IR_SPACE : IR_PULSE);
/*
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 15/26] V4L/DVB: ir-core: re-add some debug functions for keytable changes
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (9 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 18/26] V4L/DVB: ir-nec-decoder: Reimplement the entire decoder Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 17/26] V4L/DVB: Convert drivers/media/dvb/ttpci/budget-ci.c to use ir-core Mauro Carvalho Chehab
` (14 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/IR/ir-keytable.c b/drivers/media/IR/ir-keytable.c
index d3bc909..00db928 100644
--- a/drivers/media/IR/ir-keytable.c
+++ b/drivers/media/IR/ir-keytable.c
@@ -99,6 +99,8 @@ static int ir_do_setkeycode(struct input_dev *dev,
/* Did the user wish to remove the mapping? */
if (keycode == KEY_RESERVED || keycode == KEY_UNKNOWN) {
+ IR_dprintk(1, "#%d: Deleting scan 0x%04x\n",
+ i, scancode);
rc_tab->len--;
memmove(&rc_tab->scan[i], &rc_tab->scan[i + 1],
(rc_tab->len - i) * sizeof(struct ir_scancode));
@@ -114,6 +116,9 @@ static int ir_do_setkeycode(struct input_dev *dev,
if (ir_resize_table(rc_tab))
return -ENOMEM;
+ IR_dprintk(1, "#%d: New scan 0x%04x with key 0x%04x\n",
+ i, scancode, keycode);
+
/* i is the proper index to insert our new keycode */
memmove(&rc_tab->scan[i + 1], &rc_tab->scan[i],
(rc_tab->len - i) * sizeof(struct ir_scancode));
@@ -122,6 +127,8 @@ static int ir_do_setkeycode(struct input_dev *dev,
rc_tab->len++;
set_bit(keycode, dev->keybit);
} else {
+ IR_dprintk(1, "#%d: Replacing scan 0x%04x with key 0x%04x\n",
+ i, scancode, keycode);
/* A previous mapping was updated... */
clear_bit(old_keycode, dev->keybit);
/* ...but another scancode might use the same keycode */
@@ -223,6 +230,10 @@ static int ir_getkeycode(struct input_dev *dev,
}
spin_unlock_irqrestore(&rc_tab->lock, flags);
+ if (key == KEY_RESERVED)
+ IR_dprintk(1, "unknown key for scancode 0x%04x\n",
+ scancode);
+
*keycode = key;
return 0;
}
@@ -242,8 +253,9 @@ u32 ir_g_keycode_from_table(struct input_dev *dev, u32 scancode)
int keycode;
ir_getkeycode(dev, scancode, &keycode);
- IR_dprintk(1, "%s: scancode 0x%04x keycode 0x%02x\n",
- dev->name, scancode, keycode);
+ if (keycode != KEY_RESERVED)
+ IR_dprintk(1, "%s: scancode 0x%04x keycode 0x%02x\n",
+ dev->name, scancode, keycode);
return keycode;
}
EXPORT_SYMBOL_GPL(ir_g_keycode_from_table);
@@ -385,6 +397,9 @@ int __ir_input_register(struct input_dev *input_dev,
if (rc < 0)
goto out_table;
+ IR_dprintk(1, "Registered input device on %s for %s remote.\n",
+ driver_name, rc_tab->name);
+
return 0;
out_table:
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 19/26] ir-nec-decoder: Cleanups
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (7 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 20/26] V4L-DVB: ir-rc5-decoder: Add a decoder for RC-5 IR protocol Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 18/26] V4L/DVB: ir-nec-decoder: Reimplement the entire decoder Mauro Carvalho Chehab
` (16 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
Remove dead code and properly name a few constants
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/IR/ir-nec-decoder.c b/drivers/media/IR/ir-nec-decoder.c
index 33b260f..087211c 100644
--- a/drivers/media/IR/ir-nec-decoder.c
+++ b/drivers/media/IR/ir-nec-decoder.c
@@ -14,38 +14,14 @@
#include <media/ir-core.h>
+#define NEC_NBITS 32
#define NEC_UNIT 559979 /* ns */
#define NEC_HEADER_MARK (16 * NEC_UNIT)
#define NEC_HEADER_SPACE (8 * NEC_UNIT)
#define NEC_REPEAT_SPACE (4 * NEC_UNIT)
#define NEC_MARK (NEC_UNIT)
-#define NEC_0_SYMBOL (NEC_UNIT)
-#define NEC_1_SYMBOL (3 * NEC_UNIT)
-
-/* Start time: 4.5 ms + 560 us of the next pulse */
-#define MIN_START_TIME (3900000 + 560000)
-#define MAX_START_TIME (5100000 + 560000)
-
-/* Bit 1 time: 2.25ms us */
-#define MIN_BIT1_TIME 2050000
-#define MAX_BIT1_TIME 2450000
-
-/* Bit 0 time: 1.12ms us */
-#define MIN_BIT0_TIME 920000
-#define MAX_BIT0_TIME 1320000
-
-/* Total IR code is 110 ms, including the 9 ms for the start pulse */
-#define MAX_NEC_TIME 4000000
-
-/* Total IR code is 110 ms, including the 9 ms for the start pulse */
-#define MIN_REPEAT_TIME 99000000
-#define MAX_REPEAT_TIME 112000000
-
-/* Repeat time: 2.25ms us */
-#define MIN_REPEAT_START_TIME 2050000
-#define MAX_REPEAT_START_TIME 3000000
-
-#define REPEAT_TIME 240 /* ms */
+#define NEC_0_SPACE (NEC_UNIT)
+#define NEC_1_SPACE (3 * NEC_UNIT)
/* Used to register nec_decoder clients */
static LIST_HEAD(decoder_list);
@@ -223,11 +199,11 @@ static int handle_event(struct input_dev *input_dev,
if (last_bit)
goto err;
- if ((ev->delta.tv_nsec >= NEC_0_SYMBOL - NEC_UNIT / 2) &&
- (ev->delta.tv_nsec < NEC_0_SYMBOL + NEC_UNIT / 2))
+ if ((ev->delta.tv_nsec >= NEC_0_SPACE - NEC_UNIT / 2) &&
+ (ev->delta.tv_nsec < NEC_0_SPACE + NEC_UNIT / 2))
bit = 0;
- else if ((ev->delta.tv_nsec >= NEC_1_SYMBOL - NEC_UNIT / 2) &&
- (ev->delta.tv_nsec < NEC_1_SYMBOL + NEC_UNIT / 2))
+ else if ((ev->delta.tv_nsec >= NEC_1_SPACE - NEC_UNIT / 2) &&
+ (ev->delta.tv_nsec < NEC_1_SPACE + NEC_UNIT / 2))
bit = 1;
else {
IR_dprintk(1, "Decode failed at %d-th bit (%s) @%luus\n",
@@ -256,7 +232,7 @@ static int handle_event(struct input_dev *input_dev,
data->nec_code.not_command |= 1 << (shift - 24);
}
}
- if (++data->count == 32) {
+ if (++data->count == NEC_NBITS) {
u32 scancode;
/*
* Fixme: may need to accept Extended NEC protocol?
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 20/26] V4L-DVB: ir-rc5-decoder: Add a decoder for RC-5 IR protocol
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (6 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 13/26] V4L/DVB: saa7134: Add support for both positive and negative edge IRQ Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 19/26] ir-nec-decoder: Cleanups Mauro Carvalho Chehab
` (17 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
This decoder is also based on a state machine, just like the NEC protocol
decoder. It is pedantic in the sense that accepts only 14 bits. As there
are some variants that outputs less bits, it needs to be improved to also
handle those.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
create mode 100644 drivers/media/IR/ir-rc5-decoder.c
diff --git a/drivers/media/IR/Kconfig b/drivers/media/IR/Kconfig
index 0c557b8..ba81bda 100644
--- a/drivers/media/IR/Kconfig
+++ b/drivers/media/IR/Kconfig
@@ -18,3 +18,12 @@ config IR_NEC_DECODER
---help---
Enable this option if you have IR with NEC protocol, and
if the IR is decoded in software
+
+config IR_RC5_DECODER
+ tristate "Enable IR raw decoder for RC-5 protocol"
+ depends on IR_CORE
+ default y
+
+ ---help---
+ Enable this option if you have IR with RC-5 protocol, and
+ if the IR is decoded in software
diff --git a/drivers/media/IR/Makefile b/drivers/media/IR/Makefile
index 0e3f912..62e12d5 100644
--- a/drivers/media/IR/Makefile
+++ b/drivers/media/IR/Makefile
@@ -6,3 +6,4 @@ obj-y += keymaps/
obj-$(CONFIG_IR_CORE) += ir-core.o
obj-$(CONFIG_VIDEO_IR) += ir-common.o
obj-$(CONFIG_IR_NEC_DECODER) += ir-nec-decoder.o
+obj-$(CONFIG_IR_RC5_DECODER) += ir-rc5-decoder.o
diff --git a/drivers/media/IR/ir-raw-event.c b/drivers/media/IR/ir-raw-event.c
index 59f2054..617e437 100644
--- a/drivers/media/IR/ir-raw-event.c
+++ b/drivers/media/IR/ir-raw-event.c
@@ -200,6 +200,7 @@ static void init_decoders(struct work_struct *work)
/* Load the decoder modules */
load_nec_decode();
+ load_rc5_decode();
/* If needed, we may later add some init code. In this case,
it is needed to change the CONFIG_MODULE test at ir-core.h
diff --git a/drivers/media/IR/ir-rc5-decoder.c b/drivers/media/IR/ir-rc5-decoder.c
new file mode 100644
index 0000000..4b7eafe
--- /dev/null
+++ b/drivers/media/IR/ir-rc5-decoder.c
@@ -0,0 +1,371 @@
+/* ir-rc5-decoder.c - handle RC-5 IR Pulse/Space protocol
+ *
+ * Copyright (C) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation version 2 of the License.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+/*
+ * This code only handles 14 bits RC-5 protocols. There are other variants
+ * that use a different number of bits. This is currently unsupported
+ */
+
+#include <media/ir-core.h>
+
+#define RC5_NBITS 14
+#define RC5_HALFBIT 888888 /* ns */
+#define RC5_BIT (RC5_HALFBIT * 2)
+#define RC5_DURATION (RC5_BIT * RC5_NBITS)
+
+#define is_rc5_halfbit(nsec) ((ev->delta.tv_nsec >= RC5_HALFBIT / 2) && \
+ (ev->delta.tv_nsec < RC5_HALFBIT + RC5_HALFBIT / 2))
+
+#define n_half(nsec) ((ev->delta.tv_nsec + RC5_HALFBIT / 2) / RC5_HALFBIT)
+
+/* Used to register rc5_decoder clients */
+static LIST_HEAD(decoder_list);
+static spinlock_t decoder_lock;
+
+enum rc5_state {
+ STATE_INACTIVE,
+ STATE_START2_SPACE,
+ STATE_START2_MARK,
+ STATE_MARKSPACE,
+ STATE_TRAILER_MARK,
+};
+
+static char *st_name[] = {
+ "Inactive",
+ "start2 sapce",
+ "start2 mark",
+ "mark",
+ "space",
+ "trailer"
+};
+
+struct rc5_code {
+ u8 address;
+ u8 command;
+};
+
+struct decoder_data {
+ struct list_head list;
+ struct ir_input_dev *ir_dev;
+ int enabled:1;
+
+ /* State machine control */
+ enum rc5_state state;
+ struct rc5_code rc5_code;
+ unsigned n_half;
+ unsigned count;
+};
+
+
+/**
+ * get_decoder_data() - gets decoder data
+ * @input_dev: input device
+ *
+ * Returns the struct decoder_data that corresponds to a device
+ */
+
+static struct decoder_data *get_decoder_data(struct ir_input_dev *ir_dev)
+{
+ struct decoder_data *data = NULL;
+
+ spin_lock(&decoder_lock);
+ list_for_each_entry(data, &decoder_list, list) {
+ if (data->ir_dev == ir_dev)
+ break;
+ }
+ spin_unlock(&decoder_lock);
+ return data;
+}
+
+static ssize_t store_enabled(struct device *d,
+ struct device_attribute *mattr,
+ const char *buf,
+ size_t len)
+{
+ unsigned long value;
+ struct ir_input_dev *ir_dev = dev_get_drvdata(d);
+ struct decoder_data *data = get_decoder_data(ir_dev);
+
+ if (!data)
+ return -EINVAL;
+
+ if (strict_strtoul(buf, 10, &value) || value > 1)
+ return -EINVAL;
+
+ data->enabled = value;
+
+ return len;
+}
+
+static ssize_t show_enabled(struct device *d,
+ struct device_attribute *mattr, char *buf)
+{
+ struct ir_input_dev *ir_dev = dev_get_drvdata(d);
+ struct decoder_data *data = get_decoder_data(ir_dev);
+
+ if (!data)
+ return -EINVAL;
+
+ if (data->enabled)
+ return sprintf(buf, "1\n");
+ else
+ return sprintf(buf, "0\n");
+}
+
+static DEVICE_ATTR(enabled, S_IRUGO | S_IWUSR, show_enabled, store_enabled);
+
+static struct attribute *decoder_attributes[] = {
+ &dev_attr_enabled.attr,
+ NULL
+};
+
+static struct attribute_group decoder_attribute_group = {
+ .name = "rc5_decoder",
+ .attrs = decoder_attributes,
+};
+
+/**
+ * handle_event() - Decode one RC-5 pulse or space
+ * @input_dev: the struct input_dev descriptor of the device
+ * @ev: event array with type/duration of pulse/space
+ *
+ * This function returns -EINVAL if the pulse violates the state machine
+ */
+static int handle_event(struct input_dev *input_dev,
+ struct ir_raw_event *ev)
+{
+ struct decoder_data *data;
+ struct ir_input_dev *ir_dev = input_get_drvdata(input_dev);
+ int bit, last_bit, n_half;
+
+ data = get_decoder_data(ir_dev);
+ if (!data)
+ return -EINVAL;
+
+ /* Except for the initial event, what matters is the previous bit */
+ bit = (ev->type & IR_PULSE) ? 1 : 0;
+
+ last_bit = !bit;
+
+ /* Discards spurious space last_bits when inactive */
+
+ /* Very long delays are considered as start events */
+ if (ev->delta.tv_nsec > RC5_DURATION + RC5_HALFBIT / 2)
+ data->state = STATE_INACTIVE;
+
+ if (ev->type & IR_START_EVENT)
+ data->state = STATE_INACTIVE;
+
+ switch (data->state) {
+ case STATE_INACTIVE:
+IR_dprintk(1, "currently inative. Received bit (%s) @%luus\n",
+ last_bit ? "pulse" : "space",
+ (ev->delta.tv_nsec + 500) / 1000);
+
+ /* Discards the initial start space */
+ if (bit)
+ return 0;
+ data->count = 0;
+ data->n_half = 0;
+ memset (&data->rc5_code, 0, sizeof(data->rc5_code));
+
+ data->state = STATE_START2_SPACE;
+ return 0;
+ case STATE_START2_SPACE:
+ if (last_bit)
+ goto err;
+ if (!is_rc5_halfbit(ev->delta.tv_nsec))
+ goto err;
+ data->state = STATE_START2_MARK;
+ return 0;
+ case STATE_START2_MARK:
+ if (!last_bit)
+ goto err;
+
+ if (!is_rc5_halfbit(ev->delta.tv_nsec))
+ goto err;
+
+ data->state = STATE_MARKSPACE;
+ return 0;
+ case STATE_MARKSPACE:
+ n_half = n_half(ev->delta.tv_nsec);
+ if (n_half < 1 || n_half > 3) {
+ IR_dprintk(1, "Decode failed at %d-th bit (%s) @%luus\n",
+ data->count,
+ last_bit ? "pulse" : "space",
+ (ev->delta.tv_nsec + 500) / 1000);
+printk("%d halves\n", n_half);
+ goto err2;
+ }
+ data->n_half += n_half;
+
+ if (!last_bit)
+ return 0;
+
+ /* Got one complete mark/space cycle */
+
+ bit = ((data->count + 1) * 2)/ data->n_half;
+
+printk("%d halves, %d bits\n", n_half, bit);
+
+#if 1 /* SANITY check - while testing the decoder */
+ if (bit > 1) {
+ IR_dprintk(1, "Decoder HAS failed at %d-th bit (%s) @%luus\n",
+ data->count,
+ last_bit ? "pulse" : "space",
+ (ev->delta.tv_nsec + 500) / 1000);
+
+ goto err2;
+ }
+#endif
+ /* Ok, we've got a valid bit. proccess it */
+ if (bit) {
+ int shift = data->count;
+
+ /*
+ * RC-5 transmit bytes on this temporal order:
+ * address | not address | command | not command
+ */
+ if (shift < 8) {
+ data->rc5_code.address |= 1 << shift;
+ } else {
+ data->rc5_code.command |= 1 << (shift - 8);
+ }
+ }
+ IR_dprintk(1, "RC-5: bit #%d: %d (%d)\n",
+ data->count, bit, data->n_half);
+ if (++data->count >= RC5_NBITS) {
+ u32 scancode;
+ scancode = data->rc5_code.address << 8 |
+ data->rc5_code.command;
+ IR_dprintk(1, "RC-5 scancode 0x%04x\n", scancode);
+
+ ir_keydown(input_dev, scancode, 0);
+
+ data->state = STATE_TRAILER_MARK;
+ }
+ return 0;
+ case STATE_TRAILER_MARK:
+ if (!last_bit)
+ goto err;
+ data->state = STATE_INACTIVE;
+ return 0;
+ }
+
+err:
+ IR_dprintk(1, "RC-5 decoded failed at state %s (%s) @ %luus\n",
+ st_name[data->state],
+ bit ? "pulse" : "space",
+ (ev->delta.tv_nsec + 500) / 1000);
+err2:
+ data->state = STATE_INACTIVE;
+ return -EINVAL;
+}
+
+/**
+ * ir_rc5_decode() - Decodes all RC-5 pulsecodes on a given array
+ * @input_dev: the struct input_dev descriptor of the device
+ * @evs: event array with type/duration of pulse/space
+ * @len: length of the array
+ * This function returns the number of decoded pulses
+ */
+static int ir_rc5_decode(struct input_dev *input_dev,
+ struct ir_raw_event *evs,
+ int len)
+{
+ struct ir_input_dev *ir_dev = input_get_drvdata(input_dev);
+ struct decoder_data *data;
+ int pos = 0;
+ int rc = 0;
+
+ data = get_decoder_data(ir_dev);
+ if (!data || !data->enabled)
+ return 0;
+
+ for (pos = 0; pos < len; pos++)
+ handle_event(input_dev, &evs[pos]);
+
+ return rc;
+}
+
+static int ir_rc5_register(struct input_dev *input_dev)
+{
+ struct ir_input_dev *ir_dev = input_get_drvdata(input_dev);
+ struct decoder_data *data;
+ int rc;
+
+ rc = sysfs_create_group(&ir_dev->dev.kobj, &decoder_attribute_group);
+ if (rc < 0)
+ return rc;
+
+ data = kzalloc(sizeof(*data), GFP_KERNEL);
+ if (!data) {
+ sysfs_remove_group(&ir_dev->dev.kobj, &decoder_attribute_group);
+ return -ENOMEM;
+ }
+
+ data->ir_dev = ir_dev;
+ data->enabled = 1;
+
+ spin_lock(&decoder_lock);
+ list_add_tail(&data->list, &decoder_list);
+ spin_unlock(&decoder_lock);
+
+ return 0;
+}
+
+static int ir_rc5_unregister(struct input_dev *input_dev)
+{
+ struct ir_input_dev *ir_dev = input_get_drvdata(input_dev);
+ static struct decoder_data *data;
+
+ data = get_decoder_data(ir_dev);
+ if (!data)
+ return 0;
+
+ sysfs_remove_group(&ir_dev->dev.kobj, &decoder_attribute_group);
+
+ spin_lock(&decoder_lock);
+ list_del(&data->list);
+ spin_unlock(&decoder_lock);
+
+ return 0;
+}
+
+static struct ir_raw_handler rc5_handler = {
+ .decode = ir_rc5_decode,
+ .raw_register = ir_rc5_register,
+ .raw_unregister = ir_rc5_unregister,
+};
+
+static int __init ir_rc5_decode_init(void)
+{
+ ir_raw_handler_register(&rc5_handler);
+
+ printk(KERN_INFO "IR RC-5 protocol handler initialized\n");
+ return 0;
+}
+
+static void __exit ir_rc5_decode_exit(void)
+{
+ ir_raw_handler_unregister(&rc5_handler);
+}
+
+module_init(ir_rc5_decode_init);
+module_exit(ir_rc5_decode_exit);
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
+MODULE_AUTHOR("Red Hat Inc. (http://www.redhat.com)");
+MODULE_DESCRIPTION("RC-5 IR protocol decoder");
diff --git a/include/media/ir-core.h b/include/media/ir-core.h
index b452a47..4090073 100644
--- a/include/media/ir-core.h
+++ b/include/media/ir-core.h
@@ -178,4 +178,11 @@ void ir_raw_init(void);
#define load_nec_decode() 0
#endif
+/* from ir-rc5-decoder.c */
+#ifdef CONFIG_IR_RC5_DECODER_MODULE
+#define load_rc5_decode() request_module("ir-rc5-decoder")
+#else
+#define load_rc5_decode() 0
+#endif
+
#endif /* _IR_CORE */
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 13/26] V4L/DVB: saa7134: Add support for both positive and negative edge IRQ
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (5 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 21/26] V4L/DVB: cx88: don't handle IR on Pixelview too fast Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 20/26] V4L-DVB: ir-rc5-decoder: Add a decoder for RC-5 IR protocol Mauro Carvalho Chehab
` (18 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
The code that enables IRQ for the Remote Controller on saa7134 is a little
messy: it is outside saa7134-input, it checks if RC is GPIO based, and
it mixes both serial raw decode with parallel reads from a hardware-based
IR decoder.
Also, currently, it doesn't allow to trigger both transition edges at GPIO16
and GPIO18 lines. A rework on the code is needed to provide a better way
to specify what saa7134-input needs, maybe even moving part of the code from
saa7134-core and saa7134-cards into saa7134-input.
Yet, as a large rework is happening at RC core, it is better to wait until
the core changes stablize, in order to rework saa7134 RC internals.While
this don't happen, let's just change the logic a little bit to allow
enabling IRQ to be generated on both edge transitions, in order to better
support pulse/space raw decoders.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/video/saa7134/saa7134-core.c b/drivers/media/video/saa7134/saa7134-core.c
index 0612fff..90f2318 100644
--- a/drivers/media/video/saa7134/saa7134-core.c
+++ b/drivers/media/video/saa7134/saa7134-core.c
@@ -701,10 +701,12 @@ static int saa7134_hw_enable2(struct saa7134_dev *dev)
if (dev->has_remote == SAA7134_REMOTE_GPIO && dev->remote) {
if (dev->remote->mask_keydown & 0x10000)
irq2_mask |= SAA7134_IRQ2_INTE_GPIO16_N;
- else if (dev->remote->mask_keydown & 0x40000)
- irq2_mask |= SAA7134_IRQ2_INTE_GPIO18_P;
- else if (dev->remote->mask_keyup & 0x40000)
- irq2_mask |= SAA7134_IRQ2_INTE_GPIO18_N;
+ else { /* Allow enabling both IRQ edge triggers */
+ if (dev->remote->mask_keydown & 0x40000)
+ irq2_mask |= SAA7134_IRQ2_INTE_GPIO18_P;
+ if (dev->remote->mask_keyup & 0x40000)
+ irq2_mask |= SAA7134_IRQ2_INTE_GPIO18_N;
+ }
}
if (dev->has_remote == SAA7134_REMOTE_I2C) {
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 12/26] V4L/DVB: saa7134: Fix IRQ2 bit names for the register map
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (14 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 11/26] V4L/DVB: ir-common: remove keymap tables from the module Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 08/26] V4L/DVB: Break Remote Controller keymaps into modules Mauro Carvalho Chehab
` (9 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
There's an error at the IRQ2 bit map registers. Also, it doesn't
show what bits are needed for positive and for negative edge.
In the case of IR raw decoding, for some protocols, it is important
to detect both positive and negative edges. So, a latter patch
will need to use the other values.
Also, the code that detects problems on IRQ handling is incomplete,
as it disables only one of the IRQ bits for GPIO16 and GPIO18.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/video/saa7134/saa7134-core.c b/drivers/media/video/saa7134/saa7134-core.c
index 68cda10..0612fff 100644
--- a/drivers/media/video/saa7134/saa7134-core.c
+++ b/drivers/media/video/saa7134/saa7134-core.c
@@ -471,7 +471,7 @@ static char *irqbits[] = {
"DONE_RA0", "DONE_RA1", "DONE_RA2", "DONE_RA3",
"AR", "PE", "PWR_ON", "RDCAP", "INTL", "FIDT", "MMC",
"TRIG_ERR", "CONF_ERR", "LOAD_ERR",
- "GPIO16?", "GPIO18", "GPIO22", "GPIO23"
+ "GPIO16", "GPIO18", "GPIO22", "GPIO23"
};
#define IRQBITS ARRAY_SIZE(irqbits)
@@ -601,12 +601,14 @@ static irqreturn_t saa7134_irq(int irq, void *dev_id)
/* disable gpio16 IRQ */
printk(KERN_WARNING "%s/irq: looping -- "
"clearing GPIO16 enable bit\n",dev->name);
- saa_clearl(SAA7134_IRQ2, SAA7134_IRQ2_INTE_GPIO16);
+ saa_clearl(SAA7134_IRQ2, SAA7134_IRQ2_INTE_GPIO16_P);
+ saa_clearl(SAA7134_IRQ2, SAA7134_IRQ2_INTE_GPIO16_N);
} else if (report & SAA7134_IRQ_REPORT_GPIO18) {
/* disable gpio18 IRQs */
printk(KERN_WARNING "%s/irq: looping -- "
"clearing GPIO18 enable bit\n",dev->name);
- saa_clearl(SAA7134_IRQ2, SAA7134_IRQ2_INTE_GPIO18);
+ saa_clearl(SAA7134_IRQ2, SAA7134_IRQ2_INTE_GPIO18_P);
+ saa_clearl(SAA7134_IRQ2, SAA7134_IRQ2_INTE_GPIO18_N);
} else {
/* disable all irqs */
printk(KERN_WARNING "%s/irq: looping -- "
@@ -698,11 +700,11 @@ static int saa7134_hw_enable2(struct saa7134_dev *dev)
if (dev->has_remote == SAA7134_REMOTE_GPIO && dev->remote) {
if (dev->remote->mask_keydown & 0x10000)
- irq2_mask |= SAA7134_IRQ2_INTE_GPIO16;
+ irq2_mask |= SAA7134_IRQ2_INTE_GPIO16_N;
else if (dev->remote->mask_keydown & 0x40000)
- irq2_mask |= SAA7134_IRQ2_INTE_GPIO18;
+ irq2_mask |= SAA7134_IRQ2_INTE_GPIO18_P;
else if (dev->remote->mask_keyup & 0x40000)
- irq2_mask |= SAA7134_IRQ2_INTE_GPIO18A;
+ irq2_mask |= SAA7134_IRQ2_INTE_GPIO18_N;
}
if (dev->has_remote == SAA7134_REMOTE_I2C) {
diff --git a/drivers/media/video/saa7134/saa7134-input.c b/drivers/media/video/saa7134/saa7134-input.c
index 0459ae6..fd3225c 100644
--- a/drivers/media/video/saa7134/saa7134-input.c
+++ b/drivers/media/video/saa7134/saa7134-input.c
@@ -1188,14 +1188,14 @@ static void nec_task(unsigned long data)
/* Keep repeating the last key */
mod_timer(&ir->timer_keyup, jiffies + msecs_to_jiffies(150));
- saa_setl(SAA7134_IRQ2, SAA7134_IRQ2_INTE_GPIO18);
+ saa_setl(SAA7134_IRQ2, SAA7134_IRQ2_INTE_GPIO18_P);
}
static int saa7134_nec_irq(struct saa7134_dev *dev)
{
struct card_ir *ir = dev->remote;
- saa_clearl(SAA7134_IRQ2, SAA7134_IRQ2_INTE_GPIO18);
+ saa_clearl(SAA7134_IRQ2, SAA7134_IRQ2_INTE_GPIO18_P);
tasklet_schedule(&ir->tlet);
return 1;
diff --git a/drivers/media/video/saa7134/saa7134-reg.h b/drivers/media/video/saa7134/saa7134-reg.h
index cf89d96..e7e0af1 100644
--- a/drivers/media/video/saa7134/saa7134-reg.h
+++ b/drivers/media/video/saa7134/saa7134-reg.h
@@ -112,17 +112,17 @@
#define SAA7134_IRQ1_INTE_RA0_0 (1 << 0)
#define SAA7134_IRQ2 (0x2c8 >> 2)
-#define SAA7134_IRQ2_INTE_GPIO23A (1 << 17)
-#define SAA7134_IRQ2_INTE_GPIO23 (1 << 16)
-#define SAA7134_IRQ2_INTE_GPIO22A (1 << 15)
-#define SAA7134_IRQ2_INTE_GPIO22 (1 << 14)
-#define SAA7134_IRQ2_INTE_GPIO18A (1 << 13)
-#define SAA7134_IRQ2_INTE_GPIO18 (1 << 12)
-#define SAA7134_IRQ2_INTE_GPIO16 (1 << 11) /* not certain */
-#define SAA7134_IRQ2_INTE_SC2 (1 << 10)
-#define SAA7134_IRQ2_INTE_SC1 (1 << 9)
-#define SAA7134_IRQ2_INTE_SC0 (1 << 8)
-#define SAA7134_IRQ2_INTE_DEC5 (1 << 7)
+#define SAA7134_IRQ2_INTE_GPIO23_N (1 << 17) /* negative edge */
+#define SAA7134_IRQ2_INTE_GPIO23_P (1 << 16) /* positive edge */
+#define SAA7134_IRQ2_INTE_GPIO22_N (1 << 15) /* negative edge */
+#define SAA7134_IRQ2_INTE_GPIO22_P (1 << 14) /* positive edge */
+#define SAA7134_IRQ2_INTE_GPIO18_N (1 << 13) /* negative edge */
+#define SAA7134_IRQ2_INTE_GPIO18_P (1 << 12) /* positive edge */
+#define SAA7134_IRQ2_INTE_GPIO16_N (1 << 11) /* negative edge */
+#define SAA7134_IRQ2_INTE_GPIO16_P (1 << 10) /* positive edge */
+#define SAA7134_IRQ2_INTE_SC2 (1 << 9)
+#define SAA7134_IRQ2_INTE_SC1 (1 << 8)
+#define SAA7134_IRQ2_INTE_SC0 (1 << 7)
#define SAA7134_IRQ2_INTE_DEC4 (1 << 6)
#define SAA7134_IRQ2_INTE_DEC3 (1 << 5)
#define SAA7134_IRQ2_INTE_DEC2 (1 << 4)
@@ -135,7 +135,7 @@
#define SAA7134_IRQ_REPORT_GPIO23 (1 << 17)
#define SAA7134_IRQ_REPORT_GPIO22 (1 << 16)
#define SAA7134_IRQ_REPORT_GPIO18 (1 << 15)
-#define SAA7134_IRQ_REPORT_GPIO16 (1 << 14) /* not certain */
+#define SAA7134_IRQ_REPORT_GPIO16 (1 << 14)
#define SAA7134_IRQ_REPORT_LOAD_ERR (1 << 13)
#define SAA7134_IRQ_REPORT_CONF_ERR (1 << 12)
#define SAA7134_IRQ_REPORT_TRIG_ERR (1 << 11)
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 17/26] V4L/DVB: Convert drivers/media/dvb/ttpci/budget-ci.c to use ir-core
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (10 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 15/26] V4L/DVB: ir-core: re-add some debug functions for keytable changes Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 14/26] V4L/DVB: drivers/media/IR - improve keytable code Mauro Carvalho Chehab
` (13 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
From: David Härdeman <david@hardeman.nu>
Converts drivers/media/dvb/ttpci/budget-ci.c to use ir-core rather than
rolling its own keydown timeout handler and reporting keys via
drivers/media/IR/ir-functions.c.
Signed-off-by: David Härdeman <david@hardeman.nu>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/dvb/ttpci/budget-ci.c b/drivers/media/dvb/ttpci/budget-ci.c
index be20749..8950df1 100644
--- a/drivers/media/dvb/ttpci/budget-ci.c
+++ b/drivers/media/dvb/ttpci/budget-ci.c
@@ -35,7 +35,7 @@
#include <linux/interrupt.h>
#include <linux/input.h>
#include <linux/spinlock.h>
-#include <media/ir-common.h>
+#include <media/ir-core.h>
#include "budget.h"
@@ -82,12 +82,6 @@
#define SLOTSTATUS_READY 8
#define SLOTSTATUS_OCCUPIED (SLOTSTATUS_PRESENT|SLOTSTATUS_RESET|SLOTSTATUS_READY)
-/*
- * Milliseconds during which a key is regarded as pressed.
- * If an identical command arrives within this time, the timer will start over.
- */
-#define IR_KEYPRESS_TIMEOUT 250
-
/* RC5 device wildcard */
#define IR_DEVICE_ANY 255
@@ -104,12 +98,9 @@ DVB_DEFINE_MOD_OPT_ADAPTER_NR(adapter_nr);
struct budget_ci_ir {
struct input_dev *dev;
struct tasklet_struct msp430_irq_tasklet;
- struct timer_list timer_keyup;
char name[72]; /* 40 + 32 for (struct saa7146_dev).name */
char phys[32];
- struct ir_input_state state;
int rc5_device;
- u32 last_raw;
u32 ir_key;
bool have_command;
};
@@ -124,18 +115,11 @@ struct budget_ci {
u8 tuner_pll_address; /* used for philips_tdm1316l configs */
};
-static void msp430_ir_keyup(unsigned long data)
-{
- struct budget_ci_ir *ir = (struct budget_ci_ir *) data;
- ir_input_nokey(ir->dev, &ir->state);
-}
-
static void msp430_ir_interrupt(unsigned long data)
{
struct budget_ci *budget_ci = (struct budget_ci *) data;
struct input_dev *dev = budget_ci->ir.dev;
u32 command = ttpci_budget_debiread(&budget_ci->budget, DEBINOSWAP, DEBIADDR_IR, 2, 1, 0) >> 8;
- u32 raw;
/*
* The msp430 chip can generate two different bytes, command and device
@@ -171,20 +155,12 @@ static void msp430_ir_interrupt(unsigned long data)
return;
budget_ci->ir.have_command = false;
+ /* FIXME: We should generate complete scancodes with device info */
if (budget_ci->ir.rc5_device != IR_DEVICE_ANY &&
budget_ci->ir.rc5_device != (command & 0x1f))
return;
- /* Is this a repeated key sequence? (same device, command, toggle) */
- raw = budget_ci->ir.ir_key | (command << 8);
- if (budget_ci->ir.last_raw != raw || !timer_pending(&budget_ci->ir.timer_keyup)) {
- ir_input_nokey(dev, &budget_ci->ir.state);
- ir_input_keydown(dev, &budget_ci->ir.state,
- budget_ci->ir.ir_key);
- budget_ci->ir.last_raw = raw;
- }
-
- mod_timer(&budget_ci->ir.timer_keyup, jiffies + msecs_to_jiffies(IR_KEYPRESS_TIMEOUT));
+ ir_keydown(dev, budget_ci->ir.ir_key, (command & 0x20) ? 1 : 0);
}
static int msp430_ir_init(struct budget_ci *budget_ci)
@@ -251,11 +227,6 @@ static int msp430_ir_init(struct budget_ci *budget_ci)
ir_input_init(input_dev, &budget_ci->ir.state, IR_TYPE_RC5);
- /* initialise the key-up timeout handler */
- init_timer(&budget_ci->ir.timer_keyup);
- budget_ci->ir.timer_keyup.function = msp430_ir_keyup;
- budget_ci->ir.timer_keyup.data = (unsigned long) &budget_ci->ir;
- budget_ci->ir.last_raw = 0xffff; /* An impossible value */
error = ir_input_register(input_dev, ir_codes, NULL, MODULE_NAME);
if (error) {
printk(KERN_ERR "budget_ci: could not init driver for IR device (code %d)\n", error);
@@ -284,9 +255,6 @@ static void msp430_ir_deinit(struct budget_ci *budget_ci)
saa7146_setgpio(saa, 3, SAA7146_GPIO_INPUT);
tasklet_kill(&budget_ci->ir.msp430_irq_tasklet);
- del_timer_sync(&dev->timer);
- ir_input_nokey(dev, &budget_ci->ir.state);
-
ir_input_unregister(dev);
}
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 10/26] V4L/DVB: ir-core: Make use of the new IR keymap modules
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (12 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 14/26] V4L/DVB: drivers/media/IR - improve keytable code Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 11/26] V4L/DVB: ir-common: remove keymap tables from the module Mauro Carvalho Chehab
` (11 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
Instead of using the ugly keymap sequences, use the new rc-*.ko keymap
files. For now, it is still needed to have one keymap loaded, for the
RC code to work. Later patches will remove this depenency.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
create mode 100644 include/media/rc-map.h
diff --git a/drivers/media/IR/Makefile b/drivers/media/IR/Makefile
index 3a4f590..3d8dd30 100644
--- a/drivers/media/IR/Makefile
+++ b/drivers/media/IR/Makefile
@@ -1,6 +1,8 @@
ir-common-objs := ir-functions.o ir-keymaps.o
ir-core-objs := ir-keytable.o ir-sysfs.o ir-raw-event.o rc-map.o
+obj-y += keymaps/
+
obj-$(CONFIG_IR_CORE) += ir-core.o
obj-$(CONFIG_VIDEO_IR) += ir-common.o
obj-$(CONFIG_IR_NEC_DECODER) += ir-nec-decoder.o
diff --git a/drivers/media/IR/ir-sysfs.c b/drivers/media/IR/ir-sysfs.c
index 435d83e..0b05c7b 100644
--- a/drivers/media/IR/ir-sysfs.c
+++ b/drivers/media/IR/ir-sysfs.c
@@ -250,8 +250,10 @@ static int __init ir_core_init(void)
return rc;
}
- /* Initialize/load the decoders that will be used */
+ /* Initialize/load the decoders/keymap code that will be used */
ir_raw_init();
+ rc_map_init();
+
return 0;
}
diff --git a/drivers/media/IR/rc-map.c b/drivers/media/IR/rc-map.c
index 02c72f0..2f6201c 100644
--- a/drivers/media/IR/rc-map.c
+++ b/drivers/media/IR/rc-map.c
@@ -26,12 +26,14 @@ static struct rc_keymap *seek_rc_map(const char *name)
spin_lock(&rc_map_lock);
list_for_each_entry(map, &rc_map_list, list) {
- if (!strcmp(name, map->map.name))
- break;
+ if (!strcmp(name, map->map.name)) {
+ spin_unlock(&rc_map_lock);
+ return map;
+ }
}
spin_unlock(&rc_map_lock);
- return map;
+ return NULL;
}
struct ir_scancode_table *get_rc_map(const char *name)
@@ -43,15 +45,22 @@ struct ir_scancode_table *get_rc_map(const char *name)
map = seek_rc_map(name);
#ifdef MODULE
if (!map) {
- rc = request_module("name");
- if (rc < 0)
+ rc = request_module(name);
+ if (rc < 0) {
+ printk(KERN_ERR "Couldn't load IR keymap %s\n", name);
return NULL;
+ }
+ msleep(20); /* Give some time for IR to register */
map = seek_rc_map(name);
}
#endif
- if (!map)
+ if (!map) {
+ printk(KERN_ERR "IR keymap %s not found\n", name);
return NULL;
+ }
+
+ printk(KERN_INFO "Registered IR keymap %s\n", map->map.name);
return &map->map;
}
@@ -73,3 +82,9 @@ void ir_unregister_map(struct rc_keymap *map)
spin_unlock(&rc_map_lock);
}
EXPORT_SYMBOL_GPL(ir_unregister_map);
+
+void rc_map_init(void)
+{
+ spin_lock_init(&rc_map_lock);
+
+}
diff --git a/drivers/media/dvb/dm1105/dm1105.c b/drivers/media/dvb/dm1105/dm1105.c
index 3a67f30..333d7b1 100644
--- a/drivers/media/dvb/dm1105/dm1105.c
+++ b/drivers/media/dvb/dm1105/dm1105.c
@@ -595,7 +595,7 @@ static irqreturn_t dm1105_irq(int irq, void *dev_id)
int __devinit dm1105_ir_init(struct dm1105_dev *dm1105)
{
struct input_dev *input_dev;
- struct ir_scancode_table *ir_codes = &IR_KEYTABLE(dm1105_nec);
+ char *ir_codes = NULL;
u64 ir_type = IR_TYPE_OTHER;
int err = -ENOMEM;
@@ -629,7 +629,7 @@ int __devinit dm1105_ir_init(struct dm1105_dev *dm1105)
INIT_WORK(&dm1105->ir.work, dm1105_emit_key);
- err = __ir_input_register(input_dev, ir_codes, NULL, MODULE_NAME);
+ err = ir_input_register(input_dev, ir_codes, NULL, MODULE_NAME);
return err;
}
diff --git a/drivers/media/dvb/ttpci/budget-ci.c b/drivers/media/dvb/ttpci/budget-ci.c
index ab7479a..be20749 100644
--- a/drivers/media/dvb/ttpci/budget-ci.c
+++ b/drivers/media/dvb/ttpci/budget-ci.c
@@ -192,7 +192,7 @@ static int msp430_ir_init(struct budget_ci *budget_ci)
struct saa7146_dev *saa = budget_ci->budget.dev;
struct input_dev *input_dev = budget_ci->ir.dev;
int error;
- struct ir_scancode_table *ir_codes;
+ char *ir_codes = NULL;
budget_ci->ir.dev = input_dev = input_allocate_device();
@@ -232,7 +232,7 @@ static int msp430_ir_init(struct budget_ci *budget_ci)
case 0x1011:
case 0x1012:
/* The hauppauge keymap is a superset of these remotes */
- ir_codes = &IR_KEYTABLE(hauppauge_new);
+ ir_codes = RC_MAP_HAUPPAUGE_NEW;
if (rc5_device < 0)
budget_ci->ir.rc5_device = 0x1f;
@@ -241,11 +241,11 @@ static int msp430_ir_init(struct budget_ci *budget_ci)
case 0x1017:
case 0x101a:
/* for the Technotrend 1500 bundled remote */
- ir_codes = &IR_KEYTABLE(tt_1500);
+ ir_codes = RC_MAP_TT_1500;
break;
default:
/* unknown remote */
- ir_codes = &IR_KEYTABLE(budget_ci_old);
+ ir_codes = RC_MAP_BUDGET_CI_OLD;
break;
}
@@ -256,7 +256,7 @@ static int msp430_ir_init(struct budget_ci *budget_ci)
budget_ci->ir.timer_keyup.function = msp430_ir_keyup;
budget_ci->ir.timer_keyup.data = (unsigned long) &budget_ci->ir;
budget_ci->ir.last_raw = 0xffff; /* An impossible value */
- error = __ir_input_register(input_dev, ir_codes, NULL, MODULE_NAME);
+ error = ir_input_register(input_dev, ir_codes, NULL, MODULE_NAME);
if (error) {
printk(KERN_ERR "budget_ci: could not init driver for IR device (code %d)\n", error);
return error;
diff --git a/drivers/media/video/bt8xx/bttv-input.c b/drivers/media/video/bt8xx/bttv-input.c
index eae4925..814fd34 100644
--- a/drivers/media/video/bt8xx/bttv-input.c
+++ b/drivers/media/video/bt8xx/bttv-input.c
@@ -247,7 +247,7 @@ static void bttv_ir_stop(struct bttv *btv)
int bttv_input_init(struct bttv *btv)
{
struct card_ir *ir;
- struct ir_scancode_table *ir_codes = NULL;
+ char *ir_codes = NULL;
struct input_dev *input_dev;
u64 ir_type = IR_TYPE_OTHER;
int err = -ENOMEM;
@@ -265,7 +265,7 @@ int bttv_input_init(struct bttv *btv)
case BTTV_BOARD_AVERMEDIA:
case BTTV_BOARD_AVPHONE98:
case BTTV_BOARD_AVERMEDIA98:
- ir_codes = &IR_KEYTABLE(avermedia);
+ ir_codes = RC_MAP_AVERMEDIA;
ir->mask_keycode = 0xf88000;
ir->mask_keydown = 0x010000;
ir->polling = 50; // ms
@@ -273,14 +273,14 @@ int bttv_input_init(struct bttv *btv)
case BTTV_BOARD_AVDVBT_761:
case BTTV_BOARD_AVDVBT_771:
- ir_codes = &IR_KEYTABLE(avermedia_dvbt);
+ ir_codes = RC_MAP_AVERMEDIA_DVBT;
ir->mask_keycode = 0x0f00c0;
ir->mask_keydown = 0x000020;
ir->polling = 50; // ms
break;
case BTTV_BOARD_PXELVWPLTVPAK:
- ir_codes = &IR_KEYTABLE(pixelview);
+ ir_codes = RC_MAP_PIXELVIEW;
ir->mask_keycode = 0x003e00;
ir->mask_keyup = 0x010000;
ir->polling = 50; // ms
@@ -288,24 +288,24 @@ int bttv_input_init(struct bttv *btv)
case BTTV_BOARD_PV_M4900:
case BTTV_BOARD_PV_BT878P_9B:
case BTTV_BOARD_PV_BT878P_PLUS:
- ir_codes = &IR_KEYTABLE(pixelview);
+ ir_codes = RC_MAP_PIXELVIEW;
ir->mask_keycode = 0x001f00;
ir->mask_keyup = 0x008000;
ir->polling = 50; // ms
break;
case BTTV_BOARD_WINFAST2000:
- ir_codes = &IR_KEYTABLE(winfast);
+ ir_codes = RC_MAP_WINFAST;
ir->mask_keycode = 0x1f8;
break;
case BTTV_BOARD_MAGICTVIEW061:
case BTTV_BOARD_MAGICTVIEW063:
- ir_codes = &IR_KEYTABLE(winfast);
+ ir_codes = RC_MAP_WINFAST;
ir->mask_keycode = 0x0008e000;
ir->mask_keydown = 0x00200000;
break;
case BTTV_BOARD_APAC_VIEWCOMP:
- ir_codes = &IR_KEYTABLE(apac_viewcomp);
+ ir_codes = RC_MAP_APAC_VIEWCOMP;
ir->mask_keycode = 0x001f00;
ir->mask_keyup = 0x008000;
ir->polling = 50; // ms
@@ -313,30 +313,30 @@ int bttv_input_init(struct bttv *btv)
case BTTV_BOARD_ASKEY_CPH03X:
case BTTV_BOARD_CONCEPTRONIC_CTVFMI2:
case BTTV_BOARD_CONTVFMI:
- ir_codes = &IR_KEYTABLE(pixelview);
+ ir_codes = RC_MAP_PIXELVIEW;
ir->mask_keycode = 0x001F00;
ir->mask_keyup = 0x006000;
ir->polling = 50; // ms
break;
case BTTV_BOARD_NEBULA_DIGITV:
- ir_codes = &IR_KEYTABLE(nebula);
+ ir_codes = RC_MAP_NEBULA;
btv->custom_irq = bttv_rc5_irq;
ir->rc5_gpio = 1;
break;
case BTTV_BOARD_MACHTV_MAGICTV:
- ir_codes = &IR_KEYTABLE(apac_viewcomp);
+ ir_codes = RC_MAP_APAC_VIEWCOMP;
ir->mask_keycode = 0x001F00;
ir->mask_keyup = 0x004000;
ir->polling = 50; /* ms */
break;
case BTTV_BOARD_KOZUMI_KTV_01C:
- ir_codes = &IR_KEYTABLE(pctv_sedna);
+ ir_codes = RC_MAP_PCTV_SEDNA;
ir->mask_keycode = 0x001f00;
ir->mask_keyup = 0x006000;
ir->polling = 50; /* ms */
break;
case BTTV_BOARD_ENLTV_FM_2:
- ir_codes = &IR_KEYTABLE(encore_enltv2);
+ ir_codes = RC_MAP_ENCORE_ENLTV2;
ir->mask_keycode = 0x00fd00;
ir->mask_keyup = 0x000080;
ir->polling = 1; /* ms */
@@ -391,7 +391,7 @@ int bttv_input_init(struct bttv *btv)
bttv_ir_start(btv, ir);
/* all done */
- err = __ir_input_register(btv->remote->dev, ir_codes, NULL, MODULE_NAME);
+ err = ir_input_register(btv->remote->dev, ir_codes, NULL, MODULE_NAME);
if (err)
goto err_out_stop;
diff --git a/drivers/media/video/cx18/cx18-i2c.c b/drivers/media/video/cx18/cx18-i2c.c
index 476c016..cfa1f28 100644
--- a/drivers/media/video/cx18/cx18-i2c.c
+++ b/drivers/media/video/cx18/cx18-i2c.c
@@ -109,7 +109,7 @@ static int cx18_i2c_new_ir(struct cx18 *cx, struct i2c_adapter *adap, u32 hw,
/* Our default information for ir-kbd-i2c.c to use */
switch (hw) {
case CX18_HW_Z8F0811_IR_RX_HAUP:
- init_data->ir_codes = &IR_KEYTABLE(hauppauge_new);
+ init_data->ir_codes = RC_MAP_HAUPPAUGE_NEW;
init_data->internal_get_key_func = IR_KBD_GET_KEY_HAUP_XVR;
init_data->type = IR_TYPE_RC5;
init_data->name = cx->card_name;
diff --git a/drivers/media/video/cx23885/cx23885-input.c b/drivers/media/video/cx23885/cx23885-input.c
index 5767d3e..f7d0ad6 100644
--- a/drivers/media/video/cx23885/cx23885-input.c
+++ b/drivers/media/video/cx23885/cx23885-input.c
@@ -339,7 +339,7 @@ int cx23885_input_init(struct cx23885_dev *dev)
{
struct card_ir *ir;
struct input_dev *input_dev;
- struct ir_scancode_table *ir_codes = NULL;
+ char *ir_codes = NULL;
int ir_type, ir_addr, ir_start;
int ret;
@@ -354,7 +354,7 @@ int cx23885_input_init(struct cx23885_dev *dev)
case CX23885_BOARD_HAUPPAUGE_HVR1850:
case CX23885_BOARD_HAUPPAUGE_HVR1290:
/* Parameters for the grey Hauppauge remote for the HVR-1850 */
- ir_codes = &IR_KEYTABLE(hauppauge_new);
+ ir_codes = RC_MAP_HAUPPAUGE_NEW;
ir_type = IR_TYPE_RC5;
ir_addr = 0x1e; /* RC-5 system bits emitted by the remote */
ir_start = RC5_START_BITS_NORMAL; /* A basic RC-5 remote */
@@ -399,7 +399,7 @@ int cx23885_input_init(struct cx23885_dev *dev)
dev->ir_input = ir;
cx23885_input_ir_start(dev);
- ret = __ir_input_register(ir->dev, ir_codes, NULL, MODULE_NAME);
+ ret = ir_input_register(ir->dev, ir_codes, NULL, MODULE_NAME);
if (ret)
goto err_out_stop;
diff --git a/drivers/media/video/cx88/cx88-input.c b/drivers/media/video/cx88/cx88-input.c
index 638e599..f5d6130 100644
--- a/drivers/media/video/cx88/cx88-input.c
+++ b/drivers/media/video/cx88/cx88-input.c
@@ -244,7 +244,7 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
{
struct cx88_IR *ir;
struct input_dev *input_dev;
- struct ir_scancode_table *ir_codes = NULL;
+ char *ir_codes = NULL;
u64 ir_type = IR_TYPE_OTHER;
int err = -ENOMEM;
@@ -260,14 +260,14 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
case CX88_BOARD_DNTV_LIVE_DVB_T:
case CX88_BOARD_KWORLD_DVB_T:
case CX88_BOARD_KWORLD_DVB_T_CX22702:
- ir_codes = &IR_KEYTABLE(dntv_live_dvb_t);
+ ir_codes = RC_MAP_DNTV_LIVE_DVB_T;
ir->gpio_addr = MO_GP1_IO;
ir->mask_keycode = 0x1f;
ir->mask_keyup = 0x60;
ir->polling = 50; /* ms */
break;
case CX88_BOARD_TERRATEC_CINERGY_1400_DVB_T1:
- ir_codes = &IR_KEYTABLE(cinergy_1400);
+ ir_codes = RC_MAP_CINERGY_1400;
ir_type = IR_TYPE_PD;
ir->sampling = 0xeb04; /* address */
break;
@@ -282,14 +282,14 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
case CX88_BOARD_PCHDTV_HD3000:
case CX88_BOARD_PCHDTV_HD5500:
case CX88_BOARD_HAUPPAUGE_IRONLY:
- ir_codes = &IR_KEYTABLE(hauppauge_new);
+ ir_codes = RC_MAP_HAUPPAUGE_NEW;
ir_type = IR_TYPE_RC5;
ir->sampling = 1;
break;
case CX88_BOARD_WINFAST_DTV2000H:
case CX88_BOARD_WINFAST_DTV2000H_J:
case CX88_BOARD_WINFAST_DTV1800H:
- ir_codes = &IR_KEYTABLE(winfast);
+ ir_codes = RC_MAP_WINFAST;
ir->gpio_addr = MO_GP0_IO;
ir->mask_keycode = 0x8f8;
ir->mask_keyup = 0x100;
@@ -298,14 +298,14 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
case CX88_BOARD_WINFAST2000XP_EXPERT:
case CX88_BOARD_WINFAST_DTV1000:
case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL:
- ir_codes = &IR_KEYTABLE(winfast);
+ ir_codes = RC_MAP_WINFAST;
ir->gpio_addr = MO_GP0_IO;
ir->mask_keycode = 0x8f8;
ir->mask_keyup = 0x100;
ir->polling = 1; /* ms */
break;
case CX88_BOARD_IODATA_GVBCTV7E:
- ir_codes = &IR_KEYTABLE(iodata_bctv7e);
+ ir_codes = RC_MAP_IODATA_BCTV7E;
ir->gpio_addr = MO_GP0_IO;
ir->mask_keycode = 0xfd;
ir->mask_keydown = 0x02;
@@ -313,7 +313,7 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
break;
case CX88_BOARD_PROLINK_PLAYTVPVR:
case CX88_BOARD_PIXELVIEW_PLAYTV_ULTRA_PRO:
- ir_codes = &IR_KEYTABLE(pixelview);
+ ir_codes = RC_MAP_PIXELVIEW;
ir->gpio_addr = MO_GP1_IO;
ir->mask_keycode = 0x1f;
ir->mask_keyup = 0x80;
@@ -321,28 +321,28 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
break;
case CX88_BOARD_PROLINK_PV_8000GT:
case CX88_BOARD_PROLINK_PV_GLOBAL_XTREME:
- ir_codes = &IR_KEYTABLE(pixelview_new);
+ ir_codes = RC_MAP_PIXELVIEW_NEW;
ir->gpio_addr = MO_GP1_IO;
ir->mask_keycode = 0x3f;
ir->mask_keyup = 0x80;
ir->polling = 1; /* ms */
break;
case CX88_BOARD_KWORLD_LTV883:
- ir_codes = &IR_KEYTABLE(pixelview);
+ ir_codes = RC_MAP_PIXELVIEW;
ir->gpio_addr = MO_GP1_IO;
ir->mask_keycode = 0x1f;
ir->mask_keyup = 0x60;
ir->polling = 1; /* ms */
break;
case CX88_BOARD_ADSTECH_DVB_T_PCI:
- ir_codes = &IR_KEYTABLE(adstech_dvb_t_pci);
+ ir_codes = RC_MAP_ADSTECH_DVB_T_PCI;
ir->gpio_addr = MO_GP1_IO;
ir->mask_keycode = 0xbf;
ir->mask_keyup = 0x40;
ir->polling = 50; /* ms */
break;
case CX88_BOARD_MSI_TVANYWHERE_MASTER:
- ir_codes = &IR_KEYTABLE(msi_tvanywhere);
+ ir_codes = RC_MAP_MSI_TVANYWHERE;
ir->gpio_addr = MO_GP1_IO;
ir->mask_keycode = 0x1f;
ir->mask_keyup = 0x40;
@@ -350,7 +350,7 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
break;
case CX88_BOARD_AVERTV_303:
case CX88_BOARD_AVERTV_STUDIO_303:
- ir_codes = &IR_KEYTABLE(avertv_303);
+ ir_codes = RC_MAP_AVERTV_303;
ir->gpio_addr = MO_GP2_IO;
ir->mask_keycode = 0xfb;
ir->mask_keydown = 0x02;
@@ -363,41 +363,41 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
case CX88_BOARD_PROF_7300:
case CX88_BOARD_PROF_7301:
case CX88_BOARD_PROF_6200:
- ir_codes = &IR_KEYTABLE(tbs_nec);
+ ir_codes = RC_MAP_TBS_NEC;
ir_type = IR_TYPE_PD;
ir->sampling = 0xff00; /* address */
break;
case CX88_BOARD_TEVII_S460:
case CX88_BOARD_TEVII_S420:
- ir_codes = &IR_KEYTABLE(tevii_nec);
+ ir_codes = RC_MAP_TEVII_NEC;
ir_type = IR_TYPE_PD;
ir->sampling = 0xff00; /* address */
break;
case CX88_BOARD_DNTV_LIVE_DVB_T_PRO:
- ir_codes = &IR_KEYTABLE(dntv_live_dvbt_pro);
+ ir_codes = RC_MAP_DNTV_LIVE_DVBT_PRO;
ir_type = IR_TYPE_PD;
ir->sampling = 0xff00; /* address */
break;
case CX88_BOARD_NORWOOD_MICRO:
- ir_codes = &IR_KEYTABLE(norwood);
+ ir_codes = RC_MAP_NORWOOD;
ir->gpio_addr = MO_GP1_IO;
ir->mask_keycode = 0x0e;
ir->mask_keyup = 0x80;
ir->polling = 50; /* ms */
break;
case CX88_BOARD_NPGTECH_REALTV_TOP10FM:
- ir_codes = &IR_KEYTABLE(npgtech);
+ ir_codes = RC_MAP_NPGTECH;
ir->gpio_addr = MO_GP0_IO;
ir->mask_keycode = 0xfa;
ir->polling = 50; /* ms */
break;
case CX88_BOARD_PINNACLE_PCTV_HD_800i:
- ir_codes = &IR_KEYTABLE(pinnacle_pctv_hd);
+ ir_codes = RC_MAP_PINNACLE_PCTV_HD;
ir_type = IR_TYPE_RC5;
ir->sampling = 1;
break;
case CX88_BOARD_POWERCOLOR_REAL_ANGEL:
- ir_codes = &IR_KEYTABLE(powercolor_real_angel);
+ ir_codes = RC_MAP_POWERCOLOR_REAL_ANGEL;
ir->gpio_addr = MO_GP2_IO;
ir->mask_keycode = 0x7e;
ir->polling = 100; /* ms */
@@ -438,7 +438,7 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
ir->props.close = cx88_ir_close;
/* all done */
- err = __ir_input_register(ir->input, ir_codes, &ir->props, MODULE_NAME);
+ err = ir_input_register(ir->input, ir_codes, &ir->props, MODULE_NAME);
if (err)
goto err_out_free;
diff --git a/drivers/media/video/em28xx/em28xx-cards.c b/drivers/media/video/em28xx/em28xx-cards.c
index 55fcc2e..41a2c76 100644
--- a/drivers/media/video/em28xx/em28xx-cards.c
+++ b/drivers/media/video/em28xx/em28xx-cards.c
@@ -601,7 +601,7 @@ struct em28xx_board em28xx_boards[] = {
.name = "Gadmei UTV330+",
.tuner_type = TUNER_TNF_5335MF,
.tda9887_conf = TDA9887_PRESENT,
- .ir_codes = &IR_KEYTABLE(gadmei_rm008z),
+ .ir_codes = RC_MAP_GADMEI_RM008Z,
.decoder = EM28XX_SAA711X,
.xclk = EM28XX_XCLK_FREQUENCY_12MHZ,
.input = { {
@@ -790,7 +790,7 @@ struct em28xx_board em28xx_boards[] = {
.mts_firmware = 1,
.has_dvb = 1,
.dvb_gpio = hauppauge_wintv_hvr_900_digital,
- .ir_codes = &IR_KEYTABLE(hauppauge_new),
+ .ir_codes = RC_MAP_HAUPPAUGE_NEW,
.decoder = EM28XX_TVP5150,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -815,7 +815,7 @@ struct em28xx_board em28xx_boards[] = {
.tuner_type = TUNER_XC2028,
.tuner_gpio = default_tuner_gpio,
.mts_firmware = 1,
- .ir_codes = &IR_KEYTABLE(hauppauge_new),
+ .ir_codes = RC_MAP_HAUPPAUGE_NEW,
.decoder = EM28XX_TVP5150,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -841,7 +841,7 @@ struct em28xx_board em28xx_boards[] = {
.mts_firmware = 1,
.has_dvb = 1,
.dvb_gpio = hauppauge_wintv_hvr_900_digital,
- .ir_codes = &IR_KEYTABLE(hauppauge_new),
+ .ir_codes = RC_MAP_HAUPPAUGE_NEW,
.decoder = EM28XX_TVP5150,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -867,7 +867,7 @@ struct em28xx_board em28xx_boards[] = {
.mts_firmware = 1,
.has_dvb = 1,
.dvb_gpio = hauppauge_wintv_hvr_900_digital,
- .ir_codes = &IR_KEYTABLE(rc5_hauppauge_new),
+ .ir_codes = RC_MAP_RC5_HAUPPAUGE_NEW,
.decoder = EM28XX_TVP5150,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -893,7 +893,7 @@ struct em28xx_board em28xx_boards[] = {
.mts_firmware = 1,
.has_dvb = 1,
.dvb_gpio = hauppauge_wintv_hvr_900_digital,
- .ir_codes = &IR_KEYTABLE(pinnacle_pctv_hd),
+ .ir_codes = RC_MAP_PINNACLE_PCTV_HD,
.decoder = EM28XX_TVP5150,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -919,7 +919,7 @@ struct em28xx_board em28xx_boards[] = {
.mts_firmware = 1,
.has_dvb = 1,
.dvb_gpio = hauppauge_wintv_hvr_900_digital,
- .ir_codes = &IR_KEYTABLE(ati_tv_wonder_hd_600),
+ .ir_codes = RC_MAP_ATI_TV_WONDER_HD_600,
.decoder = EM28XX_TVP5150,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -945,7 +945,7 @@ struct em28xx_board em28xx_boards[] = {
.decoder = EM28XX_TVP5150,
.has_dvb = 1,
.dvb_gpio = default_digital,
- .ir_codes = &IR_KEYTABLE(terratec_cinergy_xs),
+ .ir_codes = RC_MAP_TERRATEC_CINERGY_XS,
.xclk = EM28XX_XCLK_FREQUENCY_12MHZ, /* NEC IR */
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -1295,7 +1295,7 @@ struct em28xx_board em28xx_boards[] = {
.decoder = EM28XX_SAA711X,
.has_dvb = 1,
.dvb_gpio = em2882_kworld_315u_digital,
- .ir_codes = &IR_KEYTABLE(kworld_315u),
+ .ir_codes = RC_MAP_KWORLD_315U,
.xclk = EM28XX_XCLK_FREQUENCY_12MHZ,
.i2c_speed = EM28XX_I2C_CLK_WAIT_ENABLE,
/* Analog mode - still not ready */
@@ -1424,7 +1424,7 @@ struct em28xx_board em28xx_boards[] = {
.has_dvb = 1,
.dvb_gpio = kworld_330u_digital,
.xclk = EM28XX_XCLK_FREQUENCY_12MHZ, /* NEC IR */
- .ir_codes = &IR_KEYTABLE(kworld_315u),
+ .ir_codes = RC_MAP_KWORLD_315U,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
.vmux = TVP5150_COMPOSITE0,
@@ -1447,7 +1447,7 @@ struct em28xx_board em28xx_boards[] = {
.decoder = EM28XX_TVP5150,
.has_dvb = 1,
.dvb_gpio = hauppauge_wintv_hvr_900_digital,
- .ir_codes = &IR_KEYTABLE(terratec_cinergy_xs),
+ .ir_codes = RC_MAP_TERRATEC_CINERGY_XS,
.xclk = EM28XX_XCLK_FREQUENCY_12MHZ,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -1540,7 +1540,7 @@ struct em28xx_board em28xx_boards[] = {
.mts_firmware = 1,
.decoder = EM28XX_TVP5150,
.tuner_gpio = default_tuner_gpio,
- .ir_codes = &IR_KEYTABLE(kaiomy),
+ .ir_codes = RC_MAP_KAIOMY,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
.vmux = TVP5150_COMPOSITE0,
@@ -1640,7 +1640,7 @@ struct em28xx_board em28xx_boards[] = {
.mts_firmware = 1,
.has_dvb = 1,
.dvb_gpio = evga_indtube_digital,
- .ir_codes = &IR_KEYTABLE(evga_indtube),
+ .ir_codes = RC_MAP_EVGA_INDTUBE,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
.vmux = TVP5150_COMPOSITE0,
@@ -2334,21 +2334,21 @@ void em28xx_register_i2c_ir(struct em28xx *dev)
switch (dev->model) {
case EM2800_BOARD_TERRATEC_CINERGY_200:
case EM2820_BOARD_TERRATEC_CINERGY_250:
- dev->init_data.ir_codes = &IR_KEYTABLE(em_terratec);
+ dev->init_data.ir_codes = RC_MAP_EM_TERRATEC;
dev->init_data.get_key = em28xx_get_key_terratec;
dev->init_data.name = "i2c IR (EM28XX Terratec)";
break;
case EM2820_BOARD_PINNACLE_USB_2:
- dev->init_data.ir_codes = &IR_KEYTABLE(pinnacle_grey);
+ dev->init_data.ir_codes = RC_MAP_PINNACLE_GREY;
dev->init_data.get_key = em28xx_get_key_pinnacle_usb_grey;
dev->init_data.name = "i2c IR (EM28XX Pinnacle PCTV)";
break;
case EM2820_BOARD_HAUPPAUGE_WINTV_USB_2:
- dev->init_data.ir_codes = &IR_KEYTABLE(rc5_hauppauge_new);
+ dev->init_data.ir_codes = RC_MAP_RC5_HAUPPAUGE_NEW;
dev->init_data.get_key = em28xx_get_key_em_haup;
dev->init_data.name = "i2c IR (EM2840 Hauppauge)";
case EM2820_BOARD_LEADTEK_WINFAST_USBII_DELUXE:
- dev->init_data.ir_codes = &IR_KEYTABLE(winfast_usbii_deluxe);;
+ dev->init_data.ir_codes = RC_MAP_WINFAST_USBII_DELUXE;;
dev->init_data.get_key = em28xx_get_key_winfast_usbii_deluxe;
dev->init_data.name = "i2c IR (EM2820 Winfast TV USBII Deluxe)";
break;
diff --git a/drivers/media/video/em28xx/em28xx-input.c b/drivers/media/video/em28xx/em28xx-input.c
index c237c72..3200f48 100644
--- a/drivers/media/video/em28xx/em28xx-input.c
+++ b/drivers/media/video/em28xx/em28xx-input.c
@@ -381,7 +381,6 @@ int em28xx_ir_change_protocol(void *priv, u64 ir_type)
/* Adjust xclk based o IR table for RC5/NEC tables */
- dev->board.ir_codes->ir_type = IR_TYPE_OTHER;
if (ir_type == IR_TYPE_RC5) {
dev->board.xclk |= EM28XX_XCLK_IR_RC5_MODE;
ir->full_code = 1;
@@ -392,8 +391,6 @@ int em28xx_ir_change_protocol(void *priv, u64 ir_type)
} else
rc = -EINVAL;
- dev->board.ir_codes->ir_type = ir_type;
-
em28xx_write_reg_bits(dev, EM28XX_R0F_XCLK, dev->board.xclk,
EM28XX_XCLK_IR_RC5_MODE);
@@ -456,7 +453,6 @@ int em28xx_ir_init(struct em28xx *dev)
strlcat(ir->phys, "/input0", sizeof(ir->phys));
/* Set IR protocol */
- em28xx_ir_change_protocol(ir, dev->board.ir_codes->ir_type);
err = ir_input_init(input_dev, &ir->ir, IR_TYPE_OTHER);
if (err < 0)
goto err_out_free;
@@ -474,7 +470,7 @@ int em28xx_ir_init(struct em28xx *dev)
em28xx_ir_start(ir);
/* all done */
- err = __ir_input_register(ir->input, dev->board.ir_codes,
+ err = ir_input_register(ir->input, dev->board.ir_codes,
&ir->props, MODULE_NAME);
if (err)
goto err_out_stop;
diff --git a/drivers/media/video/em28xx/em28xx.h b/drivers/media/video/em28xx/em28xx.h
index eec1291..b252d1b 100644
--- a/drivers/media/video/em28xx/em28xx.h
+++ b/drivers/media/video/em28xx/em28xx.h
@@ -412,7 +412,7 @@ struct em28xx_board {
struct em28xx_input input[MAX_EM28XX_INPUT];
struct em28xx_input radio;
- struct ir_scancode_table *ir_codes;
+ char *ir_codes;
};
struct em28xx_eeprom {
diff --git a/drivers/media/video/ir-kbd-i2c.c b/drivers/media/video/ir-kbd-i2c.c
index e6ada5e..29d4397 100644
--- a/drivers/media/video/ir-kbd-i2c.c
+++ b/drivers/media/video/ir-kbd-i2c.c
@@ -297,7 +297,7 @@ static void ir_work(struct work_struct *work)
static int ir_probe(struct i2c_client *client, const struct i2c_device_id *id)
{
- struct ir_scancode_table *ir_codes = NULL;
+ char *ir_codes = NULL;
const char *name = NULL;
u64 ir_type = 0;
struct IR_i2c *ir;
@@ -322,13 +322,13 @@ static int ir_probe(struct i2c_client *client, const struct i2c_device_id *id)
name = "Pixelview";
ir->get_key = get_key_pixelview;
ir_type = IR_TYPE_OTHER;
- ir_codes = &IR_KEYTABLE(empty);
+ ir_codes = RC_MAP_EMPTY;
break;
case 0x4b:
name = "PV951";
ir->get_key = get_key_pv951;
ir_type = IR_TYPE_OTHER;
- ir_codes = &IR_KEYTABLE(pv951);
+ ir_codes = RC_MAP_PV951;
break;
case 0x18:
case 0x1f:
@@ -337,22 +337,22 @@ static int ir_probe(struct i2c_client *client, const struct i2c_device_id *id)
ir->get_key = get_key_haup;
ir_type = IR_TYPE_RC5;
if (hauppauge == 1) {
- ir_codes = &IR_KEYTABLE(hauppauge_new);
+ ir_codes = RC_MAP_HAUPPAUGE_NEW;
} else {
- ir_codes = &IR_KEYTABLE(rc5_tv);
+ ir_codes = RC_MAP_RC5_TV;
}
break;
case 0x30:
name = "KNC One";
ir->get_key = get_key_knc1;
ir_type = IR_TYPE_OTHER;
- ir_codes = &IR_KEYTABLE(empty);
+ ir_codes = RC_MAP_EMPTY;
break;
case 0x6b:
name = "FusionHDTV";
ir->get_key = get_key_fusionhdtv;
ir_type = IR_TYPE_RC5;
- ir_codes = &IR_KEYTABLE(fusionhdtv_mce);
+ ir_codes = RC_MAP_FUSIONHDTV_MCE;
break;
case 0x0b:
case 0x47:
@@ -365,9 +365,9 @@ static int ir_probe(struct i2c_client *client, const struct i2c_device_id *id)
ir_type = IR_TYPE_RC5;
ir->get_key = get_key_haup_xvr;
if (hauppauge == 1) {
- ir_codes = &IR_KEYTABLE(hauppauge_new);
+ ir_codes = RC_MAP_HAUPPAUGE_NEW;
} else {
- ir_codes = &IR_KEYTABLE(rc5_tv);
+ ir_codes = RC_MAP_RC5_TV;
}
} else {
/* Handled by saa7134-input */
@@ -379,7 +379,7 @@ static int ir_probe(struct i2c_client *client, const struct i2c_device_id *id)
name = "AVerMedia Cardbus remote";
ir->get_key = get_key_avermedia_cardbus;
ir_type = IR_TYPE_OTHER;
- ir_codes = &IR_KEYTABLE(avermedia_cardbus);
+ ir_codes = RC_MAP_AVERMEDIA_CARDBUS;
break;
}
@@ -447,7 +447,7 @@ static int ir_probe(struct i2c_client *client, const struct i2c_device_id *id)
input_dev->name = ir->name;
input_dev->phys = ir->phys;
- err = __ir_input_register(ir->input, ir->ir_codes, NULL, MODULE_NAME);
+ err = ir_input_register(ir->input, ir->ir_codes, NULL, MODULE_NAME);
if (err)
goto err_out_free;
diff --git a/drivers/media/video/ivtv/ivtv-i2c.c b/drivers/media/video/ivtv/ivtv-i2c.c
index a363e33..a5b92d1 100644
--- a/drivers/media/video/ivtv/ivtv-i2c.c
+++ b/drivers/media/video/ivtv/ivtv-i2c.c
@@ -193,7 +193,7 @@ static int ivtv_i2c_new_ir(struct ivtv *itv, u32 hw, const char *type, u8 addr)
/* Our default information for ir-kbd-i2c.c to use */
switch (hw) {
case IVTV_HW_I2C_IR_RX_AVER:
- init_data->ir_codes = &IR_KEYTABLE(avermedia_cardbus);
+ init_data->ir_codes = RC_MAP_AVERMEDIA_CARDBUS;
init_data->internal_get_key_func =
IR_KBD_GET_KEY_AVERMEDIA_CARDBUS;
init_data->type = IR_TYPE_OTHER;
@@ -202,14 +202,14 @@ static int ivtv_i2c_new_ir(struct ivtv *itv, u32 hw, const char *type, u8 addr)
case IVTV_HW_I2C_IR_RX_HAUP_EXT:
case IVTV_HW_I2C_IR_RX_HAUP_INT:
/* Default to old black remote */
- init_data->ir_codes = &IR_KEYTABLE(rc5_tv);
+ init_data->ir_codes = RC_MAP_RC5_TV;
init_data->internal_get_key_func = IR_KBD_GET_KEY_HAUP;
init_data->type = IR_TYPE_RC5;
init_data->name = itv->card_name;
break;
case IVTV_HW_Z8F0811_IR_RX_HAUP:
/* Default to grey remote */
- init_data->ir_codes = &IR_KEYTABLE(hauppauge_new);
+ init_data->ir_codes = RC_MAP_HAUPPAUGE_NEW;
init_data->internal_get_key_func = IR_KBD_GET_KEY_HAUP_XVR;
init_data->type = IR_TYPE_RC5;
init_data->name = itv->card_name;
diff --git a/drivers/media/video/saa7134/saa7134-input.c b/drivers/media/video/saa7134/saa7134-input.c
index 2a3cae9..0459ae6 100644
--- a/drivers/media/video/saa7134/saa7134-input.c
+++ b/drivers/media/video/saa7134/saa7134-input.c
@@ -586,7 +586,7 @@ int saa7134_input_init1(struct saa7134_dev *dev)
{
struct card_ir *ir;
struct input_dev *input_dev;
- struct ir_scancode_table *ir_codes = NULL;
+ char *ir_codes = NULL;
u32 mask_keycode = 0;
u32 mask_keydown = 0;
u32 mask_keyup = 0;
@@ -594,6 +594,7 @@ int saa7134_input_init1(struct saa7134_dev *dev)
int rc5_gpio = 0;
int nec_gpio = 0;
int raw_decode = 0;
+ int allow_protocol_change = 0;
u64 ir_type = IR_TYPE_OTHER;
int err;
@@ -610,27 +611,27 @@ int saa7134_input_init1(struct saa7134_dev *dev)
case SAA7134_BOARD_FLYTVPLATINUM_FM:
case SAA7134_BOARD_FLYTVPLATINUM_MINI2:
case SAA7134_BOARD_ROVERMEDIA_LINK_PRO_FM:
- ir_codes = &IR_KEYTABLE(flyvideo);
+ ir_codes = RC_MAP_FLYVIDEO;
mask_keycode = 0xEC00000;
mask_keydown = 0x0040000;
break;
case SAA7134_BOARD_CINERGY400:
case SAA7134_BOARD_CINERGY600:
case SAA7134_BOARD_CINERGY600_MK3:
- ir_codes = &IR_KEYTABLE(cinergy);
+ ir_codes = RC_MAP_CINERGY;
mask_keycode = 0x00003f;
mask_keyup = 0x040000;
break;
case SAA7134_BOARD_ECS_TVP3XP:
case SAA7134_BOARD_ECS_TVP3XP_4CB5:
- ir_codes = &IR_KEYTABLE(eztv);
+ ir_codes = RC_MAP_EZTV;
mask_keycode = 0x00017c;
mask_keyup = 0x000002;
polling = 50; // ms
break;
case SAA7134_BOARD_KWORLD_XPERT:
case SAA7134_BOARD_AVACSSMARTTV:
- ir_codes = &IR_KEYTABLE(pixelview);
+ ir_codes = RC_MAP_PIXELVIEW;
mask_keycode = 0x00001F;
mask_keyup = 0x000020;
polling = 50; // ms
@@ -647,7 +648,7 @@ int saa7134_input_init1(struct saa7134_dev *dev)
case SAA7134_BOARD_AVERMEDIA_GO_007_FM:
case SAA7134_BOARD_AVERMEDIA_M102:
case SAA7134_BOARD_AVERMEDIA_GO_007_FM_PLUS:
- ir_codes = &IR_KEYTABLE(avermedia);
+ ir_codes = RC_MAP_AVERMEDIA;
mask_keycode = 0x0007C8;
mask_keydown = 0x000010;
polling = 50; // ms
@@ -656,14 +657,14 @@ int saa7134_input_init1(struct saa7134_dev *dev)
saa_setb(SAA7134_GPIO_GPSTATUS0, 0x4);
break;
case SAA7134_BOARD_AVERMEDIA_M135A:
- ir_codes = &IR_KEYTABLE(avermedia_m135a_rm_jx);
+ ir_codes = RC_MAP_AVERMEDIA_M135A_RM_JX;
mask_keydown = 0x0040000;
mask_keycode = 0xffff;
raw_decode = 1;
break;
case SAA7134_BOARD_AVERMEDIA_777:
case SAA7134_BOARD_AVERMEDIA_A16AR:
- ir_codes = &IR_KEYTABLE(avermedia);
+ ir_codes = RC_MAP_AVERMEDIA;
mask_keycode = 0x02F200;
mask_keydown = 0x000400;
polling = 50; // ms
@@ -672,7 +673,7 @@ int saa7134_input_init1(struct saa7134_dev *dev)
saa_setb(SAA7134_GPIO_GPSTATUS1, 0x1);
break;
case SAA7134_BOARD_AVERMEDIA_A16D:
- ir_codes = &IR_KEYTABLE(avermedia_a16d);
+ ir_codes = RC_MAP_AVERMEDIA_A16D;
mask_keycode = 0x02F200;
mask_keydown = 0x000400;
polling = 50; /* ms */
@@ -681,14 +682,14 @@ int saa7134_input_init1(struct saa7134_dev *dev)
saa_setb(SAA7134_GPIO_GPSTATUS1, 0x1);
break;
case SAA7134_BOARD_KWORLD_TERMINATOR:
- ir_codes = &IR_KEYTABLE(pixelview);
+ ir_codes = RC_MAP_PIXELVIEW;
mask_keycode = 0x00001f;
mask_keyup = 0x000060;
polling = 50; // ms
break;
case SAA7134_BOARD_MANLI_MTV001:
case SAA7134_BOARD_MANLI_MTV002:
- ir_codes = &IR_KEYTABLE(manli);
+ ir_codes = RC_MAP_MANLI;
mask_keycode = 0x001f00;
mask_keyup = 0x004000;
polling = 50; /* ms */
@@ -708,25 +709,25 @@ int saa7134_input_init1(struct saa7134_dev *dev)
case SAA7134_BOARD_BEHOLD_507_9FM:
case SAA7134_BOARD_BEHOLD_507RDS_MK3:
case SAA7134_BOARD_BEHOLD_507RDS_MK5:
- ir_codes = &IR_KEYTABLE(manli);
+ ir_codes = RC_MAP_MANLI;
mask_keycode = 0x003f00;
mask_keyup = 0x004000;
polling = 50; /* ms */
break;
case SAA7134_BOARD_BEHOLD_COLUMBUS_TVFM:
- ir_codes = &IR_KEYTABLE(behold_columbus);
+ ir_codes = RC_MAP_BEHOLD_COLUMBUS;
mask_keycode = 0x003f00;
mask_keyup = 0x004000;
polling = 50; // ms
break;
case SAA7134_BOARD_SEDNA_PC_TV_CARDBUS:
- ir_codes = &IR_KEYTABLE(pctv_sedna);
+ ir_codes = RC_MAP_PCTV_SEDNA;
mask_keycode = 0x001f00;
mask_keyup = 0x004000;
polling = 50; // ms
break;
case SAA7134_BOARD_GOTVIEW_7135:
- ir_codes = &IR_KEYTABLE(gotview7135);
+ ir_codes = RC_MAP_GOTVIEW7135;
mask_keycode = 0x0003CC;
mask_keydown = 0x000010;
polling = 5; /* ms */
@@ -735,80 +736,80 @@ int saa7134_input_init1(struct saa7134_dev *dev)
case SAA7134_BOARD_VIDEOMATE_TV_PVR:
case SAA7134_BOARD_VIDEOMATE_GOLD_PLUS:
case SAA7134_BOARD_VIDEOMATE_TV_GOLD_PLUSII:
- ir_codes = &IR_KEYTABLE(videomate_tv_pvr);
+ ir_codes = RC_MAP_VIDEOMATE_TV_PVR;
mask_keycode = 0x00003F;
mask_keyup = 0x400000;
polling = 50; // ms
break;
case SAA7134_BOARD_PROTEUS_2309:
- ir_codes = &IR_KEYTABLE(proteus_2309);
+ ir_codes = RC_MAP_PROTEUS_2309;
mask_keycode = 0x00007F;
mask_keyup = 0x000080;
polling = 50; // ms
break;
case SAA7134_BOARD_VIDEOMATE_DVBT_300:
case SAA7134_BOARD_VIDEOMATE_DVBT_200:
- ir_codes = &IR_KEYTABLE(videomate_tv_pvr);
+ ir_codes = RC_MAP_VIDEOMATE_TV_PVR;
mask_keycode = 0x003F00;
mask_keyup = 0x040000;
break;
case SAA7134_BOARD_FLYDVBS_LR300:
case SAA7134_BOARD_FLYDVBT_LR301:
case SAA7134_BOARD_FLYDVBTDUO:
- ir_codes = &IR_KEYTABLE(flydvb);
+ ir_codes = RC_MAP_FLYDVB;
mask_keycode = 0x0001F00;
mask_keydown = 0x0040000;
break;
case SAA7134_BOARD_ASUSTeK_P7131_DUAL:
case SAA7134_BOARD_ASUSTeK_P7131_HYBRID_LNA:
case SAA7134_BOARD_ASUSTeK_P7131_ANALOG:
- ir_codes = &IR_KEYTABLE(asus_pc39);
+ ir_codes = RC_MAP_ASUS_PC39;
mask_keydown = 0x0040000;
rc5_gpio = 1;
break;
case SAA7134_BOARD_ENCORE_ENLTV:
case SAA7134_BOARD_ENCORE_ENLTV_FM:
- ir_codes = &IR_KEYTABLE(encore_enltv);
+ ir_codes = RC_MAP_ENCORE_ENLTV;
mask_keycode = 0x00007f;
mask_keyup = 0x040000;
polling = 50; // ms
break;
case SAA7134_BOARD_ENCORE_ENLTV_FM53:
- ir_codes = &IR_KEYTABLE(encore_enltv_fm53);
+ ir_codes = RC_MAP_ENCORE_ENLTV_FM53;
mask_keydown = 0x0040000;
mask_keycode = 0x00007f;
nec_gpio = 1;
break;
case SAA7134_BOARD_10MOONSTVMASTER3:
- ir_codes = &IR_KEYTABLE(encore_enltv);
+ ir_codes = RC_MAP_ENCORE_ENLTV;
mask_keycode = 0x5f80000;
mask_keyup = 0x8000000;
polling = 50; //ms
break;
case SAA7134_BOARD_GENIUS_TVGO_A11MCE:
- ir_codes = &IR_KEYTABLE(genius_tvgo_a11mce);
+ ir_codes = RC_MAP_GENIUS_TVGO_A11MCE;
mask_keycode = 0xff;
mask_keydown = 0xf00000;
polling = 50; /* ms */
break;
case SAA7134_BOARD_REAL_ANGEL_220:
- ir_codes = &IR_KEYTABLE(real_audio_220_32_keys);
+ ir_codes = RC_MAP_REAL_AUDIO_220_32_KEYS;
mask_keycode = 0x3f00;
mask_keyup = 0x4000;
polling = 50; /* ms */
break;
case SAA7134_BOARD_KWORLD_PLUS_TV_ANALOG:
- ir_codes = &IR_KEYTABLE(kworld_plus_tv_analog);
+ ir_codes = RC_MAP_KWORLD_PLUS_TV_ANALOG;
mask_keycode = 0x7f;
polling = 40; /* ms */
break;
case SAA7134_BOARD_VIDEOMATE_S350:
- ir_codes = &IR_KEYTABLE(videomate_s350);
+ ir_codes = RC_MAP_VIDEOMATE_S350;
mask_keycode = 0x003f00;
mask_keydown = 0x040000;
break;
case SAA7134_BOARD_LEADTEK_WINFAST_DTV1000S:
- ir_codes = &IR_KEYTABLE(winfast);
+ ir_codes = RC_MAP_WINFAST;
mask_keycode = 0x5f00;
mask_keyup = 0x020000;
polling = 50; /* ms */
@@ -853,13 +854,11 @@ int saa7134_input_init1(struct saa7134_dev *dev)
ir->props.open = saa7134_ir_open;
ir->props.close = saa7134_ir_close;
- if (ir_codes->ir_type != IR_TYPE_OTHER && !raw_decode) {
+ if (!raw_decode && allow_protocol_change) {
ir->props.allowed_protos = IR_TYPE_RC5 | IR_TYPE_NEC;
ir->props.change_protocol = saa7134_ir_change_protocol;
-
- /* Set IR protocol */
- saa7134_ir_change_protocol(ir->props.priv, ir_codes->ir_type);
}
+
err = ir_input_init(input_dev, &ir->ir, ir_type);
if (err < 0)
goto err_out_free;
@@ -877,10 +876,10 @@ int saa7134_input_init1(struct saa7134_dev *dev)
}
input_dev->dev.parent = &dev->pci->dev;
- err = __ir_input_register(ir->dev, ir_codes, &ir->props, MODULE_NAME);
+ err = ir_input_register(ir->dev, ir_codes, &ir->props, MODULE_NAME);
if (err)
goto err_out_free;
- if (ir_codes->ir_type != IR_TYPE_OTHER) {
+ if (raw_decode) {
err = ir_raw_event_register(ir->dev);
if (err)
goto err_out_free;
@@ -938,24 +937,24 @@ void saa7134_probe_i2c_ir(struct saa7134_dev *dev)
dev->init_data.name = "Pinnacle PCTV";
if (pinnacle_remote == 0) {
dev->init_data.get_key = get_key_pinnacle_color;
- dev->init_data.ir_codes = &IR_KEYTABLE(pinnacle_color);
+ dev->init_data.ir_codes = RC_MAP_PINNACLE_COLOR;
info.addr = 0x47;
} else {
dev->init_data.get_key = get_key_pinnacle_grey;
- dev->init_data.ir_codes = &IR_KEYTABLE(pinnacle_grey);
+ dev->init_data.ir_codes = RC_MAP_PINNACLE_GREY;
info.addr = 0x47;
}
break;
case SAA7134_BOARD_UPMOST_PURPLE_TV:
dev->init_data.name = "Purple TV";
dev->init_data.get_key = get_key_purpletv;
- dev->init_data.ir_codes = &IR_KEYTABLE(purpletv);
+ dev->init_data.ir_codes = RC_MAP_PURPLETV;
info.addr = 0x7a;
break;
case SAA7134_BOARD_MSI_TVATANYWHERE_PLUS:
dev->init_data.name = "MSI TV@nywhere Plus";
dev->init_data.get_key = get_key_msi_tvanywhere_plus;
- dev->init_data.ir_codes = &IR_KEYTABLE(msi_tvanywhere_plus);
+ dev->init_data.ir_codes = RC_MAP_MSI_TVANYWHERE_PLUS;
info.addr = 0x30;
/* MSI TV@nywhere Plus controller doesn't seem to
respond to probes unless we read something from
@@ -969,7 +968,7 @@ void saa7134_probe_i2c_ir(struct saa7134_dev *dev)
case SAA7134_BOARD_HAUPPAUGE_HVR1110:
dev->init_data.name = "HVR 1110";
dev->init_data.get_key = get_key_hvr1110;
- dev->init_data.ir_codes = &IR_KEYTABLE(hauppauge_new);
+ dev->init_data.ir_codes = RC_MAP_HAUPPAUGE_NEW;
info.addr = 0x71;
break;
case SAA7134_BOARD_BEHOLD_607FM_MK3:
@@ -987,7 +986,7 @@ void saa7134_probe_i2c_ir(struct saa7134_dev *dev)
case SAA7134_BOARD_BEHOLD_X7:
dev->init_data.name = "BeholdTV";
dev->init_data.get_key = get_key_beholdm6xx;
- dev->init_data.ir_codes = &IR_KEYTABLE(behold);
+ dev->init_data.ir_codes = RC_MAP_BEHOLD;
dev->init_data.type = IR_TYPE_NEC;
info.addr = 0x2d;
break;
@@ -998,7 +997,7 @@ void saa7134_probe_i2c_ir(struct saa7134_dev *dev)
case SAA7134_BOARD_FLYDVB_TRIO:
dev->init_data.name = "FlyDVB Trio";
dev->init_data.get_key = get_key_flydvb_trio;
- dev->init_data.ir_codes = &IR_KEYTABLE(flydvb);
+ dev->init_data.ir_codes = RC_MAP_FLYDVB;
info.addr = 0x0b;
break;
default:
diff --git a/include/media/ir-core.h b/include/media/ir-core.h
index 8e975f2..e1772b8 100644
--- a/include/media/ir-core.h
+++ b/include/media/ir-core.h
@@ -21,6 +21,7 @@
#include <linux/kfifo.h>
#include <linux/time.h>
#include <linux/timer.h>
+#include <media/rc-map.h>
extern int ir_core_debug;
#define IR_dprintk(level, fmt, arg...) if (ir_core_debug >= level) \
@@ -124,6 +125,7 @@ EXPORT_SYMBOL_GPL(IR_KEYTABLE(tabname))
int ir_register_map(struct rc_keymap *map);
void ir_unregister_map(struct rc_keymap *map);
struct ir_scancode_table *get_rc_map(const char *name);
+void rc_map_init(void);
/* Routines from ir-keytable.c */
@@ -141,15 +143,30 @@ static inline int ir_input_register(struct input_dev *dev,
const struct ir_dev_props *props,
const char *driver_name) {
struct ir_scancode_table *ir_codes;
+ struct ir_input_dev *ir_dev;
+ int rc;
+
+ if (!map_name)
+ return -EINVAL;
ir_codes = get_rc_map(map_name);
if (!ir_codes)
return -EINVAL;
- return __ir_input_register(dev, ir_codes, props, driver_name);
+ rc = __ir_input_register(dev, ir_codes, props, driver_name);
+ if (rc < 0)
+ return -EINVAL;
+
+ ir_dev = input_get_drvdata(dev);
+
+ if (!rc && ir_dev->props && ir_dev->props->change_protocol)
+ rc = ir_dev->props->change_protocol(ir_dev->props->priv,
+ ir_codes->ir_type);
+
+ return rc;
}
- void ir_input_unregister(struct input_dev *input_dev);
+void ir_input_unregister(struct input_dev *input_dev);
/* Routines from ir-sysfs.c */
diff --git a/include/media/ir-kbd-i2c.h b/include/media/ir-kbd-i2c.h
index 9142936..057ff64 100644
--- a/include/media/ir-kbd-i2c.h
+++ b/include/media/ir-kbd-i2c.h
@@ -6,7 +6,7 @@
struct IR_i2c;
struct IR_i2c {
- struct ir_scancode_table *ir_codes;
+ char *ir_codes;
struct i2c_client *c;
struct input_dev *input;
@@ -34,7 +34,7 @@ enum ir_kbd_get_key_fn {
/* Can be passed when instantiating an ir_video i2c device */
struct IR_i2c_init_data {
- struct ir_scancode_table *ir_codes;
+ char *ir_codes;
const char *name;
u64 type; /* IR_TYPE_RC5, IR_TYPE_PD, etc */
/*
diff --git a/include/media/rc-map.h b/include/media/rc-map.h
new file mode 100644
index 0000000..9ea0033
--- /dev/null
+++ b/include/media/rc-map.h
@@ -0,0 +1,81 @@
+/*
+ * rc-map.h - define RC map names used by RC drivers
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/ir-core.h>
+
+#define RC_MAP_ADSTECH_DVB_T_PCI "rc-adstech-dvb-t-pci"
+#define RC_MAP_APAC_VIEWCOMP "rc-apac-viewcomp"
+#define RC_MAP_ASUS_PC39 "rc-asus-pc39"
+#define RC_MAP_ATI_TV_WONDER_HD_600 "rc-ati-tv-wonder-hd-600"
+#define RC_MAP_AVERMEDIA_A16D "rc-avermedia-a16d"
+#define RC_MAP_AVERMEDIA_CARDBUS "rc-avermedia-cardbus"
+#define RC_MAP_AVERMEDIA_DVBT "rc-avermedia-dvbt"
+#define RC_MAP_AVERMEDIA_M135A_RM_JX "rc-avermedia-m135a-rm-jx"
+#define RC_MAP_AVERMEDIA "rc-avermedia"
+#define RC_MAP_AVERTV_303 "rc-avertv-303"
+#define RC_MAP_BEHOLD_COLUMBUS "rc-behold-columbus"
+#define RC_MAP_BEHOLD "rc-behold"
+#define RC_MAP_BUDGET_CI_OLD "rc-budget-ci-old"
+#define RC_MAP_CINERGY_1400 "rc-cinergy-1400"
+#define RC_MAP_CINERGY "rc-cinergy"
+#define RC_MAP_DM1105_NEC "rc-dm1105-nec"
+#define RC_MAP_DNTV_LIVE_DVBT_PRO "rc-dntv-live-dvbt-pro"
+#define RC_MAP_DNTV_LIVE_DVB_T "rc-dntv-live-dvb-t"
+#define RC_MAP_EMPTY "rc-empty"
+#define RC_MAP_EM_TERRATEC "rc-em-terratec"
+#define RC_MAP_ENCORE_ENLTV2 "rc-encore-enltv2"
+#define RC_MAP_ENCORE_ENLTV_FM53 "rc-encore-enltv-fm53"
+#define RC_MAP_ENCORE_ENLTV "rc-encore-enltv"
+#define RC_MAP_EVGA_INDTUBE "rc-evga-indtube"
+#define RC_MAP_EZTV "rc-eztv"
+#define RC_MAP_FLYDVB "rc-flydvb"
+#define RC_MAP_FLYVIDEO "rc-flyvideo"
+#define RC_MAP_FUSIONHDTV_MCE "rc-fusionhdtv-mce"
+#define RC_MAP_GADMEI_RM008Z "rc-gadmei-rm008z"
+#define RC_MAP_GENIUS_TVGO_A11MCE "rc-genius-tvgo-a11mce"
+#define RC_MAP_GOTVIEW7135 "rc-gotview7135"
+#define RC_MAP_HAUPPAUGE_NEW "rc-hauppauge-new"
+#define RC_MAP_IODATA_BCTV7E "rc-iodata-bctv7e"
+#define RC_MAP_KAIOMY "rc-kaiomy"
+#define RC_MAP_KWORLD_315U "rc-kworld-315u"
+#define RC_MAP_KWORLD_PLUS_TV_ANALOG "rc-kworld-plus-tv-analog"
+#define RC_MAP_MANLI "rc-manli"
+#define RC_MAP_MSI_TVANYWHERE_PLUS "rc-msi-tvanywhere-plus"
+#define RC_MAP_MSI_TVANYWHERE "rc-msi-tvanywhere"
+#define RC_MAP_NEBULA "rc-nebula"
+#define RC_MAP_NEC_TERRATEC_CINERGY_XS "rc-nec-terratec-cinergy-xs"
+#define RC_MAP_NORWOOD "rc-norwood"
+#define RC_MAP_NPGTECH "rc-npgtech"
+#define RC_MAP_PCTV_SEDNA "rc-pctv-sedna"
+#define RC_MAP_PINNACLE_COLOR "rc-pinnacle-color"
+#define RC_MAP_PINNACLE_GREY "rc-pinnacle-grey"
+#define RC_MAP_PINNACLE_PCTV_HD "rc-pinnacle-pctv-hd"
+#define RC_MAP_PIXELVIEW_NEW "rc-pixelview-new"
+#define RC_MAP_PIXELVIEW "rc-pixelview"
+#define RC_MAP_POWERCOLOR_REAL_ANGEL "rc-powercolor-real-angel"
+#define RC_MAP_PROTEUS_2309 "rc-proteus-2309"
+#define RC_MAP_PURPLETV "rc-purpletv"
+#define RC_MAP_PV951 "rc-pv951"
+#define RC_MAP_RC5_HAUPPAUGE_NEW "rc-rc5-hauppauge-new"
+#define RC_MAP_RC5_TV "rc-rc5-tv"
+#define RC_MAP_REAL_AUDIO_220_32_KEYS "rc-real-audio-220-32-keys"
+#define RC_MAP_TBS_NEC "rc-tbs-nec"
+#define RC_MAP_TERRATEC_CINERGY_XS "rc-terratec-cinergy-xs"
+#define RC_MAP_TEVII_NEC "rc-tevii-nec"
+#define RC_MAP_TT_1500 "rc-tt-1500"
+#define RC_MAP_VIDEOMATE_S350 "rc-videomate-s350"
+#define RC_MAP_VIDEOMATE_TV_PVR "rc-videomate-tv-pvr"
+#define RC_MAP_WINFAST "rc-winfast"
+#define RC_MAP_WINFAST_USBII_DELUXE "rc-winfast-usbii-deluxe"
+/*
+ * Please, do not just append newer Remote Controller names at the end.
+ * The names should be ordered in alphabetical order
+ */
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 14/26] V4L/DVB: drivers/media/IR - improve keytable code
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (11 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 17/26] V4L/DVB: Convert drivers/media/dvb/ttpci/budget-ci.c to use ir-core Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 10/26] V4L/DVB: ir-core: Make use of the new IR keymap modules Mauro Carvalho Chehab
` (12 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
From: David Härdeman <david@hardeman.nu>
The attached patch rewrites much of the keytable code in
drivers/media/IR/ir-keytable.c.
The scancodes are now inserted into the array in sorted
order which allows for a binary search on lookup.
The code has also been shrunk by about 150 lines.
In addition it fixes the following bugs:
Any use of ir_seek_table() was racy.
ir_dev->driver_name is leaked between ir_input_register() and
ir_input_unregister().
ir_setkeycode() unconditionally does clear_bit() on dev->keybit
when removing a mapping, but there might be another mapping with
a different scancode and the same keycode.
This version has been updated to incorporate patch feedback from
Mauro Carvalho Chehab.
[mchehab@redhat.com: Fix a conflict with RC keytable breakup patches]
Signed-off-by: David Härdeman <david@hardeman.nu>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/IR/ir-keytable.c b/drivers/media/IR/ir-keytable.c
index 1d9c467..d3bc909 100644
--- a/drivers/media/IR/ir-keytable.c
+++ b/drivers/media/IR/ir-keytable.c
@@ -16,344 +16,214 @@
#include <linux/input.h>
#include <media/ir-common.h>
-#define IR_TAB_MIN_SIZE 32
-#define IR_TAB_MAX_SIZE 1024
+/* Sizes are in bytes, 256 bytes allows for 32 entries on x64 */
+#define IR_TAB_MIN_SIZE 256
+#define IR_TAB_MAX_SIZE 8192
/**
- * ir_seek_table() - returns the element order on the table
- * @rc_tab: the ir_scancode_table with the keymap to be used
- * @scancode: the scancode that we're seeking
+ * ir_resize_table() - resizes a scancode table if necessary
+ * @rc_tab: the ir_scancode_table to resize
+ * @return: zero on success or a negative error code
*
- * This routine is used by the input routines when a key is pressed at the
- * IR. The scancode is received and needs to be converted into a keycode.
- * If the key is not found, it returns KEY_UNKNOWN. Otherwise, returns the
- * corresponding keycode from the table.
+ * This routine will shrink the ir_scancode_table if it has lots of
+ * unused entries and grow it if it is full.
*/
-static int ir_seek_table(struct ir_scancode_table *rc_tab, u32 scancode)
+static int ir_resize_table(struct ir_scancode_table *rc_tab)
{
- int rc;
- unsigned long flags;
- struct ir_scancode *keymap = rc_tab->scan;
+ unsigned int oldalloc = rc_tab->alloc;
+ unsigned int newalloc = oldalloc;
+ struct ir_scancode *oldscan = rc_tab->scan;
+ struct ir_scancode *newscan;
- spin_lock_irqsave(&rc_tab->lock, flags);
+ if (rc_tab->size == rc_tab->len) {
+ /* All entries in use -> grow keytable */
+ if (rc_tab->alloc >= IR_TAB_MAX_SIZE)
+ return -ENOMEM;
- /* FIXME: replace it by a binary search */
+ newalloc *= 2;
+ IR_dprintk(1, "Growing table to %u bytes\n", newalloc);
+ }
- for (rc = 0; rc < rc_tab->size; rc++)
- if (keymap[rc].scancode == scancode)
- goto exit;
+ if ((rc_tab->len * 3 < rc_tab->size) && (oldalloc > IR_TAB_MIN_SIZE)) {
+ /* Less than 1/3 of entries in use -> shrink keytable */
+ newalloc /= 2;
+ IR_dprintk(1, "Shrinking table to %u bytes\n", newalloc);
+ }
- /* Not found */
- rc = -EINVAL;
+ if (newalloc == oldalloc)
+ return 0;
-exit:
- spin_unlock_irqrestore(&rc_tab->lock, flags);
- return rc;
-}
-
-/**
- * ir_roundup_tablesize() - gets an optimum value for the table size
- * @n_elems: minimum number of entries to store keycodes
- *
- * This routine is used to choose the keycode table size.
- *
- * In order to have some empty space for new keycodes,
- * and knowing in advance that kmalloc allocates only power of two
- * segments, it optimizes the allocated space to have some spare space
- * for those new keycodes by using the maximum number of entries that
- * will be effectively be allocated by kmalloc.
- * In order to reduce the quantity of table resizes, it has a minimum
- * table size of IR_TAB_MIN_SIZE.
- */
-static int ir_roundup_tablesize(int n_elems)
-{
- size_t size;
-
- if (n_elems < IR_TAB_MIN_SIZE)
- n_elems = IR_TAB_MIN_SIZE;
+ newscan = kmalloc(newalloc, GFP_ATOMIC);
+ if (!newscan) {
+ IR_dprintk(1, "Failed to kmalloc %u bytes\n", newalloc);
+ return -ENOMEM;
+ }
- /*
- * As kmalloc only allocates sizes of power of two, get as
- * much entries as possible for the allocated memory segment
- */
- size = roundup_pow_of_two(n_elems * sizeof(struct ir_scancode));
- n_elems = size / sizeof(struct ir_scancode);
-
- return n_elems;
+ memcpy(newscan, rc_tab->scan, rc_tab->len * sizeof(struct ir_scancode));
+ rc_tab->scan = newscan;
+ rc_tab->alloc = newalloc;
+ rc_tab->size = rc_tab->alloc / sizeof(struct ir_scancode);
+ kfree(oldscan);
+ return 0;
}
/**
- * ir_copy_table() - copies a keytable, discarding the unused entries
- * @destin: destin table
- * @origin: origin table
+ * ir_do_setkeycode() - internal function to set a keycode in the
+ * scancode->keycode table
+ * @dev: the struct input_dev device descriptor
+ * @rc_tab: the struct ir_scancode_table to set the keycode in
+ * @scancode: the scancode for the ir command
+ * @keycode: the keycode for the ir command
+ * @return: -EINVAL if the keycode could not be inserted, otherwise zero.
*
- * Copies all entries where the keycode is not KEY_UNKNOWN/KEY_RESERVED
- * Also copies table size and table protocol.
- * NOTE: It shouldn't copy the lock field
+ * This routine is used internally to manipulate the scancode->keycode table.
+ * The caller has to hold @rc_tab->lock.
*/
-
-static int ir_copy_table(struct ir_scancode_table *destin,
- const struct ir_scancode_table *origin)
+static int ir_do_setkeycode(struct input_dev *dev,
+ struct ir_scancode_table *rc_tab,
+ int scancode, int keycode)
{
- int i, j = 0;
+ unsigned int i;
+ int old_keycode = KEY_RESERVED;
- for (i = 0; i < origin->size; i++) {
- if (origin->scan[i].keycode == KEY_UNKNOWN ||
- origin->scan[i].keycode == KEY_RESERVED)
+ /* First check if we already have a mapping for this ir command */
+ for (i = 0; i < rc_tab->len; i++) {
+ /* Keytable is sorted from lowest to highest scancode */
+ if (rc_tab->scan[i].scancode > scancode)
+ break;
+ else if (rc_tab->scan[i].scancode < scancode)
continue;
- memcpy(&destin->scan[j], &origin->scan[i], sizeof(struct ir_scancode));
- j++;
+ old_keycode = rc_tab->scan[i].keycode;
+ rc_tab->scan[i].keycode = keycode;
+
+ /* Did the user wish to remove the mapping? */
+ if (keycode == KEY_RESERVED || keycode == KEY_UNKNOWN) {
+ rc_tab->len--;
+ memmove(&rc_tab->scan[i], &rc_tab->scan[i + 1],
+ (rc_tab->len - i) * sizeof(struct ir_scancode));
+ }
+
+ /* Possibly shrink the keytable, failure is not a problem */
+ ir_resize_table(rc_tab);
+ break;
}
- destin->size = j;
- destin->ir_type = origin->ir_type;
- IR_dprintk(1, "Copied %d scancodes to the new keycode table\n", destin->size);
-
- return 0;
-}
-
-/**
- * ir_getkeycode() - get a keycode at the evdev scancode ->keycode table
- * @dev: the struct input_dev device descriptor
- * @scancode: the desired scancode
- * @keycode: the keycode to be retorned.
- *
- * This routine is used to handle evdev EVIOCGKEY ioctl.
- * If the key is not found, returns -EINVAL, otherwise, returns 0.
- */
-static int ir_getkeycode(struct input_dev *dev,
- int scancode, int *keycode)
-{
- int elem;
- struct ir_input_dev *ir_dev = input_get_drvdata(dev);
- struct ir_scancode_table *rc_tab = &ir_dev->rc_tab;
-
- elem = ir_seek_table(rc_tab, scancode);
- if (elem >= 0) {
- *keycode = rc_tab->scan[elem].keycode;
- return 0;
- }
-
- /*
- * Scancode not found and table can't be expanded
- */
- if (elem < 0 && rc_tab->size == IR_TAB_MAX_SIZE)
- return -EINVAL;
-
- /*
- * If is there extra space, returns KEY_RESERVED,
- * otherwise, input core won't let ir_setkeycode to work
- */
- *keycode = KEY_RESERVED;
- return 0;
-}
-
-/**
- * ir_is_resize_needed() - Check if the table needs rezise
- * @table: keycode table that may need to resize
- * @n_elems: minimum number of entries to store keycodes
- *
- * Considering that kmalloc uses power of two storage areas, this
- * routine detects if the real alloced size will change. If not, it
- * just returns without doing nothing. Otherwise, it will extend or
- * reduce the table size to meet the new needs.
- *
- * It returns 0 if no resize is needed, 1 otherwise.
- */
-static int ir_is_resize_needed(struct ir_scancode_table *table, int n_elems)
-{
- int cur_size = ir_roundup_tablesize(table->size);
- int new_size = ir_roundup_tablesize(n_elems);
-
- if (cur_size == new_size)
- return 0;
-
- /* Resize is needed */
- return 1;
-}
-
-/**
- * ir_delete_key() - remove a keycode from the table
- * @rc_tab: keycode table
- * @elem: element to be removed
- *
- */
-static void ir_delete_key(struct ir_scancode_table *rc_tab, int elem)
-{
- unsigned long flags = 0;
- int newsize = rc_tab->size - 1;
- int resize = ir_is_resize_needed(rc_tab, newsize);
- struct ir_scancode *oldkeymap = rc_tab->scan;
- struct ir_scancode *newkeymap = NULL;
-
- if (resize)
- newkeymap = kzalloc(ir_roundup_tablesize(newsize) *
- sizeof(*newkeymap), GFP_ATOMIC);
-
- /* There's no memory for resize. Keep the old table */
- if (!resize || !newkeymap) {
- newkeymap = oldkeymap;
-
- /* We'll modify the live table. Lock it */
- spin_lock_irqsave(&rc_tab->lock, flags);
- }
-
- /*
- * Copy the elements before the one that will be deleted
- * if (!resize), both oldkeymap and newkeymap points
- * to the same place, so, there's no need to copy
- */
- if (resize && elem > 0)
- memcpy(newkeymap, oldkeymap,
- elem * sizeof(*newkeymap));
-
- /*
- * Copy the other elements overwriting the element to be removed
- * This operation applies to both resize and non-resize case
- */
- if (elem < newsize)
- memcpy(&newkeymap[elem], &oldkeymap[elem + 1],
- (newsize - elem) * sizeof(*newkeymap));
-
- if (resize) {
- /*
- * As the copy happened to a temporary table, only here
- * it needs to lock while replacing the table pointers
- * to use the new table
- */
- spin_lock_irqsave(&rc_tab->lock, flags);
- rc_tab->size = newsize;
- rc_tab->scan = newkeymap;
- spin_unlock_irqrestore(&rc_tab->lock, flags);
-
- /* Frees the old keytable */
- kfree(oldkeymap);
+ if (old_keycode == KEY_RESERVED) {
+ /* No previous mapping found, we might need to grow the table */
+ if (ir_resize_table(rc_tab))
+ return -ENOMEM;
+
+ /* i is the proper index to insert our new keycode */
+ memmove(&rc_tab->scan[i + 1], &rc_tab->scan[i],
+ (rc_tab->len - i) * sizeof(struct ir_scancode));
+ rc_tab->scan[i].scancode = scancode;
+ rc_tab->scan[i].keycode = keycode;
+ rc_tab->len++;
+ set_bit(keycode, dev->keybit);
} else {
- rc_tab->size = newsize;
- spin_unlock_irqrestore(&rc_tab->lock, flags);
+ /* A previous mapping was updated... */
+ clear_bit(old_keycode, dev->keybit);
+ /* ...but another scancode might use the same keycode */
+ for (i = 0; i < rc_tab->len; i++) {
+ if (rc_tab->scan[i].keycode == old_keycode) {
+ set_bit(old_keycode, dev->keybit);
+ break;
+ }
+ }
}
-}
-
-/**
- * ir_insert_key() - insert a keycode at the table
- * @rc_tab: keycode table
- * @scancode: the desired scancode
- * @keycode: the keycode to be retorned.
- *
- */
-static int ir_insert_key(struct ir_scancode_table *rc_tab,
- int scancode, int keycode)
-{
- unsigned long flags;
- int elem = rc_tab->size;
- int newsize = rc_tab->size + 1;
- int resize = ir_is_resize_needed(rc_tab, newsize);
- struct ir_scancode *oldkeymap = rc_tab->scan;
- struct ir_scancode *newkeymap;
-
- if (resize) {
- newkeymap = kzalloc(ir_roundup_tablesize(newsize) *
- sizeof(*newkeymap), GFP_ATOMIC);
- if (!newkeymap)
- return -ENOMEM;
-
- memcpy(newkeymap, oldkeymap,
- rc_tab->size * sizeof(*newkeymap));
- } else
- newkeymap = oldkeymap;
-
- /* Stores the new code at the table */
- IR_dprintk(1, "#%d: New scan 0x%04x with key 0x%04x\n",
- rc_tab->size, scancode, keycode);
-
- spin_lock_irqsave(&rc_tab->lock, flags);
- rc_tab->size = newsize;
- if (resize) {
- rc_tab->scan = newkeymap;
- kfree(oldkeymap);
- }
- newkeymap[elem].scancode = scancode;
- newkeymap[elem].keycode = keycode;
- spin_unlock_irqrestore(&rc_tab->lock, flags);
return 0;
}
/**
- * ir_setkeycode() - set a keycode at the evdev scancode ->keycode table
+ * ir_setkeycode() - set a keycode in the scancode->keycode table
* @dev: the struct input_dev device descriptor
* @scancode: the desired scancode
- * @keycode: the keycode to be retorned.
+ * @keycode: result
+ * @return: -EINVAL if the keycode could not be inserted, otherwise zero.
*
* This routine is used to handle evdev EVIOCSKEY ioctl.
- * There's one caveat here: how can we increase the size of the table?
- * If the key is not found, returns -EINVAL, otherwise, returns 0.
*/
static int ir_setkeycode(struct input_dev *dev,
int scancode, int keycode)
{
+ int rc;
+ unsigned long flags;
+ struct ir_input_dev *ir_dev = input_get_drvdata(dev);
+ struct ir_scancode_table *rc_tab = &ir_dev->rc_tab;
+
+ spin_lock_irqsave(&rc_tab->lock, flags);
+ rc = ir_do_setkeycode(dev, rc_tab, scancode, keycode);
+ spin_unlock_irqrestore(&rc_tab->lock, flags);
+ return rc;
+}
+
+/**
+ * ir_setkeytable() - sets several entries in the scancode->keycode table
+ * @dev: the struct input_dev device descriptor
+ * @to: the struct ir_scancode_table to copy entries to
+ * @from: the struct ir_scancode_table to copy entries from
+ * @return: -EINVAL if all keycodes could not be inserted, otherwise zero.
+ *
+ * This routine is used to handle table initialization.
+ */
+static int ir_setkeytable(struct input_dev *dev,
+ struct ir_scancode_table *to,
+ const struct ir_scancode_table *from)
+{
+ struct ir_input_dev *ir_dev = input_get_drvdata(dev);
+ struct ir_scancode_table *rc_tab = &ir_dev->rc_tab;
+ unsigned long flags;
+ unsigned int i;
int rc = 0;
+
+ spin_lock_irqsave(&rc_tab->lock, flags);
+ for (i = 0; i < from->size; i++) {
+ rc = ir_do_setkeycode(dev, to, from->scan[i].scancode,
+ from->scan[i].keycode);
+ if (rc)
+ break;
+ }
+ spin_unlock_irqrestore(&rc_tab->lock, flags);
+ return rc;
+}
+
+/**
+ * ir_getkeycode() - get a keycode from the scancode->keycode table
+ * @dev: the struct input_dev device descriptor
+ * @scancode: the desired scancode
+ * @keycode: used to return the keycode, if found, or KEY_RESERVED
+ * @return: always returns zero.
+ *
+ * This routine is used to handle evdev EVIOCGKEY ioctl.
+ */
+static int ir_getkeycode(struct input_dev *dev,
+ int scancode, int *keycode)
+{
+ int start, end, mid;
+ unsigned long flags;
+ int key = KEY_RESERVED;
struct ir_input_dev *ir_dev = input_get_drvdata(dev);
struct ir_scancode_table *rc_tab = &ir_dev->rc_tab;
- struct ir_scancode *keymap = rc_tab->scan;
- unsigned long flags;
- /*
- * Handle keycode table deletions
- *
- * If userspace is adding a KEY_UNKNOWN or KEY_RESERVED,
- * deal as a trial to remove an existing scancode attribution
- * if table become too big, reduce it to save space
- */
- if (keycode == KEY_UNKNOWN || keycode == KEY_RESERVED) {
- rc = ir_seek_table(rc_tab, scancode);
- if (rc < 0)
- return 0;
-
- IR_dprintk(1, "#%d: Deleting scan 0x%04x\n", rc, scancode);
- clear_bit(keymap[rc].keycode, dev->keybit);
- ir_delete_key(rc_tab, rc);
-
- return 0;
+ spin_lock_irqsave(&rc_tab->lock, flags);
+ start = 0;
+ end = rc_tab->len - 1;
+ while (start <= end) {
+ mid = (start + end) / 2;
+ if (rc_tab->scan[mid].scancode < scancode)
+ start = mid + 1;
+ else if (rc_tab->scan[mid].scancode > scancode)
+ end = mid - 1;
+ else {
+ key = rc_tab->scan[mid].keycode;
+ break;
+ }
}
+ spin_unlock_irqrestore(&rc_tab->lock, flags);
- /*
- * Handle keycode replacements
- *
- * If the scancode exists, just replace by the new value
- */
- rc = ir_seek_table(rc_tab, scancode);
- if (rc >= 0) {
- IR_dprintk(1, "#%d: Replacing scan 0x%04x with key 0x%04x\n",
- rc, scancode, keycode);
-
- clear_bit(keymap[rc].keycode, dev->keybit);
-
- spin_lock_irqsave(&rc_tab->lock, flags);
- keymap[rc].keycode = keycode;
- spin_unlock_irqrestore(&rc_tab->lock, flags);
-
- set_bit(keycode, dev->keybit);
-
- return 0;
- }
-
- /*
- * Handle new scancode inserts
- *
- * reallocate table if needed and insert a new keycode
- */
-
- /* Avoid growing the table indefinitely */
- if (rc_tab->size + 1 > IR_TAB_MAX_SIZE)
- return -EINVAL;
-
- rc = ir_insert_key(rc_tab, scancode, keycode);
- if (rc < 0)
- return rc;
- set_bit(keycode, dev->keybit);
-
+ *keycode = key;
return 0;
}
@@ -369,24 +239,12 @@ static int ir_setkeycode(struct input_dev *dev,
*/
u32 ir_g_keycode_from_table(struct input_dev *dev, u32 scancode)
{
- struct ir_input_dev *ir_dev = input_get_drvdata(dev);
- struct ir_scancode_table *rc_tab = &ir_dev->rc_tab;
- struct ir_scancode *keymap = rc_tab->scan;
- int elem;
+ int keycode;
- elem = ir_seek_table(rc_tab, scancode);
- if (elem >= 0) {
- IR_dprintk(1, "%s: scancode 0x%04x keycode 0x%02x\n",
- dev->name, scancode, keymap[elem].keycode);
-
- return rc_tab->scan[elem].keycode;
- }
-
- printk(KERN_INFO "%s: unknown key for scancode 0x%04x\n",
- dev->name, scancode);
-
- /* Reports userspace that an unknown keycode were got */
- return KEY_RESERVED;
+ ir_getkeycode(dev, scancode, &keycode);
+ IR_dprintk(1, "%s: scancode 0x%04x keycode 0x%02x\n",
+ dev->name, scancode, keycode);
+ return keycode;
}
EXPORT_SYMBOL_GPL(ir_g_keycode_from_table);
@@ -476,8 +334,7 @@ int __ir_input_register(struct input_dev *input_dev,
const char *driver_name)
{
struct ir_input_dev *ir_dev;
- struct ir_scancode *keymap = rc_tab->scan;
- int i, rc;
+ int rc;
if (rc_tab->scan == NULL || !rc_tab->size)
return -EINVAL;
@@ -486,55 +343,55 @@ int __ir_input_register(struct input_dev *input_dev,
if (!ir_dev)
return -ENOMEM;
+ ir_dev->driver_name = kasprintf(GFP_KERNEL, "%s", driver_name);
+ if (!ir_dev->driver_name) {
+ rc = -ENOMEM;
+ goto out_dev;
+ }
+
+ input_dev->getkeycode = ir_getkeycode;
+ input_dev->setkeycode = ir_setkeycode;
+ input_set_drvdata(input_dev, ir_dev);
+
spin_lock_init(&ir_dev->rc_tab.lock);
-
- ir_dev->driver_name = kmalloc(strlen(driver_name) + 1, GFP_KERNEL);
- if (!ir_dev->driver_name)
- return -ENOMEM;
- strcpy(ir_dev->driver_name, driver_name);
ir_dev->rc_tab.name = rc_tab->name;
- ir_dev->rc_tab.size = ir_roundup_tablesize(rc_tab->size);
- ir_dev->rc_tab.scan = kzalloc(ir_dev->rc_tab.size *
- sizeof(struct ir_scancode), GFP_KERNEL);
+ ir_dev->rc_tab.ir_type = rc_tab->ir_type;
+ ir_dev->rc_tab.alloc = roundup_pow_of_two(rc_tab->size *
+ sizeof(struct ir_scancode));
+ ir_dev->rc_tab.scan = kmalloc(ir_dev->rc_tab.alloc, GFP_KERNEL);
+ ir_dev->rc_tab.size = ir_dev->rc_tab.alloc / sizeof(struct ir_scancode);
+
if (!ir_dev->rc_tab.scan) {
- kfree(ir_dev);
- return -ENOMEM;
+ rc = -ENOMEM;
+ goto out_name;
}
- IR_dprintk(1, "Allocated space for %d keycode entries (%zd bytes)\n",
- ir_dev->rc_tab.size,
- ir_dev->rc_tab.size * sizeof(ir_dev->rc_tab.scan));
+ IR_dprintk(1, "Allocated space for %u keycode entries (%u bytes)\n",
+ ir_dev->rc_tab.size, ir_dev->rc_tab.alloc);
+
+ set_bit(EV_KEY, input_dev->evbit);
+ if (ir_setkeytable(input_dev, &ir_dev->rc_tab, rc_tab)) {
+ rc = -ENOMEM;
+ goto out_table;
+ }
- ir_copy_table(&ir_dev->rc_tab, rc_tab);
ir_dev->props = props;
if (props && props->open)
input_dev->open = ir_open;
if (props && props->close)
input_dev->close = ir_close;
- /* set the bits for the keys */
- IR_dprintk(1, "key map size: %d\n", rc_tab->size);
- for (i = 0; i < rc_tab->size; i++) {
- IR_dprintk(1, "#%d: setting bit for keycode 0x%04x\n",
- i, keymap[i].keycode);
- set_bit(keymap[i].keycode, input_dev->keybit);
- }
- clear_bit(0, input_dev->keybit);
-
- set_bit(EV_KEY, input_dev->evbit);
-
- input_dev->getkeycode = ir_getkeycode;
- input_dev->setkeycode = ir_setkeycode;
- input_set_drvdata(input_dev, ir_dev);
-
rc = ir_register_class(input_dev);
if (rc < 0)
- goto err;
+ goto out_table;
return 0;
-err:
- kfree(rc_tab->scan);
+out_table:
+ kfree(ir_dev->rc_tab.scan);
+out_name:
+ kfree(ir_dev->driver_name);
+out_dev:
kfree(ir_dev);
return rc;
}
@@ -563,6 +420,7 @@ void ir_input_unregister(struct input_dev *dev)
ir_unregister_class(dev);
+ kfree(ir_dev->driver_name);
kfree(ir_dev);
}
EXPORT_SYMBOL_GPL(ir_input_unregister);
diff --git a/include/media/ir-core.h b/include/media/ir-core.h
index c6b8e17..7a0be8d 100644
--- a/include/media/ir-core.h
+++ b/include/media/ir-core.h
@@ -47,7 +47,9 @@ struct ir_scancode {
struct ir_scancode_table {
struct ir_scancode *scan;
- int size;
+ unsigned int size; /* Max number of entries */
+ unsigned int len; /* Used number of entries */
+ unsigned int alloc; /* Size of *scan in bytes */
u64 ir_type;
char *name;
spinlock_t lock;
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 11/26] V4L/DVB: ir-common: remove keymap tables from the module
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (13 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 10/26] V4L/DVB: ir-core: Make use of the new IR keymap modules Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 12/26] V4L/DVB: saa7134: Fix IRQ2 bit names for the register map Mauro Carvalho Chehab
` (10 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
Now that the remote keymaps were broken into separate modules,
get rid of the keycode tables that were hardcoded into ir-common.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
delete mode 100644 drivers/media/IR/ir-keymaps.c
delete mode 100644 include/media/keycodes/adstech-dvb-t-pci.h
delete mode 100644 include/media/keycodes/apac-viewcomp.h
delete mode 100644 include/media/keycodes/asus-pc39.h
delete mode 100644 include/media/keycodes/ati-tv-wonder-hd-600.h
delete mode 100644 include/media/keycodes/avermedia-a16d.h
delete mode 100644 include/media/keycodes/avermedia-cardbus.h
delete mode 100644 include/media/keycodes/avermedia-dvbt.h
delete mode 100644 include/media/keycodes/avermedia-m135a-rm-jx.h
delete mode 100644 include/media/keycodes/avermedia.h
delete mode 100644 include/media/keycodes/avertv-303.h
delete mode 100644 include/media/keycodes/behold-columbus.h
delete mode 100644 include/media/keycodes/behold.h
delete mode 100644 include/media/keycodes/budget-ci-old.h
delete mode 100644 include/media/keycodes/cinergy-1400.h
delete mode 100644 include/media/keycodes/cinergy.h
delete mode 100644 include/media/keycodes/dm1105-nec.h
delete mode 100644 include/media/keycodes/dntv-live-dvb-t.h
delete mode 100644 include/media/keycodes/dntv-live-dvbt-pro.h
delete mode 100644 include/media/keycodes/em-terratec.h
delete mode 100644 include/media/keycodes/empty.h
delete mode 100644 include/media/keycodes/encore-enltv-fm53.h
delete mode 100644 include/media/keycodes/encore-enltv.h
delete mode 100644 include/media/keycodes/encore-enltv2.h
delete mode 100644 include/media/keycodes/evga-indtube.h
delete mode 100644 include/media/keycodes/eztv.h
delete mode 100644 include/media/keycodes/flydvb.h
delete mode 100644 include/media/keycodes/flyvideo.h
delete mode 100644 include/media/keycodes/fusionhdtv-mce.h
delete mode 100644 include/media/keycodes/gadmei-rm008z.h
delete mode 100644 include/media/keycodes/genius-tvgo-a11mce.h
delete mode 100644 include/media/keycodes/gotview7135.h
delete mode 100644 include/media/keycodes/hauppauge-new.h
delete mode 100644 include/media/keycodes/iodata-bctv7e.h
delete mode 100644 include/media/keycodes/kaiomy.h
delete mode 100644 include/media/keycodes/kworld-315u.h
delete mode 100644 include/media/keycodes/kworld-plus-tv-analog.h
delete mode 100644 include/media/keycodes/manli.h
delete mode 100644 include/media/keycodes/msi-tvanywhere-plus.h
delete mode 100644 include/media/keycodes/msi-tvanywhere.h
delete mode 100644 include/media/keycodes/nebula.h
delete mode 100644 include/media/keycodes/nec-terratec-cinergy-xs.h
delete mode 100644 include/media/keycodes/norwood.h
delete mode 100644 include/media/keycodes/npgtech.h
delete mode 100644 include/media/keycodes/pctv-sedna.h
delete mode 100644 include/media/keycodes/pinnacle-color.h
delete mode 100644 include/media/keycodes/pinnacle-grey.h
delete mode 100644 include/media/keycodes/pinnacle-pctv-hd.h
delete mode 100644 include/media/keycodes/pixelview-new.h
delete mode 100644 include/media/keycodes/pixelview.h
delete mode 100644 include/media/keycodes/powercolor-real-angel.h
delete mode 100644 include/media/keycodes/proteus-2309.h
delete mode 100644 include/media/keycodes/purpletv.h
delete mode 100644 include/media/keycodes/pv951.h
delete mode 100644 include/media/keycodes/rc5-hauppauge-new.h
delete mode 100644 include/media/keycodes/rc5-tv.h
delete mode 100644 include/media/keycodes/real-audio-220-32-keys.h
delete mode 100644 include/media/keycodes/tbs-nec.h
delete mode 100644 include/media/keycodes/terratec-cinergy-xs.h
delete mode 100644 include/media/keycodes/tevii-nec.h
delete mode 100644 include/media/keycodes/tt-1500.h
delete mode 100644 include/media/keycodes/videomate-s350.h
delete mode 100644 include/media/keycodes/videomate-tv-pvr.h
delete mode 100644 include/media/keycodes/winfast-usbii-deluxe.h
delete mode 100644 include/media/keycodes/winfast.h
diff --git a/drivers/media/IR/Makefile b/drivers/media/IR/Makefile
index 3d8dd30..0e3f912 100644
--- a/drivers/media/IR/Makefile
+++ b/drivers/media/IR/Makefile
@@ -1,4 +1,4 @@
-ir-common-objs := ir-functions.o ir-keymaps.o
+ir-common-objs := ir-functions.o
ir-core-objs := ir-keytable.o ir-sysfs.o ir-raw-event.o rc-map.o
obj-y += keymaps/
diff --git a/drivers/media/IR/ir-keymaps.c b/drivers/media/IR/ir-keymaps.c
deleted file mode 100644
index eb25531..0000000
--- a/drivers/media/IR/ir-keymaps.c
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- Keytables for supported remote controls, used on drivers/media
- devices.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-*/
-
-#define IR_KEYMAPS
-
-/*
- * NOTICE FOR DEVELOPERS:
- * The IR mappings should be as close as possible to what's
- * specified at:
- * http://linuxtv.org/wiki/index.php/Remote_Controllers
- *
- * The usage of tables with just the command part is deprecated.
- * All new IR keytables should contain address+command and need
- * to define the proper IR_TYPE (IR_TYPE_RC5/IR_TYPE_NEC).
- * The deprecated tables should use IR_TYPE_UNKNOWN
- */
-#include <linux/module.h>
-
-#include <linux/input.h>
-#include <media/ir-common.h>
-
-/*
- * All keytables got moved to include/media/keytables directory.
- * This file is still needed - at least for now, as their data is
- * dynamically inserted here by the media/ir-common.h, due to the
- * #define IR_KEYMAPS line, at the beginning of this file. The
- * plans are to get rid of this file completely in a near future.
- */
-
diff --git a/include/media/ir-common.h b/include/media/ir-common.h
index 59ce302..528050e 100644
--- a/include/media/ir-common.h
+++ b/include/media/ir-common.h
@@ -28,71 +28,6 @@
#include <linux/interrupt.h>
#include <media/ir-core.h>
-#include <media/keycodes/adstech-dvb-t-pci.h>
-#include <media/keycodes/apac-viewcomp.h>
-#include <media/keycodes/asus-pc39.h>
-#include <media/keycodes/ati-tv-wonder-hd-600.h>
-#include <media/keycodes/avermedia-a16d.h>
-#include <media/keycodes/avermedia-cardbus.h>
-#include <media/keycodes/avermedia-dvbt.h>
-#include <media/keycodes/avermedia.h>
-#include <media/keycodes/avermedia-m135a-rm-jx.h>
-#include <media/keycodes/avertv-303.h>
-#include <media/keycodes/behold-columbus.h>
-#include <media/keycodes/behold.h>
-#include <media/keycodes/budget-ci-old.h>
-#include <media/keycodes/cinergy-1400.h>
-#include <media/keycodes/cinergy.h>
-#include <media/keycodes/dm1105-nec.h>
-#include <media/keycodes/dntv-live-dvb-t.h>
-#include <media/keycodes/dntv-live-dvbt-pro.h>
-#include <media/keycodes/empty.h>
-#include <media/keycodes/em-terratec.h>
-#include <media/keycodes/encore-enltv2.h>
-#include <media/keycodes/encore-enltv-fm53.h>
-#include <media/keycodes/encore-enltv.h>
-#include <media/keycodes/evga-indtube.h>
-#include <media/keycodes/eztv.h>
-#include <media/keycodes/flydvb.h>
-#include <media/keycodes/flyvideo.h>
-#include <media/keycodes/fusionhdtv-mce.h>
-#include <media/keycodes/gadmei-rm008z.h>
-#include <media/keycodes/genius-tvgo-a11mce.h>
-#include <media/keycodes/gotview7135.h>
-#include <media/keycodes/hauppauge-new.h>
-#include <media/keycodes/iodata-bctv7e.h>
-#include <media/keycodes/kaiomy.h>
-#include <media/keycodes/kworld-315u.h>
-#include <media/keycodes/kworld-plus-tv-analog.h>
-#include <media/keycodes/manli.h>
-#include <media/keycodes/msi-tvanywhere.h>
-#include <media/keycodes/msi-tvanywhere-plus.h>
-#include <media/keycodes/nebula.h>
-#include <media/keycodes/nec-terratec-cinergy-xs.h>
-#include <media/keycodes/norwood.h>
-#include <media/keycodes/npgtech.h>
-#include <media/keycodes/pctv-sedna.h>
-#include <media/keycodes/pinnacle-color.h>
-#include <media/keycodes/pinnacle-grey.h>
-#include <media/keycodes/pinnacle-pctv-hd.h>
-#include <media/keycodes/pixelview.h>
-#include <media/keycodes/pixelview-new.h>
-#include <media/keycodes/powercolor-real-angel.h>
-#include <media/keycodes/proteus-2309.h>
-#include <media/keycodes/purpletv.h>
-#include <media/keycodes/pv951.h>
-#include <media/keycodes/rc5-hauppauge-new.h>
-#include <media/keycodes/rc5-tv.h>
-#include <media/keycodes/real-audio-220-32-keys.h>
-#include <media/keycodes/tbs-nec.h>
-#include <media/keycodes/terratec-cinergy-xs.h>
-#include <media/keycodes/tevii-nec.h>
-#include <media/keycodes/tt-1500.h>
-#include <media/keycodes/videomate-s350.h>
-#include <media/keycodes/videomate-tv-pvr.h>
-#include <media/keycodes/winfast.h>
-#include <media/keycodes/winfast-usbii-deluxe.h>
-
#define RC5_START(x) (((x)>>12)&3)
#define RC5_TOGGLE(x) (((x)>>11)&1)
#define RC5_ADDR(x) (((x)>>6)&31)
diff --git a/include/media/ir-core.h b/include/media/ir-core.h
index e1772b8..c6b8e17 100644
--- a/include/media/ir-core.h
+++ b/include/media/ir-core.h
@@ -102,24 +102,6 @@ struct ir_raw_handler {
#define to_ir_input_dev(_attr) container_of(_attr, struct ir_input_dev, attr)
-#define IR_KEYTABLE(a) \
-ir_codes_ ## a ## _table
-
-#define DECLARE_IR_KEYTABLE(a) \
-extern struct ir_scancode_table IR_KEYTABLE(a)
-
-#define DEFINE_IR_KEYTABLE(tabname, type) \
-struct ir_scancode_table IR_KEYTABLE(tabname) = { \
- .scan = tabname, \
- .size = ARRAY_SIZE(tabname), \
- .ir_type = type, \
- .name = #tabname, \
-}; \
-EXPORT_SYMBOL_GPL(IR_KEYTABLE(tabname))
-
-#define DEFINE_LEGACY_IR_KEYTABLE(tabname) \
- DEFINE_IR_KEYTABLE(tabname, IR_TYPE_UNKNOWN)
-
/* Routines from rc-map.c */
int ir_register_map(struct rc_keymap *map);
diff --git a/include/media/keycodes/adstech-dvb-t-pci.h b/include/media/keycodes/adstech-dvb-t-pci.h
deleted file mode 100644
index cfca526..0000000
--- a/include/media/keycodes/adstech-dvb-t-pci.h
+++ /dev/null
@@ -1,65 +0,0 @@
-/* adstech-dvb-t-pci.h - Keytable for adstech_dvb_t_pci Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* ADS Tech Instant TV DVB-T PCI Remote */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode adstech_dvb_t_pci[] = {
- /* Keys 0 to 9 */
- { 0x4d, KEY_0 },
- { 0x57, KEY_1 },
- { 0x4f, KEY_2 },
- { 0x53, KEY_3 },
- { 0x56, KEY_4 },
- { 0x4e, KEY_5 },
- { 0x5e, KEY_6 },
- { 0x54, KEY_7 },
- { 0x4c, KEY_8 },
- { 0x5c, KEY_9 },
-
- { 0x5b, KEY_POWER },
- { 0x5f, KEY_MUTE },
- { 0x55, KEY_GOTO },
- { 0x5d, KEY_SEARCH },
- { 0x17, KEY_EPG }, /* Guide */
- { 0x1f, KEY_MENU },
- { 0x0f, KEY_UP },
- { 0x46, KEY_DOWN },
- { 0x16, KEY_LEFT },
- { 0x1e, KEY_RIGHT },
- { 0x0e, KEY_SELECT }, /* Enter */
- { 0x5a, KEY_INFO },
- { 0x52, KEY_EXIT },
- { 0x59, KEY_PREVIOUS },
- { 0x51, KEY_NEXT },
- { 0x58, KEY_REWIND },
- { 0x50, KEY_FORWARD },
- { 0x44, KEY_PLAYPAUSE },
- { 0x07, KEY_STOP },
- { 0x1b, KEY_RECORD },
- { 0x13, KEY_TUNER }, /* Live */
- { 0x0a, KEY_A },
- { 0x12, KEY_B },
- { 0x03, KEY_PROG1 }, /* 1 */
- { 0x01, KEY_PROG2 }, /* 2 */
- { 0x00, KEY_PROG3 }, /* 3 */
- { 0x06, KEY_DVD },
- { 0x48, KEY_AUX }, /* Photo */
- { 0x40, KEY_VIDEO },
- { 0x19, KEY_AUDIO }, /* Music */
- { 0x0b, KEY_CHANNELUP },
- { 0x08, KEY_CHANNELDOWN },
- { 0x15, KEY_VOLUMEUP },
- { 0x1c, KEY_VOLUMEDOWN },
-};
-DEFINE_LEGACY_IR_KEYTABLE(adstech_dvb_t_pci);
-#else
-DECLARE_IR_KEYTABLE(adstech_dvb_t_pci);
-#endif
diff --git a/include/media/keycodes/apac-viewcomp.h b/include/media/keycodes/apac-viewcomp.h
deleted file mode 100644
index 69460c2..0000000
--- a/include/media/keycodes/apac-viewcomp.h
+++ /dev/null
@@ -1,56 +0,0 @@
-/* apac-viewcomp.h - Keytable for apac_viewcomp Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Attila Kondoros <attila.kondoros@chello.hu> */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode apac_viewcomp[] = {
-
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
- { 0x00, KEY_0 },
- { 0x17, KEY_LAST }, /* +100 */
- { 0x0a, KEY_LIST }, /* recall */
-
-
- { 0x1c, KEY_TUNER }, /* TV/FM */
- { 0x15, KEY_SEARCH }, /* scan */
- { 0x12, KEY_POWER }, /* power */
- { 0x1f, KEY_VOLUMEDOWN }, /* vol up */
- { 0x1b, KEY_VOLUMEUP }, /* vol down */
- { 0x1e, KEY_CHANNELDOWN }, /* chn up */
- { 0x1a, KEY_CHANNELUP }, /* chn down */
-
- { 0x11, KEY_VIDEO }, /* video */
- { 0x0f, KEY_ZOOM }, /* full screen */
- { 0x13, KEY_MUTE }, /* mute/unmute */
- { 0x10, KEY_TEXT }, /* min */
-
- { 0x0d, KEY_STOP }, /* freeze */
- { 0x0e, KEY_RECORD }, /* record */
- { 0x1d, KEY_PLAYPAUSE }, /* stop */
- { 0x19, KEY_PLAY }, /* play */
-
- { 0x16, KEY_GOTO }, /* osd */
- { 0x14, KEY_REFRESH }, /* default */
- { 0x0c, KEY_KPPLUS }, /* fine tune >>>> */
- { 0x18, KEY_KPMINUS }, /* fine tune <<<< */
-};
-DEFINE_LEGACY_IR_KEYTABLE(apac_viewcomp);
-#else
-DECLARE_IR_KEYTABLE(apac_viewcomp);
-#endif
diff --git a/include/media/keycodes/asus-pc39.h b/include/media/keycodes/asus-pc39.h
deleted file mode 100644
index 3e89ccd..0000000
--- a/include/media/keycodes/asus-pc39.h
+++ /dev/null
@@ -1,67 +0,0 @@
-/* asus-pc39.h - Keytable for asus_pc39 Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/*
- * Marc Fargas <telenieko@telenieko.com>
- * this is the remote control that comes with the asus p7131
- * which has a label saying is "Model PC-39"
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode asus_pc39[] = {
- /* Keys 0 to 9 */
- { 0x15, KEY_0 },
- { 0x29, KEY_1 },
- { 0x2d, KEY_2 },
- { 0x2b, KEY_3 },
- { 0x09, KEY_4 },
- { 0x0d, KEY_5 },
- { 0x0b, KEY_6 },
- { 0x31, KEY_7 },
- { 0x35, KEY_8 },
- { 0x33, KEY_9 },
-
- { 0x3e, KEY_RADIO }, /* radio */
- { 0x03, KEY_MENU }, /* dvd/menu */
- { 0x2a, KEY_VOLUMEUP },
- { 0x19, KEY_VOLUMEDOWN },
- { 0x37, KEY_UP },
- { 0x3b, KEY_DOWN },
- { 0x27, KEY_LEFT },
- { 0x2f, KEY_RIGHT },
- { 0x25, KEY_VIDEO }, /* video */
- { 0x39, KEY_AUDIO }, /* music */
-
- { 0x21, KEY_TV }, /* tv */
- { 0x1d, KEY_EXIT }, /* back */
- { 0x0a, KEY_CHANNELUP }, /* channel / program + */
- { 0x1b, KEY_CHANNELDOWN }, /* channel / program - */
- { 0x1a, KEY_ENTER }, /* enter */
-
- { 0x06, KEY_PAUSE }, /* play/pause */
- { 0x1e, KEY_PREVIOUS }, /* rew */
- { 0x26, KEY_NEXT }, /* forward */
- { 0x0e, KEY_REWIND }, /* backward << */
- { 0x3a, KEY_FASTFORWARD }, /* forward >> */
- { 0x36, KEY_STOP },
- { 0x2e, KEY_RECORD }, /* recording */
- { 0x16, KEY_POWER }, /* the button that reads "close" */
-
- { 0x11, KEY_ZOOM }, /* full screen */
- { 0x13, KEY_MACRO }, /* recall */
- { 0x23, KEY_HOME }, /* home */
- { 0x05, KEY_PVR }, /* picture */
- { 0x3d, KEY_MUTE }, /* mute */
- { 0x01, KEY_DVD }, /* dvd */
-};
-DEFINE_LEGACY_IR_KEYTABLE(asus_pc39);
-#else
-DECLARE_IR_KEYTABLE(asus_pc39);
-#endif
diff --git a/include/media/keycodes/ati-tv-wonder-hd-600.h b/include/media/keycodes/ati-tv-wonder-hd-600.h
deleted file mode 100644
index 25db7bf..0000000
--- a/include/media/keycodes/ati-tv-wonder-hd-600.h
+++ /dev/null
@@ -1,45 +0,0 @@
-/* ati-tv-wonder-hd-600.h - Keytable for ati_tv_wonder_hd_600 Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* ATI TV Wonder HD 600 USB
- Devin Heitmueller <devin.heitmueller@gmail.com>
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode ati_tv_wonder_hd_600[] = {
- { 0x00, KEY_RECORD}, /* Row 1 */
- { 0x01, KEY_PLAYPAUSE},
- { 0x02, KEY_STOP},
- { 0x03, KEY_POWER},
- { 0x04, KEY_PREVIOUS}, /* Row 2 */
- { 0x05, KEY_REWIND},
- { 0x06, KEY_FORWARD},
- { 0x07, KEY_NEXT},
- { 0x08, KEY_EPG}, /* Row 3 */
- { 0x09, KEY_HOME},
- { 0x0a, KEY_MENU},
- { 0x0b, KEY_CHANNELUP},
- { 0x0c, KEY_BACK}, /* Row 4 */
- { 0x0d, KEY_UP},
- { 0x0e, KEY_INFO},
- { 0x0f, KEY_CHANNELDOWN},
- { 0x10, KEY_LEFT}, /* Row 5 */
- { 0x11, KEY_SELECT},
- { 0x12, KEY_RIGHT},
- { 0x13, KEY_VOLUMEUP},
- { 0x14, KEY_LAST}, /* Row 6 */
- { 0x15, KEY_DOWN},
- { 0x16, KEY_MUTE},
- { 0x17, KEY_VOLUMEDOWN},
-};
-DEFINE_LEGACY_IR_KEYTABLE(ati_tv_wonder_hd_600);
-#else
-DECLARE_IR_KEYTABLE(ati_tv_wonder_hd_600);
-#endif
diff --git a/include/media/keycodes/avermedia-a16d.h b/include/media/keycodes/avermedia-a16d.h
deleted file mode 100644
index d267951..0000000
--- a/include/media/keycodes/avermedia-a16d.h
+++ /dev/null
@@ -1,52 +0,0 @@
-/* avermedia-a16d.h - Keytable for avermedia_a16d Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode avermedia_a16d[] = {
- { 0x20, KEY_LIST},
- { 0x00, KEY_POWER},
- { 0x28, KEY_1},
- { 0x18, KEY_2},
- { 0x38, KEY_3},
- { 0x24, KEY_4},
- { 0x14, KEY_5},
- { 0x34, KEY_6},
- { 0x2c, KEY_7},
- { 0x1c, KEY_8},
- { 0x3c, KEY_9},
- { 0x12, KEY_SUBTITLE},
- { 0x22, KEY_0},
- { 0x32, KEY_REWIND},
- { 0x3a, KEY_SHUFFLE},
- { 0x02, KEY_PRINT},
- { 0x11, KEY_CHANNELDOWN},
- { 0x31, KEY_CHANNELUP},
- { 0x0c, KEY_ZOOM},
- { 0x1e, KEY_VOLUMEDOWN},
- { 0x3e, KEY_VOLUMEUP},
- { 0x0a, KEY_MUTE},
- { 0x04, KEY_AUDIO},
- { 0x26, KEY_RECORD},
- { 0x06, KEY_PLAY},
- { 0x36, KEY_STOP},
- { 0x16, KEY_PAUSE},
- { 0x2e, KEY_REWIND},
- { 0x0e, KEY_FASTFORWARD},
- { 0x30, KEY_TEXT},
- { 0x21, KEY_GREEN},
- { 0x01, KEY_BLUE},
- { 0x08, KEY_EPG},
- { 0x2a, KEY_MENU},
-};
-DEFINE_LEGACY_IR_KEYTABLE(avermedia_a16d);
-#else
-DECLARE_IR_KEYTABLE(avermedia_a16d);
-#endif
diff --git a/include/media/keycodes/avermedia-cardbus.h b/include/media/keycodes/avermedia-cardbus.h
deleted file mode 100644
index 221049d..0000000
--- a/include/media/keycodes/avermedia-cardbus.h
+++ /dev/null
@@ -1,73 +0,0 @@
-/* avermedia-cardbus.h - Keytable for avermedia_cardbus Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Oldrich Jedlicka <oldium.pro@seznam.cz> */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode avermedia_cardbus[] = {
- { 0x00, KEY_POWER },
- { 0x01, KEY_TUNER }, /* TV/FM */
- { 0x03, KEY_TEXT }, /* Teletext */
- { 0x04, KEY_EPG },
- { 0x05, KEY_1 },
- { 0x06, KEY_2 },
- { 0x07, KEY_3 },
- { 0x08, KEY_AUDIO },
- { 0x09, KEY_4 },
- { 0x0a, KEY_5 },
- { 0x0b, KEY_6 },
- { 0x0c, KEY_ZOOM }, /* Full screen */
- { 0x0d, KEY_7 },
- { 0x0e, KEY_8 },
- { 0x0f, KEY_9 },
- { 0x10, KEY_PAGEUP }, /* 16-CH PREV */
- { 0x11, KEY_0 },
- { 0x12, KEY_INFO },
- { 0x13, KEY_AGAIN }, /* CH RTN - channel return */
- { 0x14, KEY_MUTE },
- { 0x15, KEY_EDIT }, /* Autoscan */
- { 0x17, KEY_SAVE }, /* Screenshot */
- { 0x18, KEY_PLAYPAUSE },
- { 0x19, KEY_RECORD },
- { 0x1a, KEY_PLAY },
- { 0x1b, KEY_STOP },
- { 0x1c, KEY_FASTFORWARD },
- { 0x1d, KEY_REWIND },
- { 0x1e, KEY_VOLUMEDOWN },
- { 0x1f, KEY_VOLUMEUP },
- { 0x22, KEY_SLEEP }, /* Sleep */
- { 0x23, KEY_ZOOM }, /* Aspect */
- { 0x26, KEY_SCREEN }, /* Pos */
- { 0x27, KEY_ANGLE }, /* Size */
- { 0x28, KEY_SELECT }, /* Select */
- { 0x29, KEY_BLUE }, /* Blue/Picture */
- { 0x2a, KEY_BACKSPACE }, /* Back */
- { 0x2b, KEY_MEDIA }, /* PIP (Picture-in-picture) */
- { 0x2c, KEY_DOWN },
- { 0x2e, KEY_DOT },
- { 0x2f, KEY_TV }, /* Live TV */
- { 0x32, KEY_LEFT },
- { 0x33, KEY_CLEAR }, /* Clear */
- { 0x35, KEY_RED }, /* Red/TV */
- { 0x36, KEY_UP },
- { 0x37, KEY_HOME }, /* Home */
- { 0x39, KEY_GREEN }, /* Green/Video */
- { 0x3d, KEY_YELLOW }, /* Yellow/Music */
- { 0x3e, KEY_OK }, /* Ok */
- { 0x3f, KEY_RIGHT },
- { 0x40, KEY_NEXT }, /* Next */
- { 0x41, KEY_PREVIOUS }, /* Previous */
- { 0x42, KEY_CHANNELDOWN }, /* Channel down */
- { 0x43, KEY_CHANNELUP }, /* Channel up */
-};
-DEFINE_LEGACY_IR_KEYTABLE(avermedia_cardbus);
-#else
-DECLARE_IR_KEYTABLE(avermedia_cardbus);
-#endif
diff --git a/include/media/keycodes/avermedia-dvbt.h b/include/media/keycodes/avermedia-dvbt.h
deleted file mode 100644
index bdaadf4..0000000
--- a/include/media/keycodes/avermedia-dvbt.h
+++ /dev/null
@@ -1,54 +0,0 @@
-/* avermedia-dvbt.h - Keytable for avermedia_dvbt Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Matt Jesson <dvb@jesson.eclipse.co.uk */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode avermedia_dvbt[] = {
- { 0x28, KEY_0 }, /* '0' / 'enter' */
- { 0x22, KEY_1 }, /* '1' */
- { 0x12, KEY_2 }, /* '2' / 'up arrow' */
- { 0x32, KEY_3 }, /* '3' */
- { 0x24, KEY_4 }, /* '4' / 'left arrow' */
- { 0x14, KEY_5 }, /* '5' */
- { 0x34, KEY_6 }, /* '6' / 'right arrow' */
- { 0x26, KEY_7 }, /* '7' */
- { 0x16, KEY_8 }, /* '8' / 'down arrow' */
- { 0x36, KEY_9 }, /* '9' */
-
- { 0x20, KEY_LIST }, /* 'source' */
- { 0x10, KEY_TEXT }, /* 'teletext' */
- { 0x00, KEY_POWER }, /* 'power' */
- { 0x04, KEY_AUDIO }, /* 'audio' */
- { 0x06, KEY_ZOOM }, /* 'full screen' */
- { 0x18, KEY_VIDEO }, /* 'display' */
- { 0x38, KEY_SEARCH }, /* 'loop' */
- { 0x08, KEY_INFO }, /* 'preview' */
- { 0x2a, KEY_REWIND }, /* 'backward <<' */
- { 0x1a, KEY_FASTFORWARD }, /* 'forward >>' */
- { 0x3a, KEY_RECORD }, /* 'capture' */
- { 0x0a, KEY_MUTE }, /* 'mute' */
- { 0x2c, KEY_RECORD }, /* 'record' */
- { 0x1c, KEY_PAUSE }, /* 'pause' */
- { 0x3c, KEY_STOP }, /* 'stop' */
- { 0x0c, KEY_PLAY }, /* 'play' */
- { 0x2e, KEY_RED }, /* 'red' */
- { 0x01, KEY_BLUE }, /* 'blue' / 'cancel' */
- { 0x0e, KEY_YELLOW }, /* 'yellow' / 'ok' */
- { 0x21, KEY_GREEN }, /* 'green' */
- { 0x11, KEY_CHANNELDOWN }, /* 'channel -' */
- { 0x31, KEY_CHANNELUP }, /* 'channel +' */
- { 0x1e, KEY_VOLUMEDOWN }, /* 'volume -' */
- { 0x3e, KEY_VOLUMEUP }, /* 'volume +' */
-};
-DEFINE_LEGACY_IR_KEYTABLE(avermedia_dvbt);
-#else
-DECLARE_IR_KEYTABLE(avermedia_dvbt);
-#endif
diff --git a/include/media/keycodes/avermedia-m135a-rm-jx.h b/include/media/keycodes/avermedia-m135a-rm-jx.h
deleted file mode 100644
index 1158598..0000000
--- a/include/media/keycodes/avermedia-m135a-rm-jx.h
+++ /dev/null
@@ -1,66 +0,0 @@
-/* avermedia-m135a-rm-jx.h - Keytable for avermedia_m135a_rm_jx Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/*
- * Avermedia M135A with IR model RM-JX
- * The same codes exist on both Positivo (BR) and original IR
- * Mauro Carvalho Chehab <mchehab@infradead.org>
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode avermedia_m135a_rm_jx[] = {
- { 0x0200, KEY_POWER2 },
- { 0x022e, KEY_DOT }, /* '.' */
- { 0x0201, KEY_MODE }, /* TV/FM or SOURCE */
-
- { 0x0205, KEY_1 },
- { 0x0206, KEY_2 },
- { 0x0207, KEY_3 },
- { 0x0209, KEY_4 },
- { 0x020a, KEY_5 },
- { 0x020b, KEY_6 },
- { 0x020d, KEY_7 },
- { 0x020e, KEY_8 },
- { 0x020f, KEY_9 },
- { 0x0211, KEY_0 },
-
- { 0x0213, KEY_RIGHT }, /* -> or L */
- { 0x0212, KEY_LEFT }, /* <- or R */
-
- { 0x0217, KEY_SLEEP }, /* Capturar Imagem or Snapshot */
- { 0x0210, KEY_SHUFFLE }, /* Amostra or 16 chan prev */
-
- { 0x0303, KEY_CHANNELUP },
- { 0x0302, KEY_CHANNELDOWN },
- { 0x021f, KEY_VOLUMEUP },
- { 0x021e, KEY_VOLUMEDOWN },
- { 0x020c, KEY_ENTER }, /* Full Screen */
-
- { 0x0214, KEY_MUTE },
- { 0x0208, KEY_AUDIO },
-
- { 0x0203, KEY_TEXT }, /* Teletext */
- { 0x0204, KEY_EPG },
- { 0x022b, KEY_TV2 }, /* TV2 or PIP */
-
- { 0x021d, KEY_RED },
- { 0x021c, KEY_YELLOW },
- { 0x0301, KEY_GREEN },
- { 0x0300, KEY_BLUE },
-
- { 0x021a, KEY_PLAYPAUSE },
- { 0x0219, KEY_RECORD },
- { 0x0218, KEY_PLAY },
- { 0x021b, KEY_STOP },
-};
-DEFINE_IR_KEYTABLE(avermedia_m135a_rm_jx, IR_TYPE_NEC);
-#else
-DECLARE_IR_KEYTABLE(avermedia_m135a_rm_jx);
-#endif
diff --git a/include/media/keycodes/avermedia.h b/include/media/keycodes/avermedia.h
deleted file mode 100644
index a483452..0000000
--- a/include/media/keycodes/avermedia.h
+++ /dev/null
@@ -1,62 +0,0 @@
-/* avermedia.h - Keytable for avermedia Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Alex Hermann <gaaf@gmx.net> */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode avermedia[] = {
- { 0x28, KEY_1 },
- { 0x18, KEY_2 },
- { 0x38, KEY_3 },
- { 0x24, KEY_4 },
- { 0x14, KEY_5 },
- { 0x34, KEY_6 },
- { 0x2c, KEY_7 },
- { 0x1c, KEY_8 },
- { 0x3c, KEY_9 },
- { 0x22, KEY_0 },
-
- { 0x20, KEY_TV }, /* TV/FM */
- { 0x10, KEY_CD }, /* CD */
- { 0x30, KEY_TEXT }, /* TELETEXT */
- { 0x00, KEY_POWER }, /* POWER */
-
- { 0x08, KEY_VIDEO }, /* VIDEO */
- { 0x04, KEY_AUDIO }, /* AUDIO */
- { 0x0c, KEY_ZOOM }, /* FULL SCREEN */
-
- { 0x12, KEY_SUBTITLE }, /* DISPLAY */
- { 0x32, KEY_REWIND }, /* LOOP */
- { 0x02, KEY_PRINT }, /* PREVIEW */
-
- { 0x2a, KEY_SEARCH }, /* AUTOSCAN */
- { 0x1a, KEY_SLEEP }, /* FREEZE */
- { 0x3a, KEY_CAMERA }, /* SNAPSHOT */
- { 0x0a, KEY_MUTE }, /* MUTE */
-
- { 0x26, KEY_RECORD }, /* RECORD */
- { 0x16, KEY_PAUSE }, /* PAUSE */
- { 0x36, KEY_STOP }, /* STOP */
- { 0x06, KEY_PLAY }, /* PLAY */
-
- { 0x2e, KEY_RED }, /* RED */
- { 0x21, KEY_GREEN }, /* GREEN */
- { 0x0e, KEY_YELLOW }, /* YELLOW */
- { 0x01, KEY_BLUE }, /* BLUE */
-
- { 0x1e, KEY_VOLUMEDOWN }, /* VOLUME- */
- { 0x3e, KEY_VOLUMEUP }, /* VOLUME+ */
- { 0x11, KEY_CHANNELDOWN }, /* CHANNEL/PAGE- */
- { 0x31, KEY_CHANNELUP } /* CHANNEL/PAGE+ */
-};
-DEFINE_LEGACY_IR_KEYTABLE(avermedia);
-#else
-DECLARE_IR_KEYTABLE(avermedia);
-#endif
diff --git a/include/media/keycodes/avertv-303.h b/include/media/keycodes/avertv-303.h
deleted file mode 100644
index 1ef10af..0000000
--- a/include/media/keycodes/avertv-303.h
+++ /dev/null
@@ -1,61 +0,0 @@
-/* avertv-303.h - Keytable for avertv_303 Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* AVERTV STUDIO 303 Remote */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode avertv_303[] = {
- { 0x2a, KEY_1 },
- { 0x32, KEY_2 },
- { 0x3a, KEY_3 },
- { 0x4a, KEY_4 },
- { 0x52, KEY_5 },
- { 0x5a, KEY_6 },
- { 0x6a, KEY_7 },
- { 0x72, KEY_8 },
- { 0x7a, KEY_9 },
- { 0x0e, KEY_0 },
-
- { 0x02, KEY_POWER },
- { 0x22, KEY_VIDEO },
- { 0x42, KEY_AUDIO },
- { 0x62, KEY_ZOOM },
- { 0x0a, KEY_TV },
- { 0x12, KEY_CD },
- { 0x1a, KEY_TEXT },
-
- { 0x16, KEY_SUBTITLE },
- { 0x1e, KEY_REWIND },
- { 0x06, KEY_PRINT },
-
- { 0x2e, KEY_SEARCH },
- { 0x36, KEY_SLEEP },
- { 0x3e, KEY_SHUFFLE },
- { 0x26, KEY_MUTE },
-
- { 0x4e, KEY_RECORD },
- { 0x56, KEY_PAUSE },
- { 0x5e, KEY_STOP },
- { 0x46, KEY_PLAY },
-
- { 0x6e, KEY_RED },
- { 0x0b, KEY_GREEN },
- { 0x66, KEY_YELLOW },
- { 0x03, KEY_BLUE },
-
- { 0x76, KEY_LEFT },
- { 0x7e, KEY_RIGHT },
- { 0x13, KEY_DOWN },
- { 0x1b, KEY_UP },
-};
-DEFINE_LEGACY_IR_KEYTABLE(avertv_303);
-#else
-DECLARE_IR_KEYTABLE(avertv_303);
-#endif
diff --git a/include/media/keycodes/behold-columbus.h b/include/media/keycodes/behold-columbus.h
deleted file mode 100644
index fb68e75..0000000
--- a/include/media/keycodes/behold-columbus.h
+++ /dev/null
@@ -1,84 +0,0 @@
-/* behold-columbus.h - Keytable for behold_columbus Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Beholder Intl. Ltd. 2008
- * Dmitry Belimov d.belimov@google.com
- * Keytable is used by BeholdTV Columbus
- * The "ascii-art picture" below (in comments, first row
- * is the keycode in hex, and subsequent row(s) shows
- * the button labels (several variants when appropriate)
- * helps to descide which keycodes to assign to the buttons.
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode behold_columbus[] = {
-
- /* 0x13 0x11 0x1C 0x12 *
- * Mute Source TV/FM Power *
- * */
-
- { 0x13, KEY_MUTE },
- { 0x11, KEY_PROPS },
- { 0x1C, KEY_TUNER }, /* KEY_TV/KEY_RADIO */
- { 0x12, KEY_POWER },
-
- /* 0x01 0x02 0x03 0x0D *
- * 1 2 3 Stereo *
- * *
- * 0x04 0x05 0x06 0x19 *
- * 4 5 6 Snapshot *
- * *
- * 0x07 0x08 0x09 0x10 *
- * 7 8 9 Zoom *
- * */
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x0D, KEY_SETUP }, /* Setup key */
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x19, KEY_CAMERA }, /* Snapshot key */
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
- { 0x10, KEY_ZOOM },
-
- /* 0x0A 0x00 0x0B 0x0C *
- * RECALL 0 ChannelUp VolumeUp *
- * */
- { 0x0A, KEY_AGAIN },
- { 0x00, KEY_0 },
- { 0x0B, KEY_CHANNELUP },
- { 0x0C, KEY_VOLUMEUP },
-
- /* 0x1B 0x1D 0x15 0x18 *
- * Timeshift Record ChannelDown VolumeDown *
- * */
-
- { 0x1B, KEY_TIME },
- { 0x1D, KEY_RECORD },
- { 0x15, KEY_CHANNELDOWN },
- { 0x18, KEY_VOLUMEDOWN },
-
- /* 0x0E 0x1E 0x0F 0x1A *
- * Stop Pause Previouse Next *
- * */
-
- { 0x0E, KEY_STOP },
- { 0x1E, KEY_PAUSE },
- { 0x0F, KEY_PREVIOUS },
- { 0x1A, KEY_NEXT },
-
-};
-DEFINE_LEGACY_IR_KEYTABLE(behold_columbus);
-#else
-DECLARE_IR_KEYTABLE(behold_columbus);
-#endif
diff --git a/include/media/keycodes/behold.h b/include/media/keycodes/behold.h
deleted file mode 100644
index 57a2dae..0000000
--- a/include/media/keycodes/behold.h
+++ /dev/null
@@ -1,117 +0,0 @@
-/* behold.h - Keytable for behold Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/*
- * Igor Kuznetsov <igk72@ya.ru>
- * Andrey J. Melnikov <temnota@kmv.ru>
- *
- * Keytable is used by BeholdTV 60x series, M6 series at
- * least, and probably other cards too.
- * The "ascii-art picture" below (in comments, first row
- * is the keycode in hex, and subsequent row(s) shows
- * the button labels (several variants when appropriate)
- * helps to descide which keycodes to assign to the buttons.
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode behold[] = {
-
- /* 0x1c 0x12 *
- * TV/FM POWER *
- * */
- { 0x1c, KEY_TUNER }, /* XXX KEY_TV / KEY_RADIO */
- { 0x12, KEY_POWER },
-
- /* 0x01 0x02 0x03 *
- * 1 2 3 *
- * *
- * 0x04 0x05 0x06 *
- * 4 5 6 *
- * *
- * 0x07 0x08 0x09 *
- * 7 8 9 *
- * */
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- /* 0x0a 0x00 0x17 *
- * RECALL 0 MODE *
- * */
- { 0x0a, KEY_AGAIN },
- { 0x00, KEY_0 },
- { 0x17, KEY_MODE },
-
- /* 0x14 0x10 *
- * ASPECT FULLSCREEN *
- * */
- { 0x14, KEY_SCREEN },
- { 0x10, KEY_ZOOM },
-
- /* 0x0b *
- * Up *
- * *
- * 0x18 0x16 0x0c *
- * Left Ok Right *
- * *
- * 0x015 *
- * Down *
- * */
- { 0x0b, KEY_CHANNELUP },
- { 0x18, KEY_VOLUMEDOWN },
- { 0x16, KEY_OK }, /* XXX KEY_ENTER */
- { 0x0c, KEY_VOLUMEUP },
- { 0x15, KEY_CHANNELDOWN },
-
- /* 0x11 0x0d *
- * MUTE INFO *
- * */
- { 0x11, KEY_MUTE },
- { 0x0d, KEY_INFO },
-
- /* 0x0f 0x1b 0x1a *
- * RECORD PLAY/PAUSE STOP *
- * *
- * 0x0e 0x1f 0x1e *
- *TELETEXT AUDIO SOURCE *
- * RED YELLOW *
- * */
- { 0x0f, KEY_RECORD },
- { 0x1b, KEY_PLAYPAUSE },
- { 0x1a, KEY_STOP },
- { 0x0e, KEY_TEXT },
- { 0x1f, KEY_RED }, /*XXX KEY_AUDIO */
- { 0x1e, KEY_YELLOW }, /*XXX KEY_SOURCE */
-
- /* 0x1d 0x13 0x19 *
- * SLEEP PREVIEW DVB *
- * GREEN BLUE *
- * */
- { 0x1d, KEY_SLEEP },
- { 0x13, KEY_GREEN },
- { 0x19, KEY_BLUE }, /* XXX KEY_SAT */
-
- /* 0x58 0x5c *
- * FREEZE SNAPSHOT *
- * */
- { 0x58, KEY_SLOW },
- { 0x5c, KEY_CAMERA },
-
-};
-DEFINE_LEGACY_IR_KEYTABLE(behold);
-#else
-DECLARE_IR_KEYTABLE(behold);
-#endif
diff --git a/include/media/keycodes/budget-ci-old.h b/include/media/keycodes/budget-ci-old.h
deleted file mode 100644
index 03ada47..0000000
--- a/include/media/keycodes/budget-ci-old.h
+++ /dev/null
@@ -1,68 +0,0 @@
-/* budget-ci-old.h - Keytable for budget_ci_old Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* From reading the following remotes:
- * Zenith Universal 7 / TV Mode 807 / VCR Mode 837
- * Hauppauge (from NOVA-CI-s box product)
- * This is a "middle of the road" approach, differences are noted
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode budget_ci_old[] = {
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
- { 0x0a, KEY_ENTER },
- { 0x0b, KEY_RED },
- { 0x0c, KEY_POWER }, /* RADIO on Hauppauge */
- { 0x0d, KEY_MUTE },
- { 0x0f, KEY_A }, /* TV on Hauppauge */
- { 0x10, KEY_VOLUMEUP },
- { 0x11, KEY_VOLUMEDOWN },
- { 0x14, KEY_B },
- { 0x1c, KEY_UP },
- { 0x1d, KEY_DOWN },
- { 0x1e, KEY_OPTION }, /* RESERVED on Hauppauge */
- { 0x1f, KEY_BREAK },
- { 0x20, KEY_CHANNELUP },
- { 0x21, KEY_CHANNELDOWN },
- { 0x22, KEY_PREVIOUS }, /* Prev Ch on Zenith, SOURCE on Hauppauge */
- { 0x24, KEY_RESTART },
- { 0x25, KEY_OK },
- { 0x26, KEY_CYCLEWINDOWS }, /* MINIMIZE on Hauppauge */
- { 0x28, KEY_ENTER }, /* VCR mode on Zenith */
- { 0x29, KEY_PAUSE },
- { 0x2b, KEY_RIGHT },
- { 0x2c, KEY_LEFT },
- { 0x2e, KEY_MENU }, /* FULL SCREEN on Hauppauge */
- { 0x30, KEY_SLOW },
- { 0x31, KEY_PREVIOUS }, /* VCR mode on Zenith */
- { 0x32, KEY_REWIND },
- { 0x34, KEY_FASTFORWARD },
- { 0x35, KEY_PLAY },
- { 0x36, KEY_STOP },
- { 0x37, KEY_RECORD },
- { 0x38, KEY_TUNER }, /* TV/VCR on Zenith */
- { 0x3a, KEY_C },
- { 0x3c, KEY_EXIT },
- { 0x3d, KEY_POWER2 },
- { 0x3e, KEY_TUNER },
-};
-DEFINE_LEGACY_IR_KEYTABLE(budget_ci_old);
-#else
-DECLARE_IR_KEYTABLE(budget_ci_old);
-#endif
diff --git a/include/media/keycodes/cinergy-1400.h b/include/media/keycodes/cinergy-1400.h
deleted file mode 100644
index 9b562ea..0000000
--- a/include/media/keycodes/cinergy-1400.h
+++ /dev/null
@@ -1,60 +0,0 @@
-/* cinergy-1400.h - Keytable for cinergy_1400 Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Cinergy 1400 DVB-T */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode cinergy_1400[] = {
- { 0x01, KEY_POWER },
- { 0x02, KEY_1 },
- { 0x03, KEY_2 },
- { 0x04, KEY_3 },
- { 0x05, KEY_4 },
- { 0x06, KEY_5 },
- { 0x07, KEY_6 },
- { 0x08, KEY_7 },
- { 0x09, KEY_8 },
- { 0x0a, KEY_9 },
- { 0x0c, KEY_0 },
-
- { 0x0b, KEY_VIDEO },
- { 0x0d, KEY_REFRESH },
- { 0x0e, KEY_SELECT },
- { 0x0f, KEY_EPG },
- { 0x10, KEY_UP },
- { 0x11, KEY_LEFT },
- { 0x12, KEY_OK },
- { 0x13, KEY_RIGHT },
- { 0x14, KEY_DOWN },
- { 0x15, KEY_TEXT },
- { 0x16, KEY_INFO },
-
- { 0x17, KEY_RED },
- { 0x18, KEY_GREEN },
- { 0x19, KEY_YELLOW },
- { 0x1a, KEY_BLUE },
-
- { 0x1b, KEY_CHANNELUP },
- { 0x1c, KEY_VOLUMEUP },
- { 0x1d, KEY_MUTE },
- { 0x1e, KEY_VOLUMEDOWN },
- { 0x1f, KEY_CHANNELDOWN },
-
- { 0x40, KEY_PAUSE },
- { 0x4c, KEY_PLAY },
- { 0x58, KEY_RECORD },
- { 0x54, KEY_PREVIOUS },
- { 0x48, KEY_STOP },
- { 0x5c, KEY_NEXT },
-};
-DEFINE_LEGACY_IR_KEYTABLE(cinergy_1400);
-#else
-DECLARE_IR_KEYTABLE(cinergy_1400);
-#endif
diff --git a/include/media/keycodes/cinergy.h b/include/media/keycodes/cinergy.h
deleted file mode 100644
index 7884696..0000000
--- a/include/media/keycodes/cinergy.h
+++ /dev/null
@@ -1,55 +0,0 @@
-/* cinergy.h - Keytable for cinergy Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode cinergy[] = {
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x0a, KEY_POWER },
- { 0x0b, KEY_PROG1 }, /* app */
- { 0x0c, KEY_ZOOM }, /* zoom/fullscreen */
- { 0x0d, KEY_CHANNELUP }, /* channel */
- { 0x0e, KEY_CHANNELDOWN }, /* channel- */
- { 0x0f, KEY_VOLUMEUP },
- { 0x10, KEY_VOLUMEDOWN },
- { 0x11, KEY_TUNER }, /* AV */
- { 0x12, KEY_NUMLOCK }, /* -/-- */
- { 0x13, KEY_AUDIO }, /* audio */
- { 0x14, KEY_MUTE },
- { 0x15, KEY_UP },
- { 0x16, KEY_DOWN },
- { 0x17, KEY_LEFT },
- { 0x18, KEY_RIGHT },
- { 0x19, BTN_LEFT, },
- { 0x1a, BTN_RIGHT, },
- { 0x1b, KEY_WWW }, /* text */
- { 0x1c, KEY_REWIND },
- { 0x1d, KEY_FORWARD },
- { 0x1e, KEY_RECORD },
- { 0x1f, KEY_PLAY },
- { 0x20, KEY_PREVIOUSSONG },
- { 0x21, KEY_NEXTSONG },
- { 0x22, KEY_PAUSE },
- { 0x23, KEY_STOP },
-};
-DEFINE_LEGACY_IR_KEYTABLE(cinergy);
-#else
-DECLARE_IR_KEYTABLE(cinergy);
-#endif
diff --git a/include/media/keycodes/dm1105-nec.h b/include/media/keycodes/dm1105-nec.h
deleted file mode 100644
index b87d770..0000000
--- a/include/media/keycodes/dm1105-nec.h
+++ /dev/null
@@ -1,52 +0,0 @@
-/* dm1105-nec.h - Keytable for dm1105_nec Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* DVBWorld remotes
- Igor M. Liplianin <liplianin@me.by>
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode dm1105_nec[] = {
- { 0x0a, KEY_POWER2}, /* power */
- { 0x0c, KEY_MUTE}, /* mute */
- { 0x11, KEY_1},
- { 0x12, KEY_2},
- { 0x13, KEY_3},
- { 0x14, KEY_4},
- { 0x15, KEY_5},
- { 0x16, KEY_6},
- { 0x17, KEY_7},
- { 0x18, KEY_8},
- { 0x19, KEY_9},
- { 0x10, KEY_0},
- { 0x1c, KEY_CHANNELUP}, /* ch+ */
- { 0x0f, KEY_CHANNELDOWN}, /* ch- */
- { 0x1a, KEY_VOLUMEUP}, /* vol+ */
- { 0x0e, KEY_VOLUMEDOWN}, /* vol- */
- { 0x04, KEY_RECORD}, /* rec */
- { 0x09, KEY_CHANNEL}, /* fav */
- { 0x08, KEY_BACKSPACE}, /* rewind */
- { 0x07, KEY_FASTFORWARD}, /* fast */
- { 0x0b, KEY_PAUSE}, /* pause */
- { 0x02, KEY_ESC}, /* cancel */
- { 0x03, KEY_TAB}, /* tab */
- { 0x00, KEY_UP}, /* up */
- { 0x1f, KEY_ENTER}, /* ok */
- { 0x01, KEY_DOWN}, /* down */
- { 0x05, KEY_RECORD}, /* cap */
- { 0x06, KEY_STOP}, /* stop */
- { 0x40, KEY_ZOOM}, /* full */
- { 0x1e, KEY_TV}, /* tvmode */
- { 0x1b, KEY_B}, /* recall */
-};
-DEFINE_LEGACY_IR_KEYTABLE(dm1105_nec);
-#else
-DECLARE_IR_KEYTABLE(dm1105_nec);
-#endif
diff --git a/include/media/keycodes/dntv-live-dvb-t.h b/include/media/keycodes/dntv-live-dvb-t.h
deleted file mode 100644
index 4431ae6..0000000
--- a/include/media/keycodes/dntv-live-dvb-t.h
+++ /dev/null
@@ -1,54 +0,0 @@
-/* dntv-live-dvb-t.h - Keytable for dntv_live_dvb_t Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* DigitalNow DNTV Live DVB-T Remote */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode dntv_live_dvb_t[] = {
- { 0x00, KEY_ESC }, /* 'go up a level?' */
- /* Keys 0 to 9 */
- { 0x0a, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x0b, KEY_TUNER }, /* tv/fm */
- { 0x0c, KEY_SEARCH }, /* scan */
- { 0x0d, KEY_STOP },
- { 0x0e, KEY_PAUSE },
- { 0x0f, KEY_LIST }, /* source */
-
- { 0x10, KEY_MUTE },
- { 0x11, KEY_REWIND }, /* backward << */
- { 0x12, KEY_POWER },
- { 0x13, KEY_CAMERA }, /* snap */
- { 0x14, KEY_AUDIO }, /* stereo */
- { 0x15, KEY_CLEAR }, /* reset */
- { 0x16, KEY_PLAY },
- { 0x17, KEY_ENTER },
- { 0x18, KEY_ZOOM }, /* full screen */
- { 0x19, KEY_FASTFORWARD }, /* forward >> */
- { 0x1a, KEY_CHANNELUP },
- { 0x1b, KEY_VOLUMEUP },
- { 0x1c, KEY_INFO }, /* preview */
- { 0x1d, KEY_RECORD }, /* record */
- { 0x1e, KEY_CHANNELDOWN },
- { 0x1f, KEY_VOLUMEDOWN },
-};
-DEFINE_LEGACY_IR_KEYTABLE(dntv_live_dvb_t);
-#else
-DECLARE_IR_KEYTABLE(dntv_live_dvb_t);
-#endif
diff --git a/include/media/keycodes/dntv-live-dvbt-pro.h b/include/media/keycodes/dntv-live-dvbt-pro.h
deleted file mode 100644
index d64fa26..0000000
--- a/include/media/keycodes/dntv-live-dvbt-pro.h
+++ /dev/null
@@ -1,73 +0,0 @@
-/* dntv-live-dvbt-pro.h - Keytable for dntv_live_dvbt_pro Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* DigitalNow DNTV Live! DVB-T Pro Remote */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode dntv_live_dvbt_pro[] = {
- { 0x16, KEY_POWER },
- { 0x5b, KEY_HOME },
-
- { 0x55, KEY_TV }, /* live tv */
- { 0x58, KEY_TUNER }, /* digital Radio */
- { 0x5a, KEY_RADIO }, /* FM radio */
- { 0x59, KEY_DVD }, /* dvd menu */
- { 0x03, KEY_1 },
- { 0x01, KEY_2 },
- { 0x06, KEY_3 },
- { 0x09, KEY_4 },
- { 0x1d, KEY_5 },
- { 0x1f, KEY_6 },
- { 0x0d, KEY_7 },
- { 0x19, KEY_8 },
- { 0x1b, KEY_9 },
- { 0x0c, KEY_CANCEL },
- { 0x15, KEY_0 },
- { 0x4a, KEY_CLEAR },
- { 0x13, KEY_BACK },
- { 0x00, KEY_TAB },
- { 0x4b, KEY_UP },
- { 0x4e, KEY_LEFT },
- { 0x4f, KEY_OK },
- { 0x52, KEY_RIGHT },
- { 0x51, KEY_DOWN },
- { 0x1e, KEY_VOLUMEUP },
- { 0x0a, KEY_VOLUMEDOWN },
- { 0x02, KEY_CHANNELDOWN },
- { 0x05, KEY_CHANNELUP },
- { 0x11, KEY_RECORD },
- { 0x14, KEY_PLAY },
- { 0x4c, KEY_PAUSE },
- { 0x1a, KEY_STOP },
- { 0x40, KEY_REWIND },
- { 0x12, KEY_FASTFORWARD },
- { 0x41, KEY_PREVIOUSSONG }, /* replay |< */
- { 0x42, KEY_NEXTSONG }, /* skip >| */
- { 0x54, KEY_CAMERA }, /* capture */
- { 0x50, KEY_LANGUAGE }, /* sap */
- { 0x47, KEY_TV2 }, /* pip */
- { 0x4d, KEY_SCREEN },
- { 0x43, KEY_SUBTITLE },
- { 0x10, KEY_MUTE },
- { 0x49, KEY_AUDIO }, /* l/r */
- { 0x07, KEY_SLEEP },
- { 0x08, KEY_VIDEO }, /* a/v */
- { 0x0e, KEY_PREVIOUS }, /* recall */
- { 0x45, KEY_ZOOM }, /* zoom + */
- { 0x46, KEY_ANGLE }, /* zoom - */
- { 0x56, KEY_RED },
- { 0x57, KEY_GREEN },
- { 0x5c, KEY_YELLOW },
- { 0x5d, KEY_BLUE },
-};
-DEFINE_LEGACY_IR_KEYTABLE(dntv_live_dvbt_pro);
-#else
-DECLARE_IR_KEYTABLE(dntv_live_dvbt_pro);
-#endif
diff --git a/include/media/keycodes/em-terratec.h b/include/media/keycodes/em-terratec.h
deleted file mode 100644
index 906557d..0000000
--- a/include/media/keycodes/em-terratec.h
+++ /dev/null
@@ -1,46 +0,0 @@
-/* em-terratec.h - Keytable for em_terratec Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode em_terratec[] = {
- { 0x01, KEY_CHANNEL },
- { 0x02, KEY_SELECT },
- { 0x03, KEY_MUTE },
- { 0x04, KEY_POWER },
- { 0x05, KEY_1 },
- { 0x06, KEY_2 },
- { 0x07, KEY_3 },
- { 0x08, KEY_CHANNELUP },
- { 0x09, KEY_4 },
- { 0x0a, KEY_5 },
- { 0x0b, KEY_6 },
- { 0x0c, KEY_CHANNELDOWN },
- { 0x0d, KEY_7 },
- { 0x0e, KEY_8 },
- { 0x0f, KEY_9 },
- { 0x10, KEY_VOLUMEUP },
- { 0x11, KEY_0 },
- { 0x12, KEY_MENU },
- { 0x13, KEY_PRINT },
- { 0x14, KEY_VOLUMEDOWN },
- { 0x16, KEY_PAUSE },
- { 0x18, KEY_RECORD },
- { 0x19, KEY_REWIND },
- { 0x1a, KEY_PLAY },
- { 0x1b, KEY_FORWARD },
- { 0x1c, KEY_BACKSPACE },
- { 0x1e, KEY_STOP },
- { 0x40, KEY_ZOOM },
-};
-DEFINE_LEGACY_IR_KEYTABLE(em_terratec);
-#else
-DECLARE_IR_KEYTABLE(em_terratec);
-#endif
diff --git a/include/media/keycodes/empty.h b/include/media/keycodes/empty.h
deleted file mode 100644
index aea866c..0000000
--- a/include/media/keycodes/empty.h
+++ /dev/null
@@ -1,20 +0,0 @@
-/* empty.h - Keytable for empty Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* empty keytable, can be used as placeholder for not-yet created keytables */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode empty[] = {
- { 0x2a, KEY_COFFEE },
-};
-DEFINE_LEGACY_IR_KEYTABLE(empty);
-#else
-DECLARE_IR_KEYTABLE(empty);
-#endif
diff --git a/include/media/keycodes/encore-enltv-fm53.h b/include/media/keycodes/encore-enltv-fm53.h
deleted file mode 100644
index bccb744..0000000
--- a/include/media/keycodes/encore-enltv-fm53.h
+++ /dev/null
@@ -1,57 +0,0 @@
-/* encore-enltv-fm53.h - Keytable for encore_enltv_fm53 Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Encore ENLTV-FM v5.3
- Mauro Carvalho Chehab <mchehab@infradead.org>
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode encore_enltv_fm53[] = {
- { 0x10, KEY_POWER2},
- { 0x06, KEY_MUTE},
-
- { 0x09, KEY_1},
- { 0x1d, KEY_2},
- { 0x1f, KEY_3},
- { 0x19, KEY_4},
- { 0x1b, KEY_5},
- { 0x11, KEY_6},
- { 0x17, KEY_7},
- { 0x12, KEY_8},
- { 0x16, KEY_9},
- { 0x48, KEY_0},
-
- { 0x04, KEY_LIST}, /* -/-- */
- { 0x40, KEY_LAST}, /* recall */
-
- { 0x02, KEY_MODE}, /* TV/AV */
- { 0x05, KEY_CAMERA}, /* SNAPSHOT */
-
- { 0x4c, KEY_CHANNELUP}, /* UP */
- { 0x00, KEY_CHANNELDOWN}, /* DOWN */
- { 0x0d, KEY_VOLUMEUP}, /* RIGHT */
- { 0x15, KEY_VOLUMEDOWN}, /* LEFT */
- { 0x49, KEY_ENTER}, /* OK */
-
- { 0x54, KEY_RECORD},
- { 0x4d, KEY_PLAY}, /* pause */
-
- { 0x1e, KEY_MENU}, /* video setting */
- { 0x0e, KEY_RIGHT}, /* <- */
- { 0x1a, KEY_LEFT}, /* -> */
-
- { 0x0a, KEY_CLEAR}, /* video default */
- { 0x0c, KEY_ZOOM}, /* hide pannel */
- { 0x47, KEY_SLEEP}, /* shutdown */
-};
-DEFINE_LEGACY_IR_KEYTABLE(encore_enltv_fm53);
-#else
-DECLARE_IR_KEYTABLE(encore_enltv_fm53);
-#endif
diff --git a/include/media/keycodes/encore-enltv.h b/include/media/keycodes/encore-enltv.h
deleted file mode 100644
index 4c55b52..0000000
--- a/include/media/keycodes/encore-enltv.h
+++ /dev/null
@@ -1,88 +0,0 @@
-/* encore-enltv.h - Keytable for encore_enltv Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Encore ENLTV-FM - black plastic, white front cover with white glowing buttons
- Juan Pablo Sormani <sorman@gmail.com> */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode encore_enltv[] = {
-
- /* Power button does nothing, neither in Windows app,
- although it sends data (used for BIOS wakeup?) */
- { 0x0d, KEY_MUTE },
-
- { 0x1e, KEY_TV },
- { 0x00, KEY_VIDEO },
- { 0x01, KEY_AUDIO }, /* music */
- { 0x02, KEY_MHP }, /* picture */
-
- { 0x1f, KEY_1 },
- { 0x03, KEY_2 },
- { 0x04, KEY_3 },
- { 0x05, KEY_4 },
- { 0x1c, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x1d, KEY_9 },
- { 0x0a, KEY_0 },
-
- { 0x09, KEY_LIST }, /* -/-- */
- { 0x0b, KEY_LAST }, /* recall */
-
- { 0x14, KEY_HOME }, /* win start menu */
- { 0x15, KEY_EXIT }, /* exit */
- { 0x16, KEY_CHANNELUP }, /* UP */
- { 0x12, KEY_CHANNELDOWN }, /* DOWN */
- { 0x0c, KEY_VOLUMEUP }, /* RIGHT */
- { 0x17, KEY_VOLUMEDOWN }, /* LEFT */
-
- { 0x18, KEY_ENTER }, /* OK */
-
- { 0x0e, KEY_ESC },
- { 0x13, KEY_CYCLEWINDOWS }, /* desktop */
- { 0x11, KEY_TAB },
- { 0x19, KEY_SWITCHVIDEOMODE }, /* switch */
-
- { 0x1a, KEY_MENU },
- { 0x1b, KEY_ZOOM }, /* fullscreen */
- { 0x44, KEY_TIME }, /* time shift */
- { 0x40, KEY_MODE }, /* source */
-
- { 0x5a, KEY_RECORD },
- { 0x42, KEY_PLAY }, /* play/pause */
- { 0x45, KEY_STOP },
- { 0x43, KEY_CAMERA }, /* camera icon */
-
- { 0x48, KEY_REWIND },
- { 0x4a, KEY_FASTFORWARD },
- { 0x49, KEY_PREVIOUS },
- { 0x4b, KEY_NEXT },
-
- { 0x4c, KEY_FAVORITES }, /* tv wall */
- { 0x4d, KEY_SOUND }, /* DVD sound */
- { 0x4e, KEY_LANGUAGE }, /* DVD lang */
- { 0x4f, KEY_TEXT }, /* DVD text */
-
- { 0x50, KEY_SLEEP }, /* shutdown */
- { 0x51, KEY_MODE }, /* stereo > main */
- { 0x52, KEY_SELECT }, /* stereo > sap */
- { 0x53, KEY_PROG1 }, /* teletext */
-
-
- { 0x59, KEY_RED }, /* AP1 */
- { 0x41, KEY_GREEN }, /* AP2 */
- { 0x47, KEY_YELLOW }, /* AP3 */
- { 0x57, KEY_BLUE }, /* AP4 */
-};
-DEFINE_LEGACY_IR_KEYTABLE(encore_enltv);
-#else
-DECLARE_IR_KEYTABLE(encore_enltv);
-#endif
diff --git a/include/media/keycodes/encore-enltv2.h b/include/media/keycodes/encore-enltv2.h
deleted file mode 100644
index 6b37fbc..0000000
--- a/include/media/keycodes/encore-enltv2.h
+++ /dev/null
@@ -1,66 +0,0 @@
-/* encore-enltv2.h - Keytable for encore_enltv2 Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Encore ENLTV2-FM - silver plastic - "Wand Media" written at the botton
- Mauro Carvalho Chehab <mchehab@infradead.org> */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode encore_enltv2[] = {
- { 0x4c, KEY_POWER2 },
- { 0x4a, KEY_TUNER },
- { 0x40, KEY_1 },
- { 0x60, KEY_2 },
- { 0x50, KEY_3 },
- { 0x70, KEY_4 },
- { 0x48, KEY_5 },
- { 0x68, KEY_6 },
- { 0x58, KEY_7 },
- { 0x78, KEY_8 },
- { 0x44, KEY_9 },
- { 0x54, KEY_0 },
-
- { 0x64, KEY_LAST }, /* +100 */
- { 0x4e, KEY_AGAIN }, /* Recall */
-
- { 0x6c, KEY_SWITCHVIDEOMODE }, /* Video Source */
- { 0x5e, KEY_MENU },
- { 0x56, KEY_SCREEN },
- { 0x7a, KEY_SETUP },
-
- { 0x46, KEY_MUTE },
- { 0x5c, KEY_MODE }, /* Stereo */
- { 0x74, KEY_INFO },
- { 0x7c, KEY_CLEAR },
-
- { 0x55, KEY_UP },
- { 0x49, KEY_DOWN },
- { 0x7e, KEY_LEFT },
- { 0x59, KEY_RIGHT },
- { 0x6a, KEY_ENTER },
-
- { 0x42, KEY_VOLUMEUP },
- { 0x62, KEY_VOLUMEDOWN },
- { 0x52, KEY_CHANNELUP },
- { 0x72, KEY_CHANNELDOWN },
-
- { 0x41, KEY_RECORD },
- { 0x51, KEY_CAMERA }, /* Snapshot */
- { 0x75, KEY_TIME }, /* Timeshift */
- { 0x71, KEY_TV2 }, /* PIP */
-
- { 0x45, KEY_REWIND },
- { 0x6f, KEY_PAUSE },
- { 0x7d, KEY_FORWARD },
- { 0x79, KEY_STOP },
-};
-DEFINE_LEGACY_IR_KEYTABLE(encore_enltv2);
-#else
-DECLARE_IR_KEYTABLE(encore_enltv2);
-#endif
diff --git a/include/media/keycodes/evga-indtube.h b/include/media/keycodes/evga-indtube.h
deleted file mode 100644
index 2aab58d..0000000
--- a/include/media/keycodes/evga-indtube.h
+++ /dev/null
@@ -1,37 +0,0 @@
-/* evga-indtube.h - Keytable for evga_indtube Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* EVGA inDtube
- Devin Heitmueller <devin.heitmueller@gmail.com>
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode evga_indtube[] = {
- { 0x12, KEY_POWER},
- { 0x02, KEY_MODE}, /* TV */
- { 0x14, KEY_MUTE},
- { 0x1a, KEY_CHANNELUP},
- { 0x16, KEY_TV2}, /* PIP */
- { 0x1d, KEY_VOLUMEUP},
- { 0x05, KEY_CHANNELDOWN},
- { 0x0f, KEY_PLAYPAUSE},
- { 0x19, KEY_VOLUMEDOWN},
- { 0x1c, KEY_REWIND},
- { 0x0d, KEY_RECORD},
- { 0x18, KEY_FORWARD},
- { 0x1e, KEY_PREVIOUS},
- { 0x1b, KEY_STOP},
- { 0x1f, KEY_NEXT},
- { 0x13, KEY_CAMERA},
-};
-DEFINE_LEGACY_IR_KEYTABLE(evga_indtube);
-#else
-DECLARE_IR_KEYTABLE(evga_indtube);
-#endif
diff --git a/include/media/keycodes/eztv.h b/include/media/keycodes/eztv.h
deleted file mode 100644
index 030f57a..0000000
--- a/include/media/keycodes/eztv.h
+++ /dev/null
@@ -1,72 +0,0 @@
-/* eztv.h - Keytable for eztv Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Alfons Geser <a.geser@cox.net>
- * updates from Job D. R. Borges <jobdrb@ig.com.br> */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode eztv[] = {
- { 0x12, KEY_POWER },
- { 0x01, KEY_TV }, /* DVR */
- { 0x15, KEY_DVD }, /* DVD */
- { 0x17, KEY_AUDIO }, /* music */
- /* DVR mode / DVD mode / music mode */
-
- { 0x1b, KEY_MUTE }, /* mute */
- { 0x02, KEY_LANGUAGE }, /* MTS/SAP / audio / autoseek */
- { 0x1e, KEY_SUBTITLE }, /* closed captioning / subtitle / seek */
- { 0x16, KEY_ZOOM }, /* full screen */
- { 0x1c, KEY_VIDEO }, /* video source / eject / delall */
- { 0x1d, KEY_RESTART }, /* playback / angle / del */
- { 0x2f, KEY_SEARCH }, /* scan / menu / playlist */
- { 0x30, KEY_CHANNEL }, /* CH surfing / bookmark / memo */
-
- { 0x31, KEY_HELP }, /* help */
- { 0x32, KEY_MODE }, /* num/memo */
- { 0x33, KEY_ESC }, /* cancel */
-
- { 0x0c, KEY_UP }, /* up */
- { 0x10, KEY_DOWN }, /* down */
- { 0x08, KEY_LEFT }, /* left */
- { 0x04, KEY_RIGHT }, /* right */
- { 0x03, KEY_SELECT }, /* select */
-
- { 0x1f, KEY_REWIND }, /* rewind */
- { 0x20, KEY_PLAYPAUSE },/* play/pause */
- { 0x29, KEY_FORWARD }, /* forward */
- { 0x14, KEY_AGAIN }, /* repeat */
- { 0x2b, KEY_RECORD }, /* recording */
- { 0x2c, KEY_STOP }, /* stop */
- { 0x2d, KEY_PLAY }, /* play */
- { 0x2e, KEY_CAMERA }, /* snapshot / shuffle */
-
- { 0x00, KEY_0 },
- { 0x05, KEY_1 },
- { 0x06, KEY_2 },
- { 0x07, KEY_3 },
- { 0x09, KEY_4 },
- { 0x0a, KEY_5 },
- { 0x0b, KEY_6 },
- { 0x0d, KEY_7 },
- { 0x0e, KEY_8 },
- { 0x0f, KEY_9 },
-
- { 0x2a, KEY_VOLUMEUP },
- { 0x11, KEY_VOLUMEDOWN },
- { 0x18, KEY_CHANNELUP },/* CH.tracking up */
- { 0x19, KEY_CHANNELDOWN },/* CH.tracking down */
-
- { 0x13, KEY_ENTER }, /* enter */
- { 0x21, KEY_DOT }, /* . (decimal dot) */
-};
-DEFINE_LEGACY_IR_KEYTABLE(eztv);
-#else
-DECLARE_IR_KEYTABLE(eztv);
-#endif
diff --git a/include/media/keycodes/flydvb.h b/include/media/keycodes/flydvb.h
deleted file mode 100644
index b270cc0..0000000
--- a/include/media/keycodes/flydvb.h
+++ /dev/null
@@ -1,54 +0,0 @@
-/* flydvb.h - Keytable for flydvb Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode flydvb[] = {
- { 0x01, KEY_ZOOM }, /* Full Screen */
- { 0x00, KEY_POWER }, /* Power */
-
- { 0x03, KEY_1 },
- { 0x04, KEY_2 },
- { 0x05, KEY_3 },
- { 0x07, KEY_4 },
- { 0x08, KEY_5 },
- { 0x09, KEY_6 },
- { 0x0b, KEY_7 },
- { 0x0c, KEY_8 },
- { 0x0d, KEY_9 },
- { 0x06, KEY_AGAIN }, /* Recall */
- { 0x0f, KEY_0 },
- { 0x10, KEY_MUTE }, /* Mute */
- { 0x02, KEY_RADIO }, /* TV/Radio */
- { 0x1b, KEY_LANGUAGE }, /* SAP (Second Audio Program) */
-
- { 0x14, KEY_VOLUMEUP }, /* VOL+ */
- { 0x17, KEY_VOLUMEDOWN }, /* VOL- */
- { 0x12, KEY_CHANNELUP }, /* CH+ */
- { 0x13, KEY_CHANNELDOWN }, /* CH- */
- { 0x1d, KEY_ENTER }, /* Enter */
-
- { 0x1a, KEY_MODE }, /* PIP */
- { 0x18, KEY_TUNER }, /* Source */
-
- { 0x1e, KEY_RECORD }, /* Record/Pause */
- { 0x15, KEY_ANGLE }, /* Swap (no label on key) */
- { 0x1c, KEY_PAUSE }, /* Timeshift/Pause */
- { 0x19, KEY_BACK }, /* Rewind << */
- { 0x0a, KEY_PLAYPAUSE }, /* Play/Pause */
- { 0x1f, KEY_FORWARD }, /* Forward >> */
- { 0x16, KEY_PREVIOUS }, /* Back |<< */
- { 0x11, KEY_STOP }, /* Stop */
- { 0x0e, KEY_NEXT }, /* End >>| */
-};
-DEFINE_LEGACY_IR_KEYTABLE(flydvb);
-#else
-DECLARE_IR_KEYTABLE(flydvb);
-#endif
diff --git a/include/media/keycodes/flyvideo.h b/include/media/keycodes/flyvideo.h
deleted file mode 100644
index 5c52f92..0000000
--- a/include/media/keycodes/flyvideo.h
+++ /dev/null
@@ -1,47 +0,0 @@
-/* flyvideo.h - Keytable for flyvideo Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode flyvideo[] = {
- { 0x0f, KEY_0 },
- { 0x03, KEY_1 },
- { 0x04, KEY_2 },
- { 0x05, KEY_3 },
- { 0x07, KEY_4 },
- { 0x08, KEY_5 },
- { 0x09, KEY_6 },
- { 0x0b, KEY_7 },
- { 0x0c, KEY_8 },
- { 0x0d, KEY_9 },
-
- { 0x0e, KEY_MODE }, /* Air/Cable */
- { 0x11, KEY_VIDEO }, /* Video */
- { 0x15, KEY_AUDIO }, /* Audio */
- { 0x00, KEY_POWER }, /* Power */
- { 0x18, KEY_TUNER }, /* AV Source */
- { 0x02, KEY_ZOOM }, /* Fullscreen */
- { 0x1a, KEY_LANGUAGE }, /* Stereo */
- { 0x1b, KEY_MUTE }, /* Mute */
- { 0x14, KEY_VOLUMEUP }, /* Volume + */
- { 0x17, KEY_VOLUMEDOWN },/* Volume - */
- { 0x12, KEY_CHANNELUP },/* Channel + */
- { 0x13, KEY_CHANNELDOWN },/* Channel - */
- { 0x06, KEY_AGAIN }, /* Recall */
- { 0x10, KEY_ENTER }, /* Enter */
-
- { 0x19, KEY_BACK }, /* Rewind ( <<< ) */
- { 0x1f, KEY_FORWARD }, /* Forward ( >>> ) */
- { 0x0a, KEY_ANGLE }, /* no label, may be used as the PAUSE button */
-};
-DEFINE_LEGACY_IR_KEYTABLE(flyvideo);
-#else
-DECLARE_IR_KEYTABLE(flyvideo);
-#endif
diff --git a/include/media/keycodes/fusionhdtv-mce.h b/include/media/keycodes/fusionhdtv-mce.h
deleted file mode 100644
index bf2998f..0000000
--- a/include/media/keycodes/fusionhdtv-mce.h
+++ /dev/null
@@ -1,74 +0,0 @@
-/* fusionhdtv-mce.h - Keytable for fusionhdtv_mce Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* DViCO FUSION HDTV MCE remote */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode fusionhdtv_mce[] = {
-
- { 0x0b, KEY_1 },
- { 0x17, KEY_2 },
- { 0x1b, KEY_3 },
- { 0x07, KEY_4 },
- { 0x50, KEY_5 },
- { 0x54, KEY_6 },
- { 0x48, KEY_7 },
- { 0x4c, KEY_8 },
- { 0x58, KEY_9 },
- { 0x03, KEY_0 },
-
- { 0x5e, KEY_OK },
- { 0x51, KEY_UP },
- { 0x53, KEY_DOWN },
- { 0x5b, KEY_LEFT },
- { 0x5f, KEY_RIGHT },
-
- { 0x02, KEY_TV }, /* Labeled DTV on remote */
- { 0x0e, KEY_MP3 },
- { 0x1a, KEY_DVD },
- { 0x1e, KEY_FAVORITES }, /* Labeled CPF on remote */
- { 0x16, KEY_SETUP },
- { 0x46, KEY_POWER2 }, /* TV On/Off button on remote */
- { 0x0a, KEY_EPG }, /* Labeled Guide on remote */
-
- { 0x49, KEY_BACK },
- { 0x59, KEY_INFO }, /* Labeled MORE on remote */
- { 0x4d, KEY_MENU }, /* Labeled DVDMENU on remote */
- { 0x55, KEY_CYCLEWINDOWS }, /* Labeled ALT-TAB on remote */
-
- { 0x0f, KEY_PREVIOUSSONG }, /* Labeled |<< REPLAY on remote */
- { 0x12, KEY_NEXTSONG }, /* Labeled >>| SKIP on remote */
- { 0x42, KEY_ENTER }, /* Labeled START with a green
- MS windows logo on remote */
-
- { 0x15, KEY_VOLUMEUP },
- { 0x05, KEY_VOLUMEDOWN },
- { 0x11, KEY_CHANNELUP },
- { 0x09, KEY_CHANNELDOWN },
-
- { 0x52, KEY_CAMERA },
- { 0x5a, KEY_TUNER },
- { 0x19, KEY_OPEN },
-
- { 0x13, KEY_MODE }, /* 4:3 16:9 select */
- { 0x1f, KEY_ZOOM },
-
- { 0x43, KEY_REWIND },
- { 0x47, KEY_PLAYPAUSE },
- { 0x4f, KEY_FASTFORWARD },
- { 0x57, KEY_MUTE },
- { 0x0d, KEY_STOP },
- { 0x01, KEY_RECORD },
- { 0x4e, KEY_POWER },
-};
-DEFINE_LEGACY_IR_KEYTABLE(fusionhdtv_mce);
-#else
-DECLARE_IR_KEYTABLE(fusionhdtv_mce);
-#endif
diff --git a/include/media/keycodes/gadmei-rm008z.h b/include/media/keycodes/gadmei-rm008z.h
deleted file mode 100644
index b73d3e5..0000000
--- a/include/media/keycodes/gadmei-rm008z.h
+++ /dev/null
@@ -1,57 +0,0 @@
-/* gadmei-rm008z.h - Keytable for gadmei_rm008z Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* GADMEI UTV330+ RM008Z remote
- Shine Liu <shinel@foxmail.com>
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode gadmei_rm008z[] = {
- { 0x14, KEY_POWER2}, /* POWER OFF */
- { 0x0c, KEY_MUTE}, /* MUTE */
-
- { 0x18, KEY_TV}, /* TV */
- { 0x0e, KEY_VIDEO}, /* AV */
- { 0x0b, KEY_AUDIO}, /* SV */
- { 0x0f, KEY_RADIO}, /* FM */
-
- { 0x00, KEY_1},
- { 0x01, KEY_2},
- { 0x02, KEY_3},
- { 0x03, KEY_4},
- { 0x04, KEY_5},
- { 0x05, KEY_6},
- { 0x06, KEY_7},
- { 0x07, KEY_8},
- { 0x08, KEY_9},
- { 0x09, KEY_0},
- { 0x0a, KEY_INFO}, /* OSD */
- { 0x1c, KEY_BACKSPACE}, /* LAST */
-
- { 0x0d, KEY_PLAY}, /* PLAY */
- { 0x1e, KEY_CAMERA}, /* SNAPSHOT */
- { 0x1a, KEY_RECORD}, /* RECORD */
- { 0x17, KEY_STOP}, /* STOP */
-
- { 0x1f, KEY_UP}, /* UP */
- { 0x44, KEY_DOWN}, /* DOWN */
- { 0x46, KEY_TAB}, /* BACK */
- { 0x4a, KEY_ZOOM}, /* FULLSECREEN */
-
- { 0x10, KEY_VOLUMEUP}, /* VOLUMEUP */
- { 0x11, KEY_VOLUMEDOWN}, /* VOLUMEDOWN */
- { 0x12, KEY_CHANNELUP}, /* CHANNELUP */
- { 0x13, KEY_CHANNELDOWN}, /* CHANNELDOWN */
- { 0x15, KEY_ENTER}, /* OK */
-};
-DEFINE_LEGACY_IR_KEYTABLE(gadmei_rm008z);
-#else
-DECLARE_IR_KEYTABLE(gadmei_rm008z);
-#endif
diff --git a/include/media/keycodes/genius-tvgo-a11mce.h b/include/media/keycodes/genius-tvgo-a11mce.h
deleted file mode 100644
index b0aad3b..0000000
--- a/include/media/keycodes/genius-tvgo-a11mce.h
+++ /dev/null
@@ -1,60 +0,0 @@
-/* genius-tvgo-a11mce.h - Keytable for genius_tvgo_a11mce Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/*
- * Remote control for the Genius TVGO A11MCE
- * Adrian Pardini <pardo.bsso@gmail.com>
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode genius_tvgo_a11mce[] = {
- /* Keys 0 to 9 */
- { 0x48, KEY_0 },
- { 0x09, KEY_1 },
- { 0x1d, KEY_2 },
- { 0x1f, KEY_3 },
- { 0x19, KEY_4 },
- { 0x1b, KEY_5 },
- { 0x11, KEY_6 },
- { 0x17, KEY_7 },
- { 0x12, KEY_8 },
- { 0x16, KEY_9 },
-
- { 0x54, KEY_RECORD }, /* recording */
- { 0x06, KEY_MUTE }, /* mute */
- { 0x10, KEY_POWER },
- { 0x40, KEY_LAST }, /* recall */
- { 0x4c, KEY_CHANNELUP }, /* channel / program + */
- { 0x00, KEY_CHANNELDOWN }, /* channel / program - */
- { 0x0d, KEY_VOLUMEUP },
- { 0x15, KEY_VOLUMEDOWN },
- { 0x4d, KEY_OK }, /* also labeled as Pause */
- { 0x1c, KEY_ZOOM }, /* full screen and Stop*/
- { 0x02, KEY_MODE }, /* AV Source or Rewind*/
- { 0x04, KEY_LIST }, /* -/-- */
- /* small arrows above numbers */
- { 0x1a, KEY_NEXT }, /* also Fast Forward */
- { 0x0e, KEY_PREVIOUS }, /* also Rewind */
- /* these are in a rather non standard layout and have
- an alternate name written */
- { 0x1e, KEY_UP }, /* Video Setting */
- { 0x0a, KEY_DOWN }, /* Video Default */
- { 0x05, KEY_CAMERA }, /* Snapshot */
- { 0x0c, KEY_RIGHT }, /* Hide Panel */
- /* Four buttons without label */
- { 0x49, KEY_RED },
- { 0x0b, KEY_GREEN },
- { 0x13, KEY_YELLOW },
- { 0x50, KEY_BLUE },
-};
-DEFINE_LEGACY_IR_KEYTABLE(genius_tvgo_a11mce);
-#else
-DECLARE_IR_KEYTABLE(genius_tvgo_a11mce);
-#endif
diff --git a/include/media/keycodes/gotview7135.h b/include/media/keycodes/gotview7135.h
deleted file mode 100644
index 1d108e8..0000000
--- a/include/media/keycodes/gotview7135.h
+++ /dev/null
@@ -1,55 +0,0 @@
-/* gotview7135.h - Keytable for gotview7135 Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Mike Baikov <mike@baikov.com> */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode gotview7135[] = {
-
- { 0x11, KEY_POWER },
- { 0x35, KEY_TV },
- { 0x1b, KEY_0 },
- { 0x29, KEY_1 },
- { 0x19, KEY_2 },
- { 0x39, KEY_3 },
- { 0x1f, KEY_4 },
- { 0x2c, KEY_5 },
- { 0x21, KEY_6 },
- { 0x24, KEY_7 },
- { 0x18, KEY_8 },
- { 0x2b, KEY_9 },
- { 0x3b, KEY_AGAIN }, /* LOOP */
- { 0x06, KEY_AUDIO },
- { 0x31, KEY_PRINT }, /* PREVIEW */
- { 0x3e, KEY_VIDEO },
- { 0x10, KEY_CHANNELUP },
- { 0x20, KEY_CHANNELDOWN },
- { 0x0c, KEY_VOLUMEDOWN },
- { 0x28, KEY_VOLUMEUP },
- { 0x08, KEY_MUTE },
- { 0x26, KEY_SEARCH }, /* SCAN */
- { 0x3f, KEY_CAMERA }, /* SNAPSHOT */
- { 0x12, KEY_RECORD },
- { 0x32, KEY_STOP },
- { 0x3c, KEY_PLAY },
- { 0x1d, KEY_REWIND },
- { 0x2d, KEY_PAUSE },
- { 0x0d, KEY_FORWARD },
- { 0x05, KEY_ZOOM }, /*FULL*/
-
- { 0x2a, KEY_F21 }, /* LIVE TIMESHIFT */
- { 0x0e, KEY_F22 }, /* MIN TIMESHIFT */
- { 0x1e, KEY_TIME }, /* TIMESHIFT */
- { 0x38, KEY_F24 }, /* NORMAL TIMESHIFT */
-};
-DEFINE_LEGACY_IR_KEYTABLE(gotview7135);
-#else
-DECLARE_IR_KEYTABLE(gotview7135);
-#endif
diff --git a/include/media/keycodes/hauppauge-new.h b/include/media/keycodes/hauppauge-new.h
deleted file mode 100644
index f06702d..0000000
--- a/include/media/keycodes/hauppauge-new.h
+++ /dev/null
@@ -1,76 +0,0 @@
-/* hauppauge-new.h - Keytable for hauppauge_new Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Hauppauge: the newer, gray remotes (seems there are multiple
- * slightly different versions), shipped with cx88+ivtv cards.
- * almost rc5 coding, but some non-standard keys */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode hauppauge_new[] = {
- /* Keys 0 to 9 */
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x0a, KEY_TEXT }, /* keypad asterisk as well */
- { 0x0b, KEY_RED }, /* red button */
- { 0x0c, KEY_RADIO },
- { 0x0d, KEY_MENU },
- { 0x0e, KEY_SUBTITLE }, /* also the # key */
- { 0x0f, KEY_MUTE },
- { 0x10, KEY_VOLUMEUP },
- { 0x11, KEY_VOLUMEDOWN },
- { 0x12, KEY_PREVIOUS }, /* previous channel */
- { 0x14, KEY_UP },
- { 0x15, KEY_DOWN },
- { 0x16, KEY_LEFT },
- { 0x17, KEY_RIGHT },
- { 0x18, KEY_VIDEO }, /* Videos */
- { 0x19, KEY_AUDIO }, /* Music */
- /* 0x1a: Pictures - presume this means
- "Multimedia Home Platform" -
- no "PICTURES" key in input.h
- */
- { 0x1a, KEY_MHP },
-
- { 0x1b, KEY_EPG }, /* Guide */
- { 0x1c, KEY_TV },
- { 0x1e, KEY_NEXTSONG }, /* skip >| */
- { 0x1f, KEY_EXIT }, /* back/exit */
- { 0x20, KEY_CHANNELUP }, /* channel / program + */
- { 0x21, KEY_CHANNELDOWN }, /* channel / program - */
- { 0x22, KEY_CHANNEL }, /* source (old black remote) */
- { 0x24, KEY_PREVIOUSSONG }, /* replay |< */
- { 0x25, KEY_ENTER }, /* OK */
- { 0x26, KEY_SLEEP }, /* minimize (old black remote) */
- { 0x29, KEY_BLUE }, /* blue key */
- { 0x2e, KEY_GREEN }, /* green button */
- { 0x30, KEY_PAUSE }, /* pause */
- { 0x32, KEY_REWIND }, /* backward << */
- { 0x34, KEY_FASTFORWARD }, /* forward >> */
- { 0x35, KEY_PLAY },
- { 0x36, KEY_STOP },
- { 0x37, KEY_RECORD }, /* recording */
- { 0x38, KEY_YELLOW }, /* yellow key */
- { 0x3b, KEY_SELECT }, /* top right button */
- { 0x3c, KEY_ZOOM }, /* full */
- { 0x3d, KEY_POWER }, /* system power (green button) */
-};
-DEFINE_LEGACY_IR_KEYTABLE(hauppauge_new);
-#else
-DECLARE_IR_KEYTABLE(hauppauge_new);
-#endif
diff --git a/include/media/keycodes/iodata-bctv7e.h b/include/media/keycodes/iodata-bctv7e.h
deleted file mode 100644
index 6dea92a..0000000
--- a/include/media/keycodes/iodata-bctv7e.h
+++ /dev/null
@@ -1,64 +0,0 @@
-/* iodata-bctv7e.h - Keytable for iodata_bctv7e Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* IO-DATA BCTV7E Remote */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode iodata_bctv7e[] = {
- { 0x40, KEY_TV },
- { 0x20, KEY_RADIO }, /* FM */
- { 0x60, KEY_EPG },
- { 0x00, KEY_POWER },
-
- /* Keys 0 to 9 */
- { 0x44, KEY_0 }, /* 10 */
- { 0x50, KEY_1 },
- { 0x30, KEY_2 },
- { 0x70, KEY_3 },
- { 0x48, KEY_4 },
- { 0x28, KEY_5 },
- { 0x68, KEY_6 },
- { 0x58, KEY_7 },
- { 0x38, KEY_8 },
- { 0x78, KEY_9 },
-
- { 0x10, KEY_L }, /* Live */
- { 0x08, KEY_TIME }, /* Time Shift */
-
- { 0x18, KEY_PLAYPAUSE }, /* Play */
-
- { 0x24, KEY_ENTER }, /* 11 */
- { 0x64, KEY_ESC }, /* 12 */
- { 0x04, KEY_M }, /* Multi */
-
- { 0x54, KEY_VIDEO },
- { 0x34, KEY_CHANNELUP },
- { 0x74, KEY_VOLUMEUP },
- { 0x14, KEY_MUTE },
-
- { 0x4c, KEY_VCR }, /* SVIDEO */
- { 0x2c, KEY_CHANNELDOWN },
- { 0x6c, KEY_VOLUMEDOWN },
- { 0x0c, KEY_ZOOM },
-
- { 0x5c, KEY_PAUSE },
- { 0x3c, KEY_RED }, /* || (red) */
- { 0x7c, KEY_RECORD }, /* recording */
- { 0x1c, KEY_STOP },
-
- { 0x41, KEY_REWIND }, /* backward << */
- { 0x21, KEY_PLAY },
- { 0x61, KEY_FASTFORWARD }, /* forward >> */
- { 0x01, KEY_NEXT }, /* skip >| */
-};
-DEFINE_LEGACY_IR_KEYTABLE(iodata_bctv7e);
-#else
-DECLARE_IR_KEYTABLE(iodata_bctv7e);
-#endif
diff --git a/include/media/keycodes/kaiomy.h b/include/media/keycodes/kaiomy.h
deleted file mode 100644
index 2d6dbbc..0000000
--- a/include/media/keycodes/kaiomy.h
+++ /dev/null
@@ -1,63 +0,0 @@
-/* kaiomy.h - Keytable for kaiomy Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Kaiomy TVnPC U2
- Mauro Carvalho Chehab <mchehab@infradead.org>
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode kaiomy[] = {
- { 0x43, KEY_POWER2},
- { 0x01, KEY_LIST},
- { 0x0b, KEY_ZOOM},
- { 0x03, KEY_POWER},
-
- { 0x04, KEY_1},
- { 0x08, KEY_2},
- { 0x02, KEY_3},
-
- { 0x0f, KEY_4},
- { 0x05, KEY_5},
- { 0x06, KEY_6},
-
- { 0x0c, KEY_7},
- { 0x0d, KEY_8},
- { 0x0a, KEY_9},
-
- { 0x11, KEY_0},
-
- { 0x09, KEY_CHANNELUP},
- { 0x07, KEY_CHANNELDOWN},
-
- { 0x0e, KEY_VOLUMEUP},
- { 0x13, KEY_VOLUMEDOWN},
-
- { 0x10, KEY_HOME},
- { 0x12, KEY_ENTER},
-
- { 0x14, KEY_RECORD},
- { 0x15, KEY_STOP},
- { 0x16, KEY_PLAY},
- { 0x17, KEY_MUTE},
-
- { 0x18, KEY_UP},
- { 0x19, KEY_DOWN},
- { 0x1a, KEY_LEFT},
- { 0x1b, KEY_RIGHT},
-
- { 0x1c, KEY_RED},
- { 0x1d, KEY_GREEN},
- { 0x1e, KEY_YELLOW},
- { 0x1f, KEY_BLUE},
-};
-DEFINE_LEGACY_IR_KEYTABLE(kaiomy);
-#else
-DECLARE_IR_KEYTABLE(kaiomy);
-#endif
diff --git a/include/media/keycodes/kworld-315u.h b/include/media/keycodes/kworld-315u.h
deleted file mode 100644
index 44e29b6..0000000
--- a/include/media/keycodes/kworld-315u.h
+++ /dev/null
@@ -1,59 +0,0 @@
-/* kworld-315u.h - Keytable for kworld_315u Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Kworld 315U
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode kworld_315u[] = {
- { 0x6143, KEY_POWER },
- { 0x6101, KEY_TUNER }, /* source */
- { 0x610b, KEY_ZOOM },
- { 0x6103, KEY_POWER2 }, /* shutdown */
-
- { 0x6104, KEY_1 },
- { 0x6108, KEY_2 },
- { 0x6102, KEY_3 },
- { 0x6109, KEY_CHANNELUP },
-
- { 0x610f, KEY_4 },
- { 0x6105, KEY_5 },
- { 0x6106, KEY_6 },
- { 0x6107, KEY_CHANNELDOWN },
-
- { 0x610c, KEY_7 },
- { 0x610d, KEY_8 },
- { 0x610a, KEY_9 },
- { 0x610e, KEY_VOLUMEUP },
-
- { 0x6110, KEY_LAST },
- { 0x6111, KEY_0 },
- { 0x6112, KEY_ENTER },
- { 0x6113, KEY_VOLUMEDOWN },
-
- { 0x6114, KEY_RECORD },
- { 0x6115, KEY_STOP },
- { 0x6116, KEY_PLAY },
- { 0x6117, KEY_MUTE },
-
- { 0x6118, KEY_UP },
- { 0x6119, KEY_DOWN },
- { 0x611a, KEY_LEFT },
- { 0x611b, KEY_RIGHT },
-
- { 0x611c, KEY_RED },
- { 0x611d, KEY_GREEN },
- { 0x611e, KEY_YELLOW },
- { 0x611f, KEY_BLUE },
-};
-DEFINE_IR_KEYTABLE(kworld_315u, IR_TYPE_NEC);
-#else
-DECLARE_IR_KEYTABLE(kworld_315u);
-#endif
diff --git a/include/media/keycodes/kworld-plus-tv-analog.h b/include/media/keycodes/kworld-plus-tv-analog.h
deleted file mode 100644
index 2b4ae0b..0000000
--- a/include/media/keycodes/kworld-plus-tv-analog.h
+++ /dev/null
@@ -1,75 +0,0 @@
-/* kworld-plus-tv-analog.h - Keytable for kworld_plus_tv_analog Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Kworld Plus TV Analog Lite PCI IR
- Mauro Carvalho Chehab <mchehab@infradead.org>
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode kworld_plus_tv_analog[] = {
- { 0x0c, KEY_PROG1 }, /* Kworld key */
- { 0x16, KEY_CLOSECD }, /* -> ) */
- { 0x1d, KEY_POWER2 },
-
- { 0x00, KEY_1 },
- { 0x01, KEY_2 },
- { 0x02, KEY_3 }, /* Two keys have the same code: 3 and left */
- { 0x03, KEY_4 }, /* Two keys have the same code: 3 and right */
- { 0x04, KEY_5 },
- { 0x05, KEY_6 },
- { 0x06, KEY_7 },
- { 0x07, KEY_8 },
- { 0x08, KEY_9 },
- { 0x0a, KEY_0 },
-
- { 0x09, KEY_AGAIN },
- { 0x14, KEY_MUTE },
-
- { 0x20, KEY_UP },
- { 0x21, KEY_DOWN },
- { 0x0b, KEY_ENTER },
-
- { 0x10, KEY_CHANNELUP },
- { 0x11, KEY_CHANNELDOWN },
-
- /* Couldn't map key left/key right since those
- conflict with '3' and '4' scancodes
- I dunno what the original driver does
- */
-
- { 0x13, KEY_VOLUMEUP },
- { 0x12, KEY_VOLUMEDOWN },
-
- /* The lower part of the IR
- There are several duplicated keycodes there.
- Most of them conflict with digits.
- Add mappings just to the unused scancodes.
- Somehow, the original driver has a way to know,
- but this doesn't seem to be on some GPIO.
- Also, it is not related to the time between keyup
- and keydown.
- */
- { 0x19, KEY_TIME}, /* Timeshift */
- { 0x1a, KEY_STOP},
- { 0x1b, KEY_RECORD},
-
- { 0x22, KEY_TEXT},
-
- { 0x15, KEY_AUDIO}, /* ((*)) */
- { 0x0f, KEY_ZOOM},
- { 0x1c, KEY_CAMERA}, /* snapshot */
-
- { 0x18, KEY_RED}, /* B */
- { 0x23, KEY_GREEN}, /* C */
-};
-DEFINE_LEGACY_IR_KEYTABLE(kworld_plus_tv_analog);
-#else
-DECLARE_IR_KEYTABLE(kworld_plus_tv_analog);
-#endif
diff --git a/include/media/keycodes/manli.h b/include/media/keycodes/manli.h
deleted file mode 100644
index 9f8e752..0000000
--- a/include/media/keycodes/manli.h
+++ /dev/null
@@ -1,111 +0,0 @@
-/* manli.h - Keytable for manli Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Michael Tokarev <mjt@tls.msk.ru>
- http://www.corpit.ru/mjt/beholdTV/remote_control.jpg
- keytable is used by MANLI MTV00[0x0c] and BeholdTV 40[13] at
- least, and probably other cards too.
- The "ascii-art picture" below (in comments, first row
- is the keycode in hex, and subsequent row(s) shows
- the button labels (several variants when appropriate)
- helps to descide which keycodes to assign to the buttons.
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode manli[] = {
-
- /* 0x1c 0x12 *
- * FUNCTION POWER *
- * FM (|) *
- * */
- { 0x1c, KEY_RADIO }, /*XXX*/
- { 0x12, KEY_POWER },
-
- /* 0x01 0x02 0x03 *
- * 1 2 3 *
- * *
- * 0x04 0x05 0x06 *
- * 4 5 6 *
- * *
- * 0x07 0x08 0x09 *
- * 7 8 9 *
- * */
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- /* 0x0a 0x00 0x17 *
- * RECALL 0 +100 *
- * PLUS *
- * */
- { 0x0a, KEY_AGAIN }, /*XXX KEY_REWIND? */
- { 0x00, KEY_0 },
- { 0x17, KEY_DIGITS }, /*XXX*/
-
- /* 0x14 0x10 *
- * MENU INFO *
- * OSD */
- { 0x14, KEY_MENU },
- { 0x10, KEY_INFO },
-
- /* 0x0b *
- * Up *
- * *
- * 0x18 0x16 0x0c *
- * Left Ok Right *
- * *
- * 0x015 *
- * Down *
- * */
- { 0x0b, KEY_UP },
- { 0x18, KEY_LEFT },
- { 0x16, KEY_OK }, /*XXX KEY_SELECT? KEY_ENTER? */
- { 0x0c, KEY_RIGHT },
- { 0x15, KEY_DOWN },
-
- /* 0x11 0x0d *
- * TV/AV MODE *
- * SOURCE STEREO *
- * */
- { 0x11, KEY_TV }, /*XXX*/
- { 0x0d, KEY_MODE }, /*XXX there's no KEY_STEREO */
-
- /* 0x0f 0x1b 0x1a *
- * AUDIO Vol+ Chan+ *
- * TIMESHIFT??? *
- * *
- * 0x0e 0x1f 0x1e *
- * SLEEP Vol- Chan- *
- * */
- { 0x0f, KEY_AUDIO },
- { 0x1b, KEY_VOLUMEUP },
- { 0x1a, KEY_CHANNELUP },
- { 0x0e, KEY_TIME },
- { 0x1f, KEY_VOLUMEDOWN },
- { 0x1e, KEY_CHANNELDOWN },
-
- /* 0x13 0x19 *
- * MUTE SNAPSHOT*
- * */
- { 0x13, KEY_MUTE },
- { 0x19, KEY_CAMERA },
-
- /* 0x1d unused ? */
-};
-DEFINE_LEGACY_IR_KEYTABLE(manli);
-#else
-DECLARE_IR_KEYTABLE(manli);
-#endif
diff --git a/include/media/keycodes/msi-tvanywhere-plus.h b/include/media/keycodes/msi-tvanywhere-plus.h
deleted file mode 100644
index c5e51ad..0000000
--- a/include/media/keycodes/msi-tvanywhere-plus.h
+++ /dev/null
@@ -1,100 +0,0 @@
-/* msi-tvanywhere-plus.h - Keytable for msi_tvanywhere_plus Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/*
- Keycodes for remote on the MSI TV@nywhere Plus. The controller IC on the card
- is marked "KS003". The controller is I2C at address 0x30, but does not seem
- to respond to probes until a read is performed from a valid device.
- I don't know why...
-
- Note: This remote may be of similar or identical design to the
- Pixelview remote (?). The raw codes and duplicate button codes
- appear to be the same.
-
- Henry Wong <henry@stuffedcow.net>
- Some changes to formatting and keycodes by Mark Schultz <n9xmj@yahoo.com>
-
-*/
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode msi_tvanywhere_plus[] = {
-
-/* ---- Remote Button Layout ----
-
- POWER SOURCE SCAN MUTE
- TV/FM 1 2 3
- |> 4 5 6
- <| 7 8 9
- ^^UP 0 + RECALL
- vvDN RECORD STOP PLAY
-
- MINIMIZE ZOOM
-
- CH+
- VOL- VOL+
- CH-
-
- SNAPSHOT MTS
-
- << FUNC >> RESET
-*/
-
- { 0x01, KEY_1 }, /* 1 */
- { 0x0b, KEY_2 }, /* 2 */
- { 0x1b, KEY_3 }, /* 3 */
- { 0x05, KEY_4 }, /* 4 */
- { 0x09, KEY_5 }, /* 5 */
- { 0x15, KEY_6 }, /* 6 */
- { 0x06, KEY_7 }, /* 7 */
- { 0x0a, KEY_8 }, /* 8 */
- { 0x12, KEY_9 }, /* 9 */
- { 0x02, KEY_0 }, /* 0 */
- { 0x10, KEY_KPPLUS }, /* + */
- { 0x13, KEY_AGAIN }, /* Recall */
-
- { 0x1e, KEY_POWER }, /* Power */
- { 0x07, KEY_TUNER }, /* Source */
- { 0x1c, KEY_SEARCH }, /* Scan */
- { 0x18, KEY_MUTE }, /* Mute */
-
- { 0x03, KEY_RADIO }, /* TV/FM */
- /* The next four keys are duplicates that appear to send the
- same IR code as Ch+, Ch-, >>, and << . The raw code assigned
- to them is the actual code + 0x20 - they will never be
- detected as such unless some way is discovered to distinguish
- these buttons from those that have the same code. */
- { 0x3f, KEY_RIGHT }, /* |> and Ch+ */
- { 0x37, KEY_LEFT }, /* <| and Ch- */
- { 0x2c, KEY_UP }, /* ^^Up and >> */
- { 0x24, KEY_DOWN }, /* vvDn and << */
-
- { 0x00, KEY_RECORD }, /* Record */
- { 0x08, KEY_STOP }, /* Stop */
- { 0x11, KEY_PLAY }, /* Play */
-
- { 0x0f, KEY_CLOSE }, /* Minimize */
- { 0x19, KEY_ZOOM }, /* Zoom */
- { 0x1a, KEY_CAMERA }, /* Snapshot */
- { 0x0d, KEY_LANGUAGE }, /* MTS */
-
- { 0x14, KEY_VOLUMEDOWN }, /* Vol- */
- { 0x16, KEY_VOLUMEUP }, /* Vol+ */
- { 0x17, KEY_CHANNELDOWN }, /* Ch- */
- { 0x1f, KEY_CHANNELUP }, /* Ch+ */
-
- { 0x04, KEY_REWIND }, /* << */
- { 0x0e, KEY_MENU }, /* Function */
- { 0x0c, KEY_FASTFORWARD }, /* >> */
- { 0x1d, KEY_RESTART }, /* Reset */
-};
-DEFINE_LEGACY_IR_KEYTABLE(msi_tvanywhere_plus);
-#else
-DECLARE_IR_KEYTABLE(msi_tvanywhere_plus);
-#endif
diff --git a/include/media/keycodes/msi-tvanywhere.h b/include/media/keycodes/msi-tvanywhere.h
deleted file mode 100644
index 2f4cfe1..0000000
--- a/include/media/keycodes/msi-tvanywhere.h
+++ /dev/null
@@ -1,44 +0,0 @@
-/* msi-tvanywhere.h - Keytable for msi_tvanywhere Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode msi_tvanywhere[] = {
- /* Keys 0 to 9 */
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x0c, KEY_MUTE },
- { 0x0f, KEY_SCREEN }, /* Full Screen */
- { 0x10, KEY_FN }, /* Funtion */
- { 0x11, KEY_TIME }, /* Time shift */
- { 0x12, KEY_POWER },
- { 0x13, KEY_MEDIA }, /* MTS */
- { 0x14, KEY_SLOW },
- { 0x16, KEY_REWIND }, /* backward << */
- { 0x17, KEY_ENTER }, /* Return */
- { 0x18, KEY_FASTFORWARD }, /* forward >> */
- { 0x1a, KEY_CHANNELUP },
- { 0x1b, KEY_VOLUMEUP },
- { 0x1e, KEY_CHANNELDOWN },
- { 0x1f, KEY_VOLUMEDOWN },
-};
-DEFINE_LEGACY_IR_KEYTABLE(msi_tvanywhere);
-#else
-DECLARE_IR_KEYTABLE(msi_tvanywhere);
-#endif
diff --git a/include/media/keycodes/nebula.h b/include/media/keycodes/nebula.h
deleted file mode 100644
index 4e2eb1f..0000000
--- a/include/media/keycodes/nebula.h
+++ /dev/null
@@ -1,73 +0,0 @@
-/* nebula.h - Keytable for nebula Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode nebula[] = {
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
- { 0x0a, KEY_TV },
- { 0x0b, KEY_AUX },
- { 0x0c, KEY_DVD },
- { 0x0d, KEY_POWER },
- { 0x0e, KEY_MHP }, /* labelled 'Picture' */
- { 0x0f, KEY_AUDIO },
- { 0x10, KEY_INFO },
- { 0x11, KEY_F13 }, /* 16:9 */
- { 0x12, KEY_F14 }, /* 14:9 */
- { 0x13, KEY_EPG },
- { 0x14, KEY_EXIT },
- { 0x15, KEY_MENU },
- { 0x16, KEY_UP },
- { 0x17, KEY_DOWN },
- { 0x18, KEY_LEFT },
- { 0x19, KEY_RIGHT },
- { 0x1a, KEY_ENTER },
- { 0x1b, KEY_CHANNELUP },
- { 0x1c, KEY_CHANNELDOWN },
- { 0x1d, KEY_VOLUMEUP },
- { 0x1e, KEY_VOLUMEDOWN },
- { 0x1f, KEY_RED },
- { 0x20, KEY_GREEN },
- { 0x21, KEY_YELLOW },
- { 0x22, KEY_BLUE },
- { 0x23, KEY_SUBTITLE },
- { 0x24, KEY_F15 }, /* AD */
- { 0x25, KEY_TEXT },
- { 0x26, KEY_MUTE },
- { 0x27, KEY_REWIND },
- { 0x28, KEY_STOP },
- { 0x29, KEY_PLAY },
- { 0x2a, KEY_FASTFORWARD },
- { 0x2b, KEY_F16 }, /* chapter */
- { 0x2c, KEY_PAUSE },
- { 0x2d, KEY_PLAY },
- { 0x2e, KEY_RECORD },
- { 0x2f, KEY_F17 }, /* picture in picture */
- { 0x30, KEY_KPPLUS }, /* zoom in */
- { 0x31, KEY_KPMINUS }, /* zoom out */
- { 0x32, KEY_F18 }, /* capture */
- { 0x33, KEY_F19 }, /* web */
- { 0x34, KEY_EMAIL },
- { 0x35, KEY_PHONE },
- { 0x36, KEY_PC },
-};
-DEFINE_LEGACY_IR_KEYTABLE(nebula);
-#else
-DECLARE_IR_KEYTABLE(nebula);
-#endif
diff --git a/include/media/keycodes/nec-terratec-cinergy-xs.h b/include/media/keycodes/nec-terratec-cinergy-xs.h
deleted file mode 100644
index 39ede1e..0000000
--- a/include/media/keycodes/nec-terratec-cinergy-xs.h
+++ /dev/null
@@ -1,81 +0,0 @@
-/* nec-terratec-cinergy-xs.h - Keytable for nec_terratec_cinergy_xs Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Terratec Cinergy Hybrid T USB XS FM
- Mauro Carvalho Chehab <mchehab@redhat.com>
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode nec_terratec_cinergy_xs[] = {
- { 0x1441, KEY_HOME},
- { 0x1401, KEY_POWER2},
-
- { 0x1442, KEY_MENU}, /* DVD menu */
- { 0x1443, KEY_SUBTITLE},
- { 0x1444, KEY_TEXT}, /* Teletext */
- { 0x1445, KEY_DELETE},
-
- { 0x1402, KEY_1},
- { 0x1403, KEY_2},
- { 0x1404, KEY_3},
- { 0x1405, KEY_4},
- { 0x1406, KEY_5},
- { 0x1407, KEY_6},
- { 0x1408, KEY_7},
- { 0x1409, KEY_8},
- { 0x140a, KEY_9},
- { 0x140c, KEY_0},
-
- { 0x140b, KEY_TUNER}, /* AV */
- { 0x140d, KEY_MODE}, /* A.B */
-
- { 0x1446, KEY_TV},
- { 0x1447, KEY_DVD},
- { 0x1449, KEY_VIDEO},
- { 0x144a, KEY_RADIO}, /* Music */
- { 0x144b, KEY_CAMERA}, /* PIC */
-
- { 0x1410, KEY_UP},
- { 0x1411, KEY_LEFT},
- { 0x1412, KEY_OK},
- { 0x1413, KEY_RIGHT},
- { 0x1414, KEY_DOWN},
-
- { 0x140f, KEY_EPG},
- { 0x1416, KEY_INFO},
- { 0x144d, KEY_BACKSPACE},
-
- { 0x141c, KEY_VOLUMEUP},
- { 0x141e, KEY_VOLUMEDOWN},
-
- { 0x144c, KEY_PLAY},
- { 0x141d, KEY_MUTE},
-
- { 0x141b, KEY_CHANNELUP},
- { 0x141f, KEY_CHANNELDOWN},
-
- { 0x1417, KEY_RED},
- { 0x1418, KEY_GREEN},
- { 0x1419, KEY_YELLOW},
- { 0x141a, KEY_BLUE},
-
- { 0x1458, KEY_RECORD},
- { 0x1448, KEY_STOP},
- { 0x1440, KEY_PAUSE},
-
- { 0x1454, KEY_LAST},
- { 0x144e, KEY_REWIND},
- { 0x144f, KEY_FASTFORWARD},
- { 0x145c, KEY_NEXT},
-};
-DEFINE_IR_KEYTABLE(nec_terratec_cinergy_xs, IR_TYPE_NEC);
-#else
-DECLARE_IR_KEYTABLE(nec_terratec_cinergy_xs);
-#endif
diff --git a/include/media/keycodes/norwood.h b/include/media/keycodes/norwood.h
deleted file mode 100644
index 7f6cc4c..0000000
--- a/include/media/keycodes/norwood.h
+++ /dev/null
@@ -1,61 +0,0 @@
-/* norwood.h - Keytable for norwood Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Norwood Micro (non-Pro) TV Tuner
- By Peter Naulls <peter@chocky.org>
- Key comments are the functions given in the manual */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode norwood[] = {
- /* Keys 0 to 9 */
- { 0x20, KEY_0 },
- { 0x21, KEY_1 },
- { 0x22, KEY_2 },
- { 0x23, KEY_3 },
- { 0x24, KEY_4 },
- { 0x25, KEY_5 },
- { 0x26, KEY_6 },
- { 0x27, KEY_7 },
- { 0x28, KEY_8 },
- { 0x29, KEY_9 },
-
- { 0x78, KEY_TUNER }, /* Video Source */
- { 0x2c, KEY_EXIT }, /* Open/Close software */
- { 0x2a, KEY_SELECT }, /* 2 Digit Select */
- { 0x69, KEY_AGAIN }, /* Recall */
-
- { 0x32, KEY_BRIGHTNESSUP }, /* Brightness increase */
- { 0x33, KEY_BRIGHTNESSDOWN }, /* Brightness decrease */
- { 0x6b, KEY_KPPLUS }, /* (not named >>>>>) */
- { 0x6c, KEY_KPMINUS }, /* (not named <<<<<) */
-
- { 0x2d, KEY_MUTE }, /* Mute */
- { 0x30, KEY_VOLUMEUP }, /* Volume up */
- { 0x31, KEY_VOLUMEDOWN }, /* Volume down */
- { 0x60, KEY_CHANNELUP }, /* Channel up */
- { 0x61, KEY_CHANNELDOWN }, /* Channel down */
-
- { 0x3f, KEY_RECORD }, /* Record */
- { 0x37, KEY_PLAY }, /* Play */
- { 0x36, KEY_PAUSE }, /* Pause */
- { 0x2b, KEY_STOP }, /* Stop */
- { 0x67, KEY_FASTFORWARD }, /* Foward */
- { 0x66, KEY_REWIND }, /* Rewind */
- { 0x3e, KEY_SEARCH }, /* Auto Scan */
- { 0x2e, KEY_CAMERA }, /* Capture Video */
- { 0x6d, KEY_MENU }, /* Show/Hide Control */
- { 0x2f, KEY_ZOOM }, /* Full Screen */
- { 0x34, KEY_RADIO }, /* FM */
- { 0x65, KEY_POWER }, /* Computer power */
-};
-DEFINE_LEGACY_IR_KEYTABLE(norwood);
-#else
-DECLARE_IR_KEYTABLE(norwood);
-#endif
diff --git a/include/media/keycodes/npgtech.h b/include/media/keycodes/npgtech.h
deleted file mode 100644
index dd1ba82..0000000
--- a/include/media/keycodes/npgtech.h
+++ /dev/null
@@ -1,57 +0,0 @@
-/* npgtech.h - Keytable for npgtech Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode npgtech[] = {
- { 0x1d, KEY_SWITCHVIDEOMODE }, /* switch inputs */
- { 0x2a, KEY_FRONT },
-
- { 0x3e, KEY_1 },
- { 0x02, KEY_2 },
- { 0x06, KEY_3 },
- { 0x0a, KEY_4 },
- { 0x0e, KEY_5 },
- { 0x12, KEY_6 },
- { 0x16, KEY_7 },
- { 0x1a, KEY_8 },
- { 0x1e, KEY_9 },
- { 0x3a, KEY_0 },
- { 0x22, KEY_NUMLOCK }, /* -/-- */
- { 0x20, KEY_REFRESH },
-
- { 0x03, KEY_BRIGHTNESSDOWN },
- { 0x28, KEY_AUDIO },
- { 0x3c, KEY_CHANNELUP },
- { 0x3f, KEY_VOLUMEDOWN },
- { 0x2e, KEY_MUTE },
- { 0x3b, KEY_VOLUMEUP },
- { 0x00, KEY_CHANNELDOWN },
- { 0x07, KEY_BRIGHTNESSUP },
- { 0x2c, KEY_TEXT },
-
- { 0x37, KEY_RECORD },
- { 0x17, KEY_PLAY },
- { 0x13, KEY_PAUSE },
- { 0x26, KEY_STOP },
- { 0x18, KEY_FASTFORWARD },
- { 0x14, KEY_REWIND },
- { 0x33, KEY_ZOOM },
- { 0x32, KEY_KEYBOARD },
- { 0x30, KEY_GOTO }, /* Pointing arrow */
- { 0x36, KEY_MACRO }, /* Maximize/Minimize (yellow) */
- { 0x0b, KEY_RADIO },
- { 0x10, KEY_POWER },
-
-};
-DEFINE_LEGACY_IR_KEYTABLE(npgtech);
-#else
-DECLARE_IR_KEYTABLE(npgtech);
-#endif
diff --git a/include/media/keycodes/pctv-sedna.h b/include/media/keycodes/pctv-sedna.h
deleted file mode 100644
index b1d511f..0000000
--- a/include/media/keycodes/pctv-sedna.h
+++ /dev/null
@@ -1,56 +0,0 @@
-/* pctv-sedna.h - Keytable for pctv_sedna Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Mapping for the 28 key remote control as seen at
- http://www.sednacomputer.com/photo/cardbus-tv.jpg
- Pavel Mihaylov <bin@bash.info>
- Also for the remote bundled with Kozumi KTV-01C card */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode pctv_sedna[] = {
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x0a, KEY_AGAIN }, /* Recall */
- { 0x0b, KEY_CHANNELUP },
- { 0x0c, KEY_VOLUMEUP },
- { 0x0d, KEY_MODE }, /* Stereo */
- { 0x0e, KEY_STOP },
- { 0x0f, KEY_PREVIOUSSONG },
- { 0x10, KEY_ZOOM },
- { 0x11, KEY_TUNER }, /* Source */
- { 0x12, KEY_POWER },
- { 0x13, KEY_MUTE },
- { 0x15, KEY_CHANNELDOWN },
- { 0x18, KEY_VOLUMEDOWN },
- { 0x19, KEY_CAMERA }, /* Snapshot */
- { 0x1a, KEY_NEXTSONG },
- { 0x1b, KEY_TIME }, /* Time Shift */
- { 0x1c, KEY_RADIO }, /* FM Radio */
- { 0x1d, KEY_RECORD },
- { 0x1e, KEY_PAUSE },
- /* additional codes for Kozumi's remote */
- { 0x14, KEY_INFO }, /* OSD */
- { 0x16, KEY_OK }, /* OK */
- { 0x17, KEY_DIGITS }, /* Plus */
- { 0x1f, KEY_PLAY }, /* Play */
-};
-DEFINE_LEGACY_IR_KEYTABLE(pctv_sedna);
-#else
-DECLARE_IR_KEYTABLE(pctv_sedna);
-#endif
diff --git a/include/media/keycodes/pinnacle-color.h b/include/media/keycodes/pinnacle-color.h
deleted file mode 100644
index a08eaeb..0000000
--- a/include/media/keycodes/pinnacle-color.h
+++ /dev/null
@@ -1,71 +0,0 @@
-/* pinnacle-color.h - Keytable for pinnacle_color Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode pinnacle_color[] = {
- { 0x59, KEY_MUTE },
- { 0x4a, KEY_POWER },
-
- { 0x18, KEY_TEXT },
- { 0x26, KEY_TV },
- { 0x3d, KEY_PRINT },
-
- { 0x48, KEY_RED },
- { 0x04, KEY_GREEN },
- { 0x11, KEY_YELLOW },
- { 0x00, KEY_BLUE },
-
- { 0x2d, KEY_VOLUMEUP },
- { 0x1e, KEY_VOLUMEDOWN },
-
- { 0x49, KEY_MENU },
-
- { 0x16, KEY_CHANNELUP },
- { 0x17, KEY_CHANNELDOWN },
-
- { 0x20, KEY_UP },
- { 0x21, KEY_DOWN },
- { 0x22, KEY_LEFT },
- { 0x23, KEY_RIGHT },
- { 0x0d, KEY_SELECT },
-
- { 0x08, KEY_BACK },
- { 0x07, KEY_REFRESH },
-
- { 0x2f, KEY_ZOOM },
- { 0x29, KEY_RECORD },
-
- { 0x4b, KEY_PAUSE },
- { 0x4d, KEY_REWIND },
- { 0x2e, KEY_PLAY },
- { 0x4e, KEY_FORWARD },
- { 0x53, KEY_PREVIOUS },
- { 0x4c, KEY_STOP },
- { 0x54, KEY_NEXT },
-
- { 0x69, KEY_0 },
- { 0x6a, KEY_1 },
- { 0x6b, KEY_2 },
- { 0x6c, KEY_3 },
- { 0x6d, KEY_4 },
- { 0x6e, KEY_5 },
- { 0x6f, KEY_6 },
- { 0x70, KEY_7 },
- { 0x71, KEY_8 },
- { 0x72, KEY_9 },
-
- { 0x74, KEY_CHANNEL },
- { 0x0a, KEY_BACKSPACE },
-};
-DEFINE_LEGACY_IR_KEYTABLE(pinnacle_color);
-#else
-DECLARE_IR_KEYTABLE(pinnacle_color);
-#endif
diff --git a/include/media/keycodes/pinnacle-grey.h b/include/media/keycodes/pinnacle-grey.h
deleted file mode 100644
index 3fd2504..0000000
--- a/include/media/keycodes/pinnacle-grey.h
+++ /dev/null
@@ -1,66 +0,0 @@
-/* pinnacle-grey.h - Keytable for pinnacle_grey Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode pinnacle_grey[] = {
- { 0x3a, KEY_0 },
- { 0x31, KEY_1 },
- { 0x32, KEY_2 },
- { 0x33, KEY_3 },
- { 0x34, KEY_4 },
- { 0x35, KEY_5 },
- { 0x36, KEY_6 },
- { 0x37, KEY_7 },
- { 0x38, KEY_8 },
- { 0x39, KEY_9 },
-
- { 0x2f, KEY_POWER },
-
- { 0x2e, KEY_P },
- { 0x1f, KEY_L },
- { 0x2b, KEY_I },
-
- { 0x2d, KEY_SCREEN },
- { 0x1e, KEY_ZOOM },
- { 0x1b, KEY_VOLUMEUP },
- { 0x0f, KEY_VOLUMEDOWN },
- { 0x17, KEY_CHANNELUP },
- { 0x1c, KEY_CHANNELDOWN },
- { 0x25, KEY_INFO },
-
- { 0x3c, KEY_MUTE },
-
- { 0x3d, KEY_LEFT },
- { 0x3b, KEY_RIGHT },
-
- { 0x3f, KEY_UP },
- { 0x3e, KEY_DOWN },
- { 0x1a, KEY_ENTER },
-
- { 0x1d, KEY_MENU },
- { 0x19, KEY_AGAIN },
- { 0x16, KEY_PREVIOUSSONG },
- { 0x13, KEY_NEXTSONG },
- { 0x15, KEY_PAUSE },
- { 0x0e, KEY_REWIND },
- { 0x0d, KEY_PLAY },
- { 0x0b, KEY_STOP },
- { 0x07, KEY_FORWARD },
- { 0x27, KEY_RECORD },
- { 0x26, KEY_TUNER },
- { 0x29, KEY_TEXT },
- { 0x2a, KEY_MEDIA },
- { 0x18, KEY_EPG },
-};
-DEFINE_LEGACY_IR_KEYTABLE(pinnacle_grey);
-#else
-DECLARE_IR_KEYTABLE(pinnacle_grey);
-#endif
diff --git a/include/media/keycodes/pinnacle-pctv-hd.h b/include/media/keycodes/pinnacle-pctv-hd.h
deleted file mode 100644
index be72d50..0000000
--- a/include/media/keycodes/pinnacle-pctv-hd.h
+++ /dev/null
@@ -1,49 +0,0 @@
-/* pinnacle-pctv-hd.h - Keytable for pinnacle_pctv_hd Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Pinnacle PCTV HD 800i mini remote */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode pinnacle_pctv_hd[] = {
-
- { 0x0f, KEY_1 },
- { 0x15, KEY_2 },
- { 0x10, KEY_3 },
- { 0x18, KEY_4 },
- { 0x1b, KEY_5 },
- { 0x1e, KEY_6 },
- { 0x11, KEY_7 },
- { 0x21, KEY_8 },
- { 0x12, KEY_9 },
- { 0x27, KEY_0 },
-
- { 0x24, KEY_ZOOM },
- { 0x2a, KEY_SUBTITLE },
-
- { 0x00, KEY_MUTE },
- { 0x01, KEY_ENTER }, /* Pinnacle Logo */
- { 0x39, KEY_POWER },
-
- { 0x03, KEY_VOLUMEUP },
- { 0x09, KEY_VOLUMEDOWN },
- { 0x06, KEY_CHANNELUP },
- { 0x0c, KEY_CHANNELDOWN },
-
- { 0x2d, KEY_REWIND },
- { 0x30, KEY_PLAYPAUSE },
- { 0x33, KEY_FASTFORWARD },
- { 0x3c, KEY_STOP },
- { 0x36, KEY_RECORD },
- { 0x3f, KEY_EPG }, /* Labeled "?" */
-};
-DEFINE_LEGACY_IR_KEYTABLE(pinnacle_pctv_hd);
-#else
-DECLARE_IR_KEYTABLE(pinnacle_pctv_hd);
-#endif
diff --git a/include/media/keycodes/pixelview-new.h b/include/media/keycodes/pixelview-new.h
deleted file mode 100644
index 76ed0c3..0000000
--- a/include/media/keycodes/pixelview-new.h
+++ /dev/null
@@ -1,59 +0,0 @@
-/* pixelview-new.h - Keytable for pixelview_new Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/*
- Mauro Carvalho Chehab <mchehab@infradead.org>
- present on PV MPEG 8000GT
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode pixelview_new[] = {
- { 0x3c, KEY_TIME }, /* Timeshift */
- { 0x12, KEY_POWER },
-
- { 0x3d, KEY_1 },
- { 0x38, KEY_2 },
- { 0x18, KEY_3 },
- { 0x35, KEY_4 },
- { 0x39, KEY_5 },
- { 0x15, KEY_6 },
- { 0x36, KEY_7 },
- { 0x3a, KEY_8 },
- { 0x1e, KEY_9 },
- { 0x3e, KEY_0 },
-
- { 0x1c, KEY_AGAIN }, /* LOOP */
- { 0x3f, KEY_MEDIA }, /* Source */
- { 0x1f, KEY_LAST }, /* +100 */
- { 0x1b, KEY_MUTE },
-
- { 0x17, KEY_CHANNELDOWN },
- { 0x16, KEY_CHANNELUP },
- { 0x10, KEY_VOLUMEUP },
- { 0x14, KEY_VOLUMEDOWN },
- { 0x13, KEY_ZOOM },
-
- { 0x19, KEY_CAMERA }, /* SNAPSHOT */
- { 0x1a, KEY_SEARCH }, /* scan */
-
- { 0x37, KEY_REWIND }, /* << */
- { 0x32, KEY_RECORD }, /* o (red) */
- { 0x33, KEY_FORWARD }, /* >> */
- { 0x11, KEY_STOP }, /* square */
- { 0x3b, KEY_PLAY }, /* > */
- { 0x30, KEY_PLAYPAUSE }, /* || */
-
- { 0x31, KEY_TV },
- { 0x34, KEY_RADIO },
-};
-DEFINE_LEGACY_IR_KEYTABLE(pixelview_new);
-#else
-DECLARE_IR_KEYTABLE(pixelview_new);
-#endif
diff --git a/include/media/keycodes/pixelview.h b/include/media/keycodes/pixelview.h
deleted file mode 100644
index e048277..0000000
--- a/include/media/keycodes/pixelview.h
+++ /dev/null
@@ -1,59 +0,0 @@
-/* pixelview.h - Keytable for pixelview Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode pixelview[] = {
-
- { 0x1e, KEY_POWER }, /* power */
- { 0x07, KEY_MEDIA }, /* source */
- { 0x1c, KEY_SEARCH }, /* scan */
-
-
- { 0x03, KEY_TUNER }, /* TV/FM */
-
- { 0x00, KEY_RECORD },
- { 0x08, KEY_STOP },
- { 0x11, KEY_PLAY },
-
- { 0x1a, KEY_PLAYPAUSE }, /* freeze */
- { 0x19, KEY_ZOOM }, /* zoom */
- { 0x0f, KEY_TEXT }, /* min */
-
- { 0x01, KEY_1 },
- { 0x0b, KEY_2 },
- { 0x1b, KEY_3 },
- { 0x05, KEY_4 },
- { 0x09, KEY_5 },
- { 0x15, KEY_6 },
- { 0x06, KEY_7 },
- { 0x0a, KEY_8 },
- { 0x12, KEY_9 },
- { 0x02, KEY_0 },
- { 0x10, KEY_LAST }, /* +100 */
- { 0x13, KEY_LIST }, /* recall */
-
- { 0x1f, KEY_CHANNELUP }, /* chn down */
- { 0x17, KEY_CHANNELDOWN }, /* chn up */
- { 0x16, KEY_VOLUMEUP }, /* vol down */
- { 0x14, KEY_VOLUMEDOWN }, /* vol up */
-
- { 0x04, KEY_KPMINUS }, /* <<< */
- { 0x0e, KEY_SETUP }, /* function */
- { 0x0c, KEY_KPPLUS }, /* >>> */
-
- { 0x0d, KEY_GOTO }, /* mts */
- { 0x1d, KEY_REFRESH }, /* reset */
- { 0x18, KEY_MUTE }, /* mute/unmute */
-};
-DEFINE_LEGACY_IR_KEYTABLE(pixelview);
-#else
-DECLARE_IR_KEYTABLE(pixelview);
-#endif
diff --git a/include/media/keycodes/powercolor-real-angel.h b/include/media/keycodes/powercolor-real-angel.h
deleted file mode 100644
index 098c4a9..0000000
--- a/include/media/keycodes/powercolor-real-angel.h
+++ /dev/null
@@ -1,57 +0,0 @@
-/* powercolor-real-angel.h - Keytable for powercolor_real_angel Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/*
- * Remote control for Powercolor Real Angel 330
- * Daniel Fraga <fragabr@gmail.com>
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode powercolor_real_angel[] = {
- { 0x38, KEY_SWITCHVIDEOMODE }, /* switch inputs */
- { 0x0c, KEY_MEDIA }, /* Turn ON/OFF App */
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
- { 0x0a, KEY_DIGITS }, /* single, double, tripple digit */
- { 0x29, KEY_PREVIOUS }, /* previous channel */
- { 0x12, KEY_BRIGHTNESSUP },
- { 0x13, KEY_BRIGHTNESSDOWN },
- { 0x2b, KEY_MODE }, /* stereo/mono */
- { 0x2c, KEY_TEXT }, /* teletext */
- { 0x20, KEY_CHANNELUP }, /* channel up */
- { 0x21, KEY_CHANNELDOWN }, /* channel down */
- { 0x10, KEY_VOLUMEUP }, /* volume up */
- { 0x11, KEY_VOLUMEDOWN }, /* volume down */
- { 0x0d, KEY_MUTE },
- { 0x1f, KEY_RECORD },
- { 0x17, KEY_PLAY },
- { 0x16, KEY_PAUSE },
- { 0x0b, KEY_STOP },
- { 0x27, KEY_FASTFORWARD },
- { 0x26, KEY_REWIND },
- { 0x1e, KEY_SEARCH }, /* autoscan */
- { 0x0e, KEY_CAMERA }, /* snapshot */
- { 0x2d, KEY_SETUP },
- { 0x0f, KEY_SCREEN }, /* full screen */
- { 0x14, KEY_RADIO }, /* FM radio */
- { 0x25, KEY_POWER }, /* power */
-};
-DEFINE_LEGACY_IR_KEYTABLE(powercolor_real_angel);
-#else
-DECLARE_IR_KEYTABLE(powercolor_real_angel);
-#endif
diff --git a/include/media/keycodes/proteus-2309.h b/include/media/keycodes/proteus-2309.h
deleted file mode 100644
index 1993702..0000000
--- a/include/media/keycodes/proteus-2309.h
+++ /dev/null
@@ -1,45 +0,0 @@
-/* proteus-2309.h - Keytable for proteus_2309 Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Michal Majchrowicz <mmajchrowicz@gmail.com> */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode proteus_2309[] = {
- /* numeric */
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x5c, KEY_POWER }, /* power */
- { 0x20, KEY_ZOOM }, /* full screen */
- { 0x0f, KEY_BACKSPACE }, /* recall */
- { 0x1b, KEY_ENTER }, /* mute */
- { 0x41, KEY_RECORD }, /* record */
- { 0x43, KEY_STOP }, /* stop */
- { 0x16, KEY_S },
- { 0x1a, KEY_POWER2 }, /* off */
- { 0x2e, KEY_RED },
- { 0x1f, KEY_CHANNELDOWN }, /* channel - */
- { 0x1c, KEY_CHANNELUP }, /* channel + */
- { 0x10, KEY_VOLUMEDOWN }, /* volume - */
- { 0x1e, KEY_VOLUMEUP }, /* volume + */
- { 0x14, KEY_F1 },
-};
-DEFINE_LEGACY_IR_KEYTABLE(proteus_2309);
-#else
-DECLARE_IR_KEYTABLE(proteus_2309);
-#endif
diff --git a/include/media/keycodes/purpletv.h b/include/media/keycodes/purpletv.h
deleted file mode 100644
index 1496264..0000000
--- a/include/media/keycodes/purpletv.h
+++ /dev/null
@@ -1,58 +0,0 @@
-/* purpletv.h - Keytable for purpletv Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode purpletv[] = {
- { 0x03, KEY_POWER },
- { 0x6f, KEY_MUTE },
- { 0x10, KEY_BACKSPACE }, /* Recall */
-
- { 0x11, KEY_0 },
- { 0x04, KEY_1 },
- { 0x05, KEY_2 },
- { 0x06, KEY_3 },
- { 0x08, KEY_4 },
- { 0x09, KEY_5 },
- { 0x0a, KEY_6 },
- { 0x0c, KEY_7 },
- { 0x0d, KEY_8 },
- { 0x0e, KEY_9 },
- { 0x12, KEY_DOT }, /* 100+ */
-
- { 0x07, KEY_VOLUMEUP },
- { 0x0b, KEY_VOLUMEDOWN },
- { 0x1a, KEY_KPPLUS },
- { 0x18, KEY_KPMINUS },
- { 0x15, KEY_UP },
- { 0x1d, KEY_DOWN },
- { 0x0f, KEY_CHANNELUP },
- { 0x13, KEY_CHANNELDOWN },
- { 0x48, KEY_ZOOM },
-
- { 0x1b, KEY_VIDEO }, /* Video source */
- { 0x1f, KEY_CAMERA }, /* Snapshot */
- { 0x49, KEY_LANGUAGE }, /* MTS Select */
- { 0x19, KEY_SEARCH }, /* Auto Scan */
-
- { 0x4b, KEY_RECORD },
- { 0x46, KEY_PLAY },
- { 0x45, KEY_PAUSE }, /* Pause */
- { 0x44, KEY_STOP },
- { 0x43, KEY_TIME }, /* Time Shift */
- { 0x17, KEY_CHANNEL }, /* SURF CH */
- { 0x40, KEY_FORWARD }, /* Forward ? */
- { 0x42, KEY_REWIND }, /* Backward ? */
-
-};
-DEFINE_LEGACY_IR_KEYTABLE(purpletv);
-#else
-DECLARE_IR_KEYTABLE(purpletv);
-#endif
diff --git a/include/media/keycodes/pv951.h b/include/media/keycodes/pv951.h
deleted file mode 100644
index 33a8bf7..0000000
--- a/include/media/keycodes/pv951.h
+++ /dev/null
@@ -1,54 +0,0 @@
-/* pv951.h - Keytable for pv951 Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Mark Phalan <phalanm@o2.ie> */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode pv951[] = {
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x12, KEY_POWER },
- { 0x10, KEY_MUTE },
- { 0x1f, KEY_VOLUMEDOWN },
- { 0x1b, KEY_VOLUMEUP },
- { 0x1a, KEY_CHANNELUP },
- { 0x1e, KEY_CHANNELDOWN },
- { 0x0e, KEY_PAGEUP },
- { 0x1d, KEY_PAGEDOWN },
- { 0x13, KEY_SOUND },
-
- { 0x18, KEY_KPPLUSMINUS }, /* CH +/- */
- { 0x16, KEY_SUBTITLE }, /* CC */
- { 0x0d, KEY_TEXT }, /* TTX */
- { 0x0b, KEY_TV }, /* AIR/CBL */
- { 0x11, KEY_PC }, /* PC/TV */
- { 0x17, KEY_OK }, /* CH RTN */
- { 0x19, KEY_MODE }, /* FUNC */
- { 0x0c, KEY_SEARCH }, /* AUTOSCAN */
-
- /* Not sure what to do with these ones! */
- { 0x0f, KEY_SELECT }, /* SOURCE */
- { 0x0a, KEY_KPPLUS }, /* +100 */
- { 0x14, KEY_EQUAL }, /* SYNC */
- { 0x1c, KEY_MEDIA }, /* PC/TV */
-};
-DEFINE_LEGACY_IR_KEYTABLE(pv951);
-#else
-DECLARE_IR_KEYTABLE(pv951);
-#endif
diff --git a/include/media/keycodes/rc5-hauppauge-new.h b/include/media/keycodes/rc5-hauppauge-new.h
deleted file mode 100644
index f02b59a..0000000
--- a/include/media/keycodes/rc5-hauppauge-new.h
+++ /dev/null
@@ -1,79 +0,0 @@
-/* rc5-hauppauge-new.h - Keytable for rc5_hauppauge_new Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/*
- * Hauppauge:the newer, gray remotes (seems there are multiple
- * slightly different versions), shipped with cx88+ivtv cards.
- *
- * This table contains the complete RC5 code, instead of just the data part
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode rc5_hauppauge_new[] = {
- /* Keys 0 to 9 */
- { 0x1e00, KEY_0 },
- { 0x1e01, KEY_1 },
- { 0x1e02, KEY_2 },
- { 0x1e03, KEY_3 },
- { 0x1e04, KEY_4 },
- { 0x1e05, KEY_5 },
- { 0x1e06, KEY_6 },
- { 0x1e07, KEY_7 },
- { 0x1e08, KEY_8 },
- { 0x1e09, KEY_9 },
-
- { 0x1e0a, KEY_TEXT }, /* keypad asterisk as well */
- { 0x1e0b, KEY_RED }, /* red button */
- { 0x1e0c, KEY_RADIO },
- { 0x1e0d, KEY_MENU },
- { 0x1e0e, KEY_SUBTITLE }, /* also the # key */
- { 0x1e0f, KEY_MUTE },
- { 0x1e10, KEY_VOLUMEUP },
- { 0x1e11, KEY_VOLUMEDOWN },
- { 0x1e12, KEY_PREVIOUS }, /* previous channel */
- { 0x1e14, KEY_UP },
- { 0x1e15, KEY_DOWN },
- { 0x1e16, KEY_LEFT },
- { 0x1e17, KEY_RIGHT },
- { 0x1e18, KEY_VIDEO }, /* Videos */
- { 0x1e19, KEY_AUDIO }, /* Music */
- /* 0x1e1a: Pictures - presume this means
- "Multimedia Home Platform" -
- no "PICTURES" key in input.h
- */
- { 0x1e1a, KEY_MHP },
-
- { 0x1e1b, KEY_EPG }, /* Guide */
- { 0x1e1c, KEY_TV },
- { 0x1e1e, KEY_NEXTSONG }, /* skip >| */
- { 0x1e1f, KEY_EXIT }, /* back/exit */
- { 0x1e20, KEY_CHANNELUP }, /* channel / program + */
- { 0x1e21, KEY_CHANNELDOWN }, /* channel / program - */
- { 0x1e22, KEY_CHANNEL }, /* source (old black remote) */
- { 0x1e24, KEY_PREVIOUSSONG }, /* replay |< */
- { 0x1e25, KEY_ENTER }, /* OK */
- { 0x1e26, KEY_SLEEP }, /* minimize (old black remote) */
- { 0x1e29, KEY_BLUE }, /* blue key */
- { 0x1e2e, KEY_GREEN }, /* green button */
- { 0x1e30, KEY_PAUSE }, /* pause */
- { 0x1e32, KEY_REWIND }, /* backward << */
- { 0x1e34, KEY_FASTFORWARD }, /* forward >> */
- { 0x1e35, KEY_PLAY },
- { 0x1e36, KEY_STOP },
- { 0x1e37, KEY_RECORD }, /* recording */
- { 0x1e38, KEY_YELLOW }, /* yellow key */
- { 0x1e3b, KEY_SELECT }, /* top right button */
- { 0x1e3c, KEY_ZOOM }, /* full */
- { 0x1e3d, KEY_POWER }, /* system power (green button) */
-};
-DEFINE_IR_KEYTABLE(rc5_hauppauge_new, IR_TYPE_RC5);
-#else
-DECLARE_IR_KEYTABLE(rc5_hauppauge_new);
-#endif
diff --git a/include/media/keycodes/rc5-tv.h b/include/media/keycodes/rc5-tv.h
deleted file mode 100644
index a429a54..0000000
--- a/include/media/keycodes/rc5-tv.h
+++ /dev/null
@@ -1,57 +0,0 @@
-/* rc5-tv.h - Keytable for rc5_tv Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* generic RC5 keytable */
-/* see http://users.pandora.be/nenya/electronics/rc5/codes00.htm */
-/* used by old (black) Hauppauge remotes */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode rc5_tv[] = {
- /* Keys 0 to 9 */
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x0b, KEY_CHANNEL }, /* channel / program (japan: 11) */
- { 0x0c, KEY_POWER }, /* standby */
- { 0x0d, KEY_MUTE }, /* mute / demute */
- { 0x0f, KEY_TV }, /* display */
- { 0x10, KEY_VOLUMEUP },
- { 0x11, KEY_VOLUMEDOWN },
- { 0x12, KEY_BRIGHTNESSUP },
- { 0x13, KEY_BRIGHTNESSDOWN },
- { 0x1e, KEY_SEARCH }, /* search + */
- { 0x20, KEY_CHANNELUP }, /* channel / program + */
- { 0x21, KEY_CHANNELDOWN }, /* channel / program - */
- { 0x22, KEY_CHANNEL }, /* alt / channel */
- { 0x23, KEY_LANGUAGE }, /* 1st / 2nd language */
- { 0x26, KEY_SLEEP }, /* sleeptimer */
- { 0x2e, KEY_MENU }, /* 2nd controls (USA: menu) */
- { 0x30, KEY_PAUSE },
- { 0x32, KEY_REWIND },
- { 0x33, KEY_GOTO },
- { 0x35, KEY_PLAY },
- { 0x36, KEY_STOP },
- { 0x37, KEY_RECORD }, /* recording */
- { 0x3c, KEY_TEXT }, /* teletext submode (Japan: 12) */
- { 0x3d, KEY_SUSPEND }, /* system standby */
-
-};
-DEFINE_LEGACY_IR_KEYTABLE(rc5_tv);
-#else
-DECLARE_IR_KEYTABLE(rc5_tv);
-#endif
diff --git a/include/media/keycodes/real-audio-220-32-keys.h b/include/media/keycodes/real-audio-220-32-keys.h
deleted file mode 100644
index 5f6835d..0000000
--- a/include/media/keycodes/real-audio-220-32-keys.h
+++ /dev/null
@@ -1,54 +0,0 @@
-/* real-audio-220-32-keys.h - Keytable for real_audio_220_32_keys Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Zogis Real Audio 220 - 32 keys IR */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode real_audio_220_32_keys[] = {
- { 0x1c, KEY_RADIO},
- { 0x12, KEY_POWER2},
-
- { 0x01, KEY_1},
- { 0x02, KEY_2},
- { 0x03, KEY_3},
- { 0x04, KEY_4},
- { 0x05, KEY_5},
- { 0x06, KEY_6},
- { 0x07, KEY_7},
- { 0x08, KEY_8},
- { 0x09, KEY_9},
- { 0x00, KEY_0},
-
- { 0x0c, KEY_VOLUMEUP},
- { 0x18, KEY_VOLUMEDOWN},
- { 0x0b, KEY_CHANNELUP},
- { 0x15, KEY_CHANNELDOWN},
- { 0x16, KEY_ENTER},
-
- { 0x11, KEY_LIST}, /* Source */
- { 0x0d, KEY_AUDIO}, /* stereo */
-
- { 0x0f, KEY_PREVIOUS}, /* Prev */
- { 0x1b, KEY_TIME}, /* Timeshift */
- { 0x1a, KEY_NEXT}, /* Next */
-
- { 0x0e, KEY_STOP},
- { 0x1f, KEY_PLAY},
- { 0x1e, KEY_PLAYPAUSE}, /* Pause */
-
- { 0x1d, KEY_RECORD},
- { 0x13, KEY_MUTE},
- { 0x19, KEY_CAMERA}, /* Snapshot */
-
-};
-DEFINE_LEGACY_IR_KEYTABLE(real_audio_220_32_keys);
-#else
-DECLARE_IR_KEYTABLE(real_audio_220_32_keys);
-#endif
diff --git a/include/media/keycodes/tbs-nec.h b/include/media/keycodes/tbs-nec.h
deleted file mode 100644
index 156985e..0000000
--- a/include/media/keycodes/tbs-nec.h
+++ /dev/null
@@ -1,50 +0,0 @@
-/* tbs-nec.h - Keytable for tbs_nec Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode tbs_nec[] = {
- { 0x04, KEY_POWER2}, /*power*/
- { 0x14, KEY_MUTE}, /*mute*/
- { 0x07, KEY_1},
- { 0x06, KEY_2},
- { 0x05, KEY_3},
- { 0x0b, KEY_4},
- { 0x0a, KEY_5},
- { 0x09, KEY_6},
- { 0x0f, KEY_7},
- { 0x0e, KEY_8},
- { 0x0d, KEY_9},
- { 0x12, KEY_0},
- { 0x16, KEY_CHANNELUP}, /*ch+*/
- { 0x11, KEY_CHANNELDOWN},/*ch-*/
- { 0x13, KEY_VOLUMEUP}, /*vol+*/
- { 0x0c, KEY_VOLUMEDOWN},/*vol-*/
- { 0x03, KEY_RECORD}, /*rec*/
- { 0x18, KEY_PAUSE}, /*pause*/
- { 0x19, KEY_OK}, /*ok*/
- { 0x1a, KEY_CAMERA}, /* snapshot */
- { 0x01, KEY_UP},
- { 0x10, KEY_LEFT},
- { 0x02, KEY_RIGHT},
- { 0x08, KEY_DOWN},
- { 0x15, KEY_FAVORITES},
- { 0x17, KEY_SUBTITLE},
- { 0x1d, KEY_ZOOM},
- { 0x1f, KEY_EXIT},
- { 0x1e, KEY_MENU},
- { 0x1c, KEY_EPG},
- { 0x00, KEY_PREVIOUS},
- { 0x1b, KEY_MODE},
-};
-DEFINE_LEGACY_IR_KEYTABLE(tbs_nec);
-#else
-DECLARE_IR_KEYTABLE(tbs_nec);
-#endif
diff --git a/include/media/keycodes/terratec-cinergy-xs.h b/include/media/keycodes/terratec-cinergy-xs.h
deleted file mode 100644
index 8f50fae..0000000
--- a/include/media/keycodes/terratec-cinergy-xs.h
+++ /dev/null
@@ -1,68 +0,0 @@
-/* terratec-cinergy-xs.h - Keytable for terratec_cinergy_xs Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Terratec Cinergy Hybrid T USB XS
- Devin Heitmueller <dheitmueller@linuxtv.org>
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode terratec_cinergy_xs[] = {
- { 0x41, KEY_HOME},
- { 0x01, KEY_POWER},
- { 0x42, KEY_MENU},
- { 0x02, KEY_1},
- { 0x03, KEY_2},
- { 0x04, KEY_3},
- { 0x43, KEY_SUBTITLE},
- { 0x05, KEY_4},
- { 0x06, KEY_5},
- { 0x07, KEY_6},
- { 0x44, KEY_TEXT},
- { 0x08, KEY_7},
- { 0x09, KEY_8},
- { 0x0a, KEY_9},
- { 0x45, KEY_DELETE},
- { 0x0b, KEY_TUNER},
- { 0x0c, KEY_0},
- { 0x0d, KEY_MODE},
- { 0x46, KEY_TV},
- { 0x47, KEY_DVD},
- { 0x49, KEY_VIDEO},
- { 0x4b, KEY_AUX},
- { 0x10, KEY_UP},
- { 0x11, KEY_LEFT},
- { 0x12, KEY_OK},
- { 0x13, KEY_RIGHT},
- { 0x14, KEY_DOWN},
- { 0x0f, KEY_EPG},
- { 0x16, KEY_INFO},
- { 0x4d, KEY_BACKSPACE},
- { 0x1c, KEY_VOLUMEUP},
- { 0x4c, KEY_PLAY},
- { 0x1b, KEY_CHANNELUP},
- { 0x1e, KEY_VOLUMEDOWN},
- { 0x1d, KEY_MUTE},
- { 0x1f, KEY_CHANNELDOWN},
- { 0x17, KEY_RED},
- { 0x18, KEY_GREEN},
- { 0x19, KEY_YELLOW},
- { 0x1a, KEY_BLUE},
- { 0x58, KEY_RECORD},
- { 0x48, KEY_STOP},
- { 0x40, KEY_PAUSE},
- { 0x54, KEY_LAST},
- { 0x4e, KEY_REWIND},
- { 0x4f, KEY_FASTFORWARD},
- { 0x5c, KEY_NEXT},
-};
-DEFINE_LEGACY_IR_KEYTABLE(terratec_cinergy_xs);
-#else
-DECLARE_IR_KEYTABLE(terratec_cinergy_xs);
-#endif
diff --git a/include/media/keycodes/tevii-nec.h b/include/media/keycodes/tevii-nec.h
deleted file mode 100644
index 6a8ea03..0000000
--- a/include/media/keycodes/tevii-nec.h
+++ /dev/null
@@ -1,65 +0,0 @@
-/* tevii-nec.h - Keytable for tevii_nec Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode tevii_nec[] = {
- { 0x0a, KEY_POWER2},
- { 0x0c, KEY_MUTE},
- { 0x11, KEY_1},
- { 0x12, KEY_2},
- { 0x13, KEY_3},
- { 0x14, KEY_4},
- { 0x15, KEY_5},
- { 0x16, KEY_6},
- { 0x17, KEY_7},
- { 0x18, KEY_8},
- { 0x19, KEY_9},
- { 0x10, KEY_0},
- { 0x1c, KEY_MENU},
- { 0x0f, KEY_VOLUMEDOWN},
- { 0x1a, KEY_LAST},
- { 0x0e, KEY_OPEN},
- { 0x04, KEY_RECORD},
- { 0x09, KEY_VOLUMEUP},
- { 0x08, KEY_CHANNELUP},
- { 0x07, KEY_PVR},
- { 0x0b, KEY_TIME},
- { 0x02, KEY_RIGHT},
- { 0x03, KEY_LEFT},
- { 0x00, KEY_UP},
- { 0x1f, KEY_OK},
- { 0x01, KEY_DOWN},
- { 0x05, KEY_TUNER},
- { 0x06, KEY_CHANNELDOWN},
- { 0x40, KEY_PLAYPAUSE},
- { 0x1e, KEY_REWIND},
- { 0x1b, KEY_FAVORITES},
- { 0x1d, KEY_BACK},
- { 0x4d, KEY_FASTFORWARD},
- { 0x44, KEY_EPG},
- { 0x4c, KEY_INFO},
- { 0x41, KEY_AB},
- { 0x43, KEY_AUDIO},
- { 0x45, KEY_SUBTITLE},
- { 0x4a, KEY_LIST},
- { 0x46, KEY_F1},
- { 0x47, KEY_F2},
- { 0x5e, KEY_F3},
- { 0x5c, KEY_F4},
- { 0x52, KEY_F5},
- { 0x5a, KEY_F6},
- { 0x56, KEY_MODE},
- { 0x58, KEY_SWITCHVIDEOMODE},
-};
-DEFINE_LEGACY_IR_KEYTABLE(tevii_nec);
-#else
-DECLARE_IR_KEYTABLE(tevii_nec);
-#endif
diff --git a/include/media/keycodes/tt-1500.h b/include/media/keycodes/tt-1500.h
deleted file mode 100644
index 45ffcba..0000000
--- a/include/media/keycodes/tt-1500.h
+++ /dev/null
@@ -1,58 +0,0 @@
-/* tt-1500.h - Keytable for tt_1500 Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* for the Technotrend 1500 bundled remotes (grey and black): */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode tt_1500[] = {
- { 0x01, KEY_POWER },
- { 0x02, KEY_SHUFFLE }, /* ? double-arrow key */
- { 0x03, KEY_1 },
- { 0x04, KEY_2 },
- { 0x05, KEY_3 },
- { 0x06, KEY_4 },
- { 0x07, KEY_5 },
- { 0x08, KEY_6 },
- { 0x09, KEY_7 },
- { 0x0a, KEY_8 },
- { 0x0b, KEY_9 },
- { 0x0c, KEY_0 },
- { 0x0d, KEY_UP },
- { 0x0e, KEY_LEFT },
- { 0x0f, KEY_OK },
- { 0x10, KEY_RIGHT },
- { 0x11, KEY_DOWN },
- { 0x12, KEY_INFO },
- { 0x13, KEY_EXIT },
- { 0x14, KEY_RED },
- { 0x15, KEY_GREEN },
- { 0x16, KEY_YELLOW },
- { 0x17, KEY_BLUE },
- { 0x18, KEY_MUTE },
- { 0x19, KEY_TEXT },
- { 0x1a, KEY_MODE }, /* ? TV/Radio */
- { 0x21, KEY_OPTION },
- { 0x22, KEY_EPG },
- { 0x23, KEY_CHANNELUP },
- { 0x24, KEY_CHANNELDOWN },
- { 0x25, KEY_VOLUMEUP },
- { 0x26, KEY_VOLUMEDOWN },
- { 0x27, KEY_SETUP },
- { 0x3a, KEY_RECORD }, /* these keys are only in the black remote */
- { 0x3b, KEY_PLAY },
- { 0x3c, KEY_STOP },
- { 0x3d, KEY_REWIND },
- { 0x3e, KEY_PAUSE },
- { 0x3f, KEY_FORWARD },
-};
-DEFINE_LEGACY_IR_KEYTABLE(tt_1500);
-#else
-DECLARE_IR_KEYTABLE(tt_1500);
-#endif
diff --git a/include/media/keycodes/videomate-s350.h b/include/media/keycodes/videomate-s350.h
deleted file mode 100644
index ff38424..0000000
--- a/include/media/keycodes/videomate-s350.h
+++ /dev/null
@@ -1,62 +0,0 @@
-/* videomate-s350.h - Keytable for videomate_s350 Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode videomate_s350[] = {
- { 0x00, KEY_TV},
- { 0x01, KEY_DVD},
- { 0x04, KEY_RECORD},
- { 0x05, KEY_VIDEO}, /* TV/Video */
- { 0x07, KEY_STOP},
- { 0x08, KEY_PLAYPAUSE},
- { 0x0a, KEY_REWIND},
- { 0x0f, KEY_FASTFORWARD},
- { 0x10, KEY_CHANNELUP},
- { 0x12, KEY_VOLUMEUP},
- { 0x13, KEY_CHANNELDOWN},
- { 0x14, KEY_MUTE},
- { 0x15, KEY_VOLUMEDOWN},
- { 0x16, KEY_1},
- { 0x17, KEY_2},
- { 0x18, KEY_3},
- { 0x19, KEY_4},
- { 0x1a, KEY_5},
- { 0x1b, KEY_6},
- { 0x1c, KEY_7},
- { 0x1d, KEY_8},
- { 0x1e, KEY_9},
- { 0x1f, KEY_0},
- { 0x21, KEY_SLEEP},
- { 0x24, KEY_ZOOM},
- { 0x25, KEY_LAST}, /* Recall */
- { 0x26, KEY_SUBTITLE}, /* CC */
- { 0x27, KEY_LANGUAGE}, /* MTS */
- { 0x29, KEY_CHANNEL}, /* SURF */
- { 0x2b, KEY_A},
- { 0x2c, KEY_B},
- { 0x2f, KEY_CAMERA}, /* Snapshot */
- { 0x23, KEY_RADIO},
- { 0x02, KEY_PREVIOUSSONG},
- { 0x06, KEY_NEXTSONG},
- { 0x03, KEY_EPG},
- { 0x09, KEY_SETUP},
- { 0x22, KEY_BACKSPACE},
- { 0x0c, KEY_UP},
- { 0x0e, KEY_DOWN},
- { 0x0b, KEY_LEFT},
- { 0x0d, KEY_RIGHT},
- { 0x11, KEY_ENTER},
- { 0x20, KEY_TEXT},
-};
-DEFINE_LEGACY_IR_KEYTABLE(videomate_s350);
-#else
-DECLARE_IR_KEYTABLE(videomate_s350);
-#endif
diff --git a/include/media/keycodes/videomate-tv-pvr.h b/include/media/keycodes/videomate-tv-pvr.h
deleted file mode 100644
index f77375d..0000000
--- a/include/media/keycodes/videomate-tv-pvr.h
+++ /dev/null
@@ -1,64 +0,0 @@
-/* videomate-tv-pvr.h - Keytable for videomate_tv_pvr Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode videomate_tv_pvr[] = {
- { 0x14, KEY_MUTE },
- { 0x24, KEY_ZOOM },
-
- { 0x01, KEY_DVD },
- { 0x23, KEY_RADIO },
- { 0x00, KEY_TV },
-
- { 0x0a, KEY_REWIND },
- { 0x08, KEY_PLAYPAUSE },
- { 0x0f, KEY_FORWARD },
-
- { 0x02, KEY_PREVIOUS },
- { 0x07, KEY_STOP },
- { 0x06, KEY_NEXT },
-
- { 0x0c, KEY_UP },
- { 0x0e, KEY_DOWN },
- { 0x0b, KEY_LEFT },
- { 0x0d, KEY_RIGHT },
- { 0x11, KEY_OK },
-
- { 0x03, KEY_MENU },
- { 0x09, KEY_SETUP },
- { 0x05, KEY_VIDEO },
- { 0x22, KEY_CHANNEL },
-
- { 0x12, KEY_VOLUMEUP },
- { 0x15, KEY_VOLUMEDOWN },
- { 0x10, KEY_CHANNELUP },
- { 0x13, KEY_CHANNELDOWN },
-
- { 0x04, KEY_RECORD },
-
- { 0x16, KEY_1 },
- { 0x17, KEY_2 },
- { 0x18, KEY_3 },
- { 0x19, KEY_4 },
- { 0x1a, KEY_5 },
- { 0x1b, KEY_6 },
- { 0x1c, KEY_7 },
- { 0x1d, KEY_8 },
- { 0x1e, KEY_9 },
- { 0x1f, KEY_0 },
-
- { 0x20, KEY_LANGUAGE },
- { 0x21, KEY_SLEEP },
-};
-DEFINE_LEGACY_IR_KEYTABLE(videomate_tv_pvr);
-#else
-DECLARE_IR_KEYTABLE(videomate_tv_pvr);
-#endif
diff --git a/include/media/keycodes/winfast-usbii-deluxe.h b/include/media/keycodes/winfast-usbii-deluxe.h
deleted file mode 100644
index 0d2c14f..0000000
--- a/include/media/keycodes/winfast-usbii-deluxe.h
+++ /dev/null
@@ -1,58 +0,0 @@
-/* winfast-usbii-deluxe.h - Keytable for winfast_usbii_deluxe Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Leadtek Winfast TV USB II Deluxe remote
- Magnus Alm <magnus.alm@gmail.com>
- */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode winfast_usbii_deluxe[] = {
- { 0x62, KEY_0},
- { 0x75, KEY_1},
- { 0x76, KEY_2},
- { 0x77, KEY_3},
- { 0x79, KEY_4},
- { 0x7a, KEY_5},
- { 0x7b, KEY_6},
- { 0x7d, KEY_7},
- { 0x7e, KEY_8},
- { 0x7f, KEY_9},
-
- { 0x38, KEY_CAMERA}, /* SNAPSHOT */
- { 0x37, KEY_RECORD}, /* RECORD */
- { 0x35, KEY_TIME}, /* TIMESHIFT */
-
- { 0x74, KEY_VOLUMEUP}, /* VOLUMEUP */
- { 0x78, KEY_VOLUMEDOWN}, /* VOLUMEDOWN */
- { 0x64, KEY_MUTE}, /* MUTE */
-
- { 0x21, KEY_CHANNEL}, /* SURF */
- { 0x7c, KEY_CHANNELUP}, /* CHANNELUP */
- { 0x60, KEY_CHANNELDOWN}, /* CHANNELDOWN */
- { 0x61, KEY_LAST}, /* LAST CHANNEL (RECALL) */
-
- { 0x72, KEY_VIDEO}, /* INPUT MODES (TV/FM) */
-
- { 0x70, KEY_POWER2}, /* TV ON/OFF */
-
- { 0x39, KEY_CYCLEWINDOWS}, /* MINIMIZE (BOSS) */
- { 0x3a, KEY_NEW}, /* PIP */
- { 0x73, KEY_ZOOM}, /* FULLSECREEN */
-
- { 0x66, KEY_INFO}, /* OSD (DISPLAY) */
-
- { 0x31, KEY_DOT}, /* '.' */
- { 0x63, KEY_ENTER}, /* ENTER */
-
-};
-DEFINE_LEGACY_IR_KEYTABLE(winfast_usbii_deluxe);
-#else
-DECLARE_IR_KEYTABLE(winfast_usbii_deluxe);
-#endif
diff --git a/include/media/keycodes/winfast.h b/include/media/keycodes/winfast.h
deleted file mode 100644
index 4f42e24..0000000
--- a/include/media/keycodes/winfast.h
+++ /dev/null
@@ -1,78 +0,0 @@
-/* winfast.h - Keytable for winfast Remote Controller
- *
- * Imported from ir-keymaps.c
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- */
-
-/* Table for Leadtek Winfast Remote Controls - used by both bttv and cx88 */
-
-#ifdef IR_KEYMAPS
-static struct ir_scancode winfast[] = {
- /* Keys 0 to 9 */
- { 0x12, KEY_0 },
- { 0x05, KEY_1 },
- { 0x06, KEY_2 },
- { 0x07, KEY_3 },
- { 0x09, KEY_4 },
- { 0x0a, KEY_5 },
- { 0x0b, KEY_6 },
- { 0x0d, KEY_7 },
- { 0x0e, KEY_8 },
- { 0x0f, KEY_9 },
-
- { 0x00, KEY_POWER },
- { 0x1b, KEY_AUDIO }, /* Audio Source */
- { 0x02, KEY_TUNER }, /* TV/FM, not on Y0400052 */
- { 0x1e, KEY_VIDEO }, /* Video Source */
- { 0x16, KEY_INFO }, /* Display information */
- { 0x04, KEY_VOLUMEUP },
- { 0x08, KEY_VOLUMEDOWN },
- { 0x0c, KEY_CHANNELUP },
- { 0x10, KEY_CHANNELDOWN },
- { 0x03, KEY_ZOOM }, /* fullscreen */
- { 0x1f, KEY_TEXT }, /* closed caption/teletext */
- { 0x20, KEY_SLEEP },
- { 0x29, KEY_CLEAR }, /* boss key */
- { 0x14, KEY_MUTE },
- { 0x2b, KEY_RED },
- { 0x2c, KEY_GREEN },
- { 0x2d, KEY_YELLOW },
- { 0x2e, KEY_BLUE },
- { 0x18, KEY_KPPLUS }, /* fine tune + , not on Y040052 */
- { 0x19, KEY_KPMINUS }, /* fine tune - , not on Y040052 */
- { 0x2a, KEY_MEDIA }, /* PIP (Picture in picture */
- { 0x21, KEY_DOT },
- { 0x13, KEY_ENTER },
- { 0x11, KEY_LAST }, /* Recall (last channel */
- { 0x22, KEY_PREVIOUS },
- { 0x23, KEY_PLAYPAUSE },
- { 0x24, KEY_NEXT },
- { 0x25, KEY_TIME }, /* Time Shifting */
- { 0x26, KEY_STOP },
- { 0x27, KEY_RECORD },
- { 0x28, KEY_SAVE }, /* Screenshot */
- { 0x2f, KEY_MENU },
- { 0x30, KEY_CANCEL },
- { 0x31, KEY_CHANNEL }, /* Channel Surf */
- { 0x32, KEY_SUBTITLE },
- { 0x33, KEY_LANGUAGE },
- { 0x34, KEY_REWIND },
- { 0x35, KEY_FASTFORWARD },
- { 0x36, KEY_TV },
- { 0x37, KEY_RADIO }, /* FM */
- { 0x38, KEY_DVD },
-
- { 0x1a, KEY_MODE}, /* change to MCE mode on Y04G0051 */
- { 0x3e, KEY_F21 }, /* MCE +VOL, on Y04G0033 */
- { 0x3a, KEY_F22 }, /* MCE -VOL, on Y04G0033 */
- { 0x3b, KEY_F23 }, /* MCE +CH, on Y04G0033 */
- { 0x3f, KEY_F24 } /* MCE -CH, on Y04G0033 */
-};
-DEFINE_LEGACY_IR_KEYTABLE(winfast);
-#else
-DECLARE_IR_KEYTABLE(winfast);
-#endif
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 06/26] V4L/DVB: ir-common: move IR tables from ir-keymaps.c to a separate file
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (20 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 04/26] V4L/DVB: rename all *_rc_keys to ir_codes_*_nec_table Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 01/26] V4L/DVB: ir-common: Use a function to declare an IR table Mauro Carvalho Chehab
` (3 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
Instead of having one big file with lots of keytables, create one include
file for each IR keymap.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
create mode 100644 include/media/keycodes/adstech-dvb-t-pci.h
create mode 100644 include/media/keycodes/apac-viewcomp.h
create mode 100644 include/media/keycodes/asus-pc39.h
create mode 100644 include/media/keycodes/ati-tv-wonder-hd-600.h
create mode 100644 include/media/keycodes/avermedia-a16d.h
create mode 100644 include/media/keycodes/avermedia-cardbus.h
create mode 100644 include/media/keycodes/avermedia-dvbt.h
create mode 100644 include/media/keycodes/avermedia-m135a-rm-jx.h
create mode 100644 include/media/keycodes/avermedia.h
create mode 100644 include/media/keycodes/avertv-303.h
create mode 100644 include/media/keycodes/behold-columbus.h
create mode 100644 include/media/keycodes/behold.h
create mode 100644 include/media/keycodes/budget-ci-old.h
create mode 100644 include/media/keycodes/cinergy-1400.h
create mode 100644 include/media/keycodes/cinergy.h
create mode 100644 include/media/keycodes/dm1105-nec.h
create mode 100644 include/media/keycodes/dntv-live-dvb-t.h
create mode 100644 include/media/keycodes/dntv-live-dvbt-pro.h
create mode 100644 include/media/keycodes/em-terratec.h
create mode 100644 include/media/keycodes/empty.h
create mode 100644 include/media/keycodes/encore-enltv-fm53.h
create mode 100644 include/media/keycodes/encore-enltv.h
create mode 100644 include/media/keycodes/encore-enltv2.h
create mode 100644 include/media/keycodes/evga-indtube.h
create mode 100644 include/media/keycodes/eztv.h
create mode 100644 include/media/keycodes/flydvb.h
create mode 100644 include/media/keycodes/flyvideo.h
create mode 100644 include/media/keycodes/fusionhdtv-mce.h
create mode 100644 include/media/keycodes/gadmei-rm008z.h
create mode 100644 include/media/keycodes/genius-tvgo-a11mce.h
create mode 100644 include/media/keycodes/gotview7135.h
create mode 100644 include/media/keycodes/hauppauge-new.h
create mode 100644 include/media/keycodes/iodata-bctv7e.h
create mode 100644 include/media/keycodes/kaiomy.h
create mode 100644 include/media/keycodes/kworld-315u.h
create mode 100644 include/media/keycodes/kworld-plus-tv-analog.h
create mode 100644 include/media/keycodes/manli.h
create mode 100644 include/media/keycodes/msi-tvanywhere-plus.h
create mode 100644 include/media/keycodes/msi-tvanywhere.h
create mode 100644 include/media/keycodes/nebula.h
create mode 100644 include/media/keycodes/nec-terratec-cinergy-xs.h
create mode 100644 include/media/keycodes/norwood.h
create mode 100644 include/media/keycodes/npgtech.h
create mode 100644 include/media/keycodes/pctv-sedna.h
create mode 100644 include/media/keycodes/pinnacle-color.h
create mode 100644 include/media/keycodes/pinnacle-grey.h
create mode 100644 include/media/keycodes/pinnacle-pctv-hd.h
create mode 100644 include/media/keycodes/pixelview-new.h
create mode 100644 include/media/keycodes/pixelview.h
create mode 100644 include/media/keycodes/powercolor-real-angel.h
create mode 100644 include/media/keycodes/proteus-2309.h
create mode 100644 include/media/keycodes/purpletv.h
create mode 100644 include/media/keycodes/pv951.h
create mode 100644 include/media/keycodes/rc5-hauppauge-new.h
create mode 100644 include/media/keycodes/rc5-tv.h
create mode 100644 include/media/keycodes/real-audio-220-32-keys.h
create mode 100644 include/media/keycodes/tbs-nec.h
create mode 100644 include/media/keycodes/terratec-cinergy-xs.h
create mode 100644 include/media/keycodes/tevii-nec.h
create mode 100644 include/media/keycodes/tt-1500.h
create mode 100644 include/media/keycodes/videomate-s350.h
create mode 100644 include/media/keycodes/videomate-tv-pvr.h
create mode 100644 include/media/keycodes/winfast-usbii-deluxe.h
create mode 100644 include/media/keycodes/winfast.h
diff --git a/drivers/media/IR/ir-keymaps.c b/drivers/media/IR/ir-keymaps.c
index 1ba9285..eb25531 100644
--- a/drivers/media/IR/ir-keymaps.c
+++ b/drivers/media/IR/ir-keymaps.c
@@ -17,3178 +17,29 @@
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
+#define IR_KEYMAPS
+
/*
* NOTICE FOR DEVELOPERS:
* The IR mappings should be as close as possible to what's
* specified at:
* http://linuxtv.org/wiki/index.php/Remote_Controllers
- */
-#include <linux/module.h>
-
-#include <linux/input.h>
-#include <media/ir-common.h>
-
-
-/*
+ *
* The usage of tables with just the command part is deprecated.
* All new IR keytables should contain address+command and need
* to define the proper IR_TYPE (IR_TYPE_RC5/IR_TYPE_NEC).
* The deprecated tables should use IR_TYPE_UNKNOWN
*/
+#include <linux/module.h>
-/* empty keytable, can be used as placeholder for not-yet created keytables */
-static struct ir_scancode empty[] = {
- { 0x2a, KEY_COFFEE },
-};
-DEFINE_LEGACY_IR_KEYTABLE(empty);
-
-/* Michal Majchrowicz <mmajchrowicz@gmail.com> */
-static struct ir_scancode proteus_2309[] = {
- /* numeric */
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x5c, KEY_POWER }, /* power */
- { 0x20, KEY_ZOOM }, /* full screen */
- { 0x0f, KEY_BACKSPACE }, /* recall */
- { 0x1b, KEY_ENTER }, /* mute */
- { 0x41, KEY_RECORD }, /* record */
- { 0x43, KEY_STOP }, /* stop */
- { 0x16, KEY_S },
- { 0x1a, KEY_POWER2 }, /* off */
- { 0x2e, KEY_RED },
- { 0x1f, KEY_CHANNELDOWN }, /* channel - */
- { 0x1c, KEY_CHANNELUP }, /* channel + */
- { 0x10, KEY_VOLUMEDOWN }, /* volume - */
- { 0x1e, KEY_VOLUMEUP }, /* volume + */
- { 0x14, KEY_F1 },
-};
-DEFINE_LEGACY_IR_KEYTABLE(proteus_2309);
-
-/* Matt Jesson <dvb@jesson.eclipse.co.uk */
-static struct ir_scancode avermedia_dvbt[] = {
- { 0x28, KEY_0 }, /* '0' / 'enter' */
- { 0x22, KEY_1 }, /* '1' */
- { 0x12, KEY_2 }, /* '2' / 'up arrow' */
- { 0x32, KEY_3 }, /* '3' */
- { 0x24, KEY_4 }, /* '4' / 'left arrow' */
- { 0x14, KEY_5 }, /* '5' */
- { 0x34, KEY_6 }, /* '6' / 'right arrow' */
- { 0x26, KEY_7 }, /* '7' */
- { 0x16, KEY_8 }, /* '8' / 'down arrow' */
- { 0x36, KEY_9 }, /* '9' */
-
- { 0x20, KEY_LIST }, /* 'source' */
- { 0x10, KEY_TEXT }, /* 'teletext' */
- { 0x00, KEY_POWER }, /* 'power' */
- { 0x04, KEY_AUDIO }, /* 'audio' */
- { 0x06, KEY_ZOOM }, /* 'full screen' */
- { 0x18, KEY_VIDEO }, /* 'display' */
- { 0x38, KEY_SEARCH }, /* 'loop' */
- { 0x08, KEY_INFO }, /* 'preview' */
- { 0x2a, KEY_REWIND }, /* 'backward <<' */
- { 0x1a, KEY_FASTFORWARD }, /* 'forward >>' */
- { 0x3a, KEY_RECORD }, /* 'capture' */
- { 0x0a, KEY_MUTE }, /* 'mute' */
- { 0x2c, KEY_RECORD }, /* 'record' */
- { 0x1c, KEY_PAUSE }, /* 'pause' */
- { 0x3c, KEY_STOP }, /* 'stop' */
- { 0x0c, KEY_PLAY }, /* 'play' */
- { 0x2e, KEY_RED }, /* 'red' */
- { 0x01, KEY_BLUE }, /* 'blue' / 'cancel' */
- { 0x0e, KEY_YELLOW }, /* 'yellow' / 'ok' */
- { 0x21, KEY_GREEN }, /* 'green' */
- { 0x11, KEY_CHANNELDOWN }, /* 'channel -' */
- { 0x31, KEY_CHANNELUP }, /* 'channel +' */
- { 0x1e, KEY_VOLUMEDOWN }, /* 'volume -' */
- { 0x3e, KEY_VOLUMEUP }, /* 'volume +' */
-};
-DEFINE_LEGACY_IR_KEYTABLE(avermedia_dvbt);
-
-/*
- * Avermedia M135A with IR model RM-JX
- * The same codes exist on both Positivo (BR) and original IR
- * Mauro Carvalho Chehab <mchehab@infradead.org>
- */
-static struct ir_scancode avermedia_m135a_rm_jx[] = {
- { 0x0200, KEY_POWER2 },
- { 0x022e, KEY_DOT }, /* '.' */
- { 0x0201, KEY_MODE }, /* TV/FM or SOURCE */
-
- { 0x0205, KEY_1 },
- { 0x0206, KEY_2 },
- { 0x0207, KEY_3 },
- { 0x0209, KEY_4 },
- { 0x020a, KEY_5 },
- { 0x020b, KEY_6 },
- { 0x020d, KEY_7 },
- { 0x020e, KEY_8 },
- { 0x020f, KEY_9 },
- { 0x0211, KEY_0 },
-
- { 0x0213, KEY_RIGHT }, /* -> or L */
- { 0x0212, KEY_LEFT }, /* <- or R */
-
- { 0x0217, KEY_SLEEP }, /* Capturar Imagem or Snapshot */
- { 0x0210, KEY_SHUFFLE }, /* Amostra or 16 chan prev */
-
- { 0x0303, KEY_CHANNELUP },
- { 0x0302, KEY_CHANNELDOWN },
- { 0x021f, KEY_VOLUMEUP },
- { 0x021e, KEY_VOLUMEDOWN },
- { 0x020c, KEY_ENTER }, /* Full Screen */
-
- { 0x0214, KEY_MUTE },
- { 0x0208, KEY_AUDIO },
-
- { 0x0203, KEY_TEXT }, /* Teletext */
- { 0x0204, KEY_EPG },
- { 0x022b, KEY_TV2 }, /* TV2 or PIP */
-
- { 0x021d, KEY_RED },
- { 0x021c, KEY_YELLOW },
- { 0x0301, KEY_GREEN },
- { 0x0300, KEY_BLUE },
-
- { 0x021a, KEY_PLAYPAUSE },
- { 0x0219, KEY_RECORD },
- { 0x0218, KEY_PLAY },
- { 0x021b, KEY_STOP },
-};
-DEFINE_IR_KEYTABLE(avermedia_m135a_rm_jx, IR_TYPE_NEC);
-
-/* Oldrich Jedlicka <oldium.pro@seznam.cz> */
-static struct ir_scancode avermedia_cardbus[] = {
- { 0x00, KEY_POWER },
- { 0x01, KEY_TUNER }, /* TV/FM */
- { 0x03, KEY_TEXT }, /* Teletext */
- { 0x04, KEY_EPG },
- { 0x05, KEY_1 },
- { 0x06, KEY_2 },
- { 0x07, KEY_3 },
- { 0x08, KEY_AUDIO },
- { 0x09, KEY_4 },
- { 0x0a, KEY_5 },
- { 0x0b, KEY_6 },
- { 0x0c, KEY_ZOOM }, /* Full screen */
- { 0x0d, KEY_7 },
- { 0x0e, KEY_8 },
- { 0x0f, KEY_9 },
- { 0x10, KEY_PAGEUP }, /* 16-CH PREV */
- { 0x11, KEY_0 },
- { 0x12, KEY_INFO },
- { 0x13, KEY_AGAIN }, /* CH RTN - channel return */
- { 0x14, KEY_MUTE },
- { 0x15, KEY_EDIT }, /* Autoscan */
- { 0x17, KEY_SAVE }, /* Screenshot */
- { 0x18, KEY_PLAYPAUSE },
- { 0x19, KEY_RECORD },
- { 0x1a, KEY_PLAY },
- { 0x1b, KEY_STOP },
- { 0x1c, KEY_FASTFORWARD },
- { 0x1d, KEY_REWIND },
- { 0x1e, KEY_VOLUMEDOWN },
- { 0x1f, KEY_VOLUMEUP },
- { 0x22, KEY_SLEEP }, /* Sleep */
- { 0x23, KEY_ZOOM }, /* Aspect */
- { 0x26, KEY_SCREEN }, /* Pos */
- { 0x27, KEY_ANGLE }, /* Size */
- { 0x28, KEY_SELECT }, /* Select */
- { 0x29, KEY_BLUE }, /* Blue/Picture */
- { 0x2a, KEY_BACKSPACE }, /* Back */
- { 0x2b, KEY_MEDIA }, /* PIP (Picture-in-picture) */
- { 0x2c, KEY_DOWN },
- { 0x2e, KEY_DOT },
- { 0x2f, KEY_TV }, /* Live TV */
- { 0x32, KEY_LEFT },
- { 0x33, KEY_CLEAR }, /* Clear */
- { 0x35, KEY_RED }, /* Red/TV */
- { 0x36, KEY_UP },
- { 0x37, KEY_HOME }, /* Home */
- { 0x39, KEY_GREEN }, /* Green/Video */
- { 0x3d, KEY_YELLOW }, /* Yellow/Music */
- { 0x3e, KEY_OK }, /* Ok */
- { 0x3f, KEY_RIGHT },
- { 0x40, KEY_NEXT }, /* Next */
- { 0x41, KEY_PREVIOUS }, /* Previous */
- { 0x42, KEY_CHANNELDOWN }, /* Channel down */
- { 0x43, KEY_CHANNELUP }, /* Channel up */
-};
-DEFINE_LEGACY_IR_KEYTABLE(avermedia_cardbus);
-
-/* Attila Kondoros <attila.kondoros@chello.hu> */
-static struct ir_scancode apac_viewcomp[] = {
-
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
- { 0x00, KEY_0 },
- { 0x17, KEY_LAST }, /* +100 */
- { 0x0a, KEY_LIST }, /* recall */
-
-
- { 0x1c, KEY_TUNER }, /* TV/FM */
- { 0x15, KEY_SEARCH }, /* scan */
- { 0x12, KEY_POWER }, /* power */
- { 0x1f, KEY_VOLUMEDOWN }, /* vol up */
- { 0x1b, KEY_VOLUMEUP }, /* vol down */
- { 0x1e, KEY_CHANNELDOWN }, /* chn up */
- { 0x1a, KEY_CHANNELUP }, /* chn down */
-
- { 0x11, KEY_VIDEO }, /* video */
- { 0x0f, KEY_ZOOM }, /* full screen */
- { 0x13, KEY_MUTE }, /* mute/unmute */
- { 0x10, KEY_TEXT }, /* min */
-
- { 0x0d, KEY_STOP }, /* freeze */
- { 0x0e, KEY_RECORD }, /* record */
- { 0x1d, KEY_PLAYPAUSE }, /* stop */
- { 0x19, KEY_PLAY }, /* play */
-
- { 0x16, KEY_GOTO }, /* osd */
- { 0x14, KEY_REFRESH }, /* default */
- { 0x0c, KEY_KPPLUS }, /* fine tune >>>> */
- { 0x18, KEY_KPMINUS }, /* fine tune <<<< */
-};
-DEFINE_LEGACY_IR_KEYTABLE(apac_viewcomp);
-
-/* ---------------------------------------------------------------------- */
-
-static struct ir_scancode pixelview[] = {
-
- { 0x1e, KEY_POWER }, /* power */
- { 0x07, KEY_MEDIA }, /* source */
- { 0x1c, KEY_SEARCH }, /* scan */
-
-
- { 0x03, KEY_TUNER }, /* TV/FM */
-
- { 0x00, KEY_RECORD },
- { 0x08, KEY_STOP },
- { 0x11, KEY_PLAY },
-
- { 0x1a, KEY_PLAYPAUSE }, /* freeze */
- { 0x19, KEY_ZOOM }, /* zoom */
- { 0x0f, KEY_TEXT }, /* min */
-
- { 0x01, KEY_1 },
- { 0x0b, KEY_2 },
- { 0x1b, KEY_3 },
- { 0x05, KEY_4 },
- { 0x09, KEY_5 },
- { 0x15, KEY_6 },
- { 0x06, KEY_7 },
- { 0x0a, KEY_8 },
- { 0x12, KEY_9 },
- { 0x02, KEY_0 },
- { 0x10, KEY_LAST }, /* +100 */
- { 0x13, KEY_LIST }, /* recall */
-
- { 0x1f, KEY_CHANNELUP }, /* chn down */
- { 0x17, KEY_CHANNELDOWN }, /* chn up */
- { 0x16, KEY_VOLUMEUP }, /* vol down */
- { 0x14, KEY_VOLUMEDOWN }, /* vol up */
-
- { 0x04, KEY_KPMINUS }, /* <<< */
- { 0x0e, KEY_SETUP }, /* function */
- { 0x0c, KEY_KPPLUS }, /* >>> */
-
- { 0x0d, KEY_GOTO }, /* mts */
- { 0x1d, KEY_REFRESH }, /* reset */
- { 0x18, KEY_MUTE }, /* mute/unmute */
-};
-DEFINE_LEGACY_IR_KEYTABLE(pixelview);
+#include <linux/input.h>
+#include <media/ir-common.h>
/*
- Mauro Carvalho Chehab <mchehab@infradead.org>
- present on PV MPEG 8000GT
- */
-static struct ir_scancode pixelview_new[] = {
- { 0x3c, KEY_TIME }, /* Timeshift */
- { 0x12, KEY_POWER },
-
- { 0x3d, KEY_1 },
- { 0x38, KEY_2 },
- { 0x18, KEY_3 },
- { 0x35, KEY_4 },
- { 0x39, KEY_5 },
- { 0x15, KEY_6 },
- { 0x36, KEY_7 },
- { 0x3a, KEY_8 },
- { 0x1e, KEY_9 },
- { 0x3e, KEY_0 },
-
- { 0x1c, KEY_AGAIN }, /* LOOP */
- { 0x3f, KEY_MEDIA }, /* Source */
- { 0x1f, KEY_LAST }, /* +100 */
- { 0x1b, KEY_MUTE },
-
- { 0x17, KEY_CHANNELDOWN },
- { 0x16, KEY_CHANNELUP },
- { 0x10, KEY_VOLUMEUP },
- { 0x14, KEY_VOLUMEDOWN },
- { 0x13, KEY_ZOOM },
-
- { 0x19, KEY_CAMERA }, /* SNAPSHOT */
- { 0x1a, KEY_SEARCH }, /* scan */
-
- { 0x37, KEY_REWIND }, /* << */
- { 0x32, KEY_RECORD }, /* o (red) */
- { 0x33, KEY_FORWARD }, /* >> */
- { 0x11, KEY_STOP }, /* square */
- { 0x3b, KEY_PLAY }, /* > */
- { 0x30, KEY_PLAYPAUSE }, /* || */
-
- { 0x31, KEY_TV },
- { 0x34, KEY_RADIO },
-};
-DEFINE_LEGACY_IR_KEYTABLE(pixelview_new);
-
-static struct ir_scancode nebula[] = {
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
- { 0x0a, KEY_TV },
- { 0x0b, KEY_AUX },
- { 0x0c, KEY_DVD },
- { 0x0d, KEY_POWER },
- { 0x0e, KEY_MHP }, /* labelled 'Picture' */
- { 0x0f, KEY_AUDIO },
- { 0x10, KEY_INFO },
- { 0x11, KEY_F13 }, /* 16:9 */
- { 0x12, KEY_F14 }, /* 14:9 */
- { 0x13, KEY_EPG },
- { 0x14, KEY_EXIT },
- { 0x15, KEY_MENU },
- { 0x16, KEY_UP },
- { 0x17, KEY_DOWN },
- { 0x18, KEY_LEFT },
- { 0x19, KEY_RIGHT },
- { 0x1a, KEY_ENTER },
- { 0x1b, KEY_CHANNELUP },
- { 0x1c, KEY_CHANNELDOWN },
- { 0x1d, KEY_VOLUMEUP },
- { 0x1e, KEY_VOLUMEDOWN },
- { 0x1f, KEY_RED },
- { 0x20, KEY_GREEN },
- { 0x21, KEY_YELLOW },
- { 0x22, KEY_BLUE },
- { 0x23, KEY_SUBTITLE },
- { 0x24, KEY_F15 }, /* AD */
- { 0x25, KEY_TEXT },
- { 0x26, KEY_MUTE },
- { 0x27, KEY_REWIND },
- { 0x28, KEY_STOP },
- { 0x29, KEY_PLAY },
- { 0x2a, KEY_FASTFORWARD },
- { 0x2b, KEY_F16 }, /* chapter */
- { 0x2c, KEY_PAUSE },
- { 0x2d, KEY_PLAY },
- { 0x2e, KEY_RECORD },
- { 0x2f, KEY_F17 }, /* picture in picture */
- { 0x30, KEY_KPPLUS }, /* zoom in */
- { 0x31, KEY_KPMINUS }, /* zoom out */
- { 0x32, KEY_F18 }, /* capture */
- { 0x33, KEY_F19 }, /* web */
- { 0x34, KEY_EMAIL },
- { 0x35, KEY_PHONE },
- { 0x36, KEY_PC },
-};
-DEFINE_LEGACY_IR_KEYTABLE(nebula);
-
-/* DigitalNow DNTV Live DVB-T Remote */
-static struct ir_scancode dntv_live_dvb_t[] = {
- { 0x00, KEY_ESC }, /* 'go up a level?' */
- /* Keys 0 to 9 */
- { 0x0a, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x0b, KEY_TUNER }, /* tv/fm */
- { 0x0c, KEY_SEARCH }, /* scan */
- { 0x0d, KEY_STOP },
- { 0x0e, KEY_PAUSE },
- { 0x0f, KEY_LIST }, /* source */
-
- { 0x10, KEY_MUTE },
- { 0x11, KEY_REWIND }, /* backward << */
- { 0x12, KEY_POWER },
- { 0x13, KEY_CAMERA }, /* snap */
- { 0x14, KEY_AUDIO }, /* stereo */
- { 0x15, KEY_CLEAR }, /* reset */
- { 0x16, KEY_PLAY },
- { 0x17, KEY_ENTER },
- { 0x18, KEY_ZOOM }, /* full screen */
- { 0x19, KEY_FASTFORWARD }, /* forward >> */
- { 0x1a, KEY_CHANNELUP },
- { 0x1b, KEY_VOLUMEUP },
- { 0x1c, KEY_INFO }, /* preview */
- { 0x1d, KEY_RECORD }, /* record */
- { 0x1e, KEY_CHANNELDOWN },
- { 0x1f, KEY_VOLUMEDOWN },
-};
-DEFINE_LEGACY_IR_KEYTABLE(dntv_live_dvb_t);
-
-/* ---------------------------------------------------------------------- */
-
-/* IO-DATA BCTV7E Remote */
-static struct ir_scancode iodata_bctv7e[] = {
- { 0x40, KEY_TV },
- { 0x20, KEY_RADIO }, /* FM */
- { 0x60, KEY_EPG },
- { 0x00, KEY_POWER },
-
- /* Keys 0 to 9 */
- { 0x44, KEY_0 }, /* 10 */
- { 0x50, KEY_1 },
- { 0x30, KEY_2 },
- { 0x70, KEY_3 },
- { 0x48, KEY_4 },
- { 0x28, KEY_5 },
- { 0x68, KEY_6 },
- { 0x58, KEY_7 },
- { 0x38, KEY_8 },
- { 0x78, KEY_9 },
-
- { 0x10, KEY_L }, /* Live */
- { 0x08, KEY_TIME }, /* Time Shift */
-
- { 0x18, KEY_PLAYPAUSE }, /* Play */
-
- { 0x24, KEY_ENTER }, /* 11 */
- { 0x64, KEY_ESC }, /* 12 */
- { 0x04, KEY_M }, /* Multi */
-
- { 0x54, KEY_VIDEO },
- { 0x34, KEY_CHANNELUP },
- { 0x74, KEY_VOLUMEUP },
- { 0x14, KEY_MUTE },
-
- { 0x4c, KEY_VCR }, /* SVIDEO */
- { 0x2c, KEY_CHANNELDOWN },
- { 0x6c, KEY_VOLUMEDOWN },
- { 0x0c, KEY_ZOOM },
-
- { 0x5c, KEY_PAUSE },
- { 0x3c, KEY_RED }, /* || (red) */
- { 0x7c, KEY_RECORD }, /* recording */
- { 0x1c, KEY_STOP },
-
- { 0x41, KEY_REWIND }, /* backward << */
- { 0x21, KEY_PLAY },
- { 0x61, KEY_FASTFORWARD }, /* forward >> */
- { 0x01, KEY_NEXT }, /* skip >| */
-};
-DEFINE_LEGACY_IR_KEYTABLE(iodata_bctv7e);
-
-/* ---------------------------------------------------------------------- */
-
-/* ADS Tech Instant TV DVB-T PCI Remote */
-static struct ir_scancode adstech_dvb_t_pci[] = {
- /* Keys 0 to 9 */
- { 0x4d, KEY_0 },
- { 0x57, KEY_1 },
- { 0x4f, KEY_2 },
- { 0x53, KEY_3 },
- { 0x56, KEY_4 },
- { 0x4e, KEY_5 },
- { 0x5e, KEY_6 },
- { 0x54, KEY_7 },
- { 0x4c, KEY_8 },
- { 0x5c, KEY_9 },
-
- { 0x5b, KEY_POWER },
- { 0x5f, KEY_MUTE },
- { 0x55, KEY_GOTO },
- { 0x5d, KEY_SEARCH },
- { 0x17, KEY_EPG }, /* Guide */
- { 0x1f, KEY_MENU },
- { 0x0f, KEY_UP },
- { 0x46, KEY_DOWN },
- { 0x16, KEY_LEFT },
- { 0x1e, KEY_RIGHT },
- { 0x0e, KEY_SELECT }, /* Enter */
- { 0x5a, KEY_INFO },
- { 0x52, KEY_EXIT },
- { 0x59, KEY_PREVIOUS },
- { 0x51, KEY_NEXT },
- { 0x58, KEY_REWIND },
- { 0x50, KEY_FORWARD },
- { 0x44, KEY_PLAYPAUSE },
- { 0x07, KEY_STOP },
- { 0x1b, KEY_RECORD },
- { 0x13, KEY_TUNER }, /* Live */
- { 0x0a, KEY_A },
- { 0x12, KEY_B },
- { 0x03, KEY_PROG1 }, /* 1 */
- { 0x01, KEY_PROG2 }, /* 2 */
- { 0x00, KEY_PROG3 }, /* 3 */
- { 0x06, KEY_DVD },
- { 0x48, KEY_AUX }, /* Photo */
- { 0x40, KEY_VIDEO },
- { 0x19, KEY_AUDIO }, /* Music */
- { 0x0b, KEY_CHANNELUP },
- { 0x08, KEY_CHANNELDOWN },
- { 0x15, KEY_VOLUMEUP },
- { 0x1c, KEY_VOLUMEDOWN },
-};
-DEFINE_LEGACY_IR_KEYTABLE(adstech_dvb_t_pci);
-
-/* ---------------------------------------------------------------------- */
-
-/* MSI TV@nywhere MASTER remote */
-
-static struct ir_scancode msi_tvanywhere[] = {
- /* Keys 0 to 9 */
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x0c, KEY_MUTE },
- { 0x0f, KEY_SCREEN }, /* Full Screen */
- { 0x10, KEY_FN }, /* Funtion */
- { 0x11, KEY_TIME }, /* Time shift */
- { 0x12, KEY_POWER },
- { 0x13, KEY_MEDIA }, /* MTS */
- { 0x14, KEY_SLOW },
- { 0x16, KEY_REWIND }, /* backward << */
- { 0x17, KEY_ENTER }, /* Return */
- { 0x18, KEY_FASTFORWARD }, /* forward >> */
- { 0x1a, KEY_CHANNELUP },
- { 0x1b, KEY_VOLUMEUP },
- { 0x1e, KEY_CHANNELDOWN },
- { 0x1f, KEY_VOLUMEDOWN },
-};
-DEFINE_LEGACY_IR_KEYTABLE(msi_tvanywhere);
-
-/* ---------------------------------------------------------------------- */
-
-/*
- Keycodes for remote on the MSI TV@nywhere Plus. The controller IC on the card
- is marked "KS003". The controller is I2C at address 0x30, but does not seem
- to respond to probes until a read is performed from a valid device.
- I don't know why...
-
- Note: This remote may be of similar or identical design to the
- Pixelview remote (?). The raw codes and duplicate button codes
- appear to be the same.
-
- Henry Wong <henry@stuffedcow.net>
- Some changes to formatting and keycodes by Mark Schultz <n9xmj@yahoo.com>
-
-*/
-
-static struct ir_scancode msi_tvanywhere_plus[] = {
-
-/* ---- Remote Button Layout ----
-
- POWER SOURCE SCAN MUTE
- TV/FM 1 2 3
- |> 4 5 6
- <| 7 8 9
- ^^UP 0 + RECALL
- vvDN RECORD STOP PLAY
-
- MINIMIZE ZOOM
-
- CH+
- VOL- VOL+
- CH-
-
- SNAPSHOT MTS
-
- << FUNC >> RESET
-*/
-
- { 0x01, KEY_1 }, /* 1 */
- { 0x0b, KEY_2 }, /* 2 */
- { 0x1b, KEY_3 }, /* 3 */
- { 0x05, KEY_4 }, /* 4 */
- { 0x09, KEY_5 }, /* 5 */
- { 0x15, KEY_6 }, /* 6 */
- { 0x06, KEY_7 }, /* 7 */
- { 0x0a, KEY_8 }, /* 8 */
- { 0x12, KEY_9 }, /* 9 */
- { 0x02, KEY_0 }, /* 0 */
- { 0x10, KEY_KPPLUS }, /* + */
- { 0x13, KEY_AGAIN }, /* Recall */
-
- { 0x1e, KEY_POWER }, /* Power */
- { 0x07, KEY_TUNER }, /* Source */
- { 0x1c, KEY_SEARCH }, /* Scan */
- { 0x18, KEY_MUTE }, /* Mute */
-
- { 0x03, KEY_RADIO }, /* TV/FM */
- /* The next four keys are duplicates that appear to send the
- same IR code as Ch+, Ch-, >>, and << . The raw code assigned
- to them is the actual code + 0x20 - they will never be
- detected as such unless some way is discovered to distinguish
- these buttons from those that have the same code. */
- { 0x3f, KEY_RIGHT }, /* |> and Ch+ */
- { 0x37, KEY_LEFT }, /* <| and Ch- */
- { 0x2c, KEY_UP }, /* ^^Up and >> */
- { 0x24, KEY_DOWN }, /* vvDn and << */
-
- { 0x00, KEY_RECORD }, /* Record */
- { 0x08, KEY_STOP }, /* Stop */
- { 0x11, KEY_PLAY }, /* Play */
-
- { 0x0f, KEY_CLOSE }, /* Minimize */
- { 0x19, KEY_ZOOM }, /* Zoom */
- { 0x1a, KEY_CAMERA }, /* Snapshot */
- { 0x0d, KEY_LANGUAGE }, /* MTS */
-
- { 0x14, KEY_VOLUMEDOWN }, /* Vol- */
- { 0x16, KEY_VOLUMEUP }, /* Vol+ */
- { 0x17, KEY_CHANNELDOWN }, /* Ch- */
- { 0x1f, KEY_CHANNELUP }, /* Ch+ */
-
- { 0x04, KEY_REWIND }, /* << */
- { 0x0e, KEY_MENU }, /* Function */
- { 0x0c, KEY_FASTFORWARD }, /* >> */
- { 0x1d, KEY_RESTART }, /* Reset */
-};
-DEFINE_LEGACY_IR_KEYTABLE(msi_tvanywhere_plus);
-
-/* ---------------------------------------------------------------------- */
-
-/* Cinergy 1400 DVB-T */
-static struct ir_scancode cinergy_1400[] = {
- { 0x01, KEY_POWER },
- { 0x02, KEY_1 },
- { 0x03, KEY_2 },
- { 0x04, KEY_3 },
- { 0x05, KEY_4 },
- { 0x06, KEY_5 },
- { 0x07, KEY_6 },
- { 0x08, KEY_7 },
- { 0x09, KEY_8 },
- { 0x0a, KEY_9 },
- { 0x0c, KEY_0 },
-
- { 0x0b, KEY_VIDEO },
- { 0x0d, KEY_REFRESH },
- { 0x0e, KEY_SELECT },
- { 0x0f, KEY_EPG },
- { 0x10, KEY_UP },
- { 0x11, KEY_LEFT },
- { 0x12, KEY_OK },
- { 0x13, KEY_RIGHT },
- { 0x14, KEY_DOWN },
- { 0x15, KEY_TEXT },
- { 0x16, KEY_INFO },
-
- { 0x17, KEY_RED },
- { 0x18, KEY_GREEN },
- { 0x19, KEY_YELLOW },
- { 0x1a, KEY_BLUE },
-
- { 0x1b, KEY_CHANNELUP },
- { 0x1c, KEY_VOLUMEUP },
- { 0x1d, KEY_MUTE },
- { 0x1e, KEY_VOLUMEDOWN },
- { 0x1f, KEY_CHANNELDOWN },
-
- { 0x40, KEY_PAUSE },
- { 0x4c, KEY_PLAY },
- { 0x58, KEY_RECORD },
- { 0x54, KEY_PREVIOUS },
- { 0x48, KEY_STOP },
- { 0x5c, KEY_NEXT },
-};
-DEFINE_LEGACY_IR_KEYTABLE(cinergy_1400);
-
-/* ---------------------------------------------------------------------- */
-
-/* AVERTV STUDIO 303 Remote */
-static struct ir_scancode avertv_303[] = {
- { 0x2a, KEY_1 },
- { 0x32, KEY_2 },
- { 0x3a, KEY_3 },
- { 0x4a, KEY_4 },
- { 0x52, KEY_5 },
- { 0x5a, KEY_6 },
- { 0x6a, KEY_7 },
- { 0x72, KEY_8 },
- { 0x7a, KEY_9 },
- { 0x0e, KEY_0 },
-
- { 0x02, KEY_POWER },
- { 0x22, KEY_VIDEO },
- { 0x42, KEY_AUDIO },
- { 0x62, KEY_ZOOM },
- { 0x0a, KEY_TV },
- { 0x12, KEY_CD },
- { 0x1a, KEY_TEXT },
-
- { 0x16, KEY_SUBTITLE },
- { 0x1e, KEY_REWIND },
- { 0x06, KEY_PRINT },
-
- { 0x2e, KEY_SEARCH },
- { 0x36, KEY_SLEEP },
- { 0x3e, KEY_SHUFFLE },
- { 0x26, KEY_MUTE },
-
- { 0x4e, KEY_RECORD },
- { 0x56, KEY_PAUSE },
- { 0x5e, KEY_STOP },
- { 0x46, KEY_PLAY },
-
- { 0x6e, KEY_RED },
- { 0x0b, KEY_GREEN },
- { 0x66, KEY_YELLOW },
- { 0x03, KEY_BLUE },
-
- { 0x76, KEY_LEFT },
- { 0x7e, KEY_RIGHT },
- { 0x13, KEY_DOWN },
- { 0x1b, KEY_UP },
-};
-DEFINE_LEGACY_IR_KEYTABLE(avertv_303);
-
-/* ---------------------------------------------------------------------- */
-
-/* DigitalNow DNTV Live! DVB-T Pro Remote */
-static struct ir_scancode dntv_live_dvbt_pro[] = {
- { 0x16, KEY_POWER },
- { 0x5b, KEY_HOME },
-
- { 0x55, KEY_TV }, /* live tv */
- { 0x58, KEY_TUNER }, /* digital Radio */
- { 0x5a, KEY_RADIO }, /* FM radio */
- { 0x59, KEY_DVD }, /* dvd menu */
- { 0x03, KEY_1 },
- { 0x01, KEY_2 },
- { 0x06, KEY_3 },
- { 0x09, KEY_4 },
- { 0x1d, KEY_5 },
- { 0x1f, KEY_6 },
- { 0x0d, KEY_7 },
- { 0x19, KEY_8 },
- { 0x1b, KEY_9 },
- { 0x0c, KEY_CANCEL },
- { 0x15, KEY_0 },
- { 0x4a, KEY_CLEAR },
- { 0x13, KEY_BACK },
- { 0x00, KEY_TAB },
- { 0x4b, KEY_UP },
- { 0x4e, KEY_LEFT },
- { 0x4f, KEY_OK },
- { 0x52, KEY_RIGHT },
- { 0x51, KEY_DOWN },
- { 0x1e, KEY_VOLUMEUP },
- { 0x0a, KEY_VOLUMEDOWN },
- { 0x02, KEY_CHANNELDOWN },
- { 0x05, KEY_CHANNELUP },
- { 0x11, KEY_RECORD },
- { 0x14, KEY_PLAY },
- { 0x4c, KEY_PAUSE },
- { 0x1a, KEY_STOP },
- { 0x40, KEY_REWIND },
- { 0x12, KEY_FASTFORWARD },
- { 0x41, KEY_PREVIOUSSONG }, /* replay |< */
- { 0x42, KEY_NEXTSONG }, /* skip >| */
- { 0x54, KEY_CAMERA }, /* capture */
- { 0x50, KEY_LANGUAGE }, /* sap */
- { 0x47, KEY_TV2 }, /* pip */
- { 0x4d, KEY_SCREEN },
- { 0x43, KEY_SUBTITLE },
- { 0x10, KEY_MUTE },
- { 0x49, KEY_AUDIO }, /* l/r */
- { 0x07, KEY_SLEEP },
- { 0x08, KEY_VIDEO }, /* a/v */
- { 0x0e, KEY_PREVIOUS }, /* recall */
- { 0x45, KEY_ZOOM }, /* zoom + */
- { 0x46, KEY_ANGLE }, /* zoom - */
- { 0x56, KEY_RED },
- { 0x57, KEY_GREEN },
- { 0x5c, KEY_YELLOW },
- { 0x5d, KEY_BLUE },
-};
-DEFINE_LEGACY_IR_KEYTABLE(dntv_live_dvbt_pro);
-
-static struct ir_scancode em_terratec[] = {
- { 0x01, KEY_CHANNEL },
- { 0x02, KEY_SELECT },
- { 0x03, KEY_MUTE },
- { 0x04, KEY_POWER },
- { 0x05, KEY_1 },
- { 0x06, KEY_2 },
- { 0x07, KEY_3 },
- { 0x08, KEY_CHANNELUP },
- { 0x09, KEY_4 },
- { 0x0a, KEY_5 },
- { 0x0b, KEY_6 },
- { 0x0c, KEY_CHANNELDOWN },
- { 0x0d, KEY_7 },
- { 0x0e, KEY_8 },
- { 0x0f, KEY_9 },
- { 0x10, KEY_VOLUMEUP },
- { 0x11, KEY_0 },
- { 0x12, KEY_MENU },
- { 0x13, KEY_PRINT },
- { 0x14, KEY_VOLUMEDOWN },
- { 0x16, KEY_PAUSE },
- { 0x18, KEY_RECORD },
- { 0x19, KEY_REWIND },
- { 0x1a, KEY_PLAY },
- { 0x1b, KEY_FORWARD },
- { 0x1c, KEY_BACKSPACE },
- { 0x1e, KEY_STOP },
- { 0x40, KEY_ZOOM },
-};
-DEFINE_LEGACY_IR_KEYTABLE(em_terratec);
-
-static struct ir_scancode pinnacle_grey[] = {
- { 0x3a, KEY_0 },
- { 0x31, KEY_1 },
- { 0x32, KEY_2 },
- { 0x33, KEY_3 },
- { 0x34, KEY_4 },
- { 0x35, KEY_5 },
- { 0x36, KEY_6 },
- { 0x37, KEY_7 },
- { 0x38, KEY_8 },
- { 0x39, KEY_9 },
-
- { 0x2f, KEY_POWER },
-
- { 0x2e, KEY_P },
- { 0x1f, KEY_L },
- { 0x2b, KEY_I },
-
- { 0x2d, KEY_SCREEN },
- { 0x1e, KEY_ZOOM },
- { 0x1b, KEY_VOLUMEUP },
- { 0x0f, KEY_VOLUMEDOWN },
- { 0x17, KEY_CHANNELUP },
- { 0x1c, KEY_CHANNELDOWN },
- { 0x25, KEY_INFO },
-
- { 0x3c, KEY_MUTE },
-
- { 0x3d, KEY_LEFT },
- { 0x3b, KEY_RIGHT },
-
- { 0x3f, KEY_UP },
- { 0x3e, KEY_DOWN },
- { 0x1a, KEY_ENTER },
-
- { 0x1d, KEY_MENU },
- { 0x19, KEY_AGAIN },
- { 0x16, KEY_PREVIOUSSONG },
- { 0x13, KEY_NEXTSONG },
- { 0x15, KEY_PAUSE },
- { 0x0e, KEY_REWIND },
- { 0x0d, KEY_PLAY },
- { 0x0b, KEY_STOP },
- { 0x07, KEY_FORWARD },
- { 0x27, KEY_RECORD },
- { 0x26, KEY_TUNER },
- { 0x29, KEY_TEXT },
- { 0x2a, KEY_MEDIA },
- { 0x18, KEY_EPG },
-};
-DEFINE_LEGACY_IR_KEYTABLE(pinnacle_grey);
-
-static struct ir_scancode flyvideo[] = {
- { 0x0f, KEY_0 },
- { 0x03, KEY_1 },
- { 0x04, KEY_2 },
- { 0x05, KEY_3 },
- { 0x07, KEY_4 },
- { 0x08, KEY_5 },
- { 0x09, KEY_6 },
- { 0x0b, KEY_7 },
- { 0x0c, KEY_8 },
- { 0x0d, KEY_9 },
-
- { 0x0e, KEY_MODE }, /* Air/Cable */
- { 0x11, KEY_VIDEO }, /* Video */
- { 0x15, KEY_AUDIO }, /* Audio */
- { 0x00, KEY_POWER }, /* Power */
- { 0x18, KEY_TUNER }, /* AV Source */
- { 0x02, KEY_ZOOM }, /* Fullscreen */
- { 0x1a, KEY_LANGUAGE }, /* Stereo */
- { 0x1b, KEY_MUTE }, /* Mute */
- { 0x14, KEY_VOLUMEUP }, /* Volume + */
- { 0x17, KEY_VOLUMEDOWN },/* Volume - */
- { 0x12, KEY_CHANNELUP },/* Channel + */
- { 0x13, KEY_CHANNELDOWN },/* Channel - */
- { 0x06, KEY_AGAIN }, /* Recall */
- { 0x10, KEY_ENTER }, /* Enter */
-
- { 0x19, KEY_BACK }, /* Rewind ( <<< ) */
- { 0x1f, KEY_FORWARD }, /* Forward ( >>> ) */
- { 0x0a, KEY_ANGLE }, /* no label, may be used as the PAUSE button */
-};
-DEFINE_LEGACY_IR_KEYTABLE(flyvideo);
-
-static struct ir_scancode flydvb[] = {
- { 0x01, KEY_ZOOM }, /* Full Screen */
- { 0x00, KEY_POWER }, /* Power */
-
- { 0x03, KEY_1 },
- { 0x04, KEY_2 },
- { 0x05, KEY_3 },
- { 0x07, KEY_4 },
- { 0x08, KEY_5 },
- { 0x09, KEY_6 },
- { 0x0b, KEY_7 },
- { 0x0c, KEY_8 },
- { 0x0d, KEY_9 },
- { 0x06, KEY_AGAIN }, /* Recall */
- { 0x0f, KEY_0 },
- { 0x10, KEY_MUTE }, /* Mute */
- { 0x02, KEY_RADIO }, /* TV/Radio */
- { 0x1b, KEY_LANGUAGE }, /* SAP (Second Audio Program) */
-
- { 0x14, KEY_VOLUMEUP }, /* VOL+ */
- { 0x17, KEY_VOLUMEDOWN }, /* VOL- */
- { 0x12, KEY_CHANNELUP }, /* CH+ */
- { 0x13, KEY_CHANNELDOWN }, /* CH- */
- { 0x1d, KEY_ENTER }, /* Enter */
-
- { 0x1a, KEY_MODE }, /* PIP */
- { 0x18, KEY_TUNER }, /* Source */
-
- { 0x1e, KEY_RECORD }, /* Record/Pause */
- { 0x15, KEY_ANGLE }, /* Swap (no label on key) */
- { 0x1c, KEY_PAUSE }, /* Timeshift/Pause */
- { 0x19, KEY_BACK }, /* Rewind << */
- { 0x0a, KEY_PLAYPAUSE }, /* Play/Pause */
- { 0x1f, KEY_FORWARD }, /* Forward >> */
- { 0x16, KEY_PREVIOUS }, /* Back |<< */
- { 0x11, KEY_STOP }, /* Stop */
- { 0x0e, KEY_NEXT }, /* End >>| */
-};
-DEFINE_LEGACY_IR_KEYTABLE(flydvb);
-
-static struct ir_scancode cinergy[] = {
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x0a, KEY_POWER },
- { 0x0b, KEY_PROG1 }, /* app */
- { 0x0c, KEY_ZOOM }, /* zoom/fullscreen */
- { 0x0d, KEY_CHANNELUP }, /* channel */
- { 0x0e, KEY_CHANNELDOWN }, /* channel- */
- { 0x0f, KEY_VOLUMEUP },
- { 0x10, KEY_VOLUMEDOWN },
- { 0x11, KEY_TUNER }, /* AV */
- { 0x12, KEY_NUMLOCK }, /* -/-- */
- { 0x13, KEY_AUDIO }, /* audio */
- { 0x14, KEY_MUTE },
- { 0x15, KEY_UP },
- { 0x16, KEY_DOWN },
- { 0x17, KEY_LEFT },
- { 0x18, KEY_RIGHT },
- { 0x19, BTN_LEFT, },
- { 0x1a, BTN_RIGHT, },
- { 0x1b, KEY_WWW }, /* text */
- { 0x1c, KEY_REWIND },
- { 0x1d, KEY_FORWARD },
- { 0x1e, KEY_RECORD },
- { 0x1f, KEY_PLAY },
- { 0x20, KEY_PREVIOUSSONG },
- { 0x21, KEY_NEXTSONG },
- { 0x22, KEY_PAUSE },
- { 0x23, KEY_STOP },
-};
-DEFINE_LEGACY_IR_KEYTABLE(cinergy);
-
-/* Alfons Geser <a.geser@cox.net>
- * updates from Job D. R. Borges <jobdrb@ig.com.br> */
-static struct ir_scancode eztv[] = {
- { 0x12, KEY_POWER },
- { 0x01, KEY_TV }, /* DVR */
- { 0x15, KEY_DVD }, /* DVD */
- { 0x17, KEY_AUDIO }, /* music */
- /* DVR mode / DVD mode / music mode */
-
- { 0x1b, KEY_MUTE }, /* mute */
- { 0x02, KEY_LANGUAGE }, /* MTS/SAP / audio / autoseek */
- { 0x1e, KEY_SUBTITLE }, /* closed captioning / subtitle / seek */
- { 0x16, KEY_ZOOM }, /* full screen */
- { 0x1c, KEY_VIDEO }, /* video source / eject / delall */
- { 0x1d, KEY_RESTART }, /* playback / angle / del */
- { 0x2f, KEY_SEARCH }, /* scan / menu / playlist */
- { 0x30, KEY_CHANNEL }, /* CH surfing / bookmark / memo */
-
- { 0x31, KEY_HELP }, /* help */
- { 0x32, KEY_MODE }, /* num/memo */
- { 0x33, KEY_ESC }, /* cancel */
-
- { 0x0c, KEY_UP }, /* up */
- { 0x10, KEY_DOWN }, /* down */
- { 0x08, KEY_LEFT }, /* left */
- { 0x04, KEY_RIGHT }, /* right */
- { 0x03, KEY_SELECT }, /* select */
-
- { 0x1f, KEY_REWIND }, /* rewind */
- { 0x20, KEY_PLAYPAUSE },/* play/pause */
- { 0x29, KEY_FORWARD }, /* forward */
- { 0x14, KEY_AGAIN }, /* repeat */
- { 0x2b, KEY_RECORD }, /* recording */
- { 0x2c, KEY_STOP }, /* stop */
- { 0x2d, KEY_PLAY }, /* play */
- { 0x2e, KEY_CAMERA }, /* snapshot / shuffle */
-
- { 0x00, KEY_0 },
- { 0x05, KEY_1 },
- { 0x06, KEY_2 },
- { 0x07, KEY_3 },
- { 0x09, KEY_4 },
- { 0x0a, KEY_5 },
- { 0x0b, KEY_6 },
- { 0x0d, KEY_7 },
- { 0x0e, KEY_8 },
- { 0x0f, KEY_9 },
-
- { 0x2a, KEY_VOLUMEUP },
- { 0x11, KEY_VOLUMEDOWN },
- { 0x18, KEY_CHANNELUP },/* CH.tracking up */
- { 0x19, KEY_CHANNELDOWN },/* CH.tracking down */
-
- { 0x13, KEY_ENTER }, /* enter */
- { 0x21, KEY_DOT }, /* . (decimal dot) */
-};
-DEFINE_LEGACY_IR_KEYTABLE(eztv);
-
-/* Alex Hermann <gaaf@gmx.net> */
-static struct ir_scancode avermedia[] = {
- { 0x28, KEY_1 },
- { 0x18, KEY_2 },
- { 0x38, KEY_3 },
- { 0x24, KEY_4 },
- { 0x14, KEY_5 },
- { 0x34, KEY_6 },
- { 0x2c, KEY_7 },
- { 0x1c, KEY_8 },
- { 0x3c, KEY_9 },
- { 0x22, KEY_0 },
-
- { 0x20, KEY_TV }, /* TV/FM */
- { 0x10, KEY_CD }, /* CD */
- { 0x30, KEY_TEXT }, /* TELETEXT */
- { 0x00, KEY_POWER }, /* POWER */
-
- { 0x08, KEY_VIDEO }, /* VIDEO */
- { 0x04, KEY_AUDIO }, /* AUDIO */
- { 0x0c, KEY_ZOOM }, /* FULL SCREEN */
-
- { 0x12, KEY_SUBTITLE }, /* DISPLAY */
- { 0x32, KEY_REWIND }, /* LOOP */
- { 0x02, KEY_PRINT }, /* PREVIEW */
-
- { 0x2a, KEY_SEARCH }, /* AUTOSCAN */
- { 0x1a, KEY_SLEEP }, /* FREEZE */
- { 0x3a, KEY_CAMERA }, /* SNAPSHOT */
- { 0x0a, KEY_MUTE }, /* MUTE */
-
- { 0x26, KEY_RECORD }, /* RECORD */
- { 0x16, KEY_PAUSE }, /* PAUSE */
- { 0x36, KEY_STOP }, /* STOP */
- { 0x06, KEY_PLAY }, /* PLAY */
-
- { 0x2e, KEY_RED }, /* RED */
- { 0x21, KEY_GREEN }, /* GREEN */
- { 0x0e, KEY_YELLOW }, /* YELLOW */
- { 0x01, KEY_BLUE }, /* BLUE */
-
- { 0x1e, KEY_VOLUMEDOWN }, /* VOLUME- */
- { 0x3e, KEY_VOLUMEUP }, /* VOLUME+ */
- { 0x11, KEY_CHANNELDOWN }, /* CHANNEL/PAGE- */
- { 0x31, KEY_CHANNELUP } /* CHANNEL/PAGE+ */
-};
-DEFINE_LEGACY_IR_KEYTABLE(avermedia);
-
-static struct ir_scancode videomate_tv_pvr[] = {
- { 0x14, KEY_MUTE },
- { 0x24, KEY_ZOOM },
-
- { 0x01, KEY_DVD },
- { 0x23, KEY_RADIO },
- { 0x00, KEY_TV },
-
- { 0x0a, KEY_REWIND },
- { 0x08, KEY_PLAYPAUSE },
- { 0x0f, KEY_FORWARD },
-
- { 0x02, KEY_PREVIOUS },
- { 0x07, KEY_STOP },
- { 0x06, KEY_NEXT },
-
- { 0x0c, KEY_UP },
- { 0x0e, KEY_DOWN },
- { 0x0b, KEY_LEFT },
- { 0x0d, KEY_RIGHT },
- { 0x11, KEY_OK },
-
- { 0x03, KEY_MENU },
- { 0x09, KEY_SETUP },
- { 0x05, KEY_VIDEO },
- { 0x22, KEY_CHANNEL },
-
- { 0x12, KEY_VOLUMEUP },
- { 0x15, KEY_VOLUMEDOWN },
- { 0x10, KEY_CHANNELUP },
- { 0x13, KEY_CHANNELDOWN },
-
- { 0x04, KEY_RECORD },
-
- { 0x16, KEY_1 },
- { 0x17, KEY_2 },
- { 0x18, KEY_3 },
- { 0x19, KEY_4 },
- { 0x1a, KEY_5 },
- { 0x1b, KEY_6 },
- { 0x1c, KEY_7 },
- { 0x1d, KEY_8 },
- { 0x1e, KEY_9 },
- { 0x1f, KEY_0 },
-
- { 0x20, KEY_LANGUAGE },
- { 0x21, KEY_SLEEP },
-};
-DEFINE_LEGACY_IR_KEYTABLE(videomate_tv_pvr);
-
-/* Michael Tokarev <mjt@tls.msk.ru>
- http://www.corpit.ru/mjt/beholdTV/remote_control.jpg
- keytable is used by MANLI MTV00[0x0c] and BeholdTV 40[13] at
- least, and probably other cards too.
- The "ascii-art picture" below (in comments, first row
- is the keycode in hex, and subsequent row(s) shows
- the button labels (several variants when appropriate)
- helps to descide which keycodes to assign to the buttons.
+ * All keytables got moved to include/media/keytables directory.
+ * This file is still needed - at least for now, as their data is
+ * dynamically inserted here by the media/ir-common.h, due to the
+ * #define IR_KEYMAPS line, at the beginning of this file. The
+ * plans are to get rid of this file completely in a near future.
*/
-static struct ir_scancode manli[] = {
-
- /* 0x1c 0x12 *
- * FUNCTION POWER *
- * FM (|) *
- * */
- { 0x1c, KEY_RADIO }, /*XXX*/
- { 0x12, KEY_POWER },
-
- /* 0x01 0x02 0x03 *
- * 1 2 3 *
- * *
- * 0x04 0x05 0x06 *
- * 4 5 6 *
- * *
- * 0x07 0x08 0x09 *
- * 7 8 9 *
- * */
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- /* 0x0a 0x00 0x17 *
- * RECALL 0 +100 *
- * PLUS *
- * */
- { 0x0a, KEY_AGAIN }, /*XXX KEY_REWIND? */
- { 0x00, KEY_0 },
- { 0x17, KEY_DIGITS }, /*XXX*/
-
- /* 0x14 0x10 *
- * MENU INFO *
- * OSD */
- { 0x14, KEY_MENU },
- { 0x10, KEY_INFO },
-
- /* 0x0b *
- * Up *
- * *
- * 0x18 0x16 0x0c *
- * Left Ok Right *
- * *
- * 0x015 *
- * Down *
- * */
- { 0x0b, KEY_UP },
- { 0x18, KEY_LEFT },
- { 0x16, KEY_OK }, /*XXX KEY_SELECT? KEY_ENTER? */
- { 0x0c, KEY_RIGHT },
- { 0x15, KEY_DOWN },
-
- /* 0x11 0x0d *
- * TV/AV MODE *
- * SOURCE STEREO *
- * */
- { 0x11, KEY_TV }, /*XXX*/
- { 0x0d, KEY_MODE }, /*XXX there's no KEY_STEREO */
-
- /* 0x0f 0x1b 0x1a *
- * AUDIO Vol+ Chan+ *
- * TIMESHIFT??? *
- * *
- * 0x0e 0x1f 0x1e *
- * SLEEP Vol- Chan- *
- * */
- { 0x0f, KEY_AUDIO },
- { 0x1b, KEY_VOLUMEUP },
- { 0x1a, KEY_CHANNELUP },
- { 0x0e, KEY_TIME },
- { 0x1f, KEY_VOLUMEDOWN },
- { 0x1e, KEY_CHANNELDOWN },
-
- /* 0x13 0x19 *
- * MUTE SNAPSHOT*
- * */
- { 0x13, KEY_MUTE },
- { 0x19, KEY_CAMERA },
-
- /* 0x1d unused ? */
-};
-DEFINE_LEGACY_IR_KEYTABLE(manli);
-
-/* Mike Baikov <mike@baikov.com> */
-static struct ir_scancode gotview7135[] = {
-
- { 0x11, KEY_POWER },
- { 0x35, KEY_TV },
- { 0x1b, KEY_0 },
- { 0x29, KEY_1 },
- { 0x19, KEY_2 },
- { 0x39, KEY_3 },
- { 0x1f, KEY_4 },
- { 0x2c, KEY_5 },
- { 0x21, KEY_6 },
- { 0x24, KEY_7 },
- { 0x18, KEY_8 },
- { 0x2b, KEY_9 },
- { 0x3b, KEY_AGAIN }, /* LOOP */
- { 0x06, KEY_AUDIO },
- { 0x31, KEY_PRINT }, /* PREVIEW */
- { 0x3e, KEY_VIDEO },
- { 0x10, KEY_CHANNELUP },
- { 0x20, KEY_CHANNELDOWN },
- { 0x0c, KEY_VOLUMEDOWN },
- { 0x28, KEY_VOLUMEUP },
- { 0x08, KEY_MUTE },
- { 0x26, KEY_SEARCH }, /* SCAN */
- { 0x3f, KEY_CAMERA }, /* SNAPSHOT */
- { 0x12, KEY_RECORD },
- { 0x32, KEY_STOP },
- { 0x3c, KEY_PLAY },
- { 0x1d, KEY_REWIND },
- { 0x2d, KEY_PAUSE },
- { 0x0d, KEY_FORWARD },
- { 0x05, KEY_ZOOM }, /*FULL*/
-
- { 0x2a, KEY_F21 }, /* LIVE TIMESHIFT */
- { 0x0e, KEY_F22 }, /* MIN TIMESHIFT */
- { 0x1e, KEY_TIME }, /* TIMESHIFT */
- { 0x38, KEY_F24 }, /* NORMAL TIMESHIFT */
-};
-DEFINE_LEGACY_IR_KEYTABLE(gotview7135);
-
-static struct ir_scancode purpletv[] = {
- { 0x03, KEY_POWER },
- { 0x6f, KEY_MUTE },
- { 0x10, KEY_BACKSPACE }, /* Recall */
-
- { 0x11, KEY_0 },
- { 0x04, KEY_1 },
- { 0x05, KEY_2 },
- { 0x06, KEY_3 },
- { 0x08, KEY_4 },
- { 0x09, KEY_5 },
- { 0x0a, KEY_6 },
- { 0x0c, KEY_7 },
- { 0x0d, KEY_8 },
- { 0x0e, KEY_9 },
- { 0x12, KEY_DOT }, /* 100+ */
-
- { 0x07, KEY_VOLUMEUP },
- { 0x0b, KEY_VOLUMEDOWN },
- { 0x1a, KEY_KPPLUS },
- { 0x18, KEY_KPMINUS },
- { 0x15, KEY_UP },
- { 0x1d, KEY_DOWN },
- { 0x0f, KEY_CHANNELUP },
- { 0x13, KEY_CHANNELDOWN },
- { 0x48, KEY_ZOOM },
-
- { 0x1b, KEY_VIDEO }, /* Video source */
- { 0x1f, KEY_CAMERA }, /* Snapshot */
- { 0x49, KEY_LANGUAGE }, /* MTS Select */
- { 0x19, KEY_SEARCH }, /* Auto Scan */
-
- { 0x4b, KEY_RECORD },
- { 0x46, KEY_PLAY },
- { 0x45, KEY_PAUSE }, /* Pause */
- { 0x44, KEY_STOP },
- { 0x43, KEY_TIME }, /* Time Shift */
- { 0x17, KEY_CHANNEL }, /* SURF CH */
- { 0x40, KEY_FORWARD }, /* Forward ? */
- { 0x42, KEY_REWIND }, /* Backward ? */
-
-};
-DEFINE_LEGACY_IR_KEYTABLE(purpletv);
-
-/* Mapping for the 28 key remote control as seen at
- http://www.sednacomputer.com/photo/cardbus-tv.jpg
- Pavel Mihaylov <bin@bash.info>
- Also for the remote bundled with Kozumi KTV-01C card */
-static struct ir_scancode pctv_sedna[] = {
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x0a, KEY_AGAIN }, /* Recall */
- { 0x0b, KEY_CHANNELUP },
- { 0x0c, KEY_VOLUMEUP },
- { 0x0d, KEY_MODE }, /* Stereo */
- { 0x0e, KEY_STOP },
- { 0x0f, KEY_PREVIOUSSONG },
- { 0x10, KEY_ZOOM },
- { 0x11, KEY_TUNER }, /* Source */
- { 0x12, KEY_POWER },
- { 0x13, KEY_MUTE },
- { 0x15, KEY_CHANNELDOWN },
- { 0x18, KEY_VOLUMEDOWN },
- { 0x19, KEY_CAMERA }, /* Snapshot */
- { 0x1a, KEY_NEXTSONG },
- { 0x1b, KEY_TIME }, /* Time Shift */
- { 0x1c, KEY_RADIO }, /* FM Radio */
- { 0x1d, KEY_RECORD },
- { 0x1e, KEY_PAUSE },
- /* additional codes for Kozumi's remote */
- { 0x14, KEY_INFO }, /* OSD */
- { 0x16, KEY_OK }, /* OK */
- { 0x17, KEY_DIGITS }, /* Plus */
- { 0x1f, KEY_PLAY }, /* Play */
-};
-DEFINE_LEGACY_IR_KEYTABLE(pctv_sedna);
-
-/* Mark Phalan <phalanm@o2.ie> */
-static struct ir_scancode pv951[] = {
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x12, KEY_POWER },
- { 0x10, KEY_MUTE },
- { 0x1f, KEY_VOLUMEDOWN },
- { 0x1b, KEY_VOLUMEUP },
- { 0x1a, KEY_CHANNELUP },
- { 0x1e, KEY_CHANNELDOWN },
- { 0x0e, KEY_PAGEUP },
- { 0x1d, KEY_PAGEDOWN },
- { 0x13, KEY_SOUND },
-
- { 0x18, KEY_KPPLUSMINUS }, /* CH +/- */
- { 0x16, KEY_SUBTITLE }, /* CC */
- { 0x0d, KEY_TEXT }, /* TTX */
- { 0x0b, KEY_TV }, /* AIR/CBL */
- { 0x11, KEY_PC }, /* PC/TV */
- { 0x17, KEY_OK }, /* CH RTN */
- { 0x19, KEY_MODE }, /* FUNC */
- { 0x0c, KEY_SEARCH }, /* AUTOSCAN */
-
- /* Not sure what to do with these ones! */
- { 0x0f, KEY_SELECT }, /* SOURCE */
- { 0x0a, KEY_KPPLUS }, /* +100 */
- { 0x14, KEY_EQUAL }, /* SYNC */
- { 0x1c, KEY_MEDIA }, /* PC/TV */
-};
-DEFINE_LEGACY_IR_KEYTABLE(pv951);
-
-/* generic RC5 keytable */
-/* see http://users.pandora.be/nenya/electronics/rc5/codes00.htm */
-/* used by old (black) Hauppauge remotes */
-static struct ir_scancode rc5_tv[] = {
- /* Keys 0 to 9 */
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x0b, KEY_CHANNEL }, /* channel / program (japan: 11) */
- { 0x0c, KEY_POWER }, /* standby */
- { 0x0d, KEY_MUTE }, /* mute / demute */
- { 0x0f, KEY_TV }, /* display */
- { 0x10, KEY_VOLUMEUP },
- { 0x11, KEY_VOLUMEDOWN },
- { 0x12, KEY_BRIGHTNESSUP },
- { 0x13, KEY_BRIGHTNESSDOWN },
- { 0x1e, KEY_SEARCH }, /* search + */
- { 0x20, KEY_CHANNELUP }, /* channel / program + */
- { 0x21, KEY_CHANNELDOWN }, /* channel / program - */
- { 0x22, KEY_CHANNEL }, /* alt / channel */
- { 0x23, KEY_LANGUAGE }, /* 1st / 2nd language */
- { 0x26, KEY_SLEEP }, /* sleeptimer */
- { 0x2e, KEY_MENU }, /* 2nd controls (USA: menu) */
- { 0x30, KEY_PAUSE },
- { 0x32, KEY_REWIND },
- { 0x33, KEY_GOTO },
- { 0x35, KEY_PLAY },
- { 0x36, KEY_STOP },
- { 0x37, KEY_RECORD }, /* recording */
- { 0x3c, KEY_TEXT }, /* teletext submode (Japan: 12) */
- { 0x3d, KEY_SUSPEND }, /* system standby */
-
-};
-DEFINE_LEGACY_IR_KEYTABLE(rc5_tv);
-
-/* Table for Leadtek Winfast Remote Controls - used by both bttv and cx88 */
-static struct ir_scancode winfast[] = {
- /* Keys 0 to 9 */
- { 0x12, KEY_0 },
- { 0x05, KEY_1 },
- { 0x06, KEY_2 },
- { 0x07, KEY_3 },
- { 0x09, KEY_4 },
- { 0x0a, KEY_5 },
- { 0x0b, KEY_6 },
- { 0x0d, KEY_7 },
- { 0x0e, KEY_8 },
- { 0x0f, KEY_9 },
-
- { 0x00, KEY_POWER },
- { 0x1b, KEY_AUDIO }, /* Audio Source */
- { 0x02, KEY_TUNER }, /* TV/FM, not on Y0400052 */
- { 0x1e, KEY_VIDEO }, /* Video Source */
- { 0x16, KEY_INFO }, /* Display information */
- { 0x04, KEY_VOLUMEUP },
- { 0x08, KEY_VOLUMEDOWN },
- { 0x0c, KEY_CHANNELUP },
- { 0x10, KEY_CHANNELDOWN },
- { 0x03, KEY_ZOOM }, /* fullscreen */
- { 0x1f, KEY_TEXT }, /* closed caption/teletext */
- { 0x20, KEY_SLEEP },
- { 0x29, KEY_CLEAR }, /* boss key */
- { 0x14, KEY_MUTE },
- { 0x2b, KEY_RED },
- { 0x2c, KEY_GREEN },
- { 0x2d, KEY_YELLOW },
- { 0x2e, KEY_BLUE },
- { 0x18, KEY_KPPLUS }, /* fine tune + , not on Y040052 */
- { 0x19, KEY_KPMINUS }, /* fine tune - , not on Y040052 */
- { 0x2a, KEY_MEDIA }, /* PIP (Picture in picture */
- { 0x21, KEY_DOT },
- { 0x13, KEY_ENTER },
- { 0x11, KEY_LAST }, /* Recall (last channel */
- { 0x22, KEY_PREVIOUS },
- { 0x23, KEY_PLAYPAUSE },
- { 0x24, KEY_NEXT },
- { 0x25, KEY_TIME }, /* Time Shifting */
- { 0x26, KEY_STOP },
- { 0x27, KEY_RECORD },
- { 0x28, KEY_SAVE }, /* Screenshot */
- { 0x2f, KEY_MENU },
- { 0x30, KEY_CANCEL },
- { 0x31, KEY_CHANNEL }, /* Channel Surf */
- { 0x32, KEY_SUBTITLE },
- { 0x33, KEY_LANGUAGE },
- { 0x34, KEY_REWIND },
- { 0x35, KEY_FASTFORWARD },
- { 0x36, KEY_TV },
- { 0x37, KEY_RADIO }, /* FM */
- { 0x38, KEY_DVD },
-
- { 0x1a, KEY_MODE}, /* change to MCE mode on Y04G0051 */
- { 0x3e, KEY_F21 }, /* MCE +VOL, on Y04G0033 */
- { 0x3a, KEY_F22 }, /* MCE -VOL, on Y04G0033 */
- { 0x3b, KEY_F23 }, /* MCE +CH, on Y04G0033 */
- { 0x3f, KEY_F24 } /* MCE -CH, on Y04G0033 */
-};
-DEFINE_LEGACY_IR_KEYTABLE(winfast);
-
-static struct ir_scancode pinnacle_color[] = {
- { 0x59, KEY_MUTE },
- { 0x4a, KEY_POWER },
-
- { 0x18, KEY_TEXT },
- { 0x26, KEY_TV },
- { 0x3d, KEY_PRINT },
-
- { 0x48, KEY_RED },
- { 0x04, KEY_GREEN },
- { 0x11, KEY_YELLOW },
- { 0x00, KEY_BLUE },
-
- { 0x2d, KEY_VOLUMEUP },
- { 0x1e, KEY_VOLUMEDOWN },
-
- { 0x49, KEY_MENU },
-
- { 0x16, KEY_CHANNELUP },
- { 0x17, KEY_CHANNELDOWN },
-
- { 0x20, KEY_UP },
- { 0x21, KEY_DOWN },
- { 0x22, KEY_LEFT },
- { 0x23, KEY_RIGHT },
- { 0x0d, KEY_SELECT },
-
- { 0x08, KEY_BACK },
- { 0x07, KEY_REFRESH },
-
- { 0x2f, KEY_ZOOM },
- { 0x29, KEY_RECORD },
-
- { 0x4b, KEY_PAUSE },
- { 0x4d, KEY_REWIND },
- { 0x2e, KEY_PLAY },
- { 0x4e, KEY_FORWARD },
- { 0x53, KEY_PREVIOUS },
- { 0x4c, KEY_STOP },
- { 0x54, KEY_NEXT },
-
- { 0x69, KEY_0 },
- { 0x6a, KEY_1 },
- { 0x6b, KEY_2 },
- { 0x6c, KEY_3 },
- { 0x6d, KEY_4 },
- { 0x6e, KEY_5 },
- { 0x6f, KEY_6 },
- { 0x70, KEY_7 },
- { 0x71, KEY_8 },
- { 0x72, KEY_9 },
-
- { 0x74, KEY_CHANNEL },
- { 0x0a, KEY_BACKSPACE },
-};
-DEFINE_LEGACY_IR_KEYTABLE(pinnacle_color);
-
-/* Hauppauge: the newer, gray remotes (seems there are multiple
- * slightly different versions), shipped with cx88+ivtv cards.
- * almost rc5 coding, but some non-standard keys */
-static struct ir_scancode hauppauge_new[] = {
- /* Keys 0 to 9 */
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- { 0x0a, KEY_TEXT }, /* keypad asterisk as well */
- { 0x0b, KEY_RED }, /* red button */
- { 0x0c, KEY_RADIO },
- { 0x0d, KEY_MENU },
- { 0x0e, KEY_SUBTITLE }, /* also the # key */
- { 0x0f, KEY_MUTE },
- { 0x10, KEY_VOLUMEUP },
- { 0x11, KEY_VOLUMEDOWN },
- { 0x12, KEY_PREVIOUS }, /* previous channel */
- { 0x14, KEY_UP },
- { 0x15, KEY_DOWN },
- { 0x16, KEY_LEFT },
- { 0x17, KEY_RIGHT },
- { 0x18, KEY_VIDEO }, /* Videos */
- { 0x19, KEY_AUDIO }, /* Music */
- /* 0x1a: Pictures - presume this means
- "Multimedia Home Platform" -
- no "PICTURES" key in input.h
- */
- { 0x1a, KEY_MHP },
-
- { 0x1b, KEY_EPG }, /* Guide */
- { 0x1c, KEY_TV },
- { 0x1e, KEY_NEXTSONG }, /* skip >| */
- { 0x1f, KEY_EXIT }, /* back/exit */
- { 0x20, KEY_CHANNELUP }, /* channel / program + */
- { 0x21, KEY_CHANNELDOWN }, /* channel / program - */
- { 0x22, KEY_CHANNEL }, /* source (old black remote) */
- { 0x24, KEY_PREVIOUSSONG }, /* replay |< */
- { 0x25, KEY_ENTER }, /* OK */
- { 0x26, KEY_SLEEP }, /* minimize (old black remote) */
- { 0x29, KEY_BLUE }, /* blue key */
- { 0x2e, KEY_GREEN }, /* green button */
- { 0x30, KEY_PAUSE }, /* pause */
- { 0x32, KEY_REWIND }, /* backward << */
- { 0x34, KEY_FASTFORWARD }, /* forward >> */
- { 0x35, KEY_PLAY },
- { 0x36, KEY_STOP },
- { 0x37, KEY_RECORD }, /* recording */
- { 0x38, KEY_YELLOW }, /* yellow key */
- { 0x3b, KEY_SELECT }, /* top right button */
- { 0x3c, KEY_ZOOM }, /* full */
- { 0x3d, KEY_POWER }, /* system power (green button) */
-};
-DEFINE_LEGACY_IR_KEYTABLE(hauppauge_new);
-
-static struct ir_scancode npgtech[] = {
- { 0x1d, KEY_SWITCHVIDEOMODE }, /* switch inputs */
- { 0x2a, KEY_FRONT },
-
- { 0x3e, KEY_1 },
- { 0x02, KEY_2 },
- { 0x06, KEY_3 },
- { 0x0a, KEY_4 },
- { 0x0e, KEY_5 },
- { 0x12, KEY_6 },
- { 0x16, KEY_7 },
- { 0x1a, KEY_8 },
- { 0x1e, KEY_9 },
- { 0x3a, KEY_0 },
- { 0x22, KEY_NUMLOCK }, /* -/-- */
- { 0x20, KEY_REFRESH },
-
- { 0x03, KEY_BRIGHTNESSDOWN },
- { 0x28, KEY_AUDIO },
- { 0x3c, KEY_CHANNELUP },
- { 0x3f, KEY_VOLUMEDOWN },
- { 0x2e, KEY_MUTE },
- { 0x3b, KEY_VOLUMEUP },
- { 0x00, KEY_CHANNELDOWN },
- { 0x07, KEY_BRIGHTNESSUP },
- { 0x2c, KEY_TEXT },
-
- { 0x37, KEY_RECORD },
- { 0x17, KEY_PLAY },
- { 0x13, KEY_PAUSE },
- { 0x26, KEY_STOP },
- { 0x18, KEY_FASTFORWARD },
- { 0x14, KEY_REWIND },
- { 0x33, KEY_ZOOM },
- { 0x32, KEY_KEYBOARD },
- { 0x30, KEY_GOTO }, /* Pointing arrow */
- { 0x36, KEY_MACRO }, /* Maximize/Minimize (yellow) */
- { 0x0b, KEY_RADIO },
- { 0x10, KEY_POWER },
-
-};
-DEFINE_LEGACY_IR_KEYTABLE(npgtech);
-
-/* Norwood Micro (non-Pro) TV Tuner
- By Peter Naulls <peter@chocky.org>
- Key comments are the functions given in the manual */
-static struct ir_scancode norwood[] = {
- /* Keys 0 to 9 */
- { 0x20, KEY_0 },
- { 0x21, KEY_1 },
- { 0x22, KEY_2 },
- { 0x23, KEY_3 },
- { 0x24, KEY_4 },
- { 0x25, KEY_5 },
- { 0x26, KEY_6 },
- { 0x27, KEY_7 },
- { 0x28, KEY_8 },
- { 0x29, KEY_9 },
-
- { 0x78, KEY_TUNER }, /* Video Source */
- { 0x2c, KEY_EXIT }, /* Open/Close software */
- { 0x2a, KEY_SELECT }, /* 2 Digit Select */
- { 0x69, KEY_AGAIN }, /* Recall */
-
- { 0x32, KEY_BRIGHTNESSUP }, /* Brightness increase */
- { 0x33, KEY_BRIGHTNESSDOWN }, /* Brightness decrease */
- { 0x6b, KEY_KPPLUS }, /* (not named >>>>>) */
- { 0x6c, KEY_KPMINUS }, /* (not named <<<<<) */
-
- { 0x2d, KEY_MUTE }, /* Mute */
- { 0x30, KEY_VOLUMEUP }, /* Volume up */
- { 0x31, KEY_VOLUMEDOWN }, /* Volume down */
- { 0x60, KEY_CHANNELUP }, /* Channel up */
- { 0x61, KEY_CHANNELDOWN }, /* Channel down */
-
- { 0x3f, KEY_RECORD }, /* Record */
- { 0x37, KEY_PLAY }, /* Play */
- { 0x36, KEY_PAUSE }, /* Pause */
- { 0x2b, KEY_STOP }, /* Stop */
- { 0x67, KEY_FASTFORWARD }, /* Foward */
- { 0x66, KEY_REWIND }, /* Rewind */
- { 0x3e, KEY_SEARCH }, /* Auto Scan */
- { 0x2e, KEY_CAMERA }, /* Capture Video */
- { 0x6d, KEY_MENU }, /* Show/Hide Control */
- { 0x2f, KEY_ZOOM }, /* Full Screen */
- { 0x34, KEY_RADIO }, /* FM */
- { 0x65, KEY_POWER }, /* Computer power */
-};
-DEFINE_LEGACY_IR_KEYTABLE(norwood);
-
-/* From reading the following remotes:
- * Zenith Universal 7 / TV Mode 807 / VCR Mode 837
- * Hauppauge (from NOVA-CI-s box product)
- * This is a "middle of the road" approach, differences are noted
- */
-static struct ir_scancode budget_ci_old[] = {
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
- { 0x0a, KEY_ENTER },
- { 0x0b, KEY_RED },
- { 0x0c, KEY_POWER }, /* RADIO on Hauppauge */
- { 0x0d, KEY_MUTE },
- { 0x0f, KEY_A }, /* TV on Hauppauge */
- { 0x10, KEY_VOLUMEUP },
- { 0x11, KEY_VOLUMEDOWN },
- { 0x14, KEY_B },
- { 0x1c, KEY_UP },
- { 0x1d, KEY_DOWN },
- { 0x1e, KEY_OPTION }, /* RESERVED on Hauppauge */
- { 0x1f, KEY_BREAK },
- { 0x20, KEY_CHANNELUP },
- { 0x21, KEY_CHANNELDOWN },
- { 0x22, KEY_PREVIOUS }, /* Prev Ch on Zenith, SOURCE on Hauppauge */
- { 0x24, KEY_RESTART },
- { 0x25, KEY_OK },
- { 0x26, KEY_CYCLEWINDOWS }, /* MINIMIZE on Hauppauge */
- { 0x28, KEY_ENTER }, /* VCR mode on Zenith */
- { 0x29, KEY_PAUSE },
- { 0x2b, KEY_RIGHT },
- { 0x2c, KEY_LEFT },
- { 0x2e, KEY_MENU }, /* FULL SCREEN on Hauppauge */
- { 0x30, KEY_SLOW },
- { 0x31, KEY_PREVIOUS }, /* VCR mode on Zenith */
- { 0x32, KEY_REWIND },
- { 0x34, KEY_FASTFORWARD },
- { 0x35, KEY_PLAY },
- { 0x36, KEY_STOP },
- { 0x37, KEY_RECORD },
- { 0x38, KEY_TUNER }, /* TV/VCR on Zenith */
- { 0x3a, KEY_C },
- { 0x3c, KEY_EXIT },
- { 0x3d, KEY_POWER2 },
- { 0x3e, KEY_TUNER },
-};
-DEFINE_LEGACY_IR_KEYTABLE(budget_ci_old);
-
-/*
- * Marc Fargas <telenieko@telenieko.com>
- * this is the remote control that comes with the asus p7131
- * which has a label saying is "Model PC-39"
- */
-static struct ir_scancode asus_pc39[] = {
- /* Keys 0 to 9 */
- { 0x15, KEY_0 },
- { 0x29, KEY_1 },
- { 0x2d, KEY_2 },
- { 0x2b, KEY_3 },
- { 0x09, KEY_4 },
- { 0x0d, KEY_5 },
- { 0x0b, KEY_6 },
- { 0x31, KEY_7 },
- { 0x35, KEY_8 },
- { 0x33, KEY_9 },
-
- { 0x3e, KEY_RADIO }, /* radio */
- { 0x03, KEY_MENU }, /* dvd/menu */
- { 0x2a, KEY_VOLUMEUP },
- { 0x19, KEY_VOLUMEDOWN },
- { 0x37, KEY_UP },
- { 0x3b, KEY_DOWN },
- { 0x27, KEY_LEFT },
- { 0x2f, KEY_RIGHT },
- { 0x25, KEY_VIDEO }, /* video */
- { 0x39, KEY_AUDIO }, /* music */
-
- { 0x21, KEY_TV }, /* tv */
- { 0x1d, KEY_EXIT }, /* back */
- { 0x0a, KEY_CHANNELUP }, /* channel / program + */
- { 0x1b, KEY_CHANNELDOWN }, /* channel / program - */
- { 0x1a, KEY_ENTER }, /* enter */
-
- { 0x06, KEY_PAUSE }, /* play/pause */
- { 0x1e, KEY_PREVIOUS }, /* rew */
- { 0x26, KEY_NEXT }, /* forward */
- { 0x0e, KEY_REWIND }, /* backward << */
- { 0x3a, KEY_FASTFORWARD }, /* forward >> */
- { 0x36, KEY_STOP },
- { 0x2e, KEY_RECORD }, /* recording */
- { 0x16, KEY_POWER }, /* the button that reads "close" */
-
- { 0x11, KEY_ZOOM }, /* full screen */
- { 0x13, KEY_MACRO }, /* recall */
- { 0x23, KEY_HOME }, /* home */
- { 0x05, KEY_PVR }, /* picture */
- { 0x3d, KEY_MUTE }, /* mute */
- { 0x01, KEY_DVD }, /* dvd */
-};
-DEFINE_LEGACY_IR_KEYTABLE(asus_pc39);
-
-/* Encore ENLTV-FM - black plastic, white front cover with white glowing buttons
- Juan Pablo Sormani <sorman@gmail.com> */
-static struct ir_scancode encore_enltv[] = {
-
- /* Power button does nothing, neither in Windows app,
- although it sends data (used for BIOS wakeup?) */
- { 0x0d, KEY_MUTE },
-
- { 0x1e, KEY_TV },
- { 0x00, KEY_VIDEO },
- { 0x01, KEY_AUDIO }, /* music */
- { 0x02, KEY_MHP }, /* picture */
-
- { 0x1f, KEY_1 },
- { 0x03, KEY_2 },
- { 0x04, KEY_3 },
- { 0x05, KEY_4 },
- { 0x1c, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x1d, KEY_9 },
- { 0x0a, KEY_0 },
-
- { 0x09, KEY_LIST }, /* -/-- */
- { 0x0b, KEY_LAST }, /* recall */
-
- { 0x14, KEY_HOME }, /* win start menu */
- { 0x15, KEY_EXIT }, /* exit */
- { 0x16, KEY_CHANNELUP }, /* UP */
- { 0x12, KEY_CHANNELDOWN }, /* DOWN */
- { 0x0c, KEY_VOLUMEUP }, /* RIGHT */
- { 0x17, KEY_VOLUMEDOWN }, /* LEFT */
-
- { 0x18, KEY_ENTER }, /* OK */
-
- { 0x0e, KEY_ESC },
- { 0x13, KEY_CYCLEWINDOWS }, /* desktop */
- { 0x11, KEY_TAB },
- { 0x19, KEY_SWITCHVIDEOMODE }, /* switch */
-
- { 0x1a, KEY_MENU },
- { 0x1b, KEY_ZOOM }, /* fullscreen */
- { 0x44, KEY_TIME }, /* time shift */
- { 0x40, KEY_MODE }, /* source */
-
- { 0x5a, KEY_RECORD },
- { 0x42, KEY_PLAY }, /* play/pause */
- { 0x45, KEY_STOP },
- { 0x43, KEY_CAMERA }, /* camera icon */
-
- { 0x48, KEY_REWIND },
- { 0x4a, KEY_FASTFORWARD },
- { 0x49, KEY_PREVIOUS },
- { 0x4b, KEY_NEXT },
-
- { 0x4c, KEY_FAVORITES }, /* tv wall */
- { 0x4d, KEY_SOUND }, /* DVD sound */
- { 0x4e, KEY_LANGUAGE }, /* DVD lang */
- { 0x4f, KEY_TEXT }, /* DVD text */
-
- { 0x50, KEY_SLEEP }, /* shutdown */
- { 0x51, KEY_MODE }, /* stereo > main */
- { 0x52, KEY_SELECT }, /* stereo > sap */
- { 0x53, KEY_PROG1 }, /* teletext */
-
-
- { 0x59, KEY_RED }, /* AP1 */
- { 0x41, KEY_GREEN }, /* AP2 */
- { 0x47, KEY_YELLOW }, /* AP3 */
- { 0x57, KEY_BLUE }, /* AP4 */
-};
-DEFINE_LEGACY_IR_KEYTABLE(encore_enltv);
-
-/* Encore ENLTV2-FM - silver plastic - "Wand Media" written at the botton
- Mauro Carvalho Chehab <mchehab@infradead.org> */
-static struct ir_scancode encore_enltv2[] = {
- { 0x4c, KEY_POWER2 },
- { 0x4a, KEY_TUNER },
- { 0x40, KEY_1 },
- { 0x60, KEY_2 },
- { 0x50, KEY_3 },
- { 0x70, KEY_4 },
- { 0x48, KEY_5 },
- { 0x68, KEY_6 },
- { 0x58, KEY_7 },
- { 0x78, KEY_8 },
- { 0x44, KEY_9 },
- { 0x54, KEY_0 },
-
- { 0x64, KEY_LAST }, /* +100 */
- { 0x4e, KEY_AGAIN }, /* Recall */
-
- { 0x6c, KEY_SWITCHVIDEOMODE }, /* Video Source */
- { 0x5e, KEY_MENU },
- { 0x56, KEY_SCREEN },
- { 0x7a, KEY_SETUP },
-
- { 0x46, KEY_MUTE },
- { 0x5c, KEY_MODE }, /* Stereo */
- { 0x74, KEY_INFO },
- { 0x7c, KEY_CLEAR },
-
- { 0x55, KEY_UP },
- { 0x49, KEY_DOWN },
- { 0x7e, KEY_LEFT },
- { 0x59, KEY_RIGHT },
- { 0x6a, KEY_ENTER },
-
- { 0x42, KEY_VOLUMEUP },
- { 0x62, KEY_VOLUMEDOWN },
- { 0x52, KEY_CHANNELUP },
- { 0x72, KEY_CHANNELDOWN },
-
- { 0x41, KEY_RECORD },
- { 0x51, KEY_CAMERA }, /* Snapshot */
- { 0x75, KEY_TIME }, /* Timeshift */
- { 0x71, KEY_TV2 }, /* PIP */
-
- { 0x45, KEY_REWIND },
- { 0x6f, KEY_PAUSE },
- { 0x7d, KEY_FORWARD },
- { 0x79, KEY_STOP },
-};
-DEFINE_LEGACY_IR_KEYTABLE(encore_enltv2);
-
-/* for the Technotrend 1500 bundled remotes (grey and black): */
-static struct ir_scancode tt_1500[] = {
- { 0x01, KEY_POWER },
- { 0x02, KEY_SHUFFLE }, /* ? double-arrow key */
- { 0x03, KEY_1 },
- { 0x04, KEY_2 },
- { 0x05, KEY_3 },
- { 0x06, KEY_4 },
- { 0x07, KEY_5 },
- { 0x08, KEY_6 },
- { 0x09, KEY_7 },
- { 0x0a, KEY_8 },
- { 0x0b, KEY_9 },
- { 0x0c, KEY_0 },
- { 0x0d, KEY_UP },
- { 0x0e, KEY_LEFT },
- { 0x0f, KEY_OK },
- { 0x10, KEY_RIGHT },
- { 0x11, KEY_DOWN },
- { 0x12, KEY_INFO },
- { 0x13, KEY_EXIT },
- { 0x14, KEY_RED },
- { 0x15, KEY_GREEN },
- { 0x16, KEY_YELLOW },
- { 0x17, KEY_BLUE },
- { 0x18, KEY_MUTE },
- { 0x19, KEY_TEXT },
- { 0x1a, KEY_MODE }, /* ? TV/Radio */
- { 0x21, KEY_OPTION },
- { 0x22, KEY_EPG },
- { 0x23, KEY_CHANNELUP },
- { 0x24, KEY_CHANNELDOWN },
- { 0x25, KEY_VOLUMEUP },
- { 0x26, KEY_VOLUMEDOWN },
- { 0x27, KEY_SETUP },
- { 0x3a, KEY_RECORD }, /* these keys are only in the black remote */
- { 0x3b, KEY_PLAY },
- { 0x3c, KEY_STOP },
- { 0x3d, KEY_REWIND },
- { 0x3e, KEY_PAUSE },
- { 0x3f, KEY_FORWARD },
-};
-DEFINE_LEGACY_IR_KEYTABLE(tt_1500);
-
-/* DViCO FUSION HDTV MCE remote */
-static struct ir_scancode fusionhdtv_mce[] = {
-
- { 0x0b, KEY_1 },
- { 0x17, KEY_2 },
- { 0x1b, KEY_3 },
- { 0x07, KEY_4 },
- { 0x50, KEY_5 },
- { 0x54, KEY_6 },
- { 0x48, KEY_7 },
- { 0x4c, KEY_8 },
- { 0x58, KEY_9 },
- { 0x03, KEY_0 },
-
- { 0x5e, KEY_OK },
- { 0x51, KEY_UP },
- { 0x53, KEY_DOWN },
- { 0x5b, KEY_LEFT },
- { 0x5f, KEY_RIGHT },
-
- { 0x02, KEY_TV }, /* Labeled DTV on remote */
- { 0x0e, KEY_MP3 },
- { 0x1a, KEY_DVD },
- { 0x1e, KEY_FAVORITES }, /* Labeled CPF on remote */
- { 0x16, KEY_SETUP },
- { 0x46, KEY_POWER2 }, /* TV On/Off button on remote */
- { 0x0a, KEY_EPG }, /* Labeled Guide on remote */
-
- { 0x49, KEY_BACK },
- { 0x59, KEY_INFO }, /* Labeled MORE on remote */
- { 0x4d, KEY_MENU }, /* Labeled DVDMENU on remote */
- { 0x55, KEY_CYCLEWINDOWS }, /* Labeled ALT-TAB on remote */
-
- { 0x0f, KEY_PREVIOUSSONG }, /* Labeled |<< REPLAY on remote */
- { 0x12, KEY_NEXTSONG }, /* Labeled >>| SKIP on remote */
- { 0x42, KEY_ENTER }, /* Labeled START with a green
- MS windows logo on remote */
-
- { 0x15, KEY_VOLUMEUP },
- { 0x05, KEY_VOLUMEDOWN },
- { 0x11, KEY_CHANNELUP },
- { 0x09, KEY_CHANNELDOWN },
-
- { 0x52, KEY_CAMERA },
- { 0x5a, KEY_TUNER },
- { 0x19, KEY_OPEN },
-
- { 0x13, KEY_MODE }, /* 4:3 16:9 select */
- { 0x1f, KEY_ZOOM },
-
- { 0x43, KEY_REWIND },
- { 0x47, KEY_PLAYPAUSE },
- { 0x4f, KEY_FASTFORWARD },
- { 0x57, KEY_MUTE },
- { 0x0d, KEY_STOP },
- { 0x01, KEY_RECORD },
- { 0x4e, KEY_POWER },
-};
-DEFINE_LEGACY_IR_KEYTABLE(fusionhdtv_mce);
-
-/* Pinnacle PCTV HD 800i mini remote */
-static struct ir_scancode pinnacle_pctv_hd[] = {
-
- { 0x0f, KEY_1 },
- { 0x15, KEY_2 },
- { 0x10, KEY_3 },
- { 0x18, KEY_4 },
- { 0x1b, KEY_5 },
- { 0x1e, KEY_6 },
- { 0x11, KEY_7 },
- { 0x21, KEY_8 },
- { 0x12, KEY_9 },
- { 0x27, KEY_0 },
-
- { 0x24, KEY_ZOOM },
- { 0x2a, KEY_SUBTITLE },
-
- { 0x00, KEY_MUTE },
- { 0x01, KEY_ENTER }, /* Pinnacle Logo */
- { 0x39, KEY_POWER },
-
- { 0x03, KEY_VOLUMEUP },
- { 0x09, KEY_VOLUMEDOWN },
- { 0x06, KEY_CHANNELUP },
- { 0x0c, KEY_CHANNELDOWN },
-
- { 0x2d, KEY_REWIND },
- { 0x30, KEY_PLAYPAUSE },
- { 0x33, KEY_FASTFORWARD },
- { 0x3c, KEY_STOP },
- { 0x36, KEY_RECORD },
- { 0x3f, KEY_EPG }, /* Labeled "?" */
-};
-DEFINE_LEGACY_IR_KEYTABLE(pinnacle_pctv_hd);
-
-/*
- * Igor Kuznetsov <igk72@ya.ru>
- * Andrey J. Melnikov <temnota@kmv.ru>
- *
- * Keytable is used by BeholdTV 60x series, M6 series at
- * least, and probably other cards too.
- * The "ascii-art picture" below (in comments, first row
- * is the keycode in hex, and subsequent row(s) shows
- * the button labels (several variants when appropriate)
- * helps to descide which keycodes to assign to the buttons.
- */
-static struct ir_scancode behold[] = {
-
- /* 0x1c 0x12 *
- * TV/FM POWER *
- * */
- { 0x1c, KEY_TUNER }, /* XXX KEY_TV / KEY_RADIO */
- { 0x12, KEY_POWER },
-
- /* 0x01 0x02 0x03 *
- * 1 2 3 *
- * *
- * 0x04 0x05 0x06 *
- * 4 5 6 *
- * *
- * 0x07 0x08 0x09 *
- * 7 8 9 *
- * */
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
-
- /* 0x0a 0x00 0x17 *
- * RECALL 0 MODE *
- * */
- { 0x0a, KEY_AGAIN },
- { 0x00, KEY_0 },
- { 0x17, KEY_MODE },
-
- /* 0x14 0x10 *
- * ASPECT FULLSCREEN *
- * */
- { 0x14, KEY_SCREEN },
- { 0x10, KEY_ZOOM },
-
- /* 0x0b *
- * Up *
- * *
- * 0x18 0x16 0x0c *
- * Left Ok Right *
- * *
- * 0x015 *
- * Down *
- * */
- { 0x0b, KEY_CHANNELUP },
- { 0x18, KEY_VOLUMEDOWN },
- { 0x16, KEY_OK }, /* XXX KEY_ENTER */
- { 0x0c, KEY_VOLUMEUP },
- { 0x15, KEY_CHANNELDOWN },
-
- /* 0x11 0x0d *
- * MUTE INFO *
- * */
- { 0x11, KEY_MUTE },
- { 0x0d, KEY_INFO },
-
- /* 0x0f 0x1b 0x1a *
- * RECORD PLAY/PAUSE STOP *
- * *
- * 0x0e 0x1f 0x1e *
- *TELETEXT AUDIO SOURCE *
- * RED YELLOW *
- * */
- { 0x0f, KEY_RECORD },
- { 0x1b, KEY_PLAYPAUSE },
- { 0x1a, KEY_STOP },
- { 0x0e, KEY_TEXT },
- { 0x1f, KEY_RED }, /*XXX KEY_AUDIO */
- { 0x1e, KEY_YELLOW }, /*XXX KEY_SOURCE */
-
- /* 0x1d 0x13 0x19 *
- * SLEEP PREVIEW DVB *
- * GREEN BLUE *
- * */
- { 0x1d, KEY_SLEEP },
- { 0x13, KEY_GREEN },
- { 0x19, KEY_BLUE }, /* XXX KEY_SAT */
-
- /* 0x58 0x5c *
- * FREEZE SNAPSHOT *
- * */
- { 0x58, KEY_SLOW },
- { 0x5c, KEY_CAMERA },
-
-};
-DEFINE_LEGACY_IR_KEYTABLE(behold);
-
-/* Beholder Intl. Ltd. 2008
- * Dmitry Belimov d.belimov@google.com
- * Keytable is used by BeholdTV Columbus
- * The "ascii-art picture" below (in comments, first row
- * is the keycode in hex, and subsequent row(s) shows
- * the button labels (several variants when appropriate)
- * helps to descide which keycodes to assign to the buttons.
- */
-static struct ir_scancode behold_columbus[] = {
-
- /* 0x13 0x11 0x1C 0x12 *
- * Mute Source TV/FM Power *
- * */
-
- { 0x13, KEY_MUTE },
- { 0x11, KEY_PROPS },
- { 0x1C, KEY_TUNER }, /* KEY_TV/KEY_RADIO */
- { 0x12, KEY_POWER },
-
- /* 0x01 0x02 0x03 0x0D *
- * 1 2 3 Stereo *
- * *
- * 0x04 0x05 0x06 0x19 *
- * 4 5 6 Snapshot *
- * *
- * 0x07 0x08 0x09 0x10 *
- * 7 8 9 Zoom *
- * */
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x0D, KEY_SETUP }, /* Setup key */
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x19, KEY_CAMERA }, /* Snapshot key */
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
- { 0x10, KEY_ZOOM },
-
- /* 0x0A 0x00 0x0B 0x0C *
- * RECALL 0 ChannelUp VolumeUp *
- * */
- { 0x0A, KEY_AGAIN },
- { 0x00, KEY_0 },
- { 0x0B, KEY_CHANNELUP },
- { 0x0C, KEY_VOLUMEUP },
-
- /* 0x1B 0x1D 0x15 0x18 *
- * Timeshift Record ChannelDown VolumeDown *
- * */
-
- { 0x1B, KEY_TIME },
- { 0x1D, KEY_RECORD },
- { 0x15, KEY_CHANNELDOWN },
- { 0x18, KEY_VOLUMEDOWN },
-
- /* 0x0E 0x1E 0x0F 0x1A *
- * Stop Pause Previouse Next *
- * */
-
- { 0x0E, KEY_STOP },
- { 0x1E, KEY_PAUSE },
- { 0x0F, KEY_PREVIOUS },
- { 0x1A, KEY_NEXT },
-
-};
-DEFINE_LEGACY_IR_KEYTABLE(behold_columbus);
-
-/*
- * Remote control for the Genius TVGO A11MCE
- * Adrian Pardini <pardo.bsso@gmail.com>
- */
-static struct ir_scancode genius_tvgo_a11mce[] = {
- /* Keys 0 to 9 */
- { 0x48, KEY_0 },
- { 0x09, KEY_1 },
- { 0x1d, KEY_2 },
- { 0x1f, KEY_3 },
- { 0x19, KEY_4 },
- { 0x1b, KEY_5 },
- { 0x11, KEY_6 },
- { 0x17, KEY_7 },
- { 0x12, KEY_8 },
- { 0x16, KEY_9 },
-
- { 0x54, KEY_RECORD }, /* recording */
- { 0x06, KEY_MUTE }, /* mute */
- { 0x10, KEY_POWER },
- { 0x40, KEY_LAST }, /* recall */
- { 0x4c, KEY_CHANNELUP }, /* channel / program + */
- { 0x00, KEY_CHANNELDOWN }, /* channel / program - */
- { 0x0d, KEY_VOLUMEUP },
- { 0x15, KEY_VOLUMEDOWN },
- { 0x4d, KEY_OK }, /* also labeled as Pause */
- { 0x1c, KEY_ZOOM }, /* full screen and Stop*/
- { 0x02, KEY_MODE }, /* AV Source or Rewind*/
- { 0x04, KEY_LIST }, /* -/-- */
- /* small arrows above numbers */
- { 0x1a, KEY_NEXT }, /* also Fast Forward */
- { 0x0e, KEY_PREVIOUS }, /* also Rewind */
- /* these are in a rather non standard layout and have
- an alternate name written */
- { 0x1e, KEY_UP }, /* Video Setting */
- { 0x0a, KEY_DOWN }, /* Video Default */
- { 0x05, KEY_CAMERA }, /* Snapshot */
- { 0x0c, KEY_RIGHT }, /* Hide Panel */
- /* Four buttons without label */
- { 0x49, KEY_RED },
- { 0x0b, KEY_GREEN },
- { 0x13, KEY_YELLOW },
- { 0x50, KEY_BLUE },
-};
-DEFINE_LEGACY_IR_KEYTABLE(genius_tvgo_a11mce);
-
-/*
- * Remote control for Powercolor Real Angel 330
- * Daniel Fraga <fragabr@gmail.com>
- */
-static struct ir_scancode powercolor_real_angel[] = {
- { 0x38, KEY_SWITCHVIDEOMODE }, /* switch inputs */
- { 0x0c, KEY_MEDIA }, /* Turn ON/OFF App */
- { 0x00, KEY_0 },
- { 0x01, KEY_1 },
- { 0x02, KEY_2 },
- { 0x03, KEY_3 },
- { 0x04, KEY_4 },
- { 0x05, KEY_5 },
- { 0x06, KEY_6 },
- { 0x07, KEY_7 },
- { 0x08, KEY_8 },
- { 0x09, KEY_9 },
- { 0x0a, KEY_DIGITS }, /* single, double, tripple digit */
- { 0x29, KEY_PREVIOUS }, /* previous channel */
- { 0x12, KEY_BRIGHTNESSUP },
- { 0x13, KEY_BRIGHTNESSDOWN },
- { 0x2b, KEY_MODE }, /* stereo/mono */
- { 0x2c, KEY_TEXT }, /* teletext */
- { 0x20, KEY_CHANNELUP }, /* channel up */
- { 0x21, KEY_CHANNELDOWN }, /* channel down */
- { 0x10, KEY_VOLUMEUP }, /* volume up */
- { 0x11, KEY_VOLUMEDOWN }, /* volume down */
- { 0x0d, KEY_MUTE },
- { 0x1f, KEY_RECORD },
- { 0x17, KEY_PLAY },
- { 0x16, KEY_PAUSE },
- { 0x0b, KEY_STOP },
- { 0x27, KEY_FASTFORWARD },
- { 0x26, KEY_REWIND },
- { 0x1e, KEY_SEARCH }, /* autoscan */
- { 0x0e, KEY_CAMERA }, /* snapshot */
- { 0x2d, KEY_SETUP },
- { 0x0f, KEY_SCREEN }, /* full screen */
- { 0x14, KEY_RADIO }, /* FM radio */
- { 0x25, KEY_POWER }, /* power */
-};
-DEFINE_LEGACY_IR_KEYTABLE(powercolor_real_angel);
-
-/* Kworld Plus TV Analog Lite PCI IR
- Mauro Carvalho Chehab <mchehab@infradead.org>
- */
-static struct ir_scancode kworld_plus_tv_analog[] = {
- { 0x0c, KEY_PROG1 }, /* Kworld key */
- { 0x16, KEY_CLOSECD }, /* -> ) */
- { 0x1d, KEY_POWER2 },
-
- { 0x00, KEY_1 },
- { 0x01, KEY_2 },
- { 0x02, KEY_3 }, /* Two keys have the same code: 3 and left */
- { 0x03, KEY_4 }, /* Two keys have the same code: 3 and right */
- { 0x04, KEY_5 },
- { 0x05, KEY_6 },
- { 0x06, KEY_7 },
- { 0x07, KEY_8 },
- { 0x08, KEY_9 },
- { 0x0a, KEY_0 },
-
- { 0x09, KEY_AGAIN },
- { 0x14, KEY_MUTE },
-
- { 0x20, KEY_UP },
- { 0x21, KEY_DOWN },
- { 0x0b, KEY_ENTER },
-
- { 0x10, KEY_CHANNELUP },
- { 0x11, KEY_CHANNELDOWN },
-
- /* Couldn't map key left/key right since those
- conflict with '3' and '4' scancodes
- I dunno what the original driver does
- */
-
- { 0x13, KEY_VOLUMEUP },
- { 0x12, KEY_VOLUMEDOWN },
-
- /* The lower part of the IR
- There are several duplicated keycodes there.
- Most of them conflict with digits.
- Add mappings just to the unused scancodes.
- Somehow, the original driver has a way to know,
- but this doesn't seem to be on some GPIO.
- Also, it is not related to the time between keyup
- and keydown.
- */
- { 0x19, KEY_TIME}, /* Timeshift */
- { 0x1a, KEY_STOP},
- { 0x1b, KEY_RECORD},
-
- { 0x22, KEY_TEXT},
-
- { 0x15, KEY_AUDIO}, /* ((*)) */
- { 0x0f, KEY_ZOOM},
- { 0x1c, KEY_CAMERA}, /* snapshot */
-
- { 0x18, KEY_RED}, /* B */
- { 0x23, KEY_GREEN}, /* C */
-};
-DEFINE_LEGACY_IR_KEYTABLE(kworld_plus_tv_analog);
-
-/* Kaiomy TVnPC U2
- Mauro Carvalho Chehab <mchehab@infradead.org>
- */
-static struct ir_scancode kaiomy[] = {
- { 0x43, KEY_POWER2},
- { 0x01, KEY_LIST},
- { 0x0b, KEY_ZOOM},
- { 0x03, KEY_POWER},
-
- { 0x04, KEY_1},
- { 0x08, KEY_2},
- { 0x02, KEY_3},
-
- { 0x0f, KEY_4},
- { 0x05, KEY_5},
- { 0x06, KEY_6},
-
- { 0x0c, KEY_7},
- { 0x0d, KEY_8},
- { 0x0a, KEY_9},
-
- { 0x11, KEY_0},
-
- { 0x09, KEY_CHANNELUP},
- { 0x07, KEY_CHANNELDOWN},
-
- { 0x0e, KEY_VOLUMEUP},
- { 0x13, KEY_VOLUMEDOWN},
-
- { 0x10, KEY_HOME},
- { 0x12, KEY_ENTER},
-
- { 0x14, KEY_RECORD},
- { 0x15, KEY_STOP},
- { 0x16, KEY_PLAY},
- { 0x17, KEY_MUTE},
-
- { 0x18, KEY_UP},
- { 0x19, KEY_DOWN},
- { 0x1a, KEY_LEFT},
- { 0x1b, KEY_RIGHT},
-
- { 0x1c, KEY_RED},
- { 0x1d, KEY_GREEN},
- { 0x1e, KEY_YELLOW},
- { 0x1f, KEY_BLUE},
-};
-DEFINE_LEGACY_IR_KEYTABLE(kaiomy);
-
-static struct ir_scancode avermedia_a16d[] = {
- { 0x20, KEY_LIST},
- { 0x00, KEY_POWER},
- { 0x28, KEY_1},
- { 0x18, KEY_2},
- { 0x38, KEY_3},
- { 0x24, KEY_4},
- { 0x14, KEY_5},
- { 0x34, KEY_6},
- { 0x2c, KEY_7},
- { 0x1c, KEY_8},
- { 0x3c, KEY_9},
- { 0x12, KEY_SUBTITLE},
- { 0x22, KEY_0},
- { 0x32, KEY_REWIND},
- { 0x3a, KEY_SHUFFLE},
- { 0x02, KEY_PRINT},
- { 0x11, KEY_CHANNELDOWN},
- { 0x31, KEY_CHANNELUP},
- { 0x0c, KEY_ZOOM},
- { 0x1e, KEY_VOLUMEDOWN},
- { 0x3e, KEY_VOLUMEUP},
- { 0x0a, KEY_MUTE},
- { 0x04, KEY_AUDIO},
- { 0x26, KEY_RECORD},
- { 0x06, KEY_PLAY},
- { 0x36, KEY_STOP},
- { 0x16, KEY_PAUSE},
- { 0x2e, KEY_REWIND},
- { 0x0e, KEY_FASTFORWARD},
- { 0x30, KEY_TEXT},
- { 0x21, KEY_GREEN},
- { 0x01, KEY_BLUE},
- { 0x08, KEY_EPG},
- { 0x2a, KEY_MENU},
-};
-DEFINE_LEGACY_IR_KEYTABLE(avermedia_a16d);
-
-/* Encore ENLTV-FM v5.3
- Mauro Carvalho Chehab <mchehab@infradead.org>
- */
-static struct ir_scancode encore_enltv_fm53[] = {
- { 0x10, KEY_POWER2},
- { 0x06, KEY_MUTE},
-
- { 0x09, KEY_1},
- { 0x1d, KEY_2},
- { 0x1f, KEY_3},
- { 0x19, KEY_4},
- { 0x1b, KEY_5},
- { 0x11, KEY_6},
- { 0x17, KEY_7},
- { 0x12, KEY_8},
- { 0x16, KEY_9},
- { 0x48, KEY_0},
-
- { 0x04, KEY_LIST}, /* -/-- */
- { 0x40, KEY_LAST}, /* recall */
-
- { 0x02, KEY_MODE}, /* TV/AV */
- { 0x05, KEY_CAMERA}, /* SNAPSHOT */
-
- { 0x4c, KEY_CHANNELUP}, /* UP */
- { 0x00, KEY_CHANNELDOWN}, /* DOWN */
- { 0x0d, KEY_VOLUMEUP}, /* RIGHT */
- { 0x15, KEY_VOLUMEDOWN}, /* LEFT */
- { 0x49, KEY_ENTER}, /* OK */
-
- { 0x54, KEY_RECORD},
- { 0x4d, KEY_PLAY}, /* pause */
-
- { 0x1e, KEY_MENU}, /* video setting */
- { 0x0e, KEY_RIGHT}, /* <- */
- { 0x1a, KEY_LEFT}, /* -> */
-
- { 0x0a, KEY_CLEAR}, /* video default */
- { 0x0c, KEY_ZOOM}, /* hide pannel */
- { 0x47, KEY_SLEEP}, /* shutdown */
-};
-DEFINE_LEGACY_IR_KEYTABLE(encore_enltv_fm53);
-
-/* Zogis Real Audio 220 - 32 keys IR */
-static struct ir_scancode real_audio_220_32_keys[] = {
- { 0x1c, KEY_RADIO},
- { 0x12, KEY_POWER2},
-
- { 0x01, KEY_1},
- { 0x02, KEY_2},
- { 0x03, KEY_3},
- { 0x04, KEY_4},
- { 0x05, KEY_5},
- { 0x06, KEY_6},
- { 0x07, KEY_7},
- { 0x08, KEY_8},
- { 0x09, KEY_9},
- { 0x00, KEY_0},
-
- { 0x0c, KEY_VOLUMEUP},
- { 0x18, KEY_VOLUMEDOWN},
- { 0x0b, KEY_CHANNELUP},
- { 0x15, KEY_CHANNELDOWN},
- { 0x16, KEY_ENTER},
-
- { 0x11, KEY_LIST}, /* Source */
- { 0x0d, KEY_AUDIO}, /* stereo */
-
- { 0x0f, KEY_PREVIOUS}, /* Prev */
- { 0x1b, KEY_TIME}, /* Timeshift */
- { 0x1a, KEY_NEXT}, /* Next */
-
- { 0x0e, KEY_STOP},
- { 0x1f, KEY_PLAY},
- { 0x1e, KEY_PLAYPAUSE}, /* Pause */
-
- { 0x1d, KEY_RECORD},
- { 0x13, KEY_MUTE},
- { 0x19, KEY_CAMERA}, /* Snapshot */
-
-};
-DEFINE_LEGACY_IR_KEYTABLE(real_audio_220_32_keys);
-
-/* ATI TV Wonder HD 600 USB
- Devin Heitmueller <devin.heitmueller@gmail.com>
- */
-static struct ir_scancode ati_tv_wonder_hd_600[] = {
- { 0x00, KEY_RECORD}, /* Row 1 */
- { 0x01, KEY_PLAYPAUSE},
- { 0x02, KEY_STOP},
- { 0x03, KEY_POWER},
- { 0x04, KEY_PREVIOUS}, /* Row 2 */
- { 0x05, KEY_REWIND},
- { 0x06, KEY_FORWARD},
- { 0x07, KEY_NEXT},
- { 0x08, KEY_EPG}, /* Row 3 */
- { 0x09, KEY_HOME},
- { 0x0a, KEY_MENU},
- { 0x0b, KEY_CHANNELUP},
- { 0x0c, KEY_BACK}, /* Row 4 */
- { 0x0d, KEY_UP},
- { 0x0e, KEY_INFO},
- { 0x0f, KEY_CHANNELDOWN},
- { 0x10, KEY_LEFT}, /* Row 5 */
- { 0x11, KEY_SELECT},
- { 0x12, KEY_RIGHT},
- { 0x13, KEY_VOLUMEUP},
- { 0x14, KEY_LAST}, /* Row 6 */
- { 0x15, KEY_DOWN},
- { 0x16, KEY_MUTE},
- { 0x17, KEY_VOLUMEDOWN},
-};
-DEFINE_LEGACY_IR_KEYTABLE(ati_tv_wonder_hd_600);
-
-/* DVBWorld remotes
- Igor M. Liplianin <liplianin@me.by>
- */
-static struct ir_scancode dm1105_nec[] = {
- { 0x0a, KEY_POWER2}, /* power */
- { 0x0c, KEY_MUTE}, /* mute */
- { 0x11, KEY_1},
- { 0x12, KEY_2},
- { 0x13, KEY_3},
- { 0x14, KEY_4},
- { 0x15, KEY_5},
- { 0x16, KEY_6},
- { 0x17, KEY_7},
- { 0x18, KEY_8},
- { 0x19, KEY_9},
- { 0x10, KEY_0},
- { 0x1c, KEY_CHANNELUP}, /* ch+ */
- { 0x0f, KEY_CHANNELDOWN}, /* ch- */
- { 0x1a, KEY_VOLUMEUP}, /* vol+ */
- { 0x0e, KEY_VOLUMEDOWN}, /* vol- */
- { 0x04, KEY_RECORD}, /* rec */
- { 0x09, KEY_CHANNEL}, /* fav */
- { 0x08, KEY_BACKSPACE}, /* rewind */
- { 0x07, KEY_FASTFORWARD}, /* fast */
- { 0x0b, KEY_PAUSE}, /* pause */
- { 0x02, KEY_ESC}, /* cancel */
- { 0x03, KEY_TAB}, /* tab */
- { 0x00, KEY_UP}, /* up */
- { 0x1f, KEY_ENTER}, /* ok */
- { 0x01, KEY_DOWN}, /* down */
- { 0x05, KEY_RECORD}, /* cap */
- { 0x06, KEY_STOP}, /* stop */
- { 0x40, KEY_ZOOM}, /* full */
- { 0x1e, KEY_TV}, /* tvmode */
- { 0x1b, KEY_B}, /* recall */
-};
-DEFINE_LEGACY_IR_KEYTABLE(dm1105_nec);
-
-static struct ir_scancode tevii_nec[] = {
- { 0x0a, KEY_POWER2},
- { 0x0c, KEY_MUTE},
- { 0x11, KEY_1},
- { 0x12, KEY_2},
- { 0x13, KEY_3},
- { 0x14, KEY_4},
- { 0x15, KEY_5},
- { 0x16, KEY_6},
- { 0x17, KEY_7},
- { 0x18, KEY_8},
- { 0x19, KEY_9},
- { 0x10, KEY_0},
- { 0x1c, KEY_MENU},
- { 0x0f, KEY_VOLUMEDOWN},
- { 0x1a, KEY_LAST},
- { 0x0e, KEY_OPEN},
- { 0x04, KEY_RECORD},
- { 0x09, KEY_VOLUMEUP},
- { 0x08, KEY_CHANNELUP},
- { 0x07, KEY_PVR},
- { 0x0b, KEY_TIME},
- { 0x02, KEY_RIGHT},
- { 0x03, KEY_LEFT},
- { 0x00, KEY_UP},
- { 0x1f, KEY_OK},
- { 0x01, KEY_DOWN},
- { 0x05, KEY_TUNER},
- { 0x06, KEY_CHANNELDOWN},
- { 0x40, KEY_PLAYPAUSE},
- { 0x1e, KEY_REWIND},
- { 0x1b, KEY_FAVORITES},
- { 0x1d, KEY_BACK},
- { 0x4d, KEY_FASTFORWARD},
- { 0x44, KEY_EPG},
- { 0x4c, KEY_INFO},
- { 0x41, KEY_AB},
- { 0x43, KEY_AUDIO},
- { 0x45, KEY_SUBTITLE},
- { 0x4a, KEY_LIST},
- { 0x46, KEY_F1},
- { 0x47, KEY_F2},
- { 0x5e, KEY_F3},
- { 0x5c, KEY_F4},
- { 0x52, KEY_F5},
- { 0x5a, KEY_F6},
- { 0x56, KEY_MODE},
- { 0x58, KEY_SWITCHVIDEOMODE},
-};
-DEFINE_LEGACY_IR_KEYTABLE(tevii_nec);
-
-static struct ir_scancode tbs_nec[] = {
- { 0x04, KEY_POWER2}, /*power*/
- { 0x14, KEY_MUTE}, /*mute*/
- { 0x07, KEY_1},
- { 0x06, KEY_2},
- { 0x05, KEY_3},
- { 0x0b, KEY_4},
- { 0x0a, KEY_5},
- { 0x09, KEY_6},
- { 0x0f, KEY_7},
- { 0x0e, KEY_8},
- { 0x0d, KEY_9},
- { 0x12, KEY_0},
- { 0x16, KEY_CHANNELUP}, /*ch+*/
- { 0x11, KEY_CHANNELDOWN},/*ch-*/
- { 0x13, KEY_VOLUMEUP}, /*vol+*/
- { 0x0c, KEY_VOLUMEDOWN},/*vol-*/
- { 0x03, KEY_RECORD}, /*rec*/
- { 0x18, KEY_PAUSE}, /*pause*/
- { 0x19, KEY_OK}, /*ok*/
- { 0x1a, KEY_CAMERA}, /* snapshot */
- { 0x01, KEY_UP},
- { 0x10, KEY_LEFT},
- { 0x02, KEY_RIGHT},
- { 0x08, KEY_DOWN},
- { 0x15, KEY_FAVORITES},
- { 0x17, KEY_SUBTITLE},
- { 0x1d, KEY_ZOOM},
- { 0x1f, KEY_EXIT},
- { 0x1e, KEY_MENU},
- { 0x1c, KEY_EPG},
- { 0x00, KEY_PREVIOUS},
- { 0x1b, KEY_MODE},
-};
-DEFINE_LEGACY_IR_KEYTABLE(tbs_nec);
-
-/* Terratec Cinergy Hybrid T USB XS
- Devin Heitmueller <dheitmueller@linuxtv.org>
- */
-static struct ir_scancode terratec_cinergy_xs[] = {
- { 0x41, KEY_HOME},
- { 0x01, KEY_POWER},
- { 0x42, KEY_MENU},
- { 0x02, KEY_1},
- { 0x03, KEY_2},
- { 0x04, KEY_3},
- { 0x43, KEY_SUBTITLE},
- { 0x05, KEY_4},
- { 0x06, KEY_5},
- { 0x07, KEY_6},
- { 0x44, KEY_TEXT},
- { 0x08, KEY_7},
- { 0x09, KEY_8},
- { 0x0a, KEY_9},
- { 0x45, KEY_DELETE},
- { 0x0b, KEY_TUNER},
- { 0x0c, KEY_0},
- { 0x0d, KEY_MODE},
- { 0x46, KEY_TV},
- { 0x47, KEY_DVD},
- { 0x49, KEY_VIDEO},
- { 0x4b, KEY_AUX},
- { 0x10, KEY_UP},
- { 0x11, KEY_LEFT},
- { 0x12, KEY_OK},
- { 0x13, KEY_RIGHT},
- { 0x14, KEY_DOWN},
- { 0x0f, KEY_EPG},
- { 0x16, KEY_INFO},
- { 0x4d, KEY_BACKSPACE},
- { 0x1c, KEY_VOLUMEUP},
- { 0x4c, KEY_PLAY},
- { 0x1b, KEY_CHANNELUP},
- { 0x1e, KEY_VOLUMEDOWN},
- { 0x1d, KEY_MUTE},
- { 0x1f, KEY_CHANNELDOWN},
- { 0x17, KEY_RED},
- { 0x18, KEY_GREEN},
- { 0x19, KEY_YELLOW},
- { 0x1a, KEY_BLUE},
- { 0x58, KEY_RECORD},
- { 0x48, KEY_STOP},
- { 0x40, KEY_PAUSE},
- { 0x54, KEY_LAST},
- { 0x4e, KEY_REWIND},
- { 0x4f, KEY_FASTFORWARD},
- { 0x5c, KEY_NEXT},
-};
-DEFINE_LEGACY_IR_KEYTABLE(terratec_cinergy_xs);
-
-/* EVGA inDtube
- Devin Heitmueller <devin.heitmueller@gmail.com>
- */
-static struct ir_scancode evga_indtube[] = {
- { 0x12, KEY_POWER},
- { 0x02, KEY_MODE}, /* TV */
- { 0x14, KEY_MUTE},
- { 0x1a, KEY_CHANNELUP},
- { 0x16, KEY_TV2}, /* PIP */
- { 0x1d, KEY_VOLUMEUP},
- { 0x05, KEY_CHANNELDOWN},
- { 0x0f, KEY_PLAYPAUSE},
- { 0x19, KEY_VOLUMEDOWN},
- { 0x1c, KEY_REWIND},
- { 0x0d, KEY_RECORD},
- { 0x18, KEY_FORWARD},
- { 0x1e, KEY_PREVIOUS},
- { 0x1b, KEY_STOP},
- { 0x1f, KEY_NEXT},
- { 0x13, KEY_CAMERA},
-};
-DEFINE_LEGACY_IR_KEYTABLE(evga_indtube);
-
-static struct ir_scancode videomate_s350[] = {
- { 0x00, KEY_TV},
- { 0x01, KEY_DVD},
- { 0x04, KEY_RECORD},
- { 0x05, KEY_VIDEO}, /* TV/Video */
- { 0x07, KEY_STOP},
- { 0x08, KEY_PLAYPAUSE},
- { 0x0a, KEY_REWIND},
- { 0x0f, KEY_FASTFORWARD},
- { 0x10, KEY_CHANNELUP},
- { 0x12, KEY_VOLUMEUP},
- { 0x13, KEY_CHANNELDOWN},
- { 0x14, KEY_MUTE},
- { 0x15, KEY_VOLUMEDOWN},
- { 0x16, KEY_1},
- { 0x17, KEY_2},
- { 0x18, KEY_3},
- { 0x19, KEY_4},
- { 0x1a, KEY_5},
- { 0x1b, KEY_6},
- { 0x1c, KEY_7},
- { 0x1d, KEY_8},
- { 0x1e, KEY_9},
- { 0x1f, KEY_0},
- { 0x21, KEY_SLEEP},
- { 0x24, KEY_ZOOM},
- { 0x25, KEY_LAST}, /* Recall */
- { 0x26, KEY_SUBTITLE}, /* CC */
- { 0x27, KEY_LANGUAGE}, /* MTS */
- { 0x29, KEY_CHANNEL}, /* SURF */
- { 0x2b, KEY_A},
- { 0x2c, KEY_B},
- { 0x2f, KEY_CAMERA}, /* Snapshot */
- { 0x23, KEY_RADIO},
- { 0x02, KEY_PREVIOUSSONG},
- { 0x06, KEY_NEXTSONG},
- { 0x03, KEY_EPG},
- { 0x09, KEY_SETUP},
- { 0x22, KEY_BACKSPACE},
- { 0x0c, KEY_UP},
- { 0x0e, KEY_DOWN},
- { 0x0b, KEY_LEFT},
- { 0x0d, KEY_RIGHT},
- { 0x11, KEY_ENTER},
- { 0x20, KEY_TEXT},
-};
-DEFINE_LEGACY_IR_KEYTABLE(videomate_s350);
-
-/* GADMEI UTV330+ RM008Z remote
- Shine Liu <shinel@foxmail.com>
- */
-static struct ir_scancode gadmei_rm008z[] = {
- { 0x14, KEY_POWER2}, /* POWER OFF */
- { 0x0c, KEY_MUTE}, /* MUTE */
-
- { 0x18, KEY_TV}, /* TV */
- { 0x0e, KEY_VIDEO}, /* AV */
- { 0x0b, KEY_AUDIO}, /* SV */
- { 0x0f, KEY_RADIO}, /* FM */
-
- { 0x00, KEY_1},
- { 0x01, KEY_2},
- { 0x02, KEY_3},
- { 0x03, KEY_4},
- { 0x04, KEY_5},
- { 0x05, KEY_6},
- { 0x06, KEY_7},
- { 0x07, KEY_8},
- { 0x08, KEY_9},
- { 0x09, KEY_0},
- { 0x0a, KEY_INFO}, /* OSD */
- { 0x1c, KEY_BACKSPACE}, /* LAST */
-
- { 0x0d, KEY_PLAY}, /* PLAY */
- { 0x1e, KEY_CAMERA}, /* SNAPSHOT */
- { 0x1a, KEY_RECORD}, /* RECORD */
- { 0x17, KEY_STOP}, /* STOP */
-
- { 0x1f, KEY_UP}, /* UP */
- { 0x44, KEY_DOWN}, /* DOWN */
- { 0x46, KEY_TAB}, /* BACK */
- { 0x4a, KEY_ZOOM}, /* FULLSECREEN */
-
- { 0x10, KEY_VOLUMEUP}, /* VOLUMEUP */
- { 0x11, KEY_VOLUMEDOWN}, /* VOLUMEDOWN */
- { 0x12, KEY_CHANNELUP}, /* CHANNELUP */
- { 0x13, KEY_CHANNELDOWN}, /* CHANNELDOWN */
- { 0x15, KEY_ENTER}, /* OK */
-};
-DEFINE_LEGACY_IR_KEYTABLE(gadmei_rm008z);
-
-/*************************************************************
- * COMPLETE SCANCODE TABLES
- * Instead of just a partial scancode, the tables bellow
- * contains the complete scancode and the receiver protocol
- *************************************************************/
-
-/*
- * Hauppauge:the newer, gray remotes (seems there are multiple
- * slightly different versions), shipped with cx88+ivtv cards.
- *
- * This table contains the complete RC5 code, instead of just the data part
- */
-static struct ir_scancode rc5_hauppauge_new[] = {
- /* Keys 0 to 9 */
- { 0x1e00, KEY_0 },
- { 0x1e01, KEY_1 },
- { 0x1e02, KEY_2 },
- { 0x1e03, KEY_3 },
- { 0x1e04, KEY_4 },
- { 0x1e05, KEY_5 },
- { 0x1e06, KEY_6 },
- { 0x1e07, KEY_7 },
- { 0x1e08, KEY_8 },
- { 0x1e09, KEY_9 },
-
- { 0x1e0a, KEY_TEXT }, /* keypad asterisk as well */
- { 0x1e0b, KEY_RED }, /* red button */
- { 0x1e0c, KEY_RADIO },
- { 0x1e0d, KEY_MENU },
- { 0x1e0e, KEY_SUBTITLE }, /* also the # key */
- { 0x1e0f, KEY_MUTE },
- { 0x1e10, KEY_VOLUMEUP },
- { 0x1e11, KEY_VOLUMEDOWN },
- { 0x1e12, KEY_PREVIOUS }, /* previous channel */
- { 0x1e14, KEY_UP },
- { 0x1e15, KEY_DOWN },
- { 0x1e16, KEY_LEFT },
- { 0x1e17, KEY_RIGHT },
- { 0x1e18, KEY_VIDEO }, /* Videos */
- { 0x1e19, KEY_AUDIO }, /* Music */
- /* 0x1e1a: Pictures - presume this means
- "Multimedia Home Platform" -
- no "PICTURES" key in input.h
- */
- { 0x1e1a, KEY_MHP },
-
- { 0x1e1b, KEY_EPG }, /* Guide */
- { 0x1e1c, KEY_TV },
- { 0x1e1e, KEY_NEXTSONG }, /* skip >| */
- { 0x1e1f, KEY_EXIT }, /* back/exit */
- { 0x1e20, KEY_CHANNELUP }, /* channel / program + */
- { 0x1e21, KEY_CHANNELDOWN }, /* channel / program - */
- { 0x1e22, KEY_CHANNEL }, /* source (old black remote) */
- { 0x1e24, KEY_PREVIOUSSONG }, /* replay |< */
- { 0x1e25, KEY_ENTER }, /* OK */
- { 0x1e26, KEY_SLEEP }, /* minimize (old black remote) */
- { 0x1e29, KEY_BLUE }, /* blue key */
- { 0x1e2e, KEY_GREEN }, /* green button */
- { 0x1e30, KEY_PAUSE }, /* pause */
- { 0x1e32, KEY_REWIND }, /* backward << */
- { 0x1e34, KEY_FASTFORWARD }, /* forward >> */
- { 0x1e35, KEY_PLAY },
- { 0x1e36, KEY_STOP },
- { 0x1e37, KEY_RECORD }, /* recording */
- { 0x1e38, KEY_YELLOW }, /* yellow key */
- { 0x1e3b, KEY_SELECT }, /* top right button */
- { 0x1e3c, KEY_ZOOM }, /* full */
- { 0x1e3d, KEY_POWER }, /* system power (green button) */
-};
-DEFINE_IR_KEYTABLE(rc5_hauppauge_new, IR_TYPE_RC5);
-
-/* Terratec Cinergy Hybrid T USB XS FM
- Mauro Carvalho Chehab <mchehab@redhat.com>
- */
-static struct ir_scancode nec_terratec_cinergy_xs[] = {
- { 0x1441, KEY_HOME},
- { 0x1401, KEY_POWER2},
-
- { 0x1442, KEY_MENU}, /* DVD menu */
- { 0x1443, KEY_SUBTITLE},
- { 0x1444, KEY_TEXT}, /* Teletext */
- { 0x1445, KEY_DELETE},
-
- { 0x1402, KEY_1},
- { 0x1403, KEY_2},
- { 0x1404, KEY_3},
- { 0x1405, KEY_4},
- { 0x1406, KEY_5},
- { 0x1407, KEY_6},
- { 0x1408, KEY_7},
- { 0x1409, KEY_8},
- { 0x140a, KEY_9},
- { 0x140c, KEY_0},
-
- { 0x140b, KEY_TUNER}, /* AV */
- { 0x140d, KEY_MODE}, /* A.B */
-
- { 0x1446, KEY_TV},
- { 0x1447, KEY_DVD},
- { 0x1449, KEY_VIDEO},
- { 0x144a, KEY_RADIO}, /* Music */
- { 0x144b, KEY_CAMERA}, /* PIC */
-
- { 0x1410, KEY_UP},
- { 0x1411, KEY_LEFT},
- { 0x1412, KEY_OK},
- { 0x1413, KEY_RIGHT},
- { 0x1414, KEY_DOWN},
-
- { 0x140f, KEY_EPG},
- { 0x1416, KEY_INFO},
- { 0x144d, KEY_BACKSPACE},
-
- { 0x141c, KEY_VOLUMEUP},
- { 0x141e, KEY_VOLUMEDOWN},
-
- { 0x144c, KEY_PLAY},
- { 0x141d, KEY_MUTE},
-
- { 0x141b, KEY_CHANNELUP},
- { 0x141f, KEY_CHANNELDOWN},
-
- { 0x1417, KEY_RED},
- { 0x1418, KEY_GREEN},
- { 0x1419, KEY_YELLOW},
- { 0x141a, KEY_BLUE},
-
- { 0x1458, KEY_RECORD},
- { 0x1448, KEY_STOP},
- { 0x1440, KEY_PAUSE},
-
- { 0x1454, KEY_LAST},
- { 0x144e, KEY_REWIND},
- { 0x144f, KEY_FASTFORWARD},
- { 0x145c, KEY_NEXT},
-};
-DEFINE_IR_KEYTABLE(nec_terratec_cinergy_xs, IR_TYPE_NEC);
-
-/* Leadtek Winfast TV USB II Deluxe remote
- Magnus Alm <magnus.alm@gmail.com>
- */
-static struct ir_scancode winfast_usbii_deluxe[] = {
- { 0x62, KEY_0},
- { 0x75, KEY_1},
- { 0x76, KEY_2},
- { 0x77, KEY_3},
- { 0x79, KEY_4},
- { 0x7a, KEY_5},
- { 0x7b, KEY_6},
- { 0x7d, KEY_7},
- { 0x7e, KEY_8},
- { 0x7f, KEY_9},
-
- { 0x38, KEY_CAMERA}, /* SNAPSHOT */
- { 0x37, KEY_RECORD}, /* RECORD */
- { 0x35, KEY_TIME}, /* TIMESHIFT */
-
- { 0x74, KEY_VOLUMEUP}, /* VOLUMEUP */
- { 0x78, KEY_VOLUMEDOWN}, /* VOLUMEDOWN */
- { 0x64, KEY_MUTE}, /* MUTE */
-
- { 0x21, KEY_CHANNEL}, /* SURF */
- { 0x7c, KEY_CHANNELUP}, /* CHANNELUP */
- { 0x60, KEY_CHANNELDOWN}, /* CHANNELDOWN */
- { 0x61, KEY_LAST}, /* LAST CHANNEL (RECALL) */
-
- { 0x72, KEY_VIDEO}, /* INPUT MODES (TV/FM) */
-
- { 0x70, KEY_POWER2}, /* TV ON/OFF */
-
- { 0x39, KEY_CYCLEWINDOWS}, /* MINIMIZE (BOSS) */
- { 0x3a, KEY_NEW}, /* PIP */
- { 0x73, KEY_ZOOM}, /* FULLSECREEN */
-
- { 0x66, KEY_INFO}, /* OSD (DISPLAY) */
-
- { 0x31, KEY_DOT}, /* '.' */
- { 0x63, KEY_ENTER}, /* ENTER */
-
-};
-DEFINE_LEGACY_IR_KEYTABLE(winfast_usbii_deluxe);
-
-/* Kworld 315U
- */
-static struct ir_scancode kworld_315u[] = {
- { 0x6143, KEY_POWER },
- { 0x6101, KEY_TUNER }, /* source */
- { 0x610b, KEY_ZOOM },
- { 0x6103, KEY_POWER2 }, /* shutdown */
-
- { 0x6104, KEY_1 },
- { 0x6108, KEY_2 },
- { 0x6102, KEY_3 },
- { 0x6109, KEY_CHANNELUP },
-
- { 0x610f, KEY_4 },
- { 0x6105, KEY_5 },
- { 0x6106, KEY_6 },
- { 0x6107, KEY_CHANNELDOWN },
-
- { 0x610c, KEY_7 },
- { 0x610d, KEY_8 },
- { 0x610a, KEY_9 },
- { 0x610e, KEY_VOLUMEUP },
-
- { 0x6110, KEY_LAST },
- { 0x6111, KEY_0 },
- { 0x6112, KEY_ENTER },
- { 0x6113, KEY_VOLUMEDOWN },
-
- { 0x6114, KEY_RECORD },
- { 0x6115, KEY_STOP },
- { 0x6116, KEY_PLAY },
- { 0x6117, KEY_MUTE },
-
- { 0x6118, KEY_UP },
- { 0x6119, KEY_DOWN },
- { 0x611a, KEY_LEFT },
- { 0x611b, KEY_RIGHT },
- { 0x611c, KEY_RED },
- { 0x611d, KEY_GREEN },
- { 0x611e, KEY_YELLOW },
- { 0x611f, KEY_BLUE },
-};
-DEFINE_IR_KEYTABLE(kworld_315u, IR_TYPE_NEC);
diff --git a/include/media/ir-common.h b/include/media/ir-common.h
index e8a6476..59ce302 100644
--- a/include/media/ir-common.h
+++ b/include/media/ir-common.h
@@ -28,6 +28,71 @@
#include <linux/interrupt.h>
#include <media/ir-core.h>
+#include <media/keycodes/adstech-dvb-t-pci.h>
+#include <media/keycodes/apac-viewcomp.h>
+#include <media/keycodes/asus-pc39.h>
+#include <media/keycodes/ati-tv-wonder-hd-600.h>
+#include <media/keycodes/avermedia-a16d.h>
+#include <media/keycodes/avermedia-cardbus.h>
+#include <media/keycodes/avermedia-dvbt.h>
+#include <media/keycodes/avermedia.h>
+#include <media/keycodes/avermedia-m135a-rm-jx.h>
+#include <media/keycodes/avertv-303.h>
+#include <media/keycodes/behold-columbus.h>
+#include <media/keycodes/behold.h>
+#include <media/keycodes/budget-ci-old.h>
+#include <media/keycodes/cinergy-1400.h>
+#include <media/keycodes/cinergy.h>
+#include <media/keycodes/dm1105-nec.h>
+#include <media/keycodes/dntv-live-dvb-t.h>
+#include <media/keycodes/dntv-live-dvbt-pro.h>
+#include <media/keycodes/empty.h>
+#include <media/keycodes/em-terratec.h>
+#include <media/keycodes/encore-enltv2.h>
+#include <media/keycodes/encore-enltv-fm53.h>
+#include <media/keycodes/encore-enltv.h>
+#include <media/keycodes/evga-indtube.h>
+#include <media/keycodes/eztv.h>
+#include <media/keycodes/flydvb.h>
+#include <media/keycodes/flyvideo.h>
+#include <media/keycodes/fusionhdtv-mce.h>
+#include <media/keycodes/gadmei-rm008z.h>
+#include <media/keycodes/genius-tvgo-a11mce.h>
+#include <media/keycodes/gotview7135.h>
+#include <media/keycodes/hauppauge-new.h>
+#include <media/keycodes/iodata-bctv7e.h>
+#include <media/keycodes/kaiomy.h>
+#include <media/keycodes/kworld-315u.h>
+#include <media/keycodes/kworld-plus-tv-analog.h>
+#include <media/keycodes/manli.h>
+#include <media/keycodes/msi-tvanywhere.h>
+#include <media/keycodes/msi-tvanywhere-plus.h>
+#include <media/keycodes/nebula.h>
+#include <media/keycodes/nec-terratec-cinergy-xs.h>
+#include <media/keycodes/norwood.h>
+#include <media/keycodes/npgtech.h>
+#include <media/keycodes/pctv-sedna.h>
+#include <media/keycodes/pinnacle-color.h>
+#include <media/keycodes/pinnacle-grey.h>
+#include <media/keycodes/pinnacle-pctv-hd.h>
+#include <media/keycodes/pixelview.h>
+#include <media/keycodes/pixelview-new.h>
+#include <media/keycodes/powercolor-real-angel.h>
+#include <media/keycodes/proteus-2309.h>
+#include <media/keycodes/purpletv.h>
+#include <media/keycodes/pv951.h>
+#include <media/keycodes/rc5-hauppauge-new.h>
+#include <media/keycodes/rc5-tv.h>
+#include <media/keycodes/real-audio-220-32-keys.h>
+#include <media/keycodes/tbs-nec.h>
+#include <media/keycodes/terratec-cinergy-xs.h>
+#include <media/keycodes/tevii-nec.h>
+#include <media/keycodes/tt-1500.h>
+#include <media/keycodes/videomate-s350.h>
+#include <media/keycodes/videomate-tv-pvr.h>
+#include <media/keycodes/winfast.h>
+#include <media/keycodes/winfast-usbii-deluxe.h>
+
#define RC5_START(x) (((x)>>12)&3)
#define RC5_TOGGLE(x) (((x)>>11)&1)
#define RC5_ADDR(x) (((x)>>6)&31)
@@ -104,89 +169,4 @@ u32 ir_rc5_decode(unsigned int code);
void ir_rc5_timer_end(unsigned long data);
void ir_rc5_timer_keyup(unsigned long data);
-/* scancode->keycode map tables from ir-keymaps.c */
-
-#define IR_KEYTABLE(a) \
-ir_codes_ ## a ## _table
-
-#define DECLARE_IR_KEYTABLE(a) \
-extern struct ir_scancode_table IR_KEYTABLE(a)
-
-#define DEFINE_IR_KEYTABLE(tabname, type) \
-struct ir_scancode_table IR_KEYTABLE(tabname) = { \
- .scan = tabname, \
- .size = ARRAY_SIZE(tabname), \
- .ir_type = type, \
- .name = #tabname, \
-}; \
-EXPORT_SYMBOL_GPL(IR_KEYTABLE(tabname))
-
-#define DEFINE_LEGACY_IR_KEYTABLE(tabname) \
- DEFINE_IR_KEYTABLE(tabname, IR_TYPE_UNKNOWN)
-
-DECLARE_IR_KEYTABLE(adstech_dvb_t_pci);
-DECLARE_IR_KEYTABLE(apac_viewcomp);
-DECLARE_IR_KEYTABLE(asus_pc39);
-DECLARE_IR_KEYTABLE(ati_tv_wonder_hd_600);
-DECLARE_IR_KEYTABLE(avermedia);
-DECLARE_IR_KEYTABLE(avermedia_a16d);
-DECLARE_IR_KEYTABLE(avermedia_cardbus);
-DECLARE_IR_KEYTABLE(avermedia_dvbt);
-DECLARE_IR_KEYTABLE(avermedia_m135a_rm_jx);
-DECLARE_IR_KEYTABLE(avertv_303);
-DECLARE_IR_KEYTABLE(behold);
-DECLARE_IR_KEYTABLE(behold_columbus);
-DECLARE_IR_KEYTABLE(budget_ci_old);
-DECLARE_IR_KEYTABLE(cinergy);
-DECLARE_IR_KEYTABLE(cinergy_1400);
-DECLARE_IR_KEYTABLE(dm1105_nec);
-DECLARE_IR_KEYTABLE(dntv_live_dvb_t);
-DECLARE_IR_KEYTABLE(dntv_live_dvbt_pro);
-DECLARE_IR_KEYTABLE(empty);
-DECLARE_IR_KEYTABLE(em_terratec);
-DECLARE_IR_KEYTABLE(encore_enltv);
-DECLARE_IR_KEYTABLE(encore_enltv2);
-DECLARE_IR_KEYTABLE(encore_enltv_fm53);
-DECLARE_IR_KEYTABLE(evga_indtube);
-DECLARE_IR_KEYTABLE(eztv);
-DECLARE_IR_KEYTABLE(flydvb);
-DECLARE_IR_KEYTABLE(flyvideo);
-DECLARE_IR_KEYTABLE(fusionhdtv_mce);
-DECLARE_IR_KEYTABLE(gadmei_rm008z);
-DECLARE_IR_KEYTABLE(genius_tvgo_a11mce);
-DECLARE_IR_KEYTABLE(gotview7135);
-DECLARE_IR_KEYTABLE(hauppauge_new);
-DECLARE_IR_KEYTABLE(iodata_bctv7e);
-DECLARE_IR_KEYTABLE(kaiomy);
-DECLARE_IR_KEYTABLE(kworld_315u);
-DECLARE_IR_KEYTABLE(kworld_plus_tv_analog);
-DECLARE_IR_KEYTABLE(manli);
-DECLARE_IR_KEYTABLE(msi_tvanywhere);
-DECLARE_IR_KEYTABLE(msi_tvanywhere_plus);
-DECLARE_IR_KEYTABLE(nebula);
-DECLARE_IR_KEYTABLE(nec_terratec_cinergy_xs);
-DECLARE_IR_KEYTABLE(norwood);
-DECLARE_IR_KEYTABLE(npgtech);
-DECLARE_IR_KEYTABLE(pctv_sedna);
-DECLARE_IR_KEYTABLE(pinnacle_color);
-DECLARE_IR_KEYTABLE(pinnacle_grey);
-DECLARE_IR_KEYTABLE(pinnacle_pctv_hd);
-DECLARE_IR_KEYTABLE(pixelview);
-DECLARE_IR_KEYTABLE(pixelview_new);
-DECLARE_IR_KEYTABLE(powercolor_real_angel);
-DECLARE_IR_KEYTABLE(proteus_2309);
-DECLARE_IR_KEYTABLE(purpletv);
-DECLARE_IR_KEYTABLE(pv951);
-DECLARE_IR_KEYTABLE(rc5_hauppauge_new);
-DECLARE_IR_KEYTABLE(rc5_tv);
-DECLARE_IR_KEYTABLE(real_audio_220_32_keys);
-DECLARE_IR_KEYTABLE(tbs_nec);
-DECLARE_IR_KEYTABLE(terratec_cinergy_xs);
-DECLARE_IR_KEYTABLE(tevii_nec);
-DECLARE_IR_KEYTABLE(tt_1500);
-DECLARE_IR_KEYTABLE(videomate_s350);
-DECLARE_IR_KEYTABLE(videomate_tv_pvr);
-DECLARE_IR_KEYTABLE(winfast);
-DECLARE_IR_KEYTABLE(winfast_usbii_deluxe);
-
#endif
diff --git a/include/media/ir-core.h b/include/media/ir-core.h
index 9a2f308..643ff25 100644
--- a/include/media/ir-core.h
+++ b/include/media/ir-core.h
@@ -96,6 +96,24 @@ struct ir_raw_handler {
#define to_ir_input_dev(_attr) container_of(_attr, struct ir_input_dev, attr)
+#define IR_KEYTABLE(a) \
+ir_codes_ ## a ## _table
+
+#define DECLARE_IR_KEYTABLE(a) \
+extern struct ir_scancode_table IR_KEYTABLE(a)
+
+#define DEFINE_IR_KEYTABLE(tabname, type) \
+struct ir_scancode_table IR_KEYTABLE(tabname) = { \
+ .scan = tabname, \
+ .size = ARRAY_SIZE(tabname), \
+ .ir_type = type, \
+ .name = #tabname, \
+}; \
+EXPORT_SYMBOL_GPL(IR_KEYTABLE(tabname))
+
+#define DEFINE_LEGACY_IR_KEYTABLE(tabname) \
+ DEFINE_IR_KEYTABLE(tabname, IR_TYPE_UNKNOWN)
+
/* Routines from ir-keytable.c */
u32 ir_g_keycode_from_table(struct input_dev *input_dev,
diff --git a/include/media/keycodes/adstech-dvb-t-pci.h b/include/media/keycodes/adstech-dvb-t-pci.h
new file mode 100644
index 0000000..cfca526
--- /dev/null
+++ b/include/media/keycodes/adstech-dvb-t-pci.h
@@ -0,0 +1,65 @@
+/* adstech-dvb-t-pci.h - Keytable for adstech_dvb_t_pci Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* ADS Tech Instant TV DVB-T PCI Remote */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode adstech_dvb_t_pci[] = {
+ /* Keys 0 to 9 */
+ { 0x4d, KEY_0 },
+ { 0x57, KEY_1 },
+ { 0x4f, KEY_2 },
+ { 0x53, KEY_3 },
+ { 0x56, KEY_4 },
+ { 0x4e, KEY_5 },
+ { 0x5e, KEY_6 },
+ { 0x54, KEY_7 },
+ { 0x4c, KEY_8 },
+ { 0x5c, KEY_9 },
+
+ { 0x5b, KEY_POWER },
+ { 0x5f, KEY_MUTE },
+ { 0x55, KEY_GOTO },
+ { 0x5d, KEY_SEARCH },
+ { 0x17, KEY_EPG }, /* Guide */
+ { 0x1f, KEY_MENU },
+ { 0x0f, KEY_UP },
+ { 0x46, KEY_DOWN },
+ { 0x16, KEY_LEFT },
+ { 0x1e, KEY_RIGHT },
+ { 0x0e, KEY_SELECT }, /* Enter */
+ { 0x5a, KEY_INFO },
+ { 0x52, KEY_EXIT },
+ { 0x59, KEY_PREVIOUS },
+ { 0x51, KEY_NEXT },
+ { 0x58, KEY_REWIND },
+ { 0x50, KEY_FORWARD },
+ { 0x44, KEY_PLAYPAUSE },
+ { 0x07, KEY_STOP },
+ { 0x1b, KEY_RECORD },
+ { 0x13, KEY_TUNER }, /* Live */
+ { 0x0a, KEY_A },
+ { 0x12, KEY_B },
+ { 0x03, KEY_PROG1 }, /* 1 */
+ { 0x01, KEY_PROG2 }, /* 2 */
+ { 0x00, KEY_PROG3 }, /* 3 */
+ { 0x06, KEY_DVD },
+ { 0x48, KEY_AUX }, /* Photo */
+ { 0x40, KEY_VIDEO },
+ { 0x19, KEY_AUDIO }, /* Music */
+ { 0x0b, KEY_CHANNELUP },
+ { 0x08, KEY_CHANNELDOWN },
+ { 0x15, KEY_VOLUMEUP },
+ { 0x1c, KEY_VOLUMEDOWN },
+};
+DEFINE_LEGACY_IR_KEYTABLE(adstech_dvb_t_pci);
+#else
+DECLARE_IR_KEYTABLE(adstech_dvb_t_pci);
+#endif
diff --git a/include/media/keycodes/apac-viewcomp.h b/include/media/keycodes/apac-viewcomp.h
new file mode 100644
index 0000000..69460c2
--- /dev/null
+++ b/include/media/keycodes/apac-viewcomp.h
@@ -0,0 +1,56 @@
+/* apac-viewcomp.h - Keytable for apac_viewcomp Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Attila Kondoros <attila.kondoros@chello.hu> */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode apac_viewcomp[] = {
+
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+ { 0x00, KEY_0 },
+ { 0x17, KEY_LAST }, /* +100 */
+ { 0x0a, KEY_LIST }, /* recall */
+
+
+ { 0x1c, KEY_TUNER }, /* TV/FM */
+ { 0x15, KEY_SEARCH }, /* scan */
+ { 0x12, KEY_POWER }, /* power */
+ { 0x1f, KEY_VOLUMEDOWN }, /* vol up */
+ { 0x1b, KEY_VOLUMEUP }, /* vol down */
+ { 0x1e, KEY_CHANNELDOWN }, /* chn up */
+ { 0x1a, KEY_CHANNELUP }, /* chn down */
+
+ { 0x11, KEY_VIDEO }, /* video */
+ { 0x0f, KEY_ZOOM }, /* full screen */
+ { 0x13, KEY_MUTE }, /* mute/unmute */
+ { 0x10, KEY_TEXT }, /* min */
+
+ { 0x0d, KEY_STOP }, /* freeze */
+ { 0x0e, KEY_RECORD }, /* record */
+ { 0x1d, KEY_PLAYPAUSE }, /* stop */
+ { 0x19, KEY_PLAY }, /* play */
+
+ { 0x16, KEY_GOTO }, /* osd */
+ { 0x14, KEY_REFRESH }, /* default */
+ { 0x0c, KEY_KPPLUS }, /* fine tune >>>> */
+ { 0x18, KEY_KPMINUS }, /* fine tune <<<< */
+};
+DEFINE_LEGACY_IR_KEYTABLE(apac_viewcomp);
+#else
+DECLARE_IR_KEYTABLE(apac_viewcomp);
+#endif
diff --git a/include/media/keycodes/asus-pc39.h b/include/media/keycodes/asus-pc39.h
new file mode 100644
index 0000000..3e89ccd
--- /dev/null
+++ b/include/media/keycodes/asus-pc39.h
@@ -0,0 +1,67 @@
+/* asus-pc39.h - Keytable for asus_pc39 Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/*
+ * Marc Fargas <telenieko@telenieko.com>
+ * this is the remote control that comes with the asus p7131
+ * which has a label saying is "Model PC-39"
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode asus_pc39[] = {
+ /* Keys 0 to 9 */
+ { 0x15, KEY_0 },
+ { 0x29, KEY_1 },
+ { 0x2d, KEY_2 },
+ { 0x2b, KEY_3 },
+ { 0x09, KEY_4 },
+ { 0x0d, KEY_5 },
+ { 0x0b, KEY_6 },
+ { 0x31, KEY_7 },
+ { 0x35, KEY_8 },
+ { 0x33, KEY_9 },
+
+ { 0x3e, KEY_RADIO }, /* radio */
+ { 0x03, KEY_MENU }, /* dvd/menu */
+ { 0x2a, KEY_VOLUMEUP },
+ { 0x19, KEY_VOLUMEDOWN },
+ { 0x37, KEY_UP },
+ { 0x3b, KEY_DOWN },
+ { 0x27, KEY_LEFT },
+ { 0x2f, KEY_RIGHT },
+ { 0x25, KEY_VIDEO }, /* video */
+ { 0x39, KEY_AUDIO }, /* music */
+
+ { 0x21, KEY_TV }, /* tv */
+ { 0x1d, KEY_EXIT }, /* back */
+ { 0x0a, KEY_CHANNELUP }, /* channel / program + */
+ { 0x1b, KEY_CHANNELDOWN }, /* channel / program - */
+ { 0x1a, KEY_ENTER }, /* enter */
+
+ { 0x06, KEY_PAUSE }, /* play/pause */
+ { 0x1e, KEY_PREVIOUS }, /* rew */
+ { 0x26, KEY_NEXT }, /* forward */
+ { 0x0e, KEY_REWIND }, /* backward << */
+ { 0x3a, KEY_FASTFORWARD }, /* forward >> */
+ { 0x36, KEY_STOP },
+ { 0x2e, KEY_RECORD }, /* recording */
+ { 0x16, KEY_POWER }, /* the button that reads "close" */
+
+ { 0x11, KEY_ZOOM }, /* full screen */
+ { 0x13, KEY_MACRO }, /* recall */
+ { 0x23, KEY_HOME }, /* home */
+ { 0x05, KEY_PVR }, /* picture */
+ { 0x3d, KEY_MUTE }, /* mute */
+ { 0x01, KEY_DVD }, /* dvd */
+};
+DEFINE_LEGACY_IR_KEYTABLE(asus_pc39);
+#else
+DECLARE_IR_KEYTABLE(asus_pc39);
+#endif
diff --git a/include/media/keycodes/ati-tv-wonder-hd-600.h b/include/media/keycodes/ati-tv-wonder-hd-600.h
new file mode 100644
index 0000000..25db7bf
--- /dev/null
+++ b/include/media/keycodes/ati-tv-wonder-hd-600.h
@@ -0,0 +1,45 @@
+/* ati-tv-wonder-hd-600.h - Keytable for ati_tv_wonder_hd_600 Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* ATI TV Wonder HD 600 USB
+ Devin Heitmueller <devin.heitmueller@gmail.com>
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode ati_tv_wonder_hd_600[] = {
+ { 0x00, KEY_RECORD}, /* Row 1 */
+ { 0x01, KEY_PLAYPAUSE},
+ { 0x02, KEY_STOP},
+ { 0x03, KEY_POWER},
+ { 0x04, KEY_PREVIOUS}, /* Row 2 */
+ { 0x05, KEY_REWIND},
+ { 0x06, KEY_FORWARD},
+ { 0x07, KEY_NEXT},
+ { 0x08, KEY_EPG}, /* Row 3 */
+ { 0x09, KEY_HOME},
+ { 0x0a, KEY_MENU},
+ { 0x0b, KEY_CHANNELUP},
+ { 0x0c, KEY_BACK}, /* Row 4 */
+ { 0x0d, KEY_UP},
+ { 0x0e, KEY_INFO},
+ { 0x0f, KEY_CHANNELDOWN},
+ { 0x10, KEY_LEFT}, /* Row 5 */
+ { 0x11, KEY_SELECT},
+ { 0x12, KEY_RIGHT},
+ { 0x13, KEY_VOLUMEUP},
+ { 0x14, KEY_LAST}, /* Row 6 */
+ { 0x15, KEY_DOWN},
+ { 0x16, KEY_MUTE},
+ { 0x17, KEY_VOLUMEDOWN},
+};
+DEFINE_LEGACY_IR_KEYTABLE(ati_tv_wonder_hd_600);
+#else
+DECLARE_IR_KEYTABLE(ati_tv_wonder_hd_600);
+#endif
diff --git a/include/media/keycodes/avermedia-a16d.h b/include/media/keycodes/avermedia-a16d.h
new file mode 100644
index 0000000..d267951
--- /dev/null
+++ b/include/media/keycodes/avermedia-a16d.h
@@ -0,0 +1,52 @@
+/* avermedia-a16d.h - Keytable for avermedia_a16d Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode avermedia_a16d[] = {
+ { 0x20, KEY_LIST},
+ { 0x00, KEY_POWER},
+ { 0x28, KEY_1},
+ { 0x18, KEY_2},
+ { 0x38, KEY_3},
+ { 0x24, KEY_4},
+ { 0x14, KEY_5},
+ { 0x34, KEY_6},
+ { 0x2c, KEY_7},
+ { 0x1c, KEY_8},
+ { 0x3c, KEY_9},
+ { 0x12, KEY_SUBTITLE},
+ { 0x22, KEY_0},
+ { 0x32, KEY_REWIND},
+ { 0x3a, KEY_SHUFFLE},
+ { 0x02, KEY_PRINT},
+ { 0x11, KEY_CHANNELDOWN},
+ { 0x31, KEY_CHANNELUP},
+ { 0x0c, KEY_ZOOM},
+ { 0x1e, KEY_VOLUMEDOWN},
+ { 0x3e, KEY_VOLUMEUP},
+ { 0x0a, KEY_MUTE},
+ { 0x04, KEY_AUDIO},
+ { 0x26, KEY_RECORD},
+ { 0x06, KEY_PLAY},
+ { 0x36, KEY_STOP},
+ { 0x16, KEY_PAUSE},
+ { 0x2e, KEY_REWIND},
+ { 0x0e, KEY_FASTFORWARD},
+ { 0x30, KEY_TEXT},
+ { 0x21, KEY_GREEN},
+ { 0x01, KEY_BLUE},
+ { 0x08, KEY_EPG},
+ { 0x2a, KEY_MENU},
+};
+DEFINE_LEGACY_IR_KEYTABLE(avermedia_a16d);
+#else
+DECLARE_IR_KEYTABLE(avermedia_a16d);
+#endif
diff --git a/include/media/keycodes/avermedia-cardbus.h b/include/media/keycodes/avermedia-cardbus.h
new file mode 100644
index 0000000..221049d
--- /dev/null
+++ b/include/media/keycodes/avermedia-cardbus.h
@@ -0,0 +1,73 @@
+/* avermedia-cardbus.h - Keytable for avermedia_cardbus Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Oldrich Jedlicka <oldium.pro@seznam.cz> */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode avermedia_cardbus[] = {
+ { 0x00, KEY_POWER },
+ { 0x01, KEY_TUNER }, /* TV/FM */
+ { 0x03, KEY_TEXT }, /* Teletext */
+ { 0x04, KEY_EPG },
+ { 0x05, KEY_1 },
+ { 0x06, KEY_2 },
+ { 0x07, KEY_3 },
+ { 0x08, KEY_AUDIO },
+ { 0x09, KEY_4 },
+ { 0x0a, KEY_5 },
+ { 0x0b, KEY_6 },
+ { 0x0c, KEY_ZOOM }, /* Full screen */
+ { 0x0d, KEY_7 },
+ { 0x0e, KEY_8 },
+ { 0x0f, KEY_9 },
+ { 0x10, KEY_PAGEUP }, /* 16-CH PREV */
+ { 0x11, KEY_0 },
+ { 0x12, KEY_INFO },
+ { 0x13, KEY_AGAIN }, /* CH RTN - channel return */
+ { 0x14, KEY_MUTE },
+ { 0x15, KEY_EDIT }, /* Autoscan */
+ { 0x17, KEY_SAVE }, /* Screenshot */
+ { 0x18, KEY_PLAYPAUSE },
+ { 0x19, KEY_RECORD },
+ { 0x1a, KEY_PLAY },
+ { 0x1b, KEY_STOP },
+ { 0x1c, KEY_FASTFORWARD },
+ { 0x1d, KEY_REWIND },
+ { 0x1e, KEY_VOLUMEDOWN },
+ { 0x1f, KEY_VOLUMEUP },
+ { 0x22, KEY_SLEEP }, /* Sleep */
+ { 0x23, KEY_ZOOM }, /* Aspect */
+ { 0x26, KEY_SCREEN }, /* Pos */
+ { 0x27, KEY_ANGLE }, /* Size */
+ { 0x28, KEY_SELECT }, /* Select */
+ { 0x29, KEY_BLUE }, /* Blue/Picture */
+ { 0x2a, KEY_BACKSPACE }, /* Back */
+ { 0x2b, KEY_MEDIA }, /* PIP (Picture-in-picture) */
+ { 0x2c, KEY_DOWN },
+ { 0x2e, KEY_DOT },
+ { 0x2f, KEY_TV }, /* Live TV */
+ { 0x32, KEY_LEFT },
+ { 0x33, KEY_CLEAR }, /* Clear */
+ { 0x35, KEY_RED }, /* Red/TV */
+ { 0x36, KEY_UP },
+ { 0x37, KEY_HOME }, /* Home */
+ { 0x39, KEY_GREEN }, /* Green/Video */
+ { 0x3d, KEY_YELLOW }, /* Yellow/Music */
+ { 0x3e, KEY_OK }, /* Ok */
+ { 0x3f, KEY_RIGHT },
+ { 0x40, KEY_NEXT }, /* Next */
+ { 0x41, KEY_PREVIOUS }, /* Previous */
+ { 0x42, KEY_CHANNELDOWN }, /* Channel down */
+ { 0x43, KEY_CHANNELUP }, /* Channel up */
+};
+DEFINE_LEGACY_IR_KEYTABLE(avermedia_cardbus);
+#else
+DECLARE_IR_KEYTABLE(avermedia_cardbus);
+#endif
diff --git a/include/media/keycodes/avermedia-dvbt.h b/include/media/keycodes/avermedia-dvbt.h
new file mode 100644
index 0000000..bdaadf4
--- /dev/null
+++ b/include/media/keycodes/avermedia-dvbt.h
@@ -0,0 +1,54 @@
+/* avermedia-dvbt.h - Keytable for avermedia_dvbt Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Matt Jesson <dvb@jesson.eclipse.co.uk */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode avermedia_dvbt[] = {
+ { 0x28, KEY_0 }, /* '0' / 'enter' */
+ { 0x22, KEY_1 }, /* '1' */
+ { 0x12, KEY_2 }, /* '2' / 'up arrow' */
+ { 0x32, KEY_3 }, /* '3' */
+ { 0x24, KEY_4 }, /* '4' / 'left arrow' */
+ { 0x14, KEY_5 }, /* '5' */
+ { 0x34, KEY_6 }, /* '6' / 'right arrow' */
+ { 0x26, KEY_7 }, /* '7' */
+ { 0x16, KEY_8 }, /* '8' / 'down arrow' */
+ { 0x36, KEY_9 }, /* '9' */
+
+ { 0x20, KEY_LIST }, /* 'source' */
+ { 0x10, KEY_TEXT }, /* 'teletext' */
+ { 0x00, KEY_POWER }, /* 'power' */
+ { 0x04, KEY_AUDIO }, /* 'audio' */
+ { 0x06, KEY_ZOOM }, /* 'full screen' */
+ { 0x18, KEY_VIDEO }, /* 'display' */
+ { 0x38, KEY_SEARCH }, /* 'loop' */
+ { 0x08, KEY_INFO }, /* 'preview' */
+ { 0x2a, KEY_REWIND }, /* 'backward <<' */
+ { 0x1a, KEY_FASTFORWARD }, /* 'forward >>' */
+ { 0x3a, KEY_RECORD }, /* 'capture' */
+ { 0x0a, KEY_MUTE }, /* 'mute' */
+ { 0x2c, KEY_RECORD }, /* 'record' */
+ { 0x1c, KEY_PAUSE }, /* 'pause' */
+ { 0x3c, KEY_STOP }, /* 'stop' */
+ { 0x0c, KEY_PLAY }, /* 'play' */
+ { 0x2e, KEY_RED }, /* 'red' */
+ { 0x01, KEY_BLUE }, /* 'blue' / 'cancel' */
+ { 0x0e, KEY_YELLOW }, /* 'yellow' / 'ok' */
+ { 0x21, KEY_GREEN }, /* 'green' */
+ { 0x11, KEY_CHANNELDOWN }, /* 'channel -' */
+ { 0x31, KEY_CHANNELUP }, /* 'channel +' */
+ { 0x1e, KEY_VOLUMEDOWN }, /* 'volume -' */
+ { 0x3e, KEY_VOLUMEUP }, /* 'volume +' */
+};
+DEFINE_LEGACY_IR_KEYTABLE(avermedia_dvbt);
+#else
+DECLARE_IR_KEYTABLE(avermedia_dvbt);
+#endif
diff --git a/include/media/keycodes/avermedia-m135a-rm-jx.h b/include/media/keycodes/avermedia-m135a-rm-jx.h
new file mode 100644
index 0000000..1158598
--- /dev/null
+++ b/include/media/keycodes/avermedia-m135a-rm-jx.h
@@ -0,0 +1,66 @@
+/* avermedia-m135a-rm-jx.h - Keytable for avermedia_m135a_rm_jx Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/*
+ * Avermedia M135A with IR model RM-JX
+ * The same codes exist on both Positivo (BR) and original IR
+ * Mauro Carvalho Chehab <mchehab@infradead.org>
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode avermedia_m135a_rm_jx[] = {
+ { 0x0200, KEY_POWER2 },
+ { 0x022e, KEY_DOT }, /* '.' */
+ { 0x0201, KEY_MODE }, /* TV/FM or SOURCE */
+
+ { 0x0205, KEY_1 },
+ { 0x0206, KEY_2 },
+ { 0x0207, KEY_3 },
+ { 0x0209, KEY_4 },
+ { 0x020a, KEY_5 },
+ { 0x020b, KEY_6 },
+ { 0x020d, KEY_7 },
+ { 0x020e, KEY_8 },
+ { 0x020f, KEY_9 },
+ { 0x0211, KEY_0 },
+
+ { 0x0213, KEY_RIGHT }, /* -> or L */
+ { 0x0212, KEY_LEFT }, /* <- or R */
+
+ { 0x0217, KEY_SLEEP }, /* Capturar Imagem or Snapshot */
+ { 0x0210, KEY_SHUFFLE }, /* Amostra or 16 chan prev */
+
+ { 0x0303, KEY_CHANNELUP },
+ { 0x0302, KEY_CHANNELDOWN },
+ { 0x021f, KEY_VOLUMEUP },
+ { 0x021e, KEY_VOLUMEDOWN },
+ { 0x020c, KEY_ENTER }, /* Full Screen */
+
+ { 0x0214, KEY_MUTE },
+ { 0x0208, KEY_AUDIO },
+
+ { 0x0203, KEY_TEXT }, /* Teletext */
+ { 0x0204, KEY_EPG },
+ { 0x022b, KEY_TV2 }, /* TV2 or PIP */
+
+ { 0x021d, KEY_RED },
+ { 0x021c, KEY_YELLOW },
+ { 0x0301, KEY_GREEN },
+ { 0x0300, KEY_BLUE },
+
+ { 0x021a, KEY_PLAYPAUSE },
+ { 0x0219, KEY_RECORD },
+ { 0x0218, KEY_PLAY },
+ { 0x021b, KEY_STOP },
+};
+DEFINE_IR_KEYTABLE(avermedia_m135a_rm_jx, IR_TYPE_NEC);
+#else
+DECLARE_IR_KEYTABLE(avermedia_m135a_rm_jx);
+#endif
diff --git a/include/media/keycodes/avermedia.h b/include/media/keycodes/avermedia.h
new file mode 100644
index 0000000..a483452
--- /dev/null
+++ b/include/media/keycodes/avermedia.h
@@ -0,0 +1,62 @@
+/* avermedia.h - Keytable for avermedia Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Alex Hermann <gaaf@gmx.net> */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode avermedia[] = {
+ { 0x28, KEY_1 },
+ { 0x18, KEY_2 },
+ { 0x38, KEY_3 },
+ { 0x24, KEY_4 },
+ { 0x14, KEY_5 },
+ { 0x34, KEY_6 },
+ { 0x2c, KEY_7 },
+ { 0x1c, KEY_8 },
+ { 0x3c, KEY_9 },
+ { 0x22, KEY_0 },
+
+ { 0x20, KEY_TV }, /* TV/FM */
+ { 0x10, KEY_CD }, /* CD */
+ { 0x30, KEY_TEXT }, /* TELETEXT */
+ { 0x00, KEY_POWER }, /* POWER */
+
+ { 0x08, KEY_VIDEO }, /* VIDEO */
+ { 0x04, KEY_AUDIO }, /* AUDIO */
+ { 0x0c, KEY_ZOOM }, /* FULL SCREEN */
+
+ { 0x12, KEY_SUBTITLE }, /* DISPLAY */
+ { 0x32, KEY_REWIND }, /* LOOP */
+ { 0x02, KEY_PRINT }, /* PREVIEW */
+
+ { 0x2a, KEY_SEARCH }, /* AUTOSCAN */
+ { 0x1a, KEY_SLEEP }, /* FREEZE */
+ { 0x3a, KEY_CAMERA }, /* SNAPSHOT */
+ { 0x0a, KEY_MUTE }, /* MUTE */
+
+ { 0x26, KEY_RECORD }, /* RECORD */
+ { 0x16, KEY_PAUSE }, /* PAUSE */
+ { 0x36, KEY_STOP }, /* STOP */
+ { 0x06, KEY_PLAY }, /* PLAY */
+
+ { 0x2e, KEY_RED }, /* RED */
+ { 0x21, KEY_GREEN }, /* GREEN */
+ { 0x0e, KEY_YELLOW }, /* YELLOW */
+ { 0x01, KEY_BLUE }, /* BLUE */
+
+ { 0x1e, KEY_VOLUMEDOWN }, /* VOLUME- */
+ { 0x3e, KEY_VOLUMEUP }, /* VOLUME+ */
+ { 0x11, KEY_CHANNELDOWN }, /* CHANNEL/PAGE- */
+ { 0x31, KEY_CHANNELUP } /* CHANNEL/PAGE+ */
+};
+DEFINE_LEGACY_IR_KEYTABLE(avermedia);
+#else
+DECLARE_IR_KEYTABLE(avermedia);
+#endif
diff --git a/include/media/keycodes/avertv-303.h b/include/media/keycodes/avertv-303.h
new file mode 100644
index 0000000..1ef10af
--- /dev/null
+++ b/include/media/keycodes/avertv-303.h
@@ -0,0 +1,61 @@
+/* avertv-303.h - Keytable for avertv_303 Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* AVERTV STUDIO 303 Remote */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode avertv_303[] = {
+ { 0x2a, KEY_1 },
+ { 0x32, KEY_2 },
+ { 0x3a, KEY_3 },
+ { 0x4a, KEY_4 },
+ { 0x52, KEY_5 },
+ { 0x5a, KEY_6 },
+ { 0x6a, KEY_7 },
+ { 0x72, KEY_8 },
+ { 0x7a, KEY_9 },
+ { 0x0e, KEY_0 },
+
+ { 0x02, KEY_POWER },
+ { 0x22, KEY_VIDEO },
+ { 0x42, KEY_AUDIO },
+ { 0x62, KEY_ZOOM },
+ { 0x0a, KEY_TV },
+ { 0x12, KEY_CD },
+ { 0x1a, KEY_TEXT },
+
+ { 0x16, KEY_SUBTITLE },
+ { 0x1e, KEY_REWIND },
+ { 0x06, KEY_PRINT },
+
+ { 0x2e, KEY_SEARCH },
+ { 0x36, KEY_SLEEP },
+ { 0x3e, KEY_SHUFFLE },
+ { 0x26, KEY_MUTE },
+
+ { 0x4e, KEY_RECORD },
+ { 0x56, KEY_PAUSE },
+ { 0x5e, KEY_STOP },
+ { 0x46, KEY_PLAY },
+
+ { 0x6e, KEY_RED },
+ { 0x0b, KEY_GREEN },
+ { 0x66, KEY_YELLOW },
+ { 0x03, KEY_BLUE },
+
+ { 0x76, KEY_LEFT },
+ { 0x7e, KEY_RIGHT },
+ { 0x13, KEY_DOWN },
+ { 0x1b, KEY_UP },
+};
+DEFINE_LEGACY_IR_KEYTABLE(avertv_303);
+#else
+DECLARE_IR_KEYTABLE(avertv_303);
+#endif
diff --git a/include/media/keycodes/behold-columbus.h b/include/media/keycodes/behold-columbus.h
new file mode 100644
index 0000000..fb68e75
--- /dev/null
+++ b/include/media/keycodes/behold-columbus.h
@@ -0,0 +1,84 @@
+/* behold-columbus.h - Keytable for behold_columbus Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Beholder Intl. Ltd. 2008
+ * Dmitry Belimov d.belimov@google.com
+ * Keytable is used by BeholdTV Columbus
+ * The "ascii-art picture" below (in comments, first row
+ * is the keycode in hex, and subsequent row(s) shows
+ * the button labels (several variants when appropriate)
+ * helps to descide which keycodes to assign to the buttons.
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode behold_columbus[] = {
+
+ /* 0x13 0x11 0x1C 0x12 *
+ * Mute Source TV/FM Power *
+ * */
+
+ { 0x13, KEY_MUTE },
+ { 0x11, KEY_PROPS },
+ { 0x1C, KEY_TUNER }, /* KEY_TV/KEY_RADIO */
+ { 0x12, KEY_POWER },
+
+ /* 0x01 0x02 0x03 0x0D *
+ * 1 2 3 Stereo *
+ * *
+ * 0x04 0x05 0x06 0x19 *
+ * 4 5 6 Snapshot *
+ * *
+ * 0x07 0x08 0x09 0x10 *
+ * 7 8 9 Zoom *
+ * */
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x0D, KEY_SETUP }, /* Setup key */
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x19, KEY_CAMERA }, /* Snapshot key */
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+ { 0x10, KEY_ZOOM },
+
+ /* 0x0A 0x00 0x0B 0x0C *
+ * RECALL 0 ChannelUp VolumeUp *
+ * */
+ { 0x0A, KEY_AGAIN },
+ { 0x00, KEY_0 },
+ { 0x0B, KEY_CHANNELUP },
+ { 0x0C, KEY_VOLUMEUP },
+
+ /* 0x1B 0x1D 0x15 0x18 *
+ * Timeshift Record ChannelDown VolumeDown *
+ * */
+
+ { 0x1B, KEY_TIME },
+ { 0x1D, KEY_RECORD },
+ { 0x15, KEY_CHANNELDOWN },
+ { 0x18, KEY_VOLUMEDOWN },
+
+ /* 0x0E 0x1E 0x0F 0x1A *
+ * Stop Pause Previouse Next *
+ * */
+
+ { 0x0E, KEY_STOP },
+ { 0x1E, KEY_PAUSE },
+ { 0x0F, KEY_PREVIOUS },
+ { 0x1A, KEY_NEXT },
+
+};
+DEFINE_LEGACY_IR_KEYTABLE(behold_columbus);
+#else
+DECLARE_IR_KEYTABLE(behold_columbus);
+#endif
diff --git a/include/media/keycodes/behold.h b/include/media/keycodes/behold.h
new file mode 100644
index 0000000..57a2dae
--- /dev/null
+++ b/include/media/keycodes/behold.h
@@ -0,0 +1,117 @@
+/* behold.h - Keytable for behold Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/*
+ * Igor Kuznetsov <igk72@ya.ru>
+ * Andrey J. Melnikov <temnota@kmv.ru>
+ *
+ * Keytable is used by BeholdTV 60x series, M6 series at
+ * least, and probably other cards too.
+ * The "ascii-art picture" below (in comments, first row
+ * is the keycode in hex, and subsequent row(s) shows
+ * the button labels (several variants when appropriate)
+ * helps to descide which keycodes to assign to the buttons.
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode behold[] = {
+
+ /* 0x1c 0x12 *
+ * TV/FM POWER *
+ * */
+ { 0x1c, KEY_TUNER }, /* XXX KEY_TV / KEY_RADIO */
+ { 0x12, KEY_POWER },
+
+ /* 0x01 0x02 0x03 *
+ * 1 2 3 *
+ * *
+ * 0x04 0x05 0x06 *
+ * 4 5 6 *
+ * *
+ * 0x07 0x08 0x09 *
+ * 7 8 9 *
+ * */
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ /* 0x0a 0x00 0x17 *
+ * RECALL 0 MODE *
+ * */
+ { 0x0a, KEY_AGAIN },
+ { 0x00, KEY_0 },
+ { 0x17, KEY_MODE },
+
+ /* 0x14 0x10 *
+ * ASPECT FULLSCREEN *
+ * */
+ { 0x14, KEY_SCREEN },
+ { 0x10, KEY_ZOOM },
+
+ /* 0x0b *
+ * Up *
+ * *
+ * 0x18 0x16 0x0c *
+ * Left Ok Right *
+ * *
+ * 0x015 *
+ * Down *
+ * */
+ { 0x0b, KEY_CHANNELUP },
+ { 0x18, KEY_VOLUMEDOWN },
+ { 0x16, KEY_OK }, /* XXX KEY_ENTER */
+ { 0x0c, KEY_VOLUMEUP },
+ { 0x15, KEY_CHANNELDOWN },
+
+ /* 0x11 0x0d *
+ * MUTE INFO *
+ * */
+ { 0x11, KEY_MUTE },
+ { 0x0d, KEY_INFO },
+
+ /* 0x0f 0x1b 0x1a *
+ * RECORD PLAY/PAUSE STOP *
+ * *
+ * 0x0e 0x1f 0x1e *
+ *TELETEXT AUDIO SOURCE *
+ * RED YELLOW *
+ * */
+ { 0x0f, KEY_RECORD },
+ { 0x1b, KEY_PLAYPAUSE },
+ { 0x1a, KEY_STOP },
+ { 0x0e, KEY_TEXT },
+ { 0x1f, KEY_RED }, /*XXX KEY_AUDIO */
+ { 0x1e, KEY_YELLOW }, /*XXX KEY_SOURCE */
+
+ /* 0x1d 0x13 0x19 *
+ * SLEEP PREVIEW DVB *
+ * GREEN BLUE *
+ * */
+ { 0x1d, KEY_SLEEP },
+ { 0x13, KEY_GREEN },
+ { 0x19, KEY_BLUE }, /* XXX KEY_SAT */
+
+ /* 0x58 0x5c *
+ * FREEZE SNAPSHOT *
+ * */
+ { 0x58, KEY_SLOW },
+ { 0x5c, KEY_CAMERA },
+
+};
+DEFINE_LEGACY_IR_KEYTABLE(behold);
+#else
+DECLARE_IR_KEYTABLE(behold);
+#endif
diff --git a/include/media/keycodes/budget-ci-old.h b/include/media/keycodes/budget-ci-old.h
new file mode 100644
index 0000000..03ada47
--- /dev/null
+++ b/include/media/keycodes/budget-ci-old.h
@@ -0,0 +1,68 @@
+/* budget-ci-old.h - Keytable for budget_ci_old Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* From reading the following remotes:
+ * Zenith Universal 7 / TV Mode 807 / VCR Mode 837
+ * Hauppauge (from NOVA-CI-s box product)
+ * This is a "middle of the road" approach, differences are noted
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode budget_ci_old[] = {
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+ { 0x0a, KEY_ENTER },
+ { 0x0b, KEY_RED },
+ { 0x0c, KEY_POWER }, /* RADIO on Hauppauge */
+ { 0x0d, KEY_MUTE },
+ { 0x0f, KEY_A }, /* TV on Hauppauge */
+ { 0x10, KEY_VOLUMEUP },
+ { 0x11, KEY_VOLUMEDOWN },
+ { 0x14, KEY_B },
+ { 0x1c, KEY_UP },
+ { 0x1d, KEY_DOWN },
+ { 0x1e, KEY_OPTION }, /* RESERVED on Hauppauge */
+ { 0x1f, KEY_BREAK },
+ { 0x20, KEY_CHANNELUP },
+ { 0x21, KEY_CHANNELDOWN },
+ { 0x22, KEY_PREVIOUS }, /* Prev Ch on Zenith, SOURCE on Hauppauge */
+ { 0x24, KEY_RESTART },
+ { 0x25, KEY_OK },
+ { 0x26, KEY_CYCLEWINDOWS }, /* MINIMIZE on Hauppauge */
+ { 0x28, KEY_ENTER }, /* VCR mode on Zenith */
+ { 0x29, KEY_PAUSE },
+ { 0x2b, KEY_RIGHT },
+ { 0x2c, KEY_LEFT },
+ { 0x2e, KEY_MENU }, /* FULL SCREEN on Hauppauge */
+ { 0x30, KEY_SLOW },
+ { 0x31, KEY_PREVIOUS }, /* VCR mode on Zenith */
+ { 0x32, KEY_REWIND },
+ { 0x34, KEY_FASTFORWARD },
+ { 0x35, KEY_PLAY },
+ { 0x36, KEY_STOP },
+ { 0x37, KEY_RECORD },
+ { 0x38, KEY_TUNER }, /* TV/VCR on Zenith */
+ { 0x3a, KEY_C },
+ { 0x3c, KEY_EXIT },
+ { 0x3d, KEY_POWER2 },
+ { 0x3e, KEY_TUNER },
+};
+DEFINE_LEGACY_IR_KEYTABLE(budget_ci_old);
+#else
+DECLARE_IR_KEYTABLE(budget_ci_old);
+#endif
diff --git a/include/media/keycodes/cinergy-1400.h b/include/media/keycodes/cinergy-1400.h
new file mode 100644
index 0000000..9b562ea
--- /dev/null
+++ b/include/media/keycodes/cinergy-1400.h
@@ -0,0 +1,60 @@
+/* cinergy-1400.h - Keytable for cinergy_1400 Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Cinergy 1400 DVB-T */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode cinergy_1400[] = {
+ { 0x01, KEY_POWER },
+ { 0x02, KEY_1 },
+ { 0x03, KEY_2 },
+ { 0x04, KEY_3 },
+ { 0x05, KEY_4 },
+ { 0x06, KEY_5 },
+ { 0x07, KEY_6 },
+ { 0x08, KEY_7 },
+ { 0x09, KEY_8 },
+ { 0x0a, KEY_9 },
+ { 0x0c, KEY_0 },
+
+ { 0x0b, KEY_VIDEO },
+ { 0x0d, KEY_REFRESH },
+ { 0x0e, KEY_SELECT },
+ { 0x0f, KEY_EPG },
+ { 0x10, KEY_UP },
+ { 0x11, KEY_LEFT },
+ { 0x12, KEY_OK },
+ { 0x13, KEY_RIGHT },
+ { 0x14, KEY_DOWN },
+ { 0x15, KEY_TEXT },
+ { 0x16, KEY_INFO },
+
+ { 0x17, KEY_RED },
+ { 0x18, KEY_GREEN },
+ { 0x19, KEY_YELLOW },
+ { 0x1a, KEY_BLUE },
+
+ { 0x1b, KEY_CHANNELUP },
+ { 0x1c, KEY_VOLUMEUP },
+ { 0x1d, KEY_MUTE },
+ { 0x1e, KEY_VOLUMEDOWN },
+ { 0x1f, KEY_CHANNELDOWN },
+
+ { 0x40, KEY_PAUSE },
+ { 0x4c, KEY_PLAY },
+ { 0x58, KEY_RECORD },
+ { 0x54, KEY_PREVIOUS },
+ { 0x48, KEY_STOP },
+ { 0x5c, KEY_NEXT },
+};
+DEFINE_LEGACY_IR_KEYTABLE(cinergy_1400);
+#else
+DECLARE_IR_KEYTABLE(cinergy_1400);
+#endif
diff --git a/include/media/keycodes/cinergy.h b/include/media/keycodes/cinergy.h
new file mode 100644
index 0000000..7884696
--- /dev/null
+++ b/include/media/keycodes/cinergy.h
@@ -0,0 +1,55 @@
+/* cinergy.h - Keytable for cinergy Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode cinergy[] = {
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x0a, KEY_POWER },
+ { 0x0b, KEY_PROG1 }, /* app */
+ { 0x0c, KEY_ZOOM }, /* zoom/fullscreen */
+ { 0x0d, KEY_CHANNELUP }, /* channel */
+ { 0x0e, KEY_CHANNELDOWN }, /* channel- */
+ { 0x0f, KEY_VOLUMEUP },
+ { 0x10, KEY_VOLUMEDOWN },
+ { 0x11, KEY_TUNER }, /* AV */
+ { 0x12, KEY_NUMLOCK }, /* -/-- */
+ { 0x13, KEY_AUDIO }, /* audio */
+ { 0x14, KEY_MUTE },
+ { 0x15, KEY_UP },
+ { 0x16, KEY_DOWN },
+ { 0x17, KEY_LEFT },
+ { 0x18, KEY_RIGHT },
+ { 0x19, BTN_LEFT, },
+ { 0x1a, BTN_RIGHT, },
+ { 0x1b, KEY_WWW }, /* text */
+ { 0x1c, KEY_REWIND },
+ { 0x1d, KEY_FORWARD },
+ { 0x1e, KEY_RECORD },
+ { 0x1f, KEY_PLAY },
+ { 0x20, KEY_PREVIOUSSONG },
+ { 0x21, KEY_NEXTSONG },
+ { 0x22, KEY_PAUSE },
+ { 0x23, KEY_STOP },
+};
+DEFINE_LEGACY_IR_KEYTABLE(cinergy);
+#else
+DECLARE_IR_KEYTABLE(cinergy);
+#endif
diff --git a/include/media/keycodes/dm1105-nec.h b/include/media/keycodes/dm1105-nec.h
new file mode 100644
index 0000000..b87d770
--- /dev/null
+++ b/include/media/keycodes/dm1105-nec.h
@@ -0,0 +1,52 @@
+/* dm1105-nec.h - Keytable for dm1105_nec Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* DVBWorld remotes
+ Igor M. Liplianin <liplianin@me.by>
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode dm1105_nec[] = {
+ { 0x0a, KEY_POWER2}, /* power */
+ { 0x0c, KEY_MUTE}, /* mute */
+ { 0x11, KEY_1},
+ { 0x12, KEY_2},
+ { 0x13, KEY_3},
+ { 0x14, KEY_4},
+ { 0x15, KEY_5},
+ { 0x16, KEY_6},
+ { 0x17, KEY_7},
+ { 0x18, KEY_8},
+ { 0x19, KEY_9},
+ { 0x10, KEY_0},
+ { 0x1c, KEY_CHANNELUP}, /* ch+ */
+ { 0x0f, KEY_CHANNELDOWN}, /* ch- */
+ { 0x1a, KEY_VOLUMEUP}, /* vol+ */
+ { 0x0e, KEY_VOLUMEDOWN}, /* vol- */
+ { 0x04, KEY_RECORD}, /* rec */
+ { 0x09, KEY_CHANNEL}, /* fav */
+ { 0x08, KEY_BACKSPACE}, /* rewind */
+ { 0x07, KEY_FASTFORWARD}, /* fast */
+ { 0x0b, KEY_PAUSE}, /* pause */
+ { 0x02, KEY_ESC}, /* cancel */
+ { 0x03, KEY_TAB}, /* tab */
+ { 0x00, KEY_UP}, /* up */
+ { 0x1f, KEY_ENTER}, /* ok */
+ { 0x01, KEY_DOWN}, /* down */
+ { 0x05, KEY_RECORD}, /* cap */
+ { 0x06, KEY_STOP}, /* stop */
+ { 0x40, KEY_ZOOM}, /* full */
+ { 0x1e, KEY_TV}, /* tvmode */
+ { 0x1b, KEY_B}, /* recall */
+};
+DEFINE_LEGACY_IR_KEYTABLE(dm1105_nec);
+#else
+DECLARE_IR_KEYTABLE(dm1105_nec);
+#endif
diff --git a/include/media/keycodes/dntv-live-dvb-t.h b/include/media/keycodes/dntv-live-dvb-t.h
new file mode 100644
index 0000000..4431ae6
--- /dev/null
+++ b/include/media/keycodes/dntv-live-dvb-t.h
@@ -0,0 +1,54 @@
+/* dntv-live-dvb-t.h - Keytable for dntv_live_dvb_t Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* DigitalNow DNTV Live DVB-T Remote */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode dntv_live_dvb_t[] = {
+ { 0x00, KEY_ESC }, /* 'go up a level?' */
+ /* Keys 0 to 9 */
+ { 0x0a, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x0b, KEY_TUNER }, /* tv/fm */
+ { 0x0c, KEY_SEARCH }, /* scan */
+ { 0x0d, KEY_STOP },
+ { 0x0e, KEY_PAUSE },
+ { 0x0f, KEY_LIST }, /* source */
+
+ { 0x10, KEY_MUTE },
+ { 0x11, KEY_REWIND }, /* backward << */
+ { 0x12, KEY_POWER },
+ { 0x13, KEY_CAMERA }, /* snap */
+ { 0x14, KEY_AUDIO }, /* stereo */
+ { 0x15, KEY_CLEAR }, /* reset */
+ { 0x16, KEY_PLAY },
+ { 0x17, KEY_ENTER },
+ { 0x18, KEY_ZOOM }, /* full screen */
+ { 0x19, KEY_FASTFORWARD }, /* forward >> */
+ { 0x1a, KEY_CHANNELUP },
+ { 0x1b, KEY_VOLUMEUP },
+ { 0x1c, KEY_INFO }, /* preview */
+ { 0x1d, KEY_RECORD }, /* record */
+ { 0x1e, KEY_CHANNELDOWN },
+ { 0x1f, KEY_VOLUMEDOWN },
+};
+DEFINE_LEGACY_IR_KEYTABLE(dntv_live_dvb_t);
+#else
+DECLARE_IR_KEYTABLE(dntv_live_dvb_t);
+#endif
diff --git a/include/media/keycodes/dntv-live-dvbt-pro.h b/include/media/keycodes/dntv-live-dvbt-pro.h
new file mode 100644
index 0000000..d64fa26
--- /dev/null
+++ b/include/media/keycodes/dntv-live-dvbt-pro.h
@@ -0,0 +1,73 @@
+/* dntv-live-dvbt-pro.h - Keytable for dntv_live_dvbt_pro Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* DigitalNow DNTV Live! DVB-T Pro Remote */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode dntv_live_dvbt_pro[] = {
+ { 0x16, KEY_POWER },
+ { 0x5b, KEY_HOME },
+
+ { 0x55, KEY_TV }, /* live tv */
+ { 0x58, KEY_TUNER }, /* digital Radio */
+ { 0x5a, KEY_RADIO }, /* FM radio */
+ { 0x59, KEY_DVD }, /* dvd menu */
+ { 0x03, KEY_1 },
+ { 0x01, KEY_2 },
+ { 0x06, KEY_3 },
+ { 0x09, KEY_4 },
+ { 0x1d, KEY_5 },
+ { 0x1f, KEY_6 },
+ { 0x0d, KEY_7 },
+ { 0x19, KEY_8 },
+ { 0x1b, KEY_9 },
+ { 0x0c, KEY_CANCEL },
+ { 0x15, KEY_0 },
+ { 0x4a, KEY_CLEAR },
+ { 0x13, KEY_BACK },
+ { 0x00, KEY_TAB },
+ { 0x4b, KEY_UP },
+ { 0x4e, KEY_LEFT },
+ { 0x4f, KEY_OK },
+ { 0x52, KEY_RIGHT },
+ { 0x51, KEY_DOWN },
+ { 0x1e, KEY_VOLUMEUP },
+ { 0x0a, KEY_VOLUMEDOWN },
+ { 0x02, KEY_CHANNELDOWN },
+ { 0x05, KEY_CHANNELUP },
+ { 0x11, KEY_RECORD },
+ { 0x14, KEY_PLAY },
+ { 0x4c, KEY_PAUSE },
+ { 0x1a, KEY_STOP },
+ { 0x40, KEY_REWIND },
+ { 0x12, KEY_FASTFORWARD },
+ { 0x41, KEY_PREVIOUSSONG }, /* replay |< */
+ { 0x42, KEY_NEXTSONG }, /* skip >| */
+ { 0x54, KEY_CAMERA }, /* capture */
+ { 0x50, KEY_LANGUAGE }, /* sap */
+ { 0x47, KEY_TV2 }, /* pip */
+ { 0x4d, KEY_SCREEN },
+ { 0x43, KEY_SUBTITLE },
+ { 0x10, KEY_MUTE },
+ { 0x49, KEY_AUDIO }, /* l/r */
+ { 0x07, KEY_SLEEP },
+ { 0x08, KEY_VIDEO }, /* a/v */
+ { 0x0e, KEY_PREVIOUS }, /* recall */
+ { 0x45, KEY_ZOOM }, /* zoom + */
+ { 0x46, KEY_ANGLE }, /* zoom - */
+ { 0x56, KEY_RED },
+ { 0x57, KEY_GREEN },
+ { 0x5c, KEY_YELLOW },
+ { 0x5d, KEY_BLUE },
+};
+DEFINE_LEGACY_IR_KEYTABLE(dntv_live_dvbt_pro);
+#else
+DECLARE_IR_KEYTABLE(dntv_live_dvbt_pro);
+#endif
diff --git a/include/media/keycodes/em-terratec.h b/include/media/keycodes/em-terratec.h
new file mode 100644
index 0000000..906557d
--- /dev/null
+++ b/include/media/keycodes/em-terratec.h
@@ -0,0 +1,46 @@
+/* em-terratec.h - Keytable for em_terratec Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode em_terratec[] = {
+ { 0x01, KEY_CHANNEL },
+ { 0x02, KEY_SELECT },
+ { 0x03, KEY_MUTE },
+ { 0x04, KEY_POWER },
+ { 0x05, KEY_1 },
+ { 0x06, KEY_2 },
+ { 0x07, KEY_3 },
+ { 0x08, KEY_CHANNELUP },
+ { 0x09, KEY_4 },
+ { 0x0a, KEY_5 },
+ { 0x0b, KEY_6 },
+ { 0x0c, KEY_CHANNELDOWN },
+ { 0x0d, KEY_7 },
+ { 0x0e, KEY_8 },
+ { 0x0f, KEY_9 },
+ { 0x10, KEY_VOLUMEUP },
+ { 0x11, KEY_0 },
+ { 0x12, KEY_MENU },
+ { 0x13, KEY_PRINT },
+ { 0x14, KEY_VOLUMEDOWN },
+ { 0x16, KEY_PAUSE },
+ { 0x18, KEY_RECORD },
+ { 0x19, KEY_REWIND },
+ { 0x1a, KEY_PLAY },
+ { 0x1b, KEY_FORWARD },
+ { 0x1c, KEY_BACKSPACE },
+ { 0x1e, KEY_STOP },
+ { 0x40, KEY_ZOOM },
+};
+DEFINE_LEGACY_IR_KEYTABLE(em_terratec);
+#else
+DECLARE_IR_KEYTABLE(em_terratec);
+#endif
diff --git a/include/media/keycodes/empty.h b/include/media/keycodes/empty.h
new file mode 100644
index 0000000..aea866c
--- /dev/null
+++ b/include/media/keycodes/empty.h
@@ -0,0 +1,20 @@
+/* empty.h - Keytable for empty Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* empty keytable, can be used as placeholder for not-yet created keytables */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode empty[] = {
+ { 0x2a, KEY_COFFEE },
+};
+DEFINE_LEGACY_IR_KEYTABLE(empty);
+#else
+DECLARE_IR_KEYTABLE(empty);
+#endif
diff --git a/include/media/keycodes/encore-enltv-fm53.h b/include/media/keycodes/encore-enltv-fm53.h
new file mode 100644
index 0000000..bccb744
--- /dev/null
+++ b/include/media/keycodes/encore-enltv-fm53.h
@@ -0,0 +1,57 @@
+/* encore-enltv-fm53.h - Keytable for encore_enltv_fm53 Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Encore ENLTV-FM v5.3
+ Mauro Carvalho Chehab <mchehab@infradead.org>
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode encore_enltv_fm53[] = {
+ { 0x10, KEY_POWER2},
+ { 0x06, KEY_MUTE},
+
+ { 0x09, KEY_1},
+ { 0x1d, KEY_2},
+ { 0x1f, KEY_3},
+ { 0x19, KEY_4},
+ { 0x1b, KEY_5},
+ { 0x11, KEY_6},
+ { 0x17, KEY_7},
+ { 0x12, KEY_8},
+ { 0x16, KEY_9},
+ { 0x48, KEY_0},
+
+ { 0x04, KEY_LIST}, /* -/-- */
+ { 0x40, KEY_LAST}, /* recall */
+
+ { 0x02, KEY_MODE}, /* TV/AV */
+ { 0x05, KEY_CAMERA}, /* SNAPSHOT */
+
+ { 0x4c, KEY_CHANNELUP}, /* UP */
+ { 0x00, KEY_CHANNELDOWN}, /* DOWN */
+ { 0x0d, KEY_VOLUMEUP}, /* RIGHT */
+ { 0x15, KEY_VOLUMEDOWN}, /* LEFT */
+ { 0x49, KEY_ENTER}, /* OK */
+
+ { 0x54, KEY_RECORD},
+ { 0x4d, KEY_PLAY}, /* pause */
+
+ { 0x1e, KEY_MENU}, /* video setting */
+ { 0x0e, KEY_RIGHT}, /* <- */
+ { 0x1a, KEY_LEFT}, /* -> */
+
+ { 0x0a, KEY_CLEAR}, /* video default */
+ { 0x0c, KEY_ZOOM}, /* hide pannel */
+ { 0x47, KEY_SLEEP}, /* shutdown */
+};
+DEFINE_LEGACY_IR_KEYTABLE(encore_enltv_fm53);
+#else
+DECLARE_IR_KEYTABLE(encore_enltv_fm53);
+#endif
diff --git a/include/media/keycodes/encore-enltv.h b/include/media/keycodes/encore-enltv.h
new file mode 100644
index 0000000..4c55b52
--- /dev/null
+++ b/include/media/keycodes/encore-enltv.h
@@ -0,0 +1,88 @@
+/* encore-enltv.h - Keytable for encore_enltv Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Encore ENLTV-FM - black plastic, white front cover with white glowing buttons
+ Juan Pablo Sormani <sorman@gmail.com> */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode encore_enltv[] = {
+
+ /* Power button does nothing, neither in Windows app,
+ although it sends data (used for BIOS wakeup?) */
+ { 0x0d, KEY_MUTE },
+
+ { 0x1e, KEY_TV },
+ { 0x00, KEY_VIDEO },
+ { 0x01, KEY_AUDIO }, /* music */
+ { 0x02, KEY_MHP }, /* picture */
+
+ { 0x1f, KEY_1 },
+ { 0x03, KEY_2 },
+ { 0x04, KEY_3 },
+ { 0x05, KEY_4 },
+ { 0x1c, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x1d, KEY_9 },
+ { 0x0a, KEY_0 },
+
+ { 0x09, KEY_LIST }, /* -/-- */
+ { 0x0b, KEY_LAST }, /* recall */
+
+ { 0x14, KEY_HOME }, /* win start menu */
+ { 0x15, KEY_EXIT }, /* exit */
+ { 0x16, KEY_CHANNELUP }, /* UP */
+ { 0x12, KEY_CHANNELDOWN }, /* DOWN */
+ { 0x0c, KEY_VOLUMEUP }, /* RIGHT */
+ { 0x17, KEY_VOLUMEDOWN }, /* LEFT */
+
+ { 0x18, KEY_ENTER }, /* OK */
+
+ { 0x0e, KEY_ESC },
+ { 0x13, KEY_CYCLEWINDOWS }, /* desktop */
+ { 0x11, KEY_TAB },
+ { 0x19, KEY_SWITCHVIDEOMODE }, /* switch */
+
+ { 0x1a, KEY_MENU },
+ { 0x1b, KEY_ZOOM }, /* fullscreen */
+ { 0x44, KEY_TIME }, /* time shift */
+ { 0x40, KEY_MODE }, /* source */
+
+ { 0x5a, KEY_RECORD },
+ { 0x42, KEY_PLAY }, /* play/pause */
+ { 0x45, KEY_STOP },
+ { 0x43, KEY_CAMERA }, /* camera icon */
+
+ { 0x48, KEY_REWIND },
+ { 0x4a, KEY_FASTFORWARD },
+ { 0x49, KEY_PREVIOUS },
+ { 0x4b, KEY_NEXT },
+
+ { 0x4c, KEY_FAVORITES }, /* tv wall */
+ { 0x4d, KEY_SOUND }, /* DVD sound */
+ { 0x4e, KEY_LANGUAGE }, /* DVD lang */
+ { 0x4f, KEY_TEXT }, /* DVD text */
+
+ { 0x50, KEY_SLEEP }, /* shutdown */
+ { 0x51, KEY_MODE }, /* stereo > main */
+ { 0x52, KEY_SELECT }, /* stereo > sap */
+ { 0x53, KEY_PROG1 }, /* teletext */
+
+
+ { 0x59, KEY_RED }, /* AP1 */
+ { 0x41, KEY_GREEN }, /* AP2 */
+ { 0x47, KEY_YELLOW }, /* AP3 */
+ { 0x57, KEY_BLUE }, /* AP4 */
+};
+DEFINE_LEGACY_IR_KEYTABLE(encore_enltv);
+#else
+DECLARE_IR_KEYTABLE(encore_enltv);
+#endif
diff --git a/include/media/keycodes/encore-enltv2.h b/include/media/keycodes/encore-enltv2.h
new file mode 100644
index 0000000..6b37fbc
--- /dev/null
+++ b/include/media/keycodes/encore-enltv2.h
@@ -0,0 +1,66 @@
+/* encore-enltv2.h - Keytable for encore_enltv2 Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Encore ENLTV2-FM - silver plastic - "Wand Media" written at the botton
+ Mauro Carvalho Chehab <mchehab@infradead.org> */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode encore_enltv2[] = {
+ { 0x4c, KEY_POWER2 },
+ { 0x4a, KEY_TUNER },
+ { 0x40, KEY_1 },
+ { 0x60, KEY_2 },
+ { 0x50, KEY_3 },
+ { 0x70, KEY_4 },
+ { 0x48, KEY_5 },
+ { 0x68, KEY_6 },
+ { 0x58, KEY_7 },
+ { 0x78, KEY_8 },
+ { 0x44, KEY_9 },
+ { 0x54, KEY_0 },
+
+ { 0x64, KEY_LAST }, /* +100 */
+ { 0x4e, KEY_AGAIN }, /* Recall */
+
+ { 0x6c, KEY_SWITCHVIDEOMODE }, /* Video Source */
+ { 0x5e, KEY_MENU },
+ { 0x56, KEY_SCREEN },
+ { 0x7a, KEY_SETUP },
+
+ { 0x46, KEY_MUTE },
+ { 0x5c, KEY_MODE }, /* Stereo */
+ { 0x74, KEY_INFO },
+ { 0x7c, KEY_CLEAR },
+
+ { 0x55, KEY_UP },
+ { 0x49, KEY_DOWN },
+ { 0x7e, KEY_LEFT },
+ { 0x59, KEY_RIGHT },
+ { 0x6a, KEY_ENTER },
+
+ { 0x42, KEY_VOLUMEUP },
+ { 0x62, KEY_VOLUMEDOWN },
+ { 0x52, KEY_CHANNELUP },
+ { 0x72, KEY_CHANNELDOWN },
+
+ { 0x41, KEY_RECORD },
+ { 0x51, KEY_CAMERA }, /* Snapshot */
+ { 0x75, KEY_TIME }, /* Timeshift */
+ { 0x71, KEY_TV2 }, /* PIP */
+
+ { 0x45, KEY_REWIND },
+ { 0x6f, KEY_PAUSE },
+ { 0x7d, KEY_FORWARD },
+ { 0x79, KEY_STOP },
+};
+DEFINE_LEGACY_IR_KEYTABLE(encore_enltv2);
+#else
+DECLARE_IR_KEYTABLE(encore_enltv2);
+#endif
diff --git a/include/media/keycodes/evga-indtube.h b/include/media/keycodes/evga-indtube.h
new file mode 100644
index 0000000..2aab58d
--- /dev/null
+++ b/include/media/keycodes/evga-indtube.h
@@ -0,0 +1,37 @@
+/* evga-indtube.h - Keytable for evga_indtube Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* EVGA inDtube
+ Devin Heitmueller <devin.heitmueller@gmail.com>
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode evga_indtube[] = {
+ { 0x12, KEY_POWER},
+ { 0x02, KEY_MODE}, /* TV */
+ { 0x14, KEY_MUTE},
+ { 0x1a, KEY_CHANNELUP},
+ { 0x16, KEY_TV2}, /* PIP */
+ { 0x1d, KEY_VOLUMEUP},
+ { 0x05, KEY_CHANNELDOWN},
+ { 0x0f, KEY_PLAYPAUSE},
+ { 0x19, KEY_VOLUMEDOWN},
+ { 0x1c, KEY_REWIND},
+ { 0x0d, KEY_RECORD},
+ { 0x18, KEY_FORWARD},
+ { 0x1e, KEY_PREVIOUS},
+ { 0x1b, KEY_STOP},
+ { 0x1f, KEY_NEXT},
+ { 0x13, KEY_CAMERA},
+};
+DEFINE_LEGACY_IR_KEYTABLE(evga_indtube);
+#else
+DECLARE_IR_KEYTABLE(evga_indtube);
+#endif
diff --git a/include/media/keycodes/eztv.h b/include/media/keycodes/eztv.h
new file mode 100644
index 0000000..030f57a
--- /dev/null
+++ b/include/media/keycodes/eztv.h
@@ -0,0 +1,72 @@
+/* eztv.h - Keytable for eztv Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Alfons Geser <a.geser@cox.net>
+ * updates from Job D. R. Borges <jobdrb@ig.com.br> */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode eztv[] = {
+ { 0x12, KEY_POWER },
+ { 0x01, KEY_TV }, /* DVR */
+ { 0x15, KEY_DVD }, /* DVD */
+ { 0x17, KEY_AUDIO }, /* music */
+ /* DVR mode / DVD mode / music mode */
+
+ { 0x1b, KEY_MUTE }, /* mute */
+ { 0x02, KEY_LANGUAGE }, /* MTS/SAP / audio / autoseek */
+ { 0x1e, KEY_SUBTITLE }, /* closed captioning / subtitle / seek */
+ { 0x16, KEY_ZOOM }, /* full screen */
+ { 0x1c, KEY_VIDEO }, /* video source / eject / delall */
+ { 0x1d, KEY_RESTART }, /* playback / angle / del */
+ { 0x2f, KEY_SEARCH }, /* scan / menu / playlist */
+ { 0x30, KEY_CHANNEL }, /* CH surfing / bookmark / memo */
+
+ { 0x31, KEY_HELP }, /* help */
+ { 0x32, KEY_MODE }, /* num/memo */
+ { 0x33, KEY_ESC }, /* cancel */
+
+ { 0x0c, KEY_UP }, /* up */
+ { 0x10, KEY_DOWN }, /* down */
+ { 0x08, KEY_LEFT }, /* left */
+ { 0x04, KEY_RIGHT }, /* right */
+ { 0x03, KEY_SELECT }, /* select */
+
+ { 0x1f, KEY_REWIND }, /* rewind */
+ { 0x20, KEY_PLAYPAUSE },/* play/pause */
+ { 0x29, KEY_FORWARD }, /* forward */
+ { 0x14, KEY_AGAIN }, /* repeat */
+ { 0x2b, KEY_RECORD }, /* recording */
+ { 0x2c, KEY_STOP }, /* stop */
+ { 0x2d, KEY_PLAY }, /* play */
+ { 0x2e, KEY_CAMERA }, /* snapshot / shuffle */
+
+ { 0x00, KEY_0 },
+ { 0x05, KEY_1 },
+ { 0x06, KEY_2 },
+ { 0x07, KEY_3 },
+ { 0x09, KEY_4 },
+ { 0x0a, KEY_5 },
+ { 0x0b, KEY_6 },
+ { 0x0d, KEY_7 },
+ { 0x0e, KEY_8 },
+ { 0x0f, KEY_9 },
+
+ { 0x2a, KEY_VOLUMEUP },
+ { 0x11, KEY_VOLUMEDOWN },
+ { 0x18, KEY_CHANNELUP },/* CH.tracking up */
+ { 0x19, KEY_CHANNELDOWN },/* CH.tracking down */
+
+ { 0x13, KEY_ENTER }, /* enter */
+ { 0x21, KEY_DOT }, /* . (decimal dot) */
+};
+DEFINE_LEGACY_IR_KEYTABLE(eztv);
+#else
+DECLARE_IR_KEYTABLE(eztv);
+#endif
diff --git a/include/media/keycodes/flydvb.h b/include/media/keycodes/flydvb.h
new file mode 100644
index 0000000..b270cc0
--- /dev/null
+++ b/include/media/keycodes/flydvb.h
@@ -0,0 +1,54 @@
+/* flydvb.h - Keytable for flydvb Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode flydvb[] = {
+ { 0x01, KEY_ZOOM }, /* Full Screen */
+ { 0x00, KEY_POWER }, /* Power */
+
+ { 0x03, KEY_1 },
+ { 0x04, KEY_2 },
+ { 0x05, KEY_3 },
+ { 0x07, KEY_4 },
+ { 0x08, KEY_5 },
+ { 0x09, KEY_6 },
+ { 0x0b, KEY_7 },
+ { 0x0c, KEY_8 },
+ { 0x0d, KEY_9 },
+ { 0x06, KEY_AGAIN }, /* Recall */
+ { 0x0f, KEY_0 },
+ { 0x10, KEY_MUTE }, /* Mute */
+ { 0x02, KEY_RADIO }, /* TV/Radio */
+ { 0x1b, KEY_LANGUAGE }, /* SAP (Second Audio Program) */
+
+ { 0x14, KEY_VOLUMEUP }, /* VOL+ */
+ { 0x17, KEY_VOLUMEDOWN }, /* VOL- */
+ { 0x12, KEY_CHANNELUP }, /* CH+ */
+ { 0x13, KEY_CHANNELDOWN }, /* CH- */
+ { 0x1d, KEY_ENTER }, /* Enter */
+
+ { 0x1a, KEY_MODE }, /* PIP */
+ { 0x18, KEY_TUNER }, /* Source */
+
+ { 0x1e, KEY_RECORD }, /* Record/Pause */
+ { 0x15, KEY_ANGLE }, /* Swap (no label on key) */
+ { 0x1c, KEY_PAUSE }, /* Timeshift/Pause */
+ { 0x19, KEY_BACK }, /* Rewind << */
+ { 0x0a, KEY_PLAYPAUSE }, /* Play/Pause */
+ { 0x1f, KEY_FORWARD }, /* Forward >> */
+ { 0x16, KEY_PREVIOUS }, /* Back |<< */
+ { 0x11, KEY_STOP }, /* Stop */
+ { 0x0e, KEY_NEXT }, /* End >>| */
+};
+DEFINE_LEGACY_IR_KEYTABLE(flydvb);
+#else
+DECLARE_IR_KEYTABLE(flydvb);
+#endif
diff --git a/include/media/keycodes/flyvideo.h b/include/media/keycodes/flyvideo.h
new file mode 100644
index 0000000..5c52f92
--- /dev/null
+++ b/include/media/keycodes/flyvideo.h
@@ -0,0 +1,47 @@
+/* flyvideo.h - Keytable for flyvideo Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode flyvideo[] = {
+ { 0x0f, KEY_0 },
+ { 0x03, KEY_1 },
+ { 0x04, KEY_2 },
+ { 0x05, KEY_3 },
+ { 0x07, KEY_4 },
+ { 0x08, KEY_5 },
+ { 0x09, KEY_6 },
+ { 0x0b, KEY_7 },
+ { 0x0c, KEY_8 },
+ { 0x0d, KEY_9 },
+
+ { 0x0e, KEY_MODE }, /* Air/Cable */
+ { 0x11, KEY_VIDEO }, /* Video */
+ { 0x15, KEY_AUDIO }, /* Audio */
+ { 0x00, KEY_POWER }, /* Power */
+ { 0x18, KEY_TUNER }, /* AV Source */
+ { 0x02, KEY_ZOOM }, /* Fullscreen */
+ { 0x1a, KEY_LANGUAGE }, /* Stereo */
+ { 0x1b, KEY_MUTE }, /* Mute */
+ { 0x14, KEY_VOLUMEUP }, /* Volume + */
+ { 0x17, KEY_VOLUMEDOWN },/* Volume - */
+ { 0x12, KEY_CHANNELUP },/* Channel + */
+ { 0x13, KEY_CHANNELDOWN },/* Channel - */
+ { 0x06, KEY_AGAIN }, /* Recall */
+ { 0x10, KEY_ENTER }, /* Enter */
+
+ { 0x19, KEY_BACK }, /* Rewind ( <<< ) */
+ { 0x1f, KEY_FORWARD }, /* Forward ( >>> ) */
+ { 0x0a, KEY_ANGLE }, /* no label, may be used as the PAUSE button */
+};
+DEFINE_LEGACY_IR_KEYTABLE(flyvideo);
+#else
+DECLARE_IR_KEYTABLE(flyvideo);
+#endif
diff --git a/include/media/keycodes/fusionhdtv-mce.h b/include/media/keycodes/fusionhdtv-mce.h
new file mode 100644
index 0000000..bf2998f
--- /dev/null
+++ b/include/media/keycodes/fusionhdtv-mce.h
@@ -0,0 +1,74 @@
+/* fusionhdtv-mce.h - Keytable for fusionhdtv_mce Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* DViCO FUSION HDTV MCE remote */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode fusionhdtv_mce[] = {
+
+ { 0x0b, KEY_1 },
+ { 0x17, KEY_2 },
+ { 0x1b, KEY_3 },
+ { 0x07, KEY_4 },
+ { 0x50, KEY_5 },
+ { 0x54, KEY_6 },
+ { 0x48, KEY_7 },
+ { 0x4c, KEY_8 },
+ { 0x58, KEY_9 },
+ { 0x03, KEY_0 },
+
+ { 0x5e, KEY_OK },
+ { 0x51, KEY_UP },
+ { 0x53, KEY_DOWN },
+ { 0x5b, KEY_LEFT },
+ { 0x5f, KEY_RIGHT },
+
+ { 0x02, KEY_TV }, /* Labeled DTV on remote */
+ { 0x0e, KEY_MP3 },
+ { 0x1a, KEY_DVD },
+ { 0x1e, KEY_FAVORITES }, /* Labeled CPF on remote */
+ { 0x16, KEY_SETUP },
+ { 0x46, KEY_POWER2 }, /* TV On/Off button on remote */
+ { 0x0a, KEY_EPG }, /* Labeled Guide on remote */
+
+ { 0x49, KEY_BACK },
+ { 0x59, KEY_INFO }, /* Labeled MORE on remote */
+ { 0x4d, KEY_MENU }, /* Labeled DVDMENU on remote */
+ { 0x55, KEY_CYCLEWINDOWS }, /* Labeled ALT-TAB on remote */
+
+ { 0x0f, KEY_PREVIOUSSONG }, /* Labeled |<< REPLAY on remote */
+ { 0x12, KEY_NEXTSONG }, /* Labeled >>| SKIP on remote */
+ { 0x42, KEY_ENTER }, /* Labeled START with a green
+ MS windows logo on remote */
+
+ { 0x15, KEY_VOLUMEUP },
+ { 0x05, KEY_VOLUMEDOWN },
+ { 0x11, KEY_CHANNELUP },
+ { 0x09, KEY_CHANNELDOWN },
+
+ { 0x52, KEY_CAMERA },
+ { 0x5a, KEY_TUNER },
+ { 0x19, KEY_OPEN },
+
+ { 0x13, KEY_MODE }, /* 4:3 16:9 select */
+ { 0x1f, KEY_ZOOM },
+
+ { 0x43, KEY_REWIND },
+ { 0x47, KEY_PLAYPAUSE },
+ { 0x4f, KEY_FASTFORWARD },
+ { 0x57, KEY_MUTE },
+ { 0x0d, KEY_STOP },
+ { 0x01, KEY_RECORD },
+ { 0x4e, KEY_POWER },
+};
+DEFINE_LEGACY_IR_KEYTABLE(fusionhdtv_mce);
+#else
+DECLARE_IR_KEYTABLE(fusionhdtv_mce);
+#endif
diff --git a/include/media/keycodes/gadmei-rm008z.h b/include/media/keycodes/gadmei-rm008z.h
new file mode 100644
index 0000000..b73d3e5
--- /dev/null
+++ b/include/media/keycodes/gadmei-rm008z.h
@@ -0,0 +1,57 @@
+/* gadmei-rm008z.h - Keytable for gadmei_rm008z Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* GADMEI UTV330+ RM008Z remote
+ Shine Liu <shinel@foxmail.com>
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode gadmei_rm008z[] = {
+ { 0x14, KEY_POWER2}, /* POWER OFF */
+ { 0x0c, KEY_MUTE}, /* MUTE */
+
+ { 0x18, KEY_TV}, /* TV */
+ { 0x0e, KEY_VIDEO}, /* AV */
+ { 0x0b, KEY_AUDIO}, /* SV */
+ { 0x0f, KEY_RADIO}, /* FM */
+
+ { 0x00, KEY_1},
+ { 0x01, KEY_2},
+ { 0x02, KEY_3},
+ { 0x03, KEY_4},
+ { 0x04, KEY_5},
+ { 0x05, KEY_6},
+ { 0x06, KEY_7},
+ { 0x07, KEY_8},
+ { 0x08, KEY_9},
+ { 0x09, KEY_0},
+ { 0x0a, KEY_INFO}, /* OSD */
+ { 0x1c, KEY_BACKSPACE}, /* LAST */
+
+ { 0x0d, KEY_PLAY}, /* PLAY */
+ { 0x1e, KEY_CAMERA}, /* SNAPSHOT */
+ { 0x1a, KEY_RECORD}, /* RECORD */
+ { 0x17, KEY_STOP}, /* STOP */
+
+ { 0x1f, KEY_UP}, /* UP */
+ { 0x44, KEY_DOWN}, /* DOWN */
+ { 0x46, KEY_TAB}, /* BACK */
+ { 0x4a, KEY_ZOOM}, /* FULLSECREEN */
+
+ { 0x10, KEY_VOLUMEUP}, /* VOLUMEUP */
+ { 0x11, KEY_VOLUMEDOWN}, /* VOLUMEDOWN */
+ { 0x12, KEY_CHANNELUP}, /* CHANNELUP */
+ { 0x13, KEY_CHANNELDOWN}, /* CHANNELDOWN */
+ { 0x15, KEY_ENTER}, /* OK */
+};
+DEFINE_LEGACY_IR_KEYTABLE(gadmei_rm008z);
+#else
+DECLARE_IR_KEYTABLE(gadmei_rm008z);
+#endif
diff --git a/include/media/keycodes/genius-tvgo-a11mce.h b/include/media/keycodes/genius-tvgo-a11mce.h
new file mode 100644
index 0000000..b0aad3b
--- /dev/null
+++ b/include/media/keycodes/genius-tvgo-a11mce.h
@@ -0,0 +1,60 @@
+/* genius-tvgo-a11mce.h - Keytable for genius_tvgo_a11mce Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/*
+ * Remote control for the Genius TVGO A11MCE
+ * Adrian Pardini <pardo.bsso@gmail.com>
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode genius_tvgo_a11mce[] = {
+ /* Keys 0 to 9 */
+ { 0x48, KEY_0 },
+ { 0x09, KEY_1 },
+ { 0x1d, KEY_2 },
+ { 0x1f, KEY_3 },
+ { 0x19, KEY_4 },
+ { 0x1b, KEY_5 },
+ { 0x11, KEY_6 },
+ { 0x17, KEY_7 },
+ { 0x12, KEY_8 },
+ { 0x16, KEY_9 },
+
+ { 0x54, KEY_RECORD }, /* recording */
+ { 0x06, KEY_MUTE }, /* mute */
+ { 0x10, KEY_POWER },
+ { 0x40, KEY_LAST }, /* recall */
+ { 0x4c, KEY_CHANNELUP }, /* channel / program + */
+ { 0x00, KEY_CHANNELDOWN }, /* channel / program - */
+ { 0x0d, KEY_VOLUMEUP },
+ { 0x15, KEY_VOLUMEDOWN },
+ { 0x4d, KEY_OK }, /* also labeled as Pause */
+ { 0x1c, KEY_ZOOM }, /* full screen and Stop*/
+ { 0x02, KEY_MODE }, /* AV Source or Rewind*/
+ { 0x04, KEY_LIST }, /* -/-- */
+ /* small arrows above numbers */
+ { 0x1a, KEY_NEXT }, /* also Fast Forward */
+ { 0x0e, KEY_PREVIOUS }, /* also Rewind */
+ /* these are in a rather non standard layout and have
+ an alternate name written */
+ { 0x1e, KEY_UP }, /* Video Setting */
+ { 0x0a, KEY_DOWN }, /* Video Default */
+ { 0x05, KEY_CAMERA }, /* Snapshot */
+ { 0x0c, KEY_RIGHT }, /* Hide Panel */
+ /* Four buttons without label */
+ { 0x49, KEY_RED },
+ { 0x0b, KEY_GREEN },
+ { 0x13, KEY_YELLOW },
+ { 0x50, KEY_BLUE },
+};
+DEFINE_LEGACY_IR_KEYTABLE(genius_tvgo_a11mce);
+#else
+DECLARE_IR_KEYTABLE(genius_tvgo_a11mce);
+#endif
diff --git a/include/media/keycodes/gotview7135.h b/include/media/keycodes/gotview7135.h
new file mode 100644
index 0000000..1d108e8
--- /dev/null
+++ b/include/media/keycodes/gotview7135.h
@@ -0,0 +1,55 @@
+/* gotview7135.h - Keytable for gotview7135 Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Mike Baikov <mike@baikov.com> */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode gotview7135[] = {
+
+ { 0x11, KEY_POWER },
+ { 0x35, KEY_TV },
+ { 0x1b, KEY_0 },
+ { 0x29, KEY_1 },
+ { 0x19, KEY_2 },
+ { 0x39, KEY_3 },
+ { 0x1f, KEY_4 },
+ { 0x2c, KEY_5 },
+ { 0x21, KEY_6 },
+ { 0x24, KEY_7 },
+ { 0x18, KEY_8 },
+ { 0x2b, KEY_9 },
+ { 0x3b, KEY_AGAIN }, /* LOOP */
+ { 0x06, KEY_AUDIO },
+ { 0x31, KEY_PRINT }, /* PREVIEW */
+ { 0x3e, KEY_VIDEO },
+ { 0x10, KEY_CHANNELUP },
+ { 0x20, KEY_CHANNELDOWN },
+ { 0x0c, KEY_VOLUMEDOWN },
+ { 0x28, KEY_VOLUMEUP },
+ { 0x08, KEY_MUTE },
+ { 0x26, KEY_SEARCH }, /* SCAN */
+ { 0x3f, KEY_CAMERA }, /* SNAPSHOT */
+ { 0x12, KEY_RECORD },
+ { 0x32, KEY_STOP },
+ { 0x3c, KEY_PLAY },
+ { 0x1d, KEY_REWIND },
+ { 0x2d, KEY_PAUSE },
+ { 0x0d, KEY_FORWARD },
+ { 0x05, KEY_ZOOM }, /*FULL*/
+
+ { 0x2a, KEY_F21 }, /* LIVE TIMESHIFT */
+ { 0x0e, KEY_F22 }, /* MIN TIMESHIFT */
+ { 0x1e, KEY_TIME }, /* TIMESHIFT */
+ { 0x38, KEY_F24 }, /* NORMAL TIMESHIFT */
+};
+DEFINE_LEGACY_IR_KEYTABLE(gotview7135);
+#else
+DECLARE_IR_KEYTABLE(gotview7135);
+#endif
diff --git a/include/media/keycodes/hauppauge-new.h b/include/media/keycodes/hauppauge-new.h
new file mode 100644
index 0000000..f06702d
--- /dev/null
+++ b/include/media/keycodes/hauppauge-new.h
@@ -0,0 +1,76 @@
+/* hauppauge-new.h - Keytable for hauppauge_new Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Hauppauge: the newer, gray remotes (seems there are multiple
+ * slightly different versions), shipped with cx88+ivtv cards.
+ * almost rc5 coding, but some non-standard keys */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode hauppauge_new[] = {
+ /* Keys 0 to 9 */
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x0a, KEY_TEXT }, /* keypad asterisk as well */
+ { 0x0b, KEY_RED }, /* red button */
+ { 0x0c, KEY_RADIO },
+ { 0x0d, KEY_MENU },
+ { 0x0e, KEY_SUBTITLE }, /* also the # key */
+ { 0x0f, KEY_MUTE },
+ { 0x10, KEY_VOLUMEUP },
+ { 0x11, KEY_VOLUMEDOWN },
+ { 0x12, KEY_PREVIOUS }, /* previous channel */
+ { 0x14, KEY_UP },
+ { 0x15, KEY_DOWN },
+ { 0x16, KEY_LEFT },
+ { 0x17, KEY_RIGHT },
+ { 0x18, KEY_VIDEO }, /* Videos */
+ { 0x19, KEY_AUDIO }, /* Music */
+ /* 0x1a: Pictures - presume this means
+ "Multimedia Home Platform" -
+ no "PICTURES" key in input.h
+ */
+ { 0x1a, KEY_MHP },
+
+ { 0x1b, KEY_EPG }, /* Guide */
+ { 0x1c, KEY_TV },
+ { 0x1e, KEY_NEXTSONG }, /* skip >| */
+ { 0x1f, KEY_EXIT }, /* back/exit */
+ { 0x20, KEY_CHANNELUP }, /* channel / program + */
+ { 0x21, KEY_CHANNELDOWN }, /* channel / program - */
+ { 0x22, KEY_CHANNEL }, /* source (old black remote) */
+ { 0x24, KEY_PREVIOUSSONG }, /* replay |< */
+ { 0x25, KEY_ENTER }, /* OK */
+ { 0x26, KEY_SLEEP }, /* minimize (old black remote) */
+ { 0x29, KEY_BLUE }, /* blue key */
+ { 0x2e, KEY_GREEN }, /* green button */
+ { 0x30, KEY_PAUSE }, /* pause */
+ { 0x32, KEY_REWIND }, /* backward << */
+ { 0x34, KEY_FASTFORWARD }, /* forward >> */
+ { 0x35, KEY_PLAY },
+ { 0x36, KEY_STOP },
+ { 0x37, KEY_RECORD }, /* recording */
+ { 0x38, KEY_YELLOW }, /* yellow key */
+ { 0x3b, KEY_SELECT }, /* top right button */
+ { 0x3c, KEY_ZOOM }, /* full */
+ { 0x3d, KEY_POWER }, /* system power (green button) */
+};
+DEFINE_LEGACY_IR_KEYTABLE(hauppauge_new);
+#else
+DECLARE_IR_KEYTABLE(hauppauge_new);
+#endif
diff --git a/include/media/keycodes/iodata-bctv7e.h b/include/media/keycodes/iodata-bctv7e.h
new file mode 100644
index 0000000..6dea92a
--- /dev/null
+++ b/include/media/keycodes/iodata-bctv7e.h
@@ -0,0 +1,64 @@
+/* iodata-bctv7e.h - Keytable for iodata_bctv7e Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* IO-DATA BCTV7E Remote */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode iodata_bctv7e[] = {
+ { 0x40, KEY_TV },
+ { 0x20, KEY_RADIO }, /* FM */
+ { 0x60, KEY_EPG },
+ { 0x00, KEY_POWER },
+
+ /* Keys 0 to 9 */
+ { 0x44, KEY_0 }, /* 10 */
+ { 0x50, KEY_1 },
+ { 0x30, KEY_2 },
+ { 0x70, KEY_3 },
+ { 0x48, KEY_4 },
+ { 0x28, KEY_5 },
+ { 0x68, KEY_6 },
+ { 0x58, KEY_7 },
+ { 0x38, KEY_8 },
+ { 0x78, KEY_9 },
+
+ { 0x10, KEY_L }, /* Live */
+ { 0x08, KEY_TIME }, /* Time Shift */
+
+ { 0x18, KEY_PLAYPAUSE }, /* Play */
+
+ { 0x24, KEY_ENTER }, /* 11 */
+ { 0x64, KEY_ESC }, /* 12 */
+ { 0x04, KEY_M }, /* Multi */
+
+ { 0x54, KEY_VIDEO },
+ { 0x34, KEY_CHANNELUP },
+ { 0x74, KEY_VOLUMEUP },
+ { 0x14, KEY_MUTE },
+
+ { 0x4c, KEY_VCR }, /* SVIDEO */
+ { 0x2c, KEY_CHANNELDOWN },
+ { 0x6c, KEY_VOLUMEDOWN },
+ { 0x0c, KEY_ZOOM },
+
+ { 0x5c, KEY_PAUSE },
+ { 0x3c, KEY_RED }, /* || (red) */
+ { 0x7c, KEY_RECORD }, /* recording */
+ { 0x1c, KEY_STOP },
+
+ { 0x41, KEY_REWIND }, /* backward << */
+ { 0x21, KEY_PLAY },
+ { 0x61, KEY_FASTFORWARD }, /* forward >> */
+ { 0x01, KEY_NEXT }, /* skip >| */
+};
+DEFINE_LEGACY_IR_KEYTABLE(iodata_bctv7e);
+#else
+DECLARE_IR_KEYTABLE(iodata_bctv7e);
+#endif
diff --git a/include/media/keycodes/kaiomy.h b/include/media/keycodes/kaiomy.h
new file mode 100644
index 0000000..2d6dbbc
--- /dev/null
+++ b/include/media/keycodes/kaiomy.h
@@ -0,0 +1,63 @@
+/* kaiomy.h - Keytable for kaiomy Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Kaiomy TVnPC U2
+ Mauro Carvalho Chehab <mchehab@infradead.org>
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode kaiomy[] = {
+ { 0x43, KEY_POWER2},
+ { 0x01, KEY_LIST},
+ { 0x0b, KEY_ZOOM},
+ { 0x03, KEY_POWER},
+
+ { 0x04, KEY_1},
+ { 0x08, KEY_2},
+ { 0x02, KEY_3},
+
+ { 0x0f, KEY_4},
+ { 0x05, KEY_5},
+ { 0x06, KEY_6},
+
+ { 0x0c, KEY_7},
+ { 0x0d, KEY_8},
+ { 0x0a, KEY_9},
+
+ { 0x11, KEY_0},
+
+ { 0x09, KEY_CHANNELUP},
+ { 0x07, KEY_CHANNELDOWN},
+
+ { 0x0e, KEY_VOLUMEUP},
+ { 0x13, KEY_VOLUMEDOWN},
+
+ { 0x10, KEY_HOME},
+ { 0x12, KEY_ENTER},
+
+ { 0x14, KEY_RECORD},
+ { 0x15, KEY_STOP},
+ { 0x16, KEY_PLAY},
+ { 0x17, KEY_MUTE},
+
+ { 0x18, KEY_UP},
+ { 0x19, KEY_DOWN},
+ { 0x1a, KEY_LEFT},
+ { 0x1b, KEY_RIGHT},
+
+ { 0x1c, KEY_RED},
+ { 0x1d, KEY_GREEN},
+ { 0x1e, KEY_YELLOW},
+ { 0x1f, KEY_BLUE},
+};
+DEFINE_LEGACY_IR_KEYTABLE(kaiomy);
+#else
+DECLARE_IR_KEYTABLE(kaiomy);
+#endif
diff --git a/include/media/keycodes/kworld-315u.h b/include/media/keycodes/kworld-315u.h
new file mode 100644
index 0000000..44e29b6
--- /dev/null
+++ b/include/media/keycodes/kworld-315u.h
@@ -0,0 +1,59 @@
+/* kworld-315u.h - Keytable for kworld_315u Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Kworld 315U
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode kworld_315u[] = {
+ { 0x6143, KEY_POWER },
+ { 0x6101, KEY_TUNER }, /* source */
+ { 0x610b, KEY_ZOOM },
+ { 0x6103, KEY_POWER2 }, /* shutdown */
+
+ { 0x6104, KEY_1 },
+ { 0x6108, KEY_2 },
+ { 0x6102, KEY_3 },
+ { 0x6109, KEY_CHANNELUP },
+
+ { 0x610f, KEY_4 },
+ { 0x6105, KEY_5 },
+ { 0x6106, KEY_6 },
+ { 0x6107, KEY_CHANNELDOWN },
+
+ { 0x610c, KEY_7 },
+ { 0x610d, KEY_8 },
+ { 0x610a, KEY_9 },
+ { 0x610e, KEY_VOLUMEUP },
+
+ { 0x6110, KEY_LAST },
+ { 0x6111, KEY_0 },
+ { 0x6112, KEY_ENTER },
+ { 0x6113, KEY_VOLUMEDOWN },
+
+ { 0x6114, KEY_RECORD },
+ { 0x6115, KEY_STOP },
+ { 0x6116, KEY_PLAY },
+ { 0x6117, KEY_MUTE },
+
+ { 0x6118, KEY_UP },
+ { 0x6119, KEY_DOWN },
+ { 0x611a, KEY_LEFT },
+ { 0x611b, KEY_RIGHT },
+
+ { 0x611c, KEY_RED },
+ { 0x611d, KEY_GREEN },
+ { 0x611e, KEY_YELLOW },
+ { 0x611f, KEY_BLUE },
+};
+DEFINE_IR_KEYTABLE(kworld_315u, IR_TYPE_NEC);
+#else
+DECLARE_IR_KEYTABLE(kworld_315u);
+#endif
diff --git a/include/media/keycodes/kworld-plus-tv-analog.h b/include/media/keycodes/kworld-plus-tv-analog.h
new file mode 100644
index 0000000..2b4ae0b
--- /dev/null
+++ b/include/media/keycodes/kworld-plus-tv-analog.h
@@ -0,0 +1,75 @@
+/* kworld-plus-tv-analog.h - Keytable for kworld_plus_tv_analog Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Kworld Plus TV Analog Lite PCI IR
+ Mauro Carvalho Chehab <mchehab@infradead.org>
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode kworld_plus_tv_analog[] = {
+ { 0x0c, KEY_PROG1 }, /* Kworld key */
+ { 0x16, KEY_CLOSECD }, /* -> ) */
+ { 0x1d, KEY_POWER2 },
+
+ { 0x00, KEY_1 },
+ { 0x01, KEY_2 },
+ { 0x02, KEY_3 }, /* Two keys have the same code: 3 and left */
+ { 0x03, KEY_4 }, /* Two keys have the same code: 3 and right */
+ { 0x04, KEY_5 },
+ { 0x05, KEY_6 },
+ { 0x06, KEY_7 },
+ { 0x07, KEY_8 },
+ { 0x08, KEY_9 },
+ { 0x0a, KEY_0 },
+
+ { 0x09, KEY_AGAIN },
+ { 0x14, KEY_MUTE },
+
+ { 0x20, KEY_UP },
+ { 0x21, KEY_DOWN },
+ { 0x0b, KEY_ENTER },
+
+ { 0x10, KEY_CHANNELUP },
+ { 0x11, KEY_CHANNELDOWN },
+
+ /* Couldn't map key left/key right since those
+ conflict with '3' and '4' scancodes
+ I dunno what the original driver does
+ */
+
+ { 0x13, KEY_VOLUMEUP },
+ { 0x12, KEY_VOLUMEDOWN },
+
+ /* The lower part of the IR
+ There are several duplicated keycodes there.
+ Most of them conflict with digits.
+ Add mappings just to the unused scancodes.
+ Somehow, the original driver has a way to know,
+ but this doesn't seem to be on some GPIO.
+ Also, it is not related to the time between keyup
+ and keydown.
+ */
+ { 0x19, KEY_TIME}, /* Timeshift */
+ { 0x1a, KEY_STOP},
+ { 0x1b, KEY_RECORD},
+
+ { 0x22, KEY_TEXT},
+
+ { 0x15, KEY_AUDIO}, /* ((*)) */
+ { 0x0f, KEY_ZOOM},
+ { 0x1c, KEY_CAMERA}, /* snapshot */
+
+ { 0x18, KEY_RED}, /* B */
+ { 0x23, KEY_GREEN}, /* C */
+};
+DEFINE_LEGACY_IR_KEYTABLE(kworld_plus_tv_analog);
+#else
+DECLARE_IR_KEYTABLE(kworld_plus_tv_analog);
+#endif
diff --git a/include/media/keycodes/manli.h b/include/media/keycodes/manli.h
new file mode 100644
index 0000000..9f8e752
--- /dev/null
+++ b/include/media/keycodes/manli.h
@@ -0,0 +1,111 @@
+/* manli.h - Keytable for manli Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Michael Tokarev <mjt@tls.msk.ru>
+ http://www.corpit.ru/mjt/beholdTV/remote_control.jpg
+ keytable is used by MANLI MTV00[0x0c] and BeholdTV 40[13] at
+ least, and probably other cards too.
+ The "ascii-art picture" below (in comments, first row
+ is the keycode in hex, and subsequent row(s) shows
+ the button labels (several variants when appropriate)
+ helps to descide which keycodes to assign to the buttons.
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode manli[] = {
+
+ /* 0x1c 0x12 *
+ * FUNCTION POWER *
+ * FM (|) *
+ * */
+ { 0x1c, KEY_RADIO }, /*XXX*/
+ { 0x12, KEY_POWER },
+
+ /* 0x01 0x02 0x03 *
+ * 1 2 3 *
+ * *
+ * 0x04 0x05 0x06 *
+ * 4 5 6 *
+ * *
+ * 0x07 0x08 0x09 *
+ * 7 8 9 *
+ * */
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ /* 0x0a 0x00 0x17 *
+ * RECALL 0 +100 *
+ * PLUS *
+ * */
+ { 0x0a, KEY_AGAIN }, /*XXX KEY_REWIND? */
+ { 0x00, KEY_0 },
+ { 0x17, KEY_DIGITS }, /*XXX*/
+
+ /* 0x14 0x10 *
+ * MENU INFO *
+ * OSD */
+ { 0x14, KEY_MENU },
+ { 0x10, KEY_INFO },
+
+ /* 0x0b *
+ * Up *
+ * *
+ * 0x18 0x16 0x0c *
+ * Left Ok Right *
+ * *
+ * 0x015 *
+ * Down *
+ * */
+ { 0x0b, KEY_UP },
+ { 0x18, KEY_LEFT },
+ { 0x16, KEY_OK }, /*XXX KEY_SELECT? KEY_ENTER? */
+ { 0x0c, KEY_RIGHT },
+ { 0x15, KEY_DOWN },
+
+ /* 0x11 0x0d *
+ * TV/AV MODE *
+ * SOURCE STEREO *
+ * */
+ { 0x11, KEY_TV }, /*XXX*/
+ { 0x0d, KEY_MODE }, /*XXX there's no KEY_STEREO */
+
+ /* 0x0f 0x1b 0x1a *
+ * AUDIO Vol+ Chan+ *
+ * TIMESHIFT??? *
+ * *
+ * 0x0e 0x1f 0x1e *
+ * SLEEP Vol- Chan- *
+ * */
+ { 0x0f, KEY_AUDIO },
+ { 0x1b, KEY_VOLUMEUP },
+ { 0x1a, KEY_CHANNELUP },
+ { 0x0e, KEY_TIME },
+ { 0x1f, KEY_VOLUMEDOWN },
+ { 0x1e, KEY_CHANNELDOWN },
+
+ /* 0x13 0x19 *
+ * MUTE SNAPSHOT*
+ * */
+ { 0x13, KEY_MUTE },
+ { 0x19, KEY_CAMERA },
+
+ /* 0x1d unused ? */
+};
+DEFINE_LEGACY_IR_KEYTABLE(manli);
+#else
+DECLARE_IR_KEYTABLE(manli);
+#endif
diff --git a/include/media/keycodes/msi-tvanywhere-plus.h b/include/media/keycodes/msi-tvanywhere-plus.h
new file mode 100644
index 0000000..c5e51ad
--- /dev/null
+++ b/include/media/keycodes/msi-tvanywhere-plus.h
@@ -0,0 +1,100 @@
+/* msi-tvanywhere-plus.h - Keytable for msi_tvanywhere_plus Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/*
+ Keycodes for remote on the MSI TV@nywhere Plus. The controller IC on the card
+ is marked "KS003". The controller is I2C at address 0x30, but does not seem
+ to respond to probes until a read is performed from a valid device.
+ I don't know why...
+
+ Note: This remote may be of similar or identical design to the
+ Pixelview remote (?). The raw codes and duplicate button codes
+ appear to be the same.
+
+ Henry Wong <henry@stuffedcow.net>
+ Some changes to formatting and keycodes by Mark Schultz <n9xmj@yahoo.com>
+
+*/
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode msi_tvanywhere_plus[] = {
+
+/* ---- Remote Button Layout ----
+
+ POWER SOURCE SCAN MUTE
+ TV/FM 1 2 3
+ |> 4 5 6
+ <| 7 8 9
+ ^^UP 0 + RECALL
+ vvDN RECORD STOP PLAY
+
+ MINIMIZE ZOOM
+
+ CH+
+ VOL- VOL+
+ CH-
+
+ SNAPSHOT MTS
+
+ << FUNC >> RESET
+*/
+
+ { 0x01, KEY_1 }, /* 1 */
+ { 0x0b, KEY_2 }, /* 2 */
+ { 0x1b, KEY_3 }, /* 3 */
+ { 0x05, KEY_4 }, /* 4 */
+ { 0x09, KEY_5 }, /* 5 */
+ { 0x15, KEY_6 }, /* 6 */
+ { 0x06, KEY_7 }, /* 7 */
+ { 0x0a, KEY_8 }, /* 8 */
+ { 0x12, KEY_9 }, /* 9 */
+ { 0x02, KEY_0 }, /* 0 */
+ { 0x10, KEY_KPPLUS }, /* + */
+ { 0x13, KEY_AGAIN }, /* Recall */
+
+ { 0x1e, KEY_POWER }, /* Power */
+ { 0x07, KEY_TUNER }, /* Source */
+ { 0x1c, KEY_SEARCH }, /* Scan */
+ { 0x18, KEY_MUTE }, /* Mute */
+
+ { 0x03, KEY_RADIO }, /* TV/FM */
+ /* The next four keys are duplicates that appear to send the
+ same IR code as Ch+, Ch-, >>, and << . The raw code assigned
+ to them is the actual code + 0x20 - they will never be
+ detected as such unless some way is discovered to distinguish
+ these buttons from those that have the same code. */
+ { 0x3f, KEY_RIGHT }, /* |> and Ch+ */
+ { 0x37, KEY_LEFT }, /* <| and Ch- */
+ { 0x2c, KEY_UP }, /* ^^Up and >> */
+ { 0x24, KEY_DOWN }, /* vvDn and << */
+
+ { 0x00, KEY_RECORD }, /* Record */
+ { 0x08, KEY_STOP }, /* Stop */
+ { 0x11, KEY_PLAY }, /* Play */
+
+ { 0x0f, KEY_CLOSE }, /* Minimize */
+ { 0x19, KEY_ZOOM }, /* Zoom */
+ { 0x1a, KEY_CAMERA }, /* Snapshot */
+ { 0x0d, KEY_LANGUAGE }, /* MTS */
+
+ { 0x14, KEY_VOLUMEDOWN }, /* Vol- */
+ { 0x16, KEY_VOLUMEUP }, /* Vol+ */
+ { 0x17, KEY_CHANNELDOWN }, /* Ch- */
+ { 0x1f, KEY_CHANNELUP }, /* Ch+ */
+
+ { 0x04, KEY_REWIND }, /* << */
+ { 0x0e, KEY_MENU }, /* Function */
+ { 0x0c, KEY_FASTFORWARD }, /* >> */
+ { 0x1d, KEY_RESTART }, /* Reset */
+};
+DEFINE_LEGACY_IR_KEYTABLE(msi_tvanywhere_plus);
+#else
+DECLARE_IR_KEYTABLE(msi_tvanywhere_plus);
+#endif
diff --git a/include/media/keycodes/msi-tvanywhere.h b/include/media/keycodes/msi-tvanywhere.h
new file mode 100644
index 0000000..2f4cfe1
--- /dev/null
+++ b/include/media/keycodes/msi-tvanywhere.h
@@ -0,0 +1,44 @@
+/* msi-tvanywhere.h - Keytable for msi_tvanywhere Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode msi_tvanywhere[] = {
+ /* Keys 0 to 9 */
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x0c, KEY_MUTE },
+ { 0x0f, KEY_SCREEN }, /* Full Screen */
+ { 0x10, KEY_FN }, /* Funtion */
+ { 0x11, KEY_TIME }, /* Time shift */
+ { 0x12, KEY_POWER },
+ { 0x13, KEY_MEDIA }, /* MTS */
+ { 0x14, KEY_SLOW },
+ { 0x16, KEY_REWIND }, /* backward << */
+ { 0x17, KEY_ENTER }, /* Return */
+ { 0x18, KEY_FASTFORWARD }, /* forward >> */
+ { 0x1a, KEY_CHANNELUP },
+ { 0x1b, KEY_VOLUMEUP },
+ { 0x1e, KEY_CHANNELDOWN },
+ { 0x1f, KEY_VOLUMEDOWN },
+};
+DEFINE_LEGACY_IR_KEYTABLE(msi_tvanywhere);
+#else
+DECLARE_IR_KEYTABLE(msi_tvanywhere);
+#endif
diff --git a/include/media/keycodes/nebula.h b/include/media/keycodes/nebula.h
new file mode 100644
index 0000000..4e2eb1f
--- /dev/null
+++ b/include/media/keycodes/nebula.h
@@ -0,0 +1,73 @@
+/* nebula.h - Keytable for nebula Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode nebula[] = {
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+ { 0x0a, KEY_TV },
+ { 0x0b, KEY_AUX },
+ { 0x0c, KEY_DVD },
+ { 0x0d, KEY_POWER },
+ { 0x0e, KEY_MHP }, /* labelled 'Picture' */
+ { 0x0f, KEY_AUDIO },
+ { 0x10, KEY_INFO },
+ { 0x11, KEY_F13 }, /* 16:9 */
+ { 0x12, KEY_F14 }, /* 14:9 */
+ { 0x13, KEY_EPG },
+ { 0x14, KEY_EXIT },
+ { 0x15, KEY_MENU },
+ { 0x16, KEY_UP },
+ { 0x17, KEY_DOWN },
+ { 0x18, KEY_LEFT },
+ { 0x19, KEY_RIGHT },
+ { 0x1a, KEY_ENTER },
+ { 0x1b, KEY_CHANNELUP },
+ { 0x1c, KEY_CHANNELDOWN },
+ { 0x1d, KEY_VOLUMEUP },
+ { 0x1e, KEY_VOLUMEDOWN },
+ { 0x1f, KEY_RED },
+ { 0x20, KEY_GREEN },
+ { 0x21, KEY_YELLOW },
+ { 0x22, KEY_BLUE },
+ { 0x23, KEY_SUBTITLE },
+ { 0x24, KEY_F15 }, /* AD */
+ { 0x25, KEY_TEXT },
+ { 0x26, KEY_MUTE },
+ { 0x27, KEY_REWIND },
+ { 0x28, KEY_STOP },
+ { 0x29, KEY_PLAY },
+ { 0x2a, KEY_FASTFORWARD },
+ { 0x2b, KEY_F16 }, /* chapter */
+ { 0x2c, KEY_PAUSE },
+ { 0x2d, KEY_PLAY },
+ { 0x2e, KEY_RECORD },
+ { 0x2f, KEY_F17 }, /* picture in picture */
+ { 0x30, KEY_KPPLUS }, /* zoom in */
+ { 0x31, KEY_KPMINUS }, /* zoom out */
+ { 0x32, KEY_F18 }, /* capture */
+ { 0x33, KEY_F19 }, /* web */
+ { 0x34, KEY_EMAIL },
+ { 0x35, KEY_PHONE },
+ { 0x36, KEY_PC },
+};
+DEFINE_LEGACY_IR_KEYTABLE(nebula);
+#else
+DECLARE_IR_KEYTABLE(nebula);
+#endif
diff --git a/include/media/keycodes/nec-terratec-cinergy-xs.h b/include/media/keycodes/nec-terratec-cinergy-xs.h
new file mode 100644
index 0000000..39ede1e
--- /dev/null
+++ b/include/media/keycodes/nec-terratec-cinergy-xs.h
@@ -0,0 +1,81 @@
+/* nec-terratec-cinergy-xs.h - Keytable for nec_terratec_cinergy_xs Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Terratec Cinergy Hybrid T USB XS FM
+ Mauro Carvalho Chehab <mchehab@redhat.com>
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode nec_terratec_cinergy_xs[] = {
+ { 0x1441, KEY_HOME},
+ { 0x1401, KEY_POWER2},
+
+ { 0x1442, KEY_MENU}, /* DVD menu */
+ { 0x1443, KEY_SUBTITLE},
+ { 0x1444, KEY_TEXT}, /* Teletext */
+ { 0x1445, KEY_DELETE},
+
+ { 0x1402, KEY_1},
+ { 0x1403, KEY_2},
+ { 0x1404, KEY_3},
+ { 0x1405, KEY_4},
+ { 0x1406, KEY_5},
+ { 0x1407, KEY_6},
+ { 0x1408, KEY_7},
+ { 0x1409, KEY_8},
+ { 0x140a, KEY_9},
+ { 0x140c, KEY_0},
+
+ { 0x140b, KEY_TUNER}, /* AV */
+ { 0x140d, KEY_MODE}, /* A.B */
+
+ { 0x1446, KEY_TV},
+ { 0x1447, KEY_DVD},
+ { 0x1449, KEY_VIDEO},
+ { 0x144a, KEY_RADIO}, /* Music */
+ { 0x144b, KEY_CAMERA}, /* PIC */
+
+ { 0x1410, KEY_UP},
+ { 0x1411, KEY_LEFT},
+ { 0x1412, KEY_OK},
+ { 0x1413, KEY_RIGHT},
+ { 0x1414, KEY_DOWN},
+
+ { 0x140f, KEY_EPG},
+ { 0x1416, KEY_INFO},
+ { 0x144d, KEY_BACKSPACE},
+
+ { 0x141c, KEY_VOLUMEUP},
+ { 0x141e, KEY_VOLUMEDOWN},
+
+ { 0x144c, KEY_PLAY},
+ { 0x141d, KEY_MUTE},
+
+ { 0x141b, KEY_CHANNELUP},
+ { 0x141f, KEY_CHANNELDOWN},
+
+ { 0x1417, KEY_RED},
+ { 0x1418, KEY_GREEN},
+ { 0x1419, KEY_YELLOW},
+ { 0x141a, KEY_BLUE},
+
+ { 0x1458, KEY_RECORD},
+ { 0x1448, KEY_STOP},
+ { 0x1440, KEY_PAUSE},
+
+ { 0x1454, KEY_LAST},
+ { 0x144e, KEY_REWIND},
+ { 0x144f, KEY_FASTFORWARD},
+ { 0x145c, KEY_NEXT},
+};
+DEFINE_IR_KEYTABLE(nec_terratec_cinergy_xs, IR_TYPE_NEC);
+#else
+DECLARE_IR_KEYTABLE(nec_terratec_cinergy_xs);
+#endif
diff --git a/include/media/keycodes/norwood.h b/include/media/keycodes/norwood.h
new file mode 100644
index 0000000..7f6cc4c
--- /dev/null
+++ b/include/media/keycodes/norwood.h
@@ -0,0 +1,61 @@
+/* norwood.h - Keytable for norwood Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Norwood Micro (non-Pro) TV Tuner
+ By Peter Naulls <peter@chocky.org>
+ Key comments are the functions given in the manual */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode norwood[] = {
+ /* Keys 0 to 9 */
+ { 0x20, KEY_0 },
+ { 0x21, KEY_1 },
+ { 0x22, KEY_2 },
+ { 0x23, KEY_3 },
+ { 0x24, KEY_4 },
+ { 0x25, KEY_5 },
+ { 0x26, KEY_6 },
+ { 0x27, KEY_7 },
+ { 0x28, KEY_8 },
+ { 0x29, KEY_9 },
+
+ { 0x78, KEY_TUNER }, /* Video Source */
+ { 0x2c, KEY_EXIT }, /* Open/Close software */
+ { 0x2a, KEY_SELECT }, /* 2 Digit Select */
+ { 0x69, KEY_AGAIN }, /* Recall */
+
+ { 0x32, KEY_BRIGHTNESSUP }, /* Brightness increase */
+ { 0x33, KEY_BRIGHTNESSDOWN }, /* Brightness decrease */
+ { 0x6b, KEY_KPPLUS }, /* (not named >>>>>) */
+ { 0x6c, KEY_KPMINUS }, /* (not named <<<<<) */
+
+ { 0x2d, KEY_MUTE }, /* Mute */
+ { 0x30, KEY_VOLUMEUP }, /* Volume up */
+ { 0x31, KEY_VOLUMEDOWN }, /* Volume down */
+ { 0x60, KEY_CHANNELUP }, /* Channel up */
+ { 0x61, KEY_CHANNELDOWN }, /* Channel down */
+
+ { 0x3f, KEY_RECORD }, /* Record */
+ { 0x37, KEY_PLAY }, /* Play */
+ { 0x36, KEY_PAUSE }, /* Pause */
+ { 0x2b, KEY_STOP }, /* Stop */
+ { 0x67, KEY_FASTFORWARD }, /* Foward */
+ { 0x66, KEY_REWIND }, /* Rewind */
+ { 0x3e, KEY_SEARCH }, /* Auto Scan */
+ { 0x2e, KEY_CAMERA }, /* Capture Video */
+ { 0x6d, KEY_MENU }, /* Show/Hide Control */
+ { 0x2f, KEY_ZOOM }, /* Full Screen */
+ { 0x34, KEY_RADIO }, /* FM */
+ { 0x65, KEY_POWER }, /* Computer power */
+};
+DEFINE_LEGACY_IR_KEYTABLE(norwood);
+#else
+DECLARE_IR_KEYTABLE(norwood);
+#endif
diff --git a/include/media/keycodes/npgtech.h b/include/media/keycodes/npgtech.h
new file mode 100644
index 0000000..dd1ba82
--- /dev/null
+++ b/include/media/keycodes/npgtech.h
@@ -0,0 +1,57 @@
+/* npgtech.h - Keytable for npgtech Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode npgtech[] = {
+ { 0x1d, KEY_SWITCHVIDEOMODE }, /* switch inputs */
+ { 0x2a, KEY_FRONT },
+
+ { 0x3e, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x06, KEY_3 },
+ { 0x0a, KEY_4 },
+ { 0x0e, KEY_5 },
+ { 0x12, KEY_6 },
+ { 0x16, KEY_7 },
+ { 0x1a, KEY_8 },
+ { 0x1e, KEY_9 },
+ { 0x3a, KEY_0 },
+ { 0x22, KEY_NUMLOCK }, /* -/-- */
+ { 0x20, KEY_REFRESH },
+
+ { 0x03, KEY_BRIGHTNESSDOWN },
+ { 0x28, KEY_AUDIO },
+ { 0x3c, KEY_CHANNELUP },
+ { 0x3f, KEY_VOLUMEDOWN },
+ { 0x2e, KEY_MUTE },
+ { 0x3b, KEY_VOLUMEUP },
+ { 0x00, KEY_CHANNELDOWN },
+ { 0x07, KEY_BRIGHTNESSUP },
+ { 0x2c, KEY_TEXT },
+
+ { 0x37, KEY_RECORD },
+ { 0x17, KEY_PLAY },
+ { 0x13, KEY_PAUSE },
+ { 0x26, KEY_STOP },
+ { 0x18, KEY_FASTFORWARD },
+ { 0x14, KEY_REWIND },
+ { 0x33, KEY_ZOOM },
+ { 0x32, KEY_KEYBOARD },
+ { 0x30, KEY_GOTO }, /* Pointing arrow */
+ { 0x36, KEY_MACRO }, /* Maximize/Minimize (yellow) */
+ { 0x0b, KEY_RADIO },
+ { 0x10, KEY_POWER },
+
+};
+DEFINE_LEGACY_IR_KEYTABLE(npgtech);
+#else
+DECLARE_IR_KEYTABLE(npgtech);
+#endif
diff --git a/include/media/keycodes/pctv-sedna.h b/include/media/keycodes/pctv-sedna.h
new file mode 100644
index 0000000..b1d511f
--- /dev/null
+++ b/include/media/keycodes/pctv-sedna.h
@@ -0,0 +1,56 @@
+/* pctv-sedna.h - Keytable for pctv_sedna Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Mapping for the 28 key remote control as seen at
+ http://www.sednacomputer.com/photo/cardbus-tv.jpg
+ Pavel Mihaylov <bin@bash.info>
+ Also for the remote bundled with Kozumi KTV-01C card */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode pctv_sedna[] = {
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x0a, KEY_AGAIN }, /* Recall */
+ { 0x0b, KEY_CHANNELUP },
+ { 0x0c, KEY_VOLUMEUP },
+ { 0x0d, KEY_MODE }, /* Stereo */
+ { 0x0e, KEY_STOP },
+ { 0x0f, KEY_PREVIOUSSONG },
+ { 0x10, KEY_ZOOM },
+ { 0x11, KEY_TUNER }, /* Source */
+ { 0x12, KEY_POWER },
+ { 0x13, KEY_MUTE },
+ { 0x15, KEY_CHANNELDOWN },
+ { 0x18, KEY_VOLUMEDOWN },
+ { 0x19, KEY_CAMERA }, /* Snapshot */
+ { 0x1a, KEY_NEXTSONG },
+ { 0x1b, KEY_TIME }, /* Time Shift */
+ { 0x1c, KEY_RADIO }, /* FM Radio */
+ { 0x1d, KEY_RECORD },
+ { 0x1e, KEY_PAUSE },
+ /* additional codes for Kozumi's remote */
+ { 0x14, KEY_INFO }, /* OSD */
+ { 0x16, KEY_OK }, /* OK */
+ { 0x17, KEY_DIGITS }, /* Plus */
+ { 0x1f, KEY_PLAY }, /* Play */
+};
+DEFINE_LEGACY_IR_KEYTABLE(pctv_sedna);
+#else
+DECLARE_IR_KEYTABLE(pctv_sedna);
+#endif
diff --git a/include/media/keycodes/pinnacle-color.h b/include/media/keycodes/pinnacle-color.h
new file mode 100644
index 0000000..a08eaeb
--- /dev/null
+++ b/include/media/keycodes/pinnacle-color.h
@@ -0,0 +1,71 @@
+/* pinnacle-color.h - Keytable for pinnacle_color Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode pinnacle_color[] = {
+ { 0x59, KEY_MUTE },
+ { 0x4a, KEY_POWER },
+
+ { 0x18, KEY_TEXT },
+ { 0x26, KEY_TV },
+ { 0x3d, KEY_PRINT },
+
+ { 0x48, KEY_RED },
+ { 0x04, KEY_GREEN },
+ { 0x11, KEY_YELLOW },
+ { 0x00, KEY_BLUE },
+
+ { 0x2d, KEY_VOLUMEUP },
+ { 0x1e, KEY_VOLUMEDOWN },
+
+ { 0x49, KEY_MENU },
+
+ { 0x16, KEY_CHANNELUP },
+ { 0x17, KEY_CHANNELDOWN },
+
+ { 0x20, KEY_UP },
+ { 0x21, KEY_DOWN },
+ { 0x22, KEY_LEFT },
+ { 0x23, KEY_RIGHT },
+ { 0x0d, KEY_SELECT },
+
+ { 0x08, KEY_BACK },
+ { 0x07, KEY_REFRESH },
+
+ { 0x2f, KEY_ZOOM },
+ { 0x29, KEY_RECORD },
+
+ { 0x4b, KEY_PAUSE },
+ { 0x4d, KEY_REWIND },
+ { 0x2e, KEY_PLAY },
+ { 0x4e, KEY_FORWARD },
+ { 0x53, KEY_PREVIOUS },
+ { 0x4c, KEY_STOP },
+ { 0x54, KEY_NEXT },
+
+ { 0x69, KEY_0 },
+ { 0x6a, KEY_1 },
+ { 0x6b, KEY_2 },
+ { 0x6c, KEY_3 },
+ { 0x6d, KEY_4 },
+ { 0x6e, KEY_5 },
+ { 0x6f, KEY_6 },
+ { 0x70, KEY_7 },
+ { 0x71, KEY_8 },
+ { 0x72, KEY_9 },
+
+ { 0x74, KEY_CHANNEL },
+ { 0x0a, KEY_BACKSPACE },
+};
+DEFINE_LEGACY_IR_KEYTABLE(pinnacle_color);
+#else
+DECLARE_IR_KEYTABLE(pinnacle_color);
+#endif
diff --git a/include/media/keycodes/pinnacle-grey.h b/include/media/keycodes/pinnacle-grey.h
new file mode 100644
index 0000000..3fd2504
--- /dev/null
+++ b/include/media/keycodes/pinnacle-grey.h
@@ -0,0 +1,66 @@
+/* pinnacle-grey.h - Keytable for pinnacle_grey Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode pinnacle_grey[] = {
+ { 0x3a, KEY_0 },
+ { 0x31, KEY_1 },
+ { 0x32, KEY_2 },
+ { 0x33, KEY_3 },
+ { 0x34, KEY_4 },
+ { 0x35, KEY_5 },
+ { 0x36, KEY_6 },
+ { 0x37, KEY_7 },
+ { 0x38, KEY_8 },
+ { 0x39, KEY_9 },
+
+ { 0x2f, KEY_POWER },
+
+ { 0x2e, KEY_P },
+ { 0x1f, KEY_L },
+ { 0x2b, KEY_I },
+
+ { 0x2d, KEY_SCREEN },
+ { 0x1e, KEY_ZOOM },
+ { 0x1b, KEY_VOLUMEUP },
+ { 0x0f, KEY_VOLUMEDOWN },
+ { 0x17, KEY_CHANNELUP },
+ { 0x1c, KEY_CHANNELDOWN },
+ { 0x25, KEY_INFO },
+
+ { 0x3c, KEY_MUTE },
+
+ { 0x3d, KEY_LEFT },
+ { 0x3b, KEY_RIGHT },
+
+ { 0x3f, KEY_UP },
+ { 0x3e, KEY_DOWN },
+ { 0x1a, KEY_ENTER },
+
+ { 0x1d, KEY_MENU },
+ { 0x19, KEY_AGAIN },
+ { 0x16, KEY_PREVIOUSSONG },
+ { 0x13, KEY_NEXTSONG },
+ { 0x15, KEY_PAUSE },
+ { 0x0e, KEY_REWIND },
+ { 0x0d, KEY_PLAY },
+ { 0x0b, KEY_STOP },
+ { 0x07, KEY_FORWARD },
+ { 0x27, KEY_RECORD },
+ { 0x26, KEY_TUNER },
+ { 0x29, KEY_TEXT },
+ { 0x2a, KEY_MEDIA },
+ { 0x18, KEY_EPG },
+};
+DEFINE_LEGACY_IR_KEYTABLE(pinnacle_grey);
+#else
+DECLARE_IR_KEYTABLE(pinnacle_grey);
+#endif
diff --git a/include/media/keycodes/pinnacle-pctv-hd.h b/include/media/keycodes/pinnacle-pctv-hd.h
new file mode 100644
index 0000000..be72d50
--- /dev/null
+++ b/include/media/keycodes/pinnacle-pctv-hd.h
@@ -0,0 +1,49 @@
+/* pinnacle-pctv-hd.h - Keytable for pinnacle_pctv_hd Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Pinnacle PCTV HD 800i mini remote */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode pinnacle_pctv_hd[] = {
+
+ { 0x0f, KEY_1 },
+ { 0x15, KEY_2 },
+ { 0x10, KEY_3 },
+ { 0x18, KEY_4 },
+ { 0x1b, KEY_5 },
+ { 0x1e, KEY_6 },
+ { 0x11, KEY_7 },
+ { 0x21, KEY_8 },
+ { 0x12, KEY_9 },
+ { 0x27, KEY_0 },
+
+ { 0x24, KEY_ZOOM },
+ { 0x2a, KEY_SUBTITLE },
+
+ { 0x00, KEY_MUTE },
+ { 0x01, KEY_ENTER }, /* Pinnacle Logo */
+ { 0x39, KEY_POWER },
+
+ { 0x03, KEY_VOLUMEUP },
+ { 0x09, KEY_VOLUMEDOWN },
+ { 0x06, KEY_CHANNELUP },
+ { 0x0c, KEY_CHANNELDOWN },
+
+ { 0x2d, KEY_REWIND },
+ { 0x30, KEY_PLAYPAUSE },
+ { 0x33, KEY_FASTFORWARD },
+ { 0x3c, KEY_STOP },
+ { 0x36, KEY_RECORD },
+ { 0x3f, KEY_EPG }, /* Labeled "?" */
+};
+DEFINE_LEGACY_IR_KEYTABLE(pinnacle_pctv_hd);
+#else
+DECLARE_IR_KEYTABLE(pinnacle_pctv_hd);
+#endif
diff --git a/include/media/keycodes/pixelview-new.h b/include/media/keycodes/pixelview-new.h
new file mode 100644
index 0000000..76ed0c3
--- /dev/null
+++ b/include/media/keycodes/pixelview-new.h
@@ -0,0 +1,59 @@
+/* pixelview-new.h - Keytable for pixelview_new Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/*
+ Mauro Carvalho Chehab <mchehab@infradead.org>
+ present on PV MPEG 8000GT
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode pixelview_new[] = {
+ { 0x3c, KEY_TIME }, /* Timeshift */
+ { 0x12, KEY_POWER },
+
+ { 0x3d, KEY_1 },
+ { 0x38, KEY_2 },
+ { 0x18, KEY_3 },
+ { 0x35, KEY_4 },
+ { 0x39, KEY_5 },
+ { 0x15, KEY_6 },
+ { 0x36, KEY_7 },
+ { 0x3a, KEY_8 },
+ { 0x1e, KEY_9 },
+ { 0x3e, KEY_0 },
+
+ { 0x1c, KEY_AGAIN }, /* LOOP */
+ { 0x3f, KEY_MEDIA }, /* Source */
+ { 0x1f, KEY_LAST }, /* +100 */
+ { 0x1b, KEY_MUTE },
+
+ { 0x17, KEY_CHANNELDOWN },
+ { 0x16, KEY_CHANNELUP },
+ { 0x10, KEY_VOLUMEUP },
+ { 0x14, KEY_VOLUMEDOWN },
+ { 0x13, KEY_ZOOM },
+
+ { 0x19, KEY_CAMERA }, /* SNAPSHOT */
+ { 0x1a, KEY_SEARCH }, /* scan */
+
+ { 0x37, KEY_REWIND }, /* << */
+ { 0x32, KEY_RECORD }, /* o (red) */
+ { 0x33, KEY_FORWARD }, /* >> */
+ { 0x11, KEY_STOP }, /* square */
+ { 0x3b, KEY_PLAY }, /* > */
+ { 0x30, KEY_PLAYPAUSE }, /* || */
+
+ { 0x31, KEY_TV },
+ { 0x34, KEY_RADIO },
+};
+DEFINE_LEGACY_IR_KEYTABLE(pixelview_new);
+#else
+DECLARE_IR_KEYTABLE(pixelview_new);
+#endif
diff --git a/include/media/keycodes/pixelview.h b/include/media/keycodes/pixelview.h
new file mode 100644
index 0000000..e048277
--- /dev/null
+++ b/include/media/keycodes/pixelview.h
@@ -0,0 +1,59 @@
+/* pixelview.h - Keytable for pixelview Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode pixelview[] = {
+
+ { 0x1e, KEY_POWER }, /* power */
+ { 0x07, KEY_MEDIA }, /* source */
+ { 0x1c, KEY_SEARCH }, /* scan */
+
+
+ { 0x03, KEY_TUNER }, /* TV/FM */
+
+ { 0x00, KEY_RECORD },
+ { 0x08, KEY_STOP },
+ { 0x11, KEY_PLAY },
+
+ { 0x1a, KEY_PLAYPAUSE }, /* freeze */
+ { 0x19, KEY_ZOOM }, /* zoom */
+ { 0x0f, KEY_TEXT }, /* min */
+
+ { 0x01, KEY_1 },
+ { 0x0b, KEY_2 },
+ { 0x1b, KEY_3 },
+ { 0x05, KEY_4 },
+ { 0x09, KEY_5 },
+ { 0x15, KEY_6 },
+ { 0x06, KEY_7 },
+ { 0x0a, KEY_8 },
+ { 0x12, KEY_9 },
+ { 0x02, KEY_0 },
+ { 0x10, KEY_LAST }, /* +100 */
+ { 0x13, KEY_LIST }, /* recall */
+
+ { 0x1f, KEY_CHANNELUP }, /* chn down */
+ { 0x17, KEY_CHANNELDOWN }, /* chn up */
+ { 0x16, KEY_VOLUMEUP }, /* vol down */
+ { 0x14, KEY_VOLUMEDOWN }, /* vol up */
+
+ { 0x04, KEY_KPMINUS }, /* <<< */
+ { 0x0e, KEY_SETUP }, /* function */
+ { 0x0c, KEY_KPPLUS }, /* >>> */
+
+ { 0x0d, KEY_GOTO }, /* mts */
+ { 0x1d, KEY_REFRESH }, /* reset */
+ { 0x18, KEY_MUTE }, /* mute/unmute */
+};
+DEFINE_LEGACY_IR_KEYTABLE(pixelview);
+#else
+DECLARE_IR_KEYTABLE(pixelview);
+#endif
diff --git a/include/media/keycodes/powercolor-real-angel.h b/include/media/keycodes/powercolor-real-angel.h
new file mode 100644
index 0000000..098c4a9
--- /dev/null
+++ b/include/media/keycodes/powercolor-real-angel.h
@@ -0,0 +1,57 @@
+/* powercolor-real-angel.h - Keytable for powercolor_real_angel Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/*
+ * Remote control for Powercolor Real Angel 330
+ * Daniel Fraga <fragabr@gmail.com>
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode powercolor_real_angel[] = {
+ { 0x38, KEY_SWITCHVIDEOMODE }, /* switch inputs */
+ { 0x0c, KEY_MEDIA }, /* Turn ON/OFF App */
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+ { 0x0a, KEY_DIGITS }, /* single, double, tripple digit */
+ { 0x29, KEY_PREVIOUS }, /* previous channel */
+ { 0x12, KEY_BRIGHTNESSUP },
+ { 0x13, KEY_BRIGHTNESSDOWN },
+ { 0x2b, KEY_MODE }, /* stereo/mono */
+ { 0x2c, KEY_TEXT }, /* teletext */
+ { 0x20, KEY_CHANNELUP }, /* channel up */
+ { 0x21, KEY_CHANNELDOWN }, /* channel down */
+ { 0x10, KEY_VOLUMEUP }, /* volume up */
+ { 0x11, KEY_VOLUMEDOWN }, /* volume down */
+ { 0x0d, KEY_MUTE },
+ { 0x1f, KEY_RECORD },
+ { 0x17, KEY_PLAY },
+ { 0x16, KEY_PAUSE },
+ { 0x0b, KEY_STOP },
+ { 0x27, KEY_FASTFORWARD },
+ { 0x26, KEY_REWIND },
+ { 0x1e, KEY_SEARCH }, /* autoscan */
+ { 0x0e, KEY_CAMERA }, /* snapshot */
+ { 0x2d, KEY_SETUP },
+ { 0x0f, KEY_SCREEN }, /* full screen */
+ { 0x14, KEY_RADIO }, /* FM radio */
+ { 0x25, KEY_POWER }, /* power */
+};
+DEFINE_LEGACY_IR_KEYTABLE(powercolor_real_angel);
+#else
+DECLARE_IR_KEYTABLE(powercolor_real_angel);
+#endif
diff --git a/include/media/keycodes/proteus-2309.h b/include/media/keycodes/proteus-2309.h
new file mode 100644
index 0000000..1993702
--- /dev/null
+++ b/include/media/keycodes/proteus-2309.h
@@ -0,0 +1,45 @@
+/* proteus-2309.h - Keytable for proteus_2309 Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Michal Majchrowicz <mmajchrowicz@gmail.com> */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode proteus_2309[] = {
+ /* numeric */
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x5c, KEY_POWER }, /* power */
+ { 0x20, KEY_ZOOM }, /* full screen */
+ { 0x0f, KEY_BACKSPACE }, /* recall */
+ { 0x1b, KEY_ENTER }, /* mute */
+ { 0x41, KEY_RECORD }, /* record */
+ { 0x43, KEY_STOP }, /* stop */
+ { 0x16, KEY_S },
+ { 0x1a, KEY_POWER2 }, /* off */
+ { 0x2e, KEY_RED },
+ { 0x1f, KEY_CHANNELDOWN }, /* channel - */
+ { 0x1c, KEY_CHANNELUP }, /* channel + */
+ { 0x10, KEY_VOLUMEDOWN }, /* volume - */
+ { 0x1e, KEY_VOLUMEUP }, /* volume + */
+ { 0x14, KEY_F1 },
+};
+DEFINE_LEGACY_IR_KEYTABLE(proteus_2309);
+#else
+DECLARE_IR_KEYTABLE(proteus_2309);
+#endif
diff --git a/include/media/keycodes/purpletv.h b/include/media/keycodes/purpletv.h
new file mode 100644
index 0000000..1496264
--- /dev/null
+++ b/include/media/keycodes/purpletv.h
@@ -0,0 +1,58 @@
+/* purpletv.h - Keytable for purpletv Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode purpletv[] = {
+ { 0x03, KEY_POWER },
+ { 0x6f, KEY_MUTE },
+ { 0x10, KEY_BACKSPACE }, /* Recall */
+
+ { 0x11, KEY_0 },
+ { 0x04, KEY_1 },
+ { 0x05, KEY_2 },
+ { 0x06, KEY_3 },
+ { 0x08, KEY_4 },
+ { 0x09, KEY_5 },
+ { 0x0a, KEY_6 },
+ { 0x0c, KEY_7 },
+ { 0x0d, KEY_8 },
+ { 0x0e, KEY_9 },
+ { 0x12, KEY_DOT }, /* 100+ */
+
+ { 0x07, KEY_VOLUMEUP },
+ { 0x0b, KEY_VOLUMEDOWN },
+ { 0x1a, KEY_KPPLUS },
+ { 0x18, KEY_KPMINUS },
+ { 0x15, KEY_UP },
+ { 0x1d, KEY_DOWN },
+ { 0x0f, KEY_CHANNELUP },
+ { 0x13, KEY_CHANNELDOWN },
+ { 0x48, KEY_ZOOM },
+
+ { 0x1b, KEY_VIDEO }, /* Video source */
+ { 0x1f, KEY_CAMERA }, /* Snapshot */
+ { 0x49, KEY_LANGUAGE }, /* MTS Select */
+ { 0x19, KEY_SEARCH }, /* Auto Scan */
+
+ { 0x4b, KEY_RECORD },
+ { 0x46, KEY_PLAY },
+ { 0x45, KEY_PAUSE }, /* Pause */
+ { 0x44, KEY_STOP },
+ { 0x43, KEY_TIME }, /* Time Shift */
+ { 0x17, KEY_CHANNEL }, /* SURF CH */
+ { 0x40, KEY_FORWARD }, /* Forward ? */
+ { 0x42, KEY_REWIND }, /* Backward ? */
+
+};
+DEFINE_LEGACY_IR_KEYTABLE(purpletv);
+#else
+DECLARE_IR_KEYTABLE(purpletv);
+#endif
diff --git a/include/media/keycodes/pv951.h b/include/media/keycodes/pv951.h
new file mode 100644
index 0000000..33a8bf7
--- /dev/null
+++ b/include/media/keycodes/pv951.h
@@ -0,0 +1,54 @@
+/* pv951.h - Keytable for pv951 Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Mark Phalan <phalanm@o2.ie> */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode pv951[] = {
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x12, KEY_POWER },
+ { 0x10, KEY_MUTE },
+ { 0x1f, KEY_VOLUMEDOWN },
+ { 0x1b, KEY_VOLUMEUP },
+ { 0x1a, KEY_CHANNELUP },
+ { 0x1e, KEY_CHANNELDOWN },
+ { 0x0e, KEY_PAGEUP },
+ { 0x1d, KEY_PAGEDOWN },
+ { 0x13, KEY_SOUND },
+
+ { 0x18, KEY_KPPLUSMINUS }, /* CH +/- */
+ { 0x16, KEY_SUBTITLE }, /* CC */
+ { 0x0d, KEY_TEXT }, /* TTX */
+ { 0x0b, KEY_TV }, /* AIR/CBL */
+ { 0x11, KEY_PC }, /* PC/TV */
+ { 0x17, KEY_OK }, /* CH RTN */
+ { 0x19, KEY_MODE }, /* FUNC */
+ { 0x0c, KEY_SEARCH }, /* AUTOSCAN */
+
+ /* Not sure what to do with these ones! */
+ { 0x0f, KEY_SELECT }, /* SOURCE */
+ { 0x0a, KEY_KPPLUS }, /* +100 */
+ { 0x14, KEY_EQUAL }, /* SYNC */
+ { 0x1c, KEY_MEDIA }, /* PC/TV */
+};
+DEFINE_LEGACY_IR_KEYTABLE(pv951);
+#else
+DECLARE_IR_KEYTABLE(pv951);
+#endif
diff --git a/include/media/keycodes/rc5-hauppauge-new.h b/include/media/keycodes/rc5-hauppauge-new.h
new file mode 100644
index 0000000..f02b59a
--- /dev/null
+++ b/include/media/keycodes/rc5-hauppauge-new.h
@@ -0,0 +1,79 @@
+/* rc5-hauppauge-new.h - Keytable for rc5_hauppauge_new Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/*
+ * Hauppauge:the newer, gray remotes (seems there are multiple
+ * slightly different versions), shipped with cx88+ivtv cards.
+ *
+ * This table contains the complete RC5 code, instead of just the data part
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode rc5_hauppauge_new[] = {
+ /* Keys 0 to 9 */
+ { 0x1e00, KEY_0 },
+ { 0x1e01, KEY_1 },
+ { 0x1e02, KEY_2 },
+ { 0x1e03, KEY_3 },
+ { 0x1e04, KEY_4 },
+ { 0x1e05, KEY_5 },
+ { 0x1e06, KEY_6 },
+ { 0x1e07, KEY_7 },
+ { 0x1e08, KEY_8 },
+ { 0x1e09, KEY_9 },
+
+ { 0x1e0a, KEY_TEXT }, /* keypad asterisk as well */
+ { 0x1e0b, KEY_RED }, /* red button */
+ { 0x1e0c, KEY_RADIO },
+ { 0x1e0d, KEY_MENU },
+ { 0x1e0e, KEY_SUBTITLE }, /* also the # key */
+ { 0x1e0f, KEY_MUTE },
+ { 0x1e10, KEY_VOLUMEUP },
+ { 0x1e11, KEY_VOLUMEDOWN },
+ { 0x1e12, KEY_PREVIOUS }, /* previous channel */
+ { 0x1e14, KEY_UP },
+ { 0x1e15, KEY_DOWN },
+ { 0x1e16, KEY_LEFT },
+ { 0x1e17, KEY_RIGHT },
+ { 0x1e18, KEY_VIDEO }, /* Videos */
+ { 0x1e19, KEY_AUDIO }, /* Music */
+ /* 0x1e1a: Pictures - presume this means
+ "Multimedia Home Platform" -
+ no "PICTURES" key in input.h
+ */
+ { 0x1e1a, KEY_MHP },
+
+ { 0x1e1b, KEY_EPG }, /* Guide */
+ { 0x1e1c, KEY_TV },
+ { 0x1e1e, KEY_NEXTSONG }, /* skip >| */
+ { 0x1e1f, KEY_EXIT }, /* back/exit */
+ { 0x1e20, KEY_CHANNELUP }, /* channel / program + */
+ { 0x1e21, KEY_CHANNELDOWN }, /* channel / program - */
+ { 0x1e22, KEY_CHANNEL }, /* source (old black remote) */
+ { 0x1e24, KEY_PREVIOUSSONG }, /* replay |< */
+ { 0x1e25, KEY_ENTER }, /* OK */
+ { 0x1e26, KEY_SLEEP }, /* minimize (old black remote) */
+ { 0x1e29, KEY_BLUE }, /* blue key */
+ { 0x1e2e, KEY_GREEN }, /* green button */
+ { 0x1e30, KEY_PAUSE }, /* pause */
+ { 0x1e32, KEY_REWIND }, /* backward << */
+ { 0x1e34, KEY_FASTFORWARD }, /* forward >> */
+ { 0x1e35, KEY_PLAY },
+ { 0x1e36, KEY_STOP },
+ { 0x1e37, KEY_RECORD }, /* recording */
+ { 0x1e38, KEY_YELLOW }, /* yellow key */
+ { 0x1e3b, KEY_SELECT }, /* top right button */
+ { 0x1e3c, KEY_ZOOM }, /* full */
+ { 0x1e3d, KEY_POWER }, /* system power (green button) */
+};
+DEFINE_IR_KEYTABLE(rc5_hauppauge_new, IR_TYPE_RC5);
+#else
+DECLARE_IR_KEYTABLE(rc5_hauppauge_new);
+#endif
diff --git a/include/media/keycodes/rc5-tv.h b/include/media/keycodes/rc5-tv.h
new file mode 100644
index 0000000..a429a54
--- /dev/null
+++ b/include/media/keycodes/rc5-tv.h
@@ -0,0 +1,57 @@
+/* rc5-tv.h - Keytable for rc5_tv Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* generic RC5 keytable */
+/* see http://users.pandora.be/nenya/electronics/rc5/codes00.htm */
+/* used by old (black) Hauppauge remotes */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode rc5_tv[] = {
+ /* Keys 0 to 9 */
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x0b, KEY_CHANNEL }, /* channel / program (japan: 11) */
+ { 0x0c, KEY_POWER }, /* standby */
+ { 0x0d, KEY_MUTE }, /* mute / demute */
+ { 0x0f, KEY_TV }, /* display */
+ { 0x10, KEY_VOLUMEUP },
+ { 0x11, KEY_VOLUMEDOWN },
+ { 0x12, KEY_BRIGHTNESSUP },
+ { 0x13, KEY_BRIGHTNESSDOWN },
+ { 0x1e, KEY_SEARCH }, /* search + */
+ { 0x20, KEY_CHANNELUP }, /* channel / program + */
+ { 0x21, KEY_CHANNELDOWN }, /* channel / program - */
+ { 0x22, KEY_CHANNEL }, /* alt / channel */
+ { 0x23, KEY_LANGUAGE }, /* 1st / 2nd language */
+ { 0x26, KEY_SLEEP }, /* sleeptimer */
+ { 0x2e, KEY_MENU }, /* 2nd controls (USA: menu) */
+ { 0x30, KEY_PAUSE },
+ { 0x32, KEY_REWIND },
+ { 0x33, KEY_GOTO },
+ { 0x35, KEY_PLAY },
+ { 0x36, KEY_STOP },
+ { 0x37, KEY_RECORD }, /* recording */
+ { 0x3c, KEY_TEXT }, /* teletext submode (Japan: 12) */
+ { 0x3d, KEY_SUSPEND }, /* system standby */
+
+};
+DEFINE_LEGACY_IR_KEYTABLE(rc5_tv);
+#else
+DECLARE_IR_KEYTABLE(rc5_tv);
+#endif
diff --git a/include/media/keycodes/real-audio-220-32-keys.h b/include/media/keycodes/real-audio-220-32-keys.h
new file mode 100644
index 0000000..5f6835d
--- /dev/null
+++ b/include/media/keycodes/real-audio-220-32-keys.h
@@ -0,0 +1,54 @@
+/* real-audio-220-32-keys.h - Keytable for real_audio_220_32_keys Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Zogis Real Audio 220 - 32 keys IR */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode real_audio_220_32_keys[] = {
+ { 0x1c, KEY_RADIO},
+ { 0x12, KEY_POWER2},
+
+ { 0x01, KEY_1},
+ { 0x02, KEY_2},
+ { 0x03, KEY_3},
+ { 0x04, KEY_4},
+ { 0x05, KEY_5},
+ { 0x06, KEY_6},
+ { 0x07, KEY_7},
+ { 0x08, KEY_8},
+ { 0x09, KEY_9},
+ { 0x00, KEY_0},
+
+ { 0x0c, KEY_VOLUMEUP},
+ { 0x18, KEY_VOLUMEDOWN},
+ { 0x0b, KEY_CHANNELUP},
+ { 0x15, KEY_CHANNELDOWN},
+ { 0x16, KEY_ENTER},
+
+ { 0x11, KEY_LIST}, /* Source */
+ { 0x0d, KEY_AUDIO}, /* stereo */
+
+ { 0x0f, KEY_PREVIOUS}, /* Prev */
+ { 0x1b, KEY_TIME}, /* Timeshift */
+ { 0x1a, KEY_NEXT}, /* Next */
+
+ { 0x0e, KEY_STOP},
+ { 0x1f, KEY_PLAY},
+ { 0x1e, KEY_PLAYPAUSE}, /* Pause */
+
+ { 0x1d, KEY_RECORD},
+ { 0x13, KEY_MUTE},
+ { 0x19, KEY_CAMERA}, /* Snapshot */
+
+};
+DEFINE_LEGACY_IR_KEYTABLE(real_audio_220_32_keys);
+#else
+DECLARE_IR_KEYTABLE(real_audio_220_32_keys);
+#endif
diff --git a/include/media/keycodes/tbs-nec.h b/include/media/keycodes/tbs-nec.h
new file mode 100644
index 0000000..156985e
--- /dev/null
+++ b/include/media/keycodes/tbs-nec.h
@@ -0,0 +1,50 @@
+/* tbs-nec.h - Keytable for tbs_nec Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode tbs_nec[] = {
+ { 0x04, KEY_POWER2}, /*power*/
+ { 0x14, KEY_MUTE}, /*mute*/
+ { 0x07, KEY_1},
+ { 0x06, KEY_2},
+ { 0x05, KEY_3},
+ { 0x0b, KEY_4},
+ { 0x0a, KEY_5},
+ { 0x09, KEY_6},
+ { 0x0f, KEY_7},
+ { 0x0e, KEY_8},
+ { 0x0d, KEY_9},
+ { 0x12, KEY_0},
+ { 0x16, KEY_CHANNELUP}, /*ch+*/
+ { 0x11, KEY_CHANNELDOWN},/*ch-*/
+ { 0x13, KEY_VOLUMEUP}, /*vol+*/
+ { 0x0c, KEY_VOLUMEDOWN},/*vol-*/
+ { 0x03, KEY_RECORD}, /*rec*/
+ { 0x18, KEY_PAUSE}, /*pause*/
+ { 0x19, KEY_OK}, /*ok*/
+ { 0x1a, KEY_CAMERA}, /* snapshot */
+ { 0x01, KEY_UP},
+ { 0x10, KEY_LEFT},
+ { 0x02, KEY_RIGHT},
+ { 0x08, KEY_DOWN},
+ { 0x15, KEY_FAVORITES},
+ { 0x17, KEY_SUBTITLE},
+ { 0x1d, KEY_ZOOM},
+ { 0x1f, KEY_EXIT},
+ { 0x1e, KEY_MENU},
+ { 0x1c, KEY_EPG},
+ { 0x00, KEY_PREVIOUS},
+ { 0x1b, KEY_MODE},
+};
+DEFINE_LEGACY_IR_KEYTABLE(tbs_nec);
+#else
+DECLARE_IR_KEYTABLE(tbs_nec);
+#endif
diff --git a/include/media/keycodes/terratec-cinergy-xs.h b/include/media/keycodes/terratec-cinergy-xs.h
new file mode 100644
index 0000000..8f50fae
--- /dev/null
+++ b/include/media/keycodes/terratec-cinergy-xs.h
@@ -0,0 +1,68 @@
+/* terratec-cinergy-xs.h - Keytable for terratec_cinergy_xs Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Terratec Cinergy Hybrid T USB XS
+ Devin Heitmueller <dheitmueller@linuxtv.org>
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode terratec_cinergy_xs[] = {
+ { 0x41, KEY_HOME},
+ { 0x01, KEY_POWER},
+ { 0x42, KEY_MENU},
+ { 0x02, KEY_1},
+ { 0x03, KEY_2},
+ { 0x04, KEY_3},
+ { 0x43, KEY_SUBTITLE},
+ { 0x05, KEY_4},
+ { 0x06, KEY_5},
+ { 0x07, KEY_6},
+ { 0x44, KEY_TEXT},
+ { 0x08, KEY_7},
+ { 0x09, KEY_8},
+ { 0x0a, KEY_9},
+ { 0x45, KEY_DELETE},
+ { 0x0b, KEY_TUNER},
+ { 0x0c, KEY_0},
+ { 0x0d, KEY_MODE},
+ { 0x46, KEY_TV},
+ { 0x47, KEY_DVD},
+ { 0x49, KEY_VIDEO},
+ { 0x4b, KEY_AUX},
+ { 0x10, KEY_UP},
+ { 0x11, KEY_LEFT},
+ { 0x12, KEY_OK},
+ { 0x13, KEY_RIGHT},
+ { 0x14, KEY_DOWN},
+ { 0x0f, KEY_EPG},
+ { 0x16, KEY_INFO},
+ { 0x4d, KEY_BACKSPACE},
+ { 0x1c, KEY_VOLUMEUP},
+ { 0x4c, KEY_PLAY},
+ { 0x1b, KEY_CHANNELUP},
+ { 0x1e, KEY_VOLUMEDOWN},
+ { 0x1d, KEY_MUTE},
+ { 0x1f, KEY_CHANNELDOWN},
+ { 0x17, KEY_RED},
+ { 0x18, KEY_GREEN},
+ { 0x19, KEY_YELLOW},
+ { 0x1a, KEY_BLUE},
+ { 0x58, KEY_RECORD},
+ { 0x48, KEY_STOP},
+ { 0x40, KEY_PAUSE},
+ { 0x54, KEY_LAST},
+ { 0x4e, KEY_REWIND},
+ { 0x4f, KEY_FASTFORWARD},
+ { 0x5c, KEY_NEXT},
+};
+DEFINE_LEGACY_IR_KEYTABLE(terratec_cinergy_xs);
+#else
+DECLARE_IR_KEYTABLE(terratec_cinergy_xs);
+#endif
diff --git a/include/media/keycodes/tevii-nec.h b/include/media/keycodes/tevii-nec.h
new file mode 100644
index 0000000..6a8ea03
--- /dev/null
+++ b/include/media/keycodes/tevii-nec.h
@@ -0,0 +1,65 @@
+/* tevii-nec.h - Keytable for tevii_nec Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode tevii_nec[] = {
+ { 0x0a, KEY_POWER2},
+ { 0x0c, KEY_MUTE},
+ { 0x11, KEY_1},
+ { 0x12, KEY_2},
+ { 0x13, KEY_3},
+ { 0x14, KEY_4},
+ { 0x15, KEY_5},
+ { 0x16, KEY_6},
+ { 0x17, KEY_7},
+ { 0x18, KEY_8},
+ { 0x19, KEY_9},
+ { 0x10, KEY_0},
+ { 0x1c, KEY_MENU},
+ { 0x0f, KEY_VOLUMEDOWN},
+ { 0x1a, KEY_LAST},
+ { 0x0e, KEY_OPEN},
+ { 0x04, KEY_RECORD},
+ { 0x09, KEY_VOLUMEUP},
+ { 0x08, KEY_CHANNELUP},
+ { 0x07, KEY_PVR},
+ { 0x0b, KEY_TIME},
+ { 0x02, KEY_RIGHT},
+ { 0x03, KEY_LEFT},
+ { 0x00, KEY_UP},
+ { 0x1f, KEY_OK},
+ { 0x01, KEY_DOWN},
+ { 0x05, KEY_TUNER},
+ { 0x06, KEY_CHANNELDOWN},
+ { 0x40, KEY_PLAYPAUSE},
+ { 0x1e, KEY_REWIND},
+ { 0x1b, KEY_FAVORITES},
+ { 0x1d, KEY_BACK},
+ { 0x4d, KEY_FASTFORWARD},
+ { 0x44, KEY_EPG},
+ { 0x4c, KEY_INFO},
+ { 0x41, KEY_AB},
+ { 0x43, KEY_AUDIO},
+ { 0x45, KEY_SUBTITLE},
+ { 0x4a, KEY_LIST},
+ { 0x46, KEY_F1},
+ { 0x47, KEY_F2},
+ { 0x5e, KEY_F3},
+ { 0x5c, KEY_F4},
+ { 0x52, KEY_F5},
+ { 0x5a, KEY_F6},
+ { 0x56, KEY_MODE},
+ { 0x58, KEY_SWITCHVIDEOMODE},
+};
+DEFINE_LEGACY_IR_KEYTABLE(tevii_nec);
+#else
+DECLARE_IR_KEYTABLE(tevii_nec);
+#endif
diff --git a/include/media/keycodes/tt-1500.h b/include/media/keycodes/tt-1500.h
new file mode 100644
index 0000000..45ffcba
--- /dev/null
+++ b/include/media/keycodes/tt-1500.h
@@ -0,0 +1,58 @@
+/* tt-1500.h - Keytable for tt_1500 Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* for the Technotrend 1500 bundled remotes (grey and black): */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode tt_1500[] = {
+ { 0x01, KEY_POWER },
+ { 0x02, KEY_SHUFFLE }, /* ? double-arrow key */
+ { 0x03, KEY_1 },
+ { 0x04, KEY_2 },
+ { 0x05, KEY_3 },
+ { 0x06, KEY_4 },
+ { 0x07, KEY_5 },
+ { 0x08, KEY_6 },
+ { 0x09, KEY_7 },
+ { 0x0a, KEY_8 },
+ { 0x0b, KEY_9 },
+ { 0x0c, KEY_0 },
+ { 0x0d, KEY_UP },
+ { 0x0e, KEY_LEFT },
+ { 0x0f, KEY_OK },
+ { 0x10, KEY_RIGHT },
+ { 0x11, KEY_DOWN },
+ { 0x12, KEY_INFO },
+ { 0x13, KEY_EXIT },
+ { 0x14, KEY_RED },
+ { 0x15, KEY_GREEN },
+ { 0x16, KEY_YELLOW },
+ { 0x17, KEY_BLUE },
+ { 0x18, KEY_MUTE },
+ { 0x19, KEY_TEXT },
+ { 0x1a, KEY_MODE }, /* ? TV/Radio */
+ { 0x21, KEY_OPTION },
+ { 0x22, KEY_EPG },
+ { 0x23, KEY_CHANNELUP },
+ { 0x24, KEY_CHANNELDOWN },
+ { 0x25, KEY_VOLUMEUP },
+ { 0x26, KEY_VOLUMEDOWN },
+ { 0x27, KEY_SETUP },
+ { 0x3a, KEY_RECORD }, /* these keys are only in the black remote */
+ { 0x3b, KEY_PLAY },
+ { 0x3c, KEY_STOP },
+ { 0x3d, KEY_REWIND },
+ { 0x3e, KEY_PAUSE },
+ { 0x3f, KEY_FORWARD },
+};
+DEFINE_LEGACY_IR_KEYTABLE(tt_1500);
+#else
+DECLARE_IR_KEYTABLE(tt_1500);
+#endif
diff --git a/include/media/keycodes/videomate-s350.h b/include/media/keycodes/videomate-s350.h
new file mode 100644
index 0000000..ff38424
--- /dev/null
+++ b/include/media/keycodes/videomate-s350.h
@@ -0,0 +1,62 @@
+/* videomate-s350.h - Keytable for videomate_s350 Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode videomate_s350[] = {
+ { 0x00, KEY_TV},
+ { 0x01, KEY_DVD},
+ { 0x04, KEY_RECORD},
+ { 0x05, KEY_VIDEO}, /* TV/Video */
+ { 0x07, KEY_STOP},
+ { 0x08, KEY_PLAYPAUSE},
+ { 0x0a, KEY_REWIND},
+ { 0x0f, KEY_FASTFORWARD},
+ { 0x10, KEY_CHANNELUP},
+ { 0x12, KEY_VOLUMEUP},
+ { 0x13, KEY_CHANNELDOWN},
+ { 0x14, KEY_MUTE},
+ { 0x15, KEY_VOLUMEDOWN},
+ { 0x16, KEY_1},
+ { 0x17, KEY_2},
+ { 0x18, KEY_3},
+ { 0x19, KEY_4},
+ { 0x1a, KEY_5},
+ { 0x1b, KEY_6},
+ { 0x1c, KEY_7},
+ { 0x1d, KEY_8},
+ { 0x1e, KEY_9},
+ { 0x1f, KEY_0},
+ { 0x21, KEY_SLEEP},
+ { 0x24, KEY_ZOOM},
+ { 0x25, KEY_LAST}, /* Recall */
+ { 0x26, KEY_SUBTITLE}, /* CC */
+ { 0x27, KEY_LANGUAGE}, /* MTS */
+ { 0x29, KEY_CHANNEL}, /* SURF */
+ { 0x2b, KEY_A},
+ { 0x2c, KEY_B},
+ { 0x2f, KEY_CAMERA}, /* Snapshot */
+ { 0x23, KEY_RADIO},
+ { 0x02, KEY_PREVIOUSSONG},
+ { 0x06, KEY_NEXTSONG},
+ { 0x03, KEY_EPG},
+ { 0x09, KEY_SETUP},
+ { 0x22, KEY_BACKSPACE},
+ { 0x0c, KEY_UP},
+ { 0x0e, KEY_DOWN},
+ { 0x0b, KEY_LEFT},
+ { 0x0d, KEY_RIGHT},
+ { 0x11, KEY_ENTER},
+ { 0x20, KEY_TEXT},
+};
+DEFINE_LEGACY_IR_KEYTABLE(videomate_s350);
+#else
+DECLARE_IR_KEYTABLE(videomate_s350);
+#endif
diff --git a/include/media/keycodes/videomate-tv-pvr.h b/include/media/keycodes/videomate-tv-pvr.h
new file mode 100644
index 0000000..f77375d
--- /dev/null
+++ b/include/media/keycodes/videomate-tv-pvr.h
@@ -0,0 +1,64 @@
+/* videomate-tv-pvr.h - Keytable for videomate_tv_pvr Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode videomate_tv_pvr[] = {
+ { 0x14, KEY_MUTE },
+ { 0x24, KEY_ZOOM },
+
+ { 0x01, KEY_DVD },
+ { 0x23, KEY_RADIO },
+ { 0x00, KEY_TV },
+
+ { 0x0a, KEY_REWIND },
+ { 0x08, KEY_PLAYPAUSE },
+ { 0x0f, KEY_FORWARD },
+
+ { 0x02, KEY_PREVIOUS },
+ { 0x07, KEY_STOP },
+ { 0x06, KEY_NEXT },
+
+ { 0x0c, KEY_UP },
+ { 0x0e, KEY_DOWN },
+ { 0x0b, KEY_LEFT },
+ { 0x0d, KEY_RIGHT },
+ { 0x11, KEY_OK },
+
+ { 0x03, KEY_MENU },
+ { 0x09, KEY_SETUP },
+ { 0x05, KEY_VIDEO },
+ { 0x22, KEY_CHANNEL },
+
+ { 0x12, KEY_VOLUMEUP },
+ { 0x15, KEY_VOLUMEDOWN },
+ { 0x10, KEY_CHANNELUP },
+ { 0x13, KEY_CHANNELDOWN },
+
+ { 0x04, KEY_RECORD },
+
+ { 0x16, KEY_1 },
+ { 0x17, KEY_2 },
+ { 0x18, KEY_3 },
+ { 0x19, KEY_4 },
+ { 0x1a, KEY_5 },
+ { 0x1b, KEY_6 },
+ { 0x1c, KEY_7 },
+ { 0x1d, KEY_8 },
+ { 0x1e, KEY_9 },
+ { 0x1f, KEY_0 },
+
+ { 0x20, KEY_LANGUAGE },
+ { 0x21, KEY_SLEEP },
+};
+DEFINE_LEGACY_IR_KEYTABLE(videomate_tv_pvr);
+#else
+DECLARE_IR_KEYTABLE(videomate_tv_pvr);
+#endif
diff --git a/include/media/keycodes/winfast-usbii-deluxe.h b/include/media/keycodes/winfast-usbii-deluxe.h
new file mode 100644
index 0000000..0d2c14f
--- /dev/null
+++ b/include/media/keycodes/winfast-usbii-deluxe.h
@@ -0,0 +1,58 @@
+/* winfast-usbii-deluxe.h - Keytable for winfast_usbii_deluxe Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Leadtek Winfast TV USB II Deluxe remote
+ Magnus Alm <magnus.alm@gmail.com>
+ */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode winfast_usbii_deluxe[] = {
+ { 0x62, KEY_0},
+ { 0x75, KEY_1},
+ { 0x76, KEY_2},
+ { 0x77, KEY_3},
+ { 0x79, KEY_4},
+ { 0x7a, KEY_5},
+ { 0x7b, KEY_6},
+ { 0x7d, KEY_7},
+ { 0x7e, KEY_8},
+ { 0x7f, KEY_9},
+
+ { 0x38, KEY_CAMERA}, /* SNAPSHOT */
+ { 0x37, KEY_RECORD}, /* RECORD */
+ { 0x35, KEY_TIME}, /* TIMESHIFT */
+
+ { 0x74, KEY_VOLUMEUP}, /* VOLUMEUP */
+ { 0x78, KEY_VOLUMEDOWN}, /* VOLUMEDOWN */
+ { 0x64, KEY_MUTE}, /* MUTE */
+
+ { 0x21, KEY_CHANNEL}, /* SURF */
+ { 0x7c, KEY_CHANNELUP}, /* CHANNELUP */
+ { 0x60, KEY_CHANNELDOWN}, /* CHANNELDOWN */
+ { 0x61, KEY_LAST}, /* LAST CHANNEL (RECALL) */
+
+ { 0x72, KEY_VIDEO}, /* INPUT MODES (TV/FM) */
+
+ { 0x70, KEY_POWER2}, /* TV ON/OFF */
+
+ { 0x39, KEY_CYCLEWINDOWS}, /* MINIMIZE (BOSS) */
+ { 0x3a, KEY_NEW}, /* PIP */
+ { 0x73, KEY_ZOOM}, /* FULLSECREEN */
+
+ { 0x66, KEY_INFO}, /* OSD (DISPLAY) */
+
+ { 0x31, KEY_DOT}, /* '.' */
+ { 0x63, KEY_ENTER}, /* ENTER */
+
+};
+DEFINE_LEGACY_IR_KEYTABLE(winfast_usbii_deluxe);
+#else
+DECLARE_IR_KEYTABLE(winfast_usbii_deluxe);
+#endif
diff --git a/include/media/keycodes/winfast.h b/include/media/keycodes/winfast.h
new file mode 100644
index 0000000..4f42e24
--- /dev/null
+++ b/include/media/keycodes/winfast.h
@@ -0,0 +1,78 @@
+/* winfast.h - Keytable for winfast Remote Controller
+ *
+ * Imported from ir-keymaps.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+/* Table for Leadtek Winfast Remote Controls - used by both bttv and cx88 */
+
+#ifdef IR_KEYMAPS
+static struct ir_scancode winfast[] = {
+ /* Keys 0 to 9 */
+ { 0x12, KEY_0 },
+ { 0x05, KEY_1 },
+ { 0x06, KEY_2 },
+ { 0x07, KEY_3 },
+ { 0x09, KEY_4 },
+ { 0x0a, KEY_5 },
+ { 0x0b, KEY_6 },
+ { 0x0d, KEY_7 },
+ { 0x0e, KEY_8 },
+ { 0x0f, KEY_9 },
+
+ { 0x00, KEY_POWER },
+ { 0x1b, KEY_AUDIO }, /* Audio Source */
+ { 0x02, KEY_TUNER }, /* TV/FM, not on Y0400052 */
+ { 0x1e, KEY_VIDEO }, /* Video Source */
+ { 0x16, KEY_INFO }, /* Display information */
+ { 0x04, KEY_VOLUMEUP },
+ { 0x08, KEY_VOLUMEDOWN },
+ { 0x0c, KEY_CHANNELUP },
+ { 0x10, KEY_CHANNELDOWN },
+ { 0x03, KEY_ZOOM }, /* fullscreen */
+ { 0x1f, KEY_TEXT }, /* closed caption/teletext */
+ { 0x20, KEY_SLEEP },
+ { 0x29, KEY_CLEAR }, /* boss key */
+ { 0x14, KEY_MUTE },
+ { 0x2b, KEY_RED },
+ { 0x2c, KEY_GREEN },
+ { 0x2d, KEY_YELLOW },
+ { 0x2e, KEY_BLUE },
+ { 0x18, KEY_KPPLUS }, /* fine tune + , not on Y040052 */
+ { 0x19, KEY_KPMINUS }, /* fine tune - , not on Y040052 */
+ { 0x2a, KEY_MEDIA }, /* PIP (Picture in picture */
+ { 0x21, KEY_DOT },
+ { 0x13, KEY_ENTER },
+ { 0x11, KEY_LAST }, /* Recall (last channel */
+ { 0x22, KEY_PREVIOUS },
+ { 0x23, KEY_PLAYPAUSE },
+ { 0x24, KEY_NEXT },
+ { 0x25, KEY_TIME }, /* Time Shifting */
+ { 0x26, KEY_STOP },
+ { 0x27, KEY_RECORD },
+ { 0x28, KEY_SAVE }, /* Screenshot */
+ { 0x2f, KEY_MENU },
+ { 0x30, KEY_CANCEL },
+ { 0x31, KEY_CHANNEL }, /* Channel Surf */
+ { 0x32, KEY_SUBTITLE },
+ { 0x33, KEY_LANGUAGE },
+ { 0x34, KEY_REWIND },
+ { 0x35, KEY_FASTFORWARD },
+ { 0x36, KEY_TV },
+ { 0x37, KEY_RADIO }, /* FM */
+ { 0x38, KEY_DVD },
+
+ { 0x1a, KEY_MODE}, /* change to MCE mode on Y04G0051 */
+ { 0x3e, KEY_F21 }, /* MCE +VOL, on Y04G0033 */
+ { 0x3a, KEY_F22 }, /* MCE -VOL, on Y04G0033 */
+ { 0x3b, KEY_F23 }, /* MCE +CH, on Y04G0033 */
+ { 0x3f, KEY_F24 } /* MCE -CH, on Y04G0033 */
+};
+DEFINE_LEGACY_IR_KEYTABLE(winfast);
+#else
+DECLARE_IR_KEYTABLE(winfast);
+#endif
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 07/26] V4L/DVB: ir-core: Add support for RC map code register
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (16 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 08/26] V4L/DVB: Break Remote Controller keymaps into modules Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 05/26] V4L/DVB: ir-common: Use macros to define the keytables Mauro Carvalho Chehab
` (7 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
Instead of having all RC tables hardcoded on one file with
all tables there, add infrastructure for registering and dynamically
load the table(s) when needed.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
create mode 100644 drivers/media/IR/rc-map.c
diff --git a/drivers/media/IR/Makefile b/drivers/media/IR/Makefile
index 6140b27..3a4f590 100644
--- a/drivers/media/IR/Makefile
+++ b/drivers/media/IR/Makefile
@@ -1,5 +1,5 @@
ir-common-objs := ir-functions.o ir-keymaps.o
-ir-core-objs := ir-keytable.o ir-sysfs.o ir-raw-event.o
+ir-core-objs := ir-keytable.o ir-sysfs.o ir-raw-event.o rc-map.o
obj-$(CONFIG_IR_CORE) += ir-core.o
obj-$(CONFIG_VIDEO_IR) += ir-common.o
diff --git a/drivers/media/IR/rc-map.c b/drivers/media/IR/rc-map.c
new file mode 100644
index 0000000..aa269f5
--- /dev/null
+++ b/drivers/media/IR/rc-map.c
@@ -0,0 +1,75 @@
+/* ir-raw-event.c - handle IR Pulse/Space event
+ *
+ * Copyright (C) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation version 2 of the License.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+#include <media/ir-core.h>
+#include <linux/spinlock.h>
+
+/* Used to handle IR raw handler extensions */
+static LIST_HEAD(rc_map_list);
+static spinlock_t rc_map_lock;
+
+
+static struct rc_keymap *seek_rc_map(const char *name)
+{
+ struct rc_keymap *map = NULL;
+
+ spin_lock(&rc_map_lock);
+ list_for_each_entry(map, &rc_map_list, list) {
+ if (!strcmp(name, map->map.name))
+ break;
+ }
+ spin_unlock(&rc_map_lock);
+
+ return map;
+}
+
+struct ir_scancode_table *get_rc_map(const char *name)
+{
+ int rc = 0;
+
+ struct rc_keymap *map;
+
+ map = seek_rc_map(name);
+#ifdef MODULE
+ if (!map) {
+ rc = request_module("name");
+ if (rc < 0)
+ return NULL;
+
+ map = seek_rc_map(name);
+ }
+#endif
+ if (!map)
+ return NULL;
+
+ return &map->map;
+}
+EXPORT_SYMBOL_GPL(get_rc_map);
+
+int ir_register_map(struct rc_keymap *map)
+{
+ spin_lock(&rc_map_lock);
+ list_add_tail(&map->list, &rc_map_list);
+ spin_unlock(&rc_map_lock);
+ return 0;
+}
+EXPORT_SYMBOL_GPL(ir_raw_handler_register);
+
+void ir_unregister_map(struct rc_keymap *map)
+{
+ spin_lock(&rc_map_lock);
+ list_del(&map->list);
+ spin_unlock(&rc_map_lock);
+}
+EXPORT_SYMBOL_GPL(ir_raw_handler_unregister);
diff --git a/include/media/ir-core.h b/include/media/ir-core.h
index 643ff25..39df3cf 100644
--- a/include/media/ir-core.h
+++ b/include/media/ir-core.h
@@ -52,6 +52,11 @@ struct ir_scancode_table {
spinlock_t lock;
};
+struct rc_keymap {
+ struct list_head list;
+ struct ir_scancode_table map;
+};
+
struct ir_dev_props {
unsigned long allowed_protos;
void *priv;
@@ -126,6 +131,12 @@ int ir_input_register(struct input_dev *dev,
const char *driver_name);
void ir_input_unregister(struct input_dev *input_dev);
+/* Routines from rc-map.c */
+
+int ir_register_map(struct rc_keymap *map);
+void ir_unregister_map(struct rc_keymap *map);
+struct ir_scancode_table *get_rc_map(const char *name);
+
/* Routines from ir-sysfs.c */
int ir_register_class(struct input_dev *input_dev);
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 08/26] V4L/DVB: Break Remote Controller keymaps into modules
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (15 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 12/26] V4L/DVB: saa7134: Fix IRQ2 bit names for the register map Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-10 12:27 ` Andy Walls
2010-04-06 18:18 ` [PATCH 07/26] V4L/DVB: ir-core: Add support for RC map code register Mauro Carvalho Chehab
` (8 subsequent siblings)
25 siblings, 1 reply; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
The original Remote Controller approach were very messy: a big file,
that were part of ir-common kernel module, containing 64 different
RC keymap tables, used by the V4L/DVB drivers.
Better to break each RC keymap table into a separate module,
registering them into rc core on a process similar to the fs/nls tables.
As an userspace program is now in charge of loading those tables,
adds an option to allow the complete removal of those tables from
kernelspace.
Yet, on embedded devices like Set Top Boxes and TV sets, maybe the
only available input device is the IR. So, we should keep allowing
the usage of in-kernel tables, but a latter patch should change
the default to 'n', after giving some time for distros to add
the v4l-utils with the ir-keytable program, to allow the table
load via userspace.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
create mode 100644 drivers/media/IR/keymaps/Kconfig
create mode 100644 drivers/media/IR/keymaps/Makefile
create mode 100644 drivers/media/IR/keymaps/rc-adstech-dvb-t-pci.c
create mode 100644 drivers/media/IR/keymaps/rc-apac-viewcomp.c
create mode 100644 drivers/media/IR/keymaps/rc-asus-pc39.c
create mode 100644 drivers/media/IR/keymaps/rc-ati-tv-wonder-hd-600.c
create mode 100644 drivers/media/IR/keymaps/rc-avermedia-a16d.c
create mode 100644 drivers/media/IR/keymaps/rc-avermedia-cardbus.c
create mode 100644 drivers/media/IR/keymaps/rc-avermedia-dvbt.c
create mode 100644 drivers/media/IR/keymaps/rc-avermedia-m135a-rm-jx.c
create mode 100644 drivers/media/IR/keymaps/rc-avermedia.c
create mode 100644 drivers/media/IR/keymaps/rc-avertv-303.c
create mode 100644 drivers/media/IR/keymaps/rc-behold-columbus.c
create mode 100644 drivers/media/IR/keymaps/rc-behold.c
create mode 100644 drivers/media/IR/keymaps/rc-budget-ci-old.c
create mode 100644 drivers/media/IR/keymaps/rc-cinergy-1400.c
create mode 100644 drivers/media/IR/keymaps/rc-cinergy.c
create mode 100644 drivers/media/IR/keymaps/rc-dm1105-nec.c
create mode 100644 drivers/media/IR/keymaps/rc-dntv-live-dvb-t.c
create mode 100644 drivers/media/IR/keymaps/rc-dntv-live-dvbt-pro.c
create mode 100644 drivers/media/IR/keymaps/rc-em-terratec.c
create mode 100644 drivers/media/IR/keymaps/rc-empty.c
create mode 100644 drivers/media/IR/keymaps/rc-encore-enltv-fm53.c
create mode 100644 drivers/media/IR/keymaps/rc-encore-enltv.c
create mode 100644 drivers/media/IR/keymaps/rc-encore-enltv2.c
create mode 100644 drivers/media/IR/keymaps/rc-evga-indtube.c
create mode 100644 drivers/media/IR/keymaps/rc-eztv.c
create mode 100644 drivers/media/IR/keymaps/rc-flydvb.c
create mode 100644 drivers/media/IR/keymaps/rc-flyvideo.c
create mode 100644 drivers/media/IR/keymaps/rc-fusionhdtv-mce.c
create mode 100644 drivers/media/IR/keymaps/rc-gadmei-rm008z.c
create mode 100644 drivers/media/IR/keymaps/rc-genius-tvgo-a11mce.c
create mode 100644 drivers/media/IR/keymaps/rc-gotview7135.c
create mode 100644 drivers/media/IR/keymaps/rc-hauppauge-new.c
create mode 100644 drivers/media/IR/keymaps/rc-iodata-bctv7e.c
create mode 100644 drivers/media/IR/keymaps/rc-kaiomy.c
create mode 100644 drivers/media/IR/keymaps/rc-kworld-315u.c
create mode 100644 drivers/media/IR/keymaps/rc-kworld-plus-tv-analog.c
create mode 100644 drivers/media/IR/keymaps/rc-manli.c
create mode 100644 drivers/media/IR/keymaps/rc-msi-tvanywhere-plus.c
create mode 100644 drivers/media/IR/keymaps/rc-msi-tvanywhere.c
create mode 100644 drivers/media/IR/keymaps/rc-nebula.c
create mode 100644 drivers/media/IR/keymaps/rc-nec-terratec-cinergy-xs.c
create mode 100644 drivers/media/IR/keymaps/rc-norwood.c
create mode 100644 drivers/media/IR/keymaps/rc-npgtech.c
create mode 100644 drivers/media/IR/keymaps/rc-pctv-sedna.c
create mode 100644 drivers/media/IR/keymaps/rc-pinnacle-color.c
create mode 100644 drivers/media/IR/keymaps/rc-pinnacle-grey.c
create mode 100644 drivers/media/IR/keymaps/rc-pinnacle-pctv-hd.c
create mode 100644 drivers/media/IR/keymaps/rc-pixelview-new.c
create mode 100644 drivers/media/IR/keymaps/rc-pixelview.c
create mode 100644 drivers/media/IR/keymaps/rc-powercolor-real-angel.c
create mode 100644 drivers/media/IR/keymaps/rc-proteus-2309.c
create mode 100644 drivers/media/IR/keymaps/rc-purpletv.c
create mode 100644 drivers/media/IR/keymaps/rc-pv951.c
create mode 100644 drivers/media/IR/keymaps/rc-rc5-hauppauge-new.c
create mode 100644 drivers/media/IR/keymaps/rc-rc5-tv.c
create mode 100644 drivers/media/IR/keymaps/rc-real-audio-220-32-keys.c
create mode 100644 drivers/media/IR/keymaps/rc-tbs-nec.c
create mode 100644 drivers/media/IR/keymaps/rc-terratec-cinergy-xs.c
create mode 100644 drivers/media/IR/keymaps/rc-tevii-nec.c
create mode 100644 drivers/media/IR/keymaps/rc-tt-1500.c
create mode 100644 drivers/media/IR/keymaps/rc-videomate-s350.c
create mode 100644 drivers/media/IR/keymaps/rc-videomate-tv-pvr.c
create mode 100644 drivers/media/IR/keymaps/rc-winfast-usbii-deluxe.c
create mode 100644 drivers/media/IR/keymaps/rc-winfast.c
diff --git a/drivers/media/IR/Kconfig b/drivers/media/IR/Kconfig
index de410d4..0c557b8 100644
--- a/drivers/media/IR/Kconfig
+++ b/drivers/media/IR/Kconfig
@@ -8,6 +8,8 @@ config VIDEO_IR
depends on IR_CORE
default IR_CORE
+source "drivers/media/IR/keymaps/Kconfig"
+
config IR_NEC_DECODER
tristate "Enable IR raw decoder for NEC protocol"
depends on IR_CORE
diff --git a/drivers/media/IR/keymaps/Kconfig b/drivers/media/IR/keymaps/Kconfig
new file mode 100644
index 0000000..14b22f5
--- /dev/null
+++ b/drivers/media/IR/keymaps/Kconfig
@@ -0,0 +1,15 @@
+config RC_MAP
+ tristate "Compile Remote Controller keymap modules"
+ depends on IR_CORE
+ default y
+
+ ---help---
+ This option enables the compilation of lots of Remote
+ Controller tables. They are short tables, but if you
+ don't use a remote controller, or prefer to load the
+ tables on userspace, you should disable it.
+
+ The ir-keytable program, available at v4l-utils package
+ provide the tool and the same RC maps for load from
+ userspace. Its available at
+ http://git.linuxtv.org/v4l-utils
diff --git a/drivers/media/IR/keymaps/Makefile b/drivers/media/IR/keymaps/Makefile
new file mode 100644
index 0000000..937b7db
--- /dev/null
+++ b/drivers/media/IR/keymaps/Makefile
@@ -0,0 +1,64 @@
+obj-$(CONFIG_RC_MAP) += rc-adstech-dvb-t-pci.o \
+ rc-apac-viewcomp.o \
+ rc-asus-pc39.o \
+ rc-ati-tv-wonder-hd-600.o \
+ rc-avermedia-a16d.o \
+ rc-avermedia.o \
+ rc-avermedia-cardbus.o \
+ rc-avermedia-dvbt.o \
+ rc-avermedia-m135a-rm-jx.o \
+ rc-avertv-303.o \
+ rc-behold.o \
+ rc-behold-columbus.o \
+ rc-budget-ci-old.o \
+ rc-cinergy-1400.o \
+ rc-cinergy.o \
+ rc-dm1105-nec.o \
+ rc-dntv-live-dvb-t.o \
+ rc-dntv-live-dvbt-pro.o \
+ rc-empty.o \
+ rc-em-terratec.o \
+ rc-encore-enltv2.o \
+ rc-encore-enltv.o \
+ rc-encore-enltv-fm53.o \
+ rc-evga-indtube.o \
+ rc-eztv.o \
+ rc-flydvb.o \
+ rc-flyvideo.o \
+ rc-fusionhdtv-mce.o \
+ rc-gadmei-rm008z.o \
+ rc-genius-tvgo-a11mce.o \
+ rc-gotview7135.o \
+ rc-hauppauge-new.o \
+ rc-iodata-bctv7e.o \
+ rc-kaiomy.o \
+ rc-kworld-315u.o \
+ rc-kworld-plus-tv-analog.o \
+ rc-manli.o \
+ rc-msi-tvanywhere.o \
+ rc-msi-tvanywhere-plus.o \
+ rc-nebula.o \
+ rc-nec-terratec-cinergy-xs.o \
+ rc-norwood.o \
+ rc-npgtech.o \
+ rc-pctv-sedna.o \
+ rc-pinnacle-color.o \
+ rc-pinnacle-grey.o \
+ rc-pinnacle-pctv-hd.o \
+ rc-pixelview.o \
+ rc-pixelview-new.o \
+ rc-powercolor-real-angel.o \
+ rc-proteus-2309.o \
+ rc-purpletv.o \
+ rc-pv951.o \
+ rc-rc5-hauppauge-new.o \
+ rc-rc5-tv.o \
+ rc-real-audio-220-32-keys.o \
+ rc-tbs-nec.o \
+ rc-terratec-cinergy-xs.o \
+ rc-tevii-nec.o \
+ rc-tt-1500.o \
+ rc-videomate-s350.o \
+ rc-videomate-tv-pvr.o \
+ rc-winfast.o \
+ rc-winfast-usbii-deluxe.o
diff --git a/drivers/media/IR/keymaps/rc-adstech-dvb-t-pci.c b/drivers/media/IR/keymaps/rc-adstech-dvb-t-pci.c
new file mode 100644
index 0000000..b172831
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-adstech-dvb-t-pci.c
@@ -0,0 +1,89 @@
+/* adstech-dvb-t-pci.h - Keytable for adstech_dvb_t_pci Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* ADS Tech Instant TV DVB-T PCI Remote */
+
+static struct ir_scancode adstech_dvb_t_pci[] = {
+ /* Keys 0 to 9 */
+ { 0x4d, KEY_0 },
+ { 0x57, KEY_1 },
+ { 0x4f, KEY_2 },
+ { 0x53, KEY_3 },
+ { 0x56, KEY_4 },
+ { 0x4e, KEY_5 },
+ { 0x5e, KEY_6 },
+ { 0x54, KEY_7 },
+ { 0x4c, KEY_8 },
+ { 0x5c, KEY_9 },
+
+ { 0x5b, KEY_POWER },
+ { 0x5f, KEY_MUTE },
+ { 0x55, KEY_GOTO },
+ { 0x5d, KEY_SEARCH },
+ { 0x17, KEY_EPG }, /* Guide */
+ { 0x1f, KEY_MENU },
+ { 0x0f, KEY_UP },
+ { 0x46, KEY_DOWN },
+ { 0x16, KEY_LEFT },
+ { 0x1e, KEY_RIGHT },
+ { 0x0e, KEY_SELECT }, /* Enter */
+ { 0x5a, KEY_INFO },
+ { 0x52, KEY_EXIT },
+ { 0x59, KEY_PREVIOUS },
+ { 0x51, KEY_NEXT },
+ { 0x58, KEY_REWIND },
+ { 0x50, KEY_FORWARD },
+ { 0x44, KEY_PLAYPAUSE },
+ { 0x07, KEY_STOP },
+ { 0x1b, KEY_RECORD },
+ { 0x13, KEY_TUNER }, /* Live */
+ { 0x0a, KEY_A },
+ { 0x12, KEY_B },
+ { 0x03, KEY_PROG1 }, /* 1 */
+ { 0x01, KEY_PROG2 }, /* 2 */
+ { 0x00, KEY_PROG3 }, /* 3 */
+ { 0x06, KEY_DVD },
+ { 0x48, KEY_AUX }, /* Photo */
+ { 0x40, KEY_VIDEO },
+ { 0x19, KEY_AUDIO }, /* Music */
+ { 0x0b, KEY_CHANNELUP },
+ { 0x08, KEY_CHANNELDOWN },
+ { 0x15, KEY_VOLUMEUP },
+ { 0x1c, KEY_VOLUMEDOWN },
+};
+
+static struct rc_keymap adstech_dvb_t_pci_map = {
+ .map = {
+ .scan = adstech_dvb_t_pci,
+ .size = ARRAY_SIZE(adstech_dvb_t_pci),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_ADSTECH_DVB_T_PCI,
+ }
+};
+
+static int __init init_rc_map_adstech_dvb_t_pci(void)
+{
+ return ir_register_map(&adstech_dvb_t_pci_map);
+}
+
+static void __exit exit_rc_map_adstech_dvb_t_pci(void)
+{
+ ir_unregister_map(&adstech_dvb_t_pci_map);
+}
+
+module_init(init_rc_map_adstech_dvb_t_pci)
+module_exit(exit_rc_map_adstech_dvb_t_pci)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-apac-viewcomp.c b/drivers/media/IR/keymaps/rc-apac-viewcomp.c
new file mode 100644
index 0000000..0ef2b56
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-apac-viewcomp.c
@@ -0,0 +1,80 @@
+/* apac-viewcomp.h - Keytable for apac_viewcomp Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Attila Kondoros <attila.kondoros@chello.hu> */
+
+static struct ir_scancode apac_viewcomp[] = {
+
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+ { 0x00, KEY_0 },
+ { 0x17, KEY_LAST }, /* +100 */
+ { 0x0a, KEY_LIST }, /* recall */
+
+
+ { 0x1c, KEY_TUNER }, /* TV/FM */
+ { 0x15, KEY_SEARCH }, /* scan */
+ { 0x12, KEY_POWER }, /* power */
+ { 0x1f, KEY_VOLUMEDOWN }, /* vol up */
+ { 0x1b, KEY_VOLUMEUP }, /* vol down */
+ { 0x1e, KEY_CHANNELDOWN }, /* chn up */
+ { 0x1a, KEY_CHANNELUP }, /* chn down */
+
+ { 0x11, KEY_VIDEO }, /* video */
+ { 0x0f, KEY_ZOOM }, /* full screen */
+ { 0x13, KEY_MUTE }, /* mute/unmute */
+ { 0x10, KEY_TEXT }, /* min */
+
+ { 0x0d, KEY_STOP }, /* freeze */
+ { 0x0e, KEY_RECORD }, /* record */
+ { 0x1d, KEY_PLAYPAUSE }, /* stop */
+ { 0x19, KEY_PLAY }, /* play */
+
+ { 0x16, KEY_GOTO }, /* osd */
+ { 0x14, KEY_REFRESH }, /* default */
+ { 0x0c, KEY_KPPLUS }, /* fine tune >>>> */
+ { 0x18, KEY_KPMINUS }, /* fine tune <<<< */
+};
+
+static struct rc_keymap apac_viewcomp_map = {
+ .map = {
+ .scan = apac_viewcomp,
+ .size = ARRAY_SIZE(apac_viewcomp),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_APAC_VIEWCOMP,
+ }
+};
+
+static int __init init_rc_map_apac_viewcomp(void)
+{
+ return ir_register_map(&apac_viewcomp_map);
+}
+
+static void __exit exit_rc_map_apac_viewcomp(void)
+{
+ ir_unregister_map(&apac_viewcomp_map);
+}
+
+module_init(init_rc_map_apac_viewcomp)
+module_exit(exit_rc_map_apac_viewcomp)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-asus-pc39.c b/drivers/media/IR/keymaps/rc-asus-pc39.c
new file mode 100644
index 0000000..2aa068c
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-asus-pc39.c
@@ -0,0 +1,91 @@
+/* asus-pc39.h - Keytable for asus_pc39 Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/*
+ * Marc Fargas <telenieko@telenieko.com>
+ * this is the remote control that comes with the asus p7131
+ * which has a label saying is "Model PC-39"
+ */
+
+static struct ir_scancode asus_pc39[] = {
+ /* Keys 0 to 9 */
+ { 0x15, KEY_0 },
+ { 0x29, KEY_1 },
+ { 0x2d, KEY_2 },
+ { 0x2b, KEY_3 },
+ { 0x09, KEY_4 },
+ { 0x0d, KEY_5 },
+ { 0x0b, KEY_6 },
+ { 0x31, KEY_7 },
+ { 0x35, KEY_8 },
+ { 0x33, KEY_9 },
+
+ { 0x3e, KEY_RADIO }, /* radio */
+ { 0x03, KEY_MENU }, /* dvd/menu */
+ { 0x2a, KEY_VOLUMEUP },
+ { 0x19, KEY_VOLUMEDOWN },
+ { 0x37, KEY_UP },
+ { 0x3b, KEY_DOWN },
+ { 0x27, KEY_LEFT },
+ { 0x2f, KEY_RIGHT },
+ { 0x25, KEY_VIDEO }, /* video */
+ { 0x39, KEY_AUDIO }, /* music */
+
+ { 0x21, KEY_TV }, /* tv */
+ { 0x1d, KEY_EXIT }, /* back */
+ { 0x0a, KEY_CHANNELUP }, /* channel / program + */
+ { 0x1b, KEY_CHANNELDOWN }, /* channel / program - */
+ { 0x1a, KEY_ENTER }, /* enter */
+
+ { 0x06, KEY_PAUSE }, /* play/pause */
+ { 0x1e, KEY_PREVIOUS }, /* rew */
+ { 0x26, KEY_NEXT }, /* forward */
+ { 0x0e, KEY_REWIND }, /* backward << */
+ { 0x3a, KEY_FASTFORWARD }, /* forward >> */
+ { 0x36, KEY_STOP },
+ { 0x2e, KEY_RECORD }, /* recording */
+ { 0x16, KEY_POWER }, /* the button that reads "close" */
+
+ { 0x11, KEY_ZOOM }, /* full screen */
+ { 0x13, KEY_MACRO }, /* recall */
+ { 0x23, KEY_HOME }, /* home */
+ { 0x05, KEY_PVR }, /* picture */
+ { 0x3d, KEY_MUTE }, /* mute */
+ { 0x01, KEY_DVD }, /* dvd */
+};
+
+static struct rc_keymap asus_pc39_map = {
+ .map = {
+ .scan = asus_pc39,
+ .size = ARRAY_SIZE(asus_pc39),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_ASUS_PC39,
+ }
+};
+
+static int __init init_rc_map_asus_pc39(void)
+{
+ return ir_register_map(&asus_pc39_map);
+}
+
+static void __exit exit_rc_map_asus_pc39(void)
+{
+ ir_unregister_map(&asus_pc39_map);
+}
+
+module_init(init_rc_map_asus_pc39)
+module_exit(exit_rc_map_asus_pc39)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-ati-tv-wonder-hd-600.c b/drivers/media/IR/keymaps/rc-ati-tv-wonder-hd-600.c
new file mode 100644
index 0000000..8edfd29
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-ati-tv-wonder-hd-600.c
@@ -0,0 +1,69 @@
+/* ati-tv-wonder-hd-600.h - Keytable for ati_tv_wonder_hd_600 Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* ATI TV Wonder HD 600 USB
+ Devin Heitmueller <devin.heitmueller@gmail.com>
+ */
+
+static struct ir_scancode ati_tv_wonder_hd_600[] = {
+ { 0x00, KEY_RECORD}, /* Row 1 */
+ { 0x01, KEY_PLAYPAUSE},
+ { 0x02, KEY_STOP},
+ { 0x03, KEY_POWER},
+ { 0x04, KEY_PREVIOUS}, /* Row 2 */
+ { 0x05, KEY_REWIND},
+ { 0x06, KEY_FORWARD},
+ { 0x07, KEY_NEXT},
+ { 0x08, KEY_EPG}, /* Row 3 */
+ { 0x09, KEY_HOME},
+ { 0x0a, KEY_MENU},
+ { 0x0b, KEY_CHANNELUP},
+ { 0x0c, KEY_BACK}, /* Row 4 */
+ { 0x0d, KEY_UP},
+ { 0x0e, KEY_INFO},
+ { 0x0f, KEY_CHANNELDOWN},
+ { 0x10, KEY_LEFT}, /* Row 5 */
+ { 0x11, KEY_SELECT},
+ { 0x12, KEY_RIGHT},
+ { 0x13, KEY_VOLUMEUP},
+ { 0x14, KEY_LAST}, /* Row 6 */
+ { 0x15, KEY_DOWN},
+ { 0x16, KEY_MUTE},
+ { 0x17, KEY_VOLUMEDOWN},
+};
+
+static struct rc_keymap ati_tv_wonder_hd_600_map = {
+ .map = {
+ .scan = ati_tv_wonder_hd_600,
+ .size = ARRAY_SIZE(ati_tv_wonder_hd_600),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_ATI_TV_WONDER_HD_600,
+ }
+};
+
+static int __init init_rc_map_ati_tv_wonder_hd_600(void)
+{
+ return ir_register_map(&ati_tv_wonder_hd_600_map);
+}
+
+static void __exit exit_rc_map_ati_tv_wonder_hd_600(void)
+{
+ ir_unregister_map(&ati_tv_wonder_hd_600_map);
+}
+
+module_init(init_rc_map_ati_tv_wonder_hd_600)
+module_exit(exit_rc_map_ati_tv_wonder_hd_600)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-avermedia-a16d.c b/drivers/media/IR/keymaps/rc-avermedia-a16d.c
new file mode 100644
index 0000000..12f0435
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-avermedia-a16d.c
@@ -0,0 +1,75 @@
+/* avermedia-a16d.h - Keytable for avermedia_a16d Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+static struct ir_scancode avermedia_a16d[] = {
+ { 0x20, KEY_LIST},
+ { 0x00, KEY_POWER},
+ { 0x28, KEY_1},
+ { 0x18, KEY_2},
+ { 0x38, KEY_3},
+ { 0x24, KEY_4},
+ { 0x14, KEY_5},
+ { 0x34, KEY_6},
+ { 0x2c, KEY_7},
+ { 0x1c, KEY_8},
+ { 0x3c, KEY_9},
+ { 0x12, KEY_SUBTITLE},
+ { 0x22, KEY_0},
+ { 0x32, KEY_REWIND},
+ { 0x3a, KEY_SHUFFLE},
+ { 0x02, KEY_PRINT},
+ { 0x11, KEY_CHANNELDOWN},
+ { 0x31, KEY_CHANNELUP},
+ { 0x0c, KEY_ZOOM},
+ { 0x1e, KEY_VOLUMEDOWN},
+ { 0x3e, KEY_VOLUMEUP},
+ { 0x0a, KEY_MUTE},
+ { 0x04, KEY_AUDIO},
+ { 0x26, KEY_RECORD},
+ { 0x06, KEY_PLAY},
+ { 0x36, KEY_STOP},
+ { 0x16, KEY_PAUSE},
+ { 0x2e, KEY_REWIND},
+ { 0x0e, KEY_FASTFORWARD},
+ { 0x30, KEY_TEXT},
+ { 0x21, KEY_GREEN},
+ { 0x01, KEY_BLUE},
+ { 0x08, KEY_EPG},
+ { 0x2a, KEY_MENU},
+};
+
+static struct rc_keymap avermedia_a16d_map = {
+ .map = {
+ .scan = avermedia_a16d,
+ .size = ARRAY_SIZE(avermedia_a16d),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_AVERMEDIA_A16D,
+ }
+};
+
+static int __init init_rc_map_avermedia_a16d(void)
+{
+ return ir_register_map(&avermedia_a16d_map);
+}
+
+static void __exit exit_rc_map_avermedia_a16d(void)
+{
+ ir_unregister_map(&avermedia_a16d_map);
+}
+
+module_init(init_rc_map_avermedia_a16d)
+module_exit(exit_rc_map_avermedia_a16d)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-avermedia-cardbus.c b/drivers/media/IR/keymaps/rc-avermedia-cardbus.c
new file mode 100644
index 0000000..2a945b0
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-avermedia-cardbus.c
@@ -0,0 +1,97 @@
+/* avermedia-cardbus.h - Keytable for avermedia_cardbus Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Oldrich Jedlicka <oldium.pro@seznam.cz> */
+
+static struct ir_scancode avermedia_cardbus[] = {
+ { 0x00, KEY_POWER },
+ { 0x01, KEY_TUNER }, /* TV/FM */
+ { 0x03, KEY_TEXT }, /* Teletext */
+ { 0x04, KEY_EPG },
+ { 0x05, KEY_1 },
+ { 0x06, KEY_2 },
+ { 0x07, KEY_3 },
+ { 0x08, KEY_AUDIO },
+ { 0x09, KEY_4 },
+ { 0x0a, KEY_5 },
+ { 0x0b, KEY_6 },
+ { 0x0c, KEY_ZOOM }, /* Full screen */
+ { 0x0d, KEY_7 },
+ { 0x0e, KEY_8 },
+ { 0x0f, KEY_9 },
+ { 0x10, KEY_PAGEUP }, /* 16-CH PREV */
+ { 0x11, KEY_0 },
+ { 0x12, KEY_INFO },
+ { 0x13, KEY_AGAIN }, /* CH RTN - channel return */
+ { 0x14, KEY_MUTE },
+ { 0x15, KEY_EDIT }, /* Autoscan */
+ { 0x17, KEY_SAVE }, /* Screenshot */
+ { 0x18, KEY_PLAYPAUSE },
+ { 0x19, KEY_RECORD },
+ { 0x1a, KEY_PLAY },
+ { 0x1b, KEY_STOP },
+ { 0x1c, KEY_FASTFORWARD },
+ { 0x1d, KEY_REWIND },
+ { 0x1e, KEY_VOLUMEDOWN },
+ { 0x1f, KEY_VOLUMEUP },
+ { 0x22, KEY_SLEEP }, /* Sleep */
+ { 0x23, KEY_ZOOM }, /* Aspect */
+ { 0x26, KEY_SCREEN }, /* Pos */
+ { 0x27, KEY_ANGLE }, /* Size */
+ { 0x28, KEY_SELECT }, /* Select */
+ { 0x29, KEY_BLUE }, /* Blue/Picture */
+ { 0x2a, KEY_BACKSPACE }, /* Back */
+ { 0x2b, KEY_MEDIA }, /* PIP (Picture-in-picture) */
+ { 0x2c, KEY_DOWN },
+ { 0x2e, KEY_DOT },
+ { 0x2f, KEY_TV }, /* Live TV */
+ { 0x32, KEY_LEFT },
+ { 0x33, KEY_CLEAR }, /* Clear */
+ { 0x35, KEY_RED }, /* Red/TV */
+ { 0x36, KEY_UP },
+ { 0x37, KEY_HOME }, /* Home */
+ { 0x39, KEY_GREEN }, /* Green/Video */
+ { 0x3d, KEY_YELLOW }, /* Yellow/Music */
+ { 0x3e, KEY_OK }, /* Ok */
+ { 0x3f, KEY_RIGHT },
+ { 0x40, KEY_NEXT }, /* Next */
+ { 0x41, KEY_PREVIOUS }, /* Previous */
+ { 0x42, KEY_CHANNELDOWN }, /* Channel down */
+ { 0x43, KEY_CHANNELUP }, /* Channel up */
+};
+
+static struct rc_keymap avermedia_cardbus_map = {
+ .map = {
+ .scan = avermedia_cardbus,
+ .size = ARRAY_SIZE(avermedia_cardbus),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_AVERMEDIA_CARDBUS,
+ }
+};
+
+static int __init init_rc_map_avermedia_cardbus(void)
+{
+ return ir_register_map(&avermedia_cardbus_map);
+}
+
+static void __exit exit_rc_map_avermedia_cardbus(void)
+{
+ ir_unregister_map(&avermedia_cardbus_map);
+}
+
+module_init(init_rc_map_avermedia_cardbus)
+module_exit(exit_rc_map_avermedia_cardbus)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-avermedia-dvbt.c b/drivers/media/IR/keymaps/rc-avermedia-dvbt.c
new file mode 100644
index 0000000..39dde62
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-avermedia-dvbt.c
@@ -0,0 +1,78 @@
+/* avermedia-dvbt.h - Keytable for avermedia_dvbt Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Matt Jesson <dvb@jesson.eclipse.co.uk */
+
+static struct ir_scancode avermedia_dvbt[] = {
+ { 0x28, KEY_0 }, /* '0' / 'enter' */
+ { 0x22, KEY_1 }, /* '1' */
+ { 0x12, KEY_2 }, /* '2' / 'up arrow' */
+ { 0x32, KEY_3 }, /* '3' */
+ { 0x24, KEY_4 }, /* '4' / 'left arrow' */
+ { 0x14, KEY_5 }, /* '5' */
+ { 0x34, KEY_6 }, /* '6' / 'right arrow' */
+ { 0x26, KEY_7 }, /* '7' */
+ { 0x16, KEY_8 }, /* '8' / 'down arrow' */
+ { 0x36, KEY_9 }, /* '9' */
+
+ { 0x20, KEY_LIST }, /* 'source' */
+ { 0x10, KEY_TEXT }, /* 'teletext' */
+ { 0x00, KEY_POWER }, /* 'power' */
+ { 0x04, KEY_AUDIO }, /* 'audio' */
+ { 0x06, KEY_ZOOM }, /* 'full screen' */
+ { 0x18, KEY_VIDEO }, /* 'display' */
+ { 0x38, KEY_SEARCH }, /* 'loop' */
+ { 0x08, KEY_INFO }, /* 'preview' */
+ { 0x2a, KEY_REWIND }, /* 'backward <<' */
+ { 0x1a, KEY_FASTFORWARD }, /* 'forward >>' */
+ { 0x3a, KEY_RECORD }, /* 'capture' */
+ { 0x0a, KEY_MUTE }, /* 'mute' */
+ { 0x2c, KEY_RECORD }, /* 'record' */
+ { 0x1c, KEY_PAUSE }, /* 'pause' */
+ { 0x3c, KEY_STOP }, /* 'stop' */
+ { 0x0c, KEY_PLAY }, /* 'play' */
+ { 0x2e, KEY_RED }, /* 'red' */
+ { 0x01, KEY_BLUE }, /* 'blue' / 'cancel' */
+ { 0x0e, KEY_YELLOW }, /* 'yellow' / 'ok' */
+ { 0x21, KEY_GREEN }, /* 'green' */
+ { 0x11, KEY_CHANNELDOWN }, /* 'channel -' */
+ { 0x31, KEY_CHANNELUP }, /* 'channel +' */
+ { 0x1e, KEY_VOLUMEDOWN }, /* 'volume -' */
+ { 0x3e, KEY_VOLUMEUP }, /* 'volume +' */
+};
+
+static struct rc_keymap avermedia_dvbt_map = {
+ .map = {
+ .scan = avermedia_dvbt,
+ .size = ARRAY_SIZE(avermedia_dvbt),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_AVERMEDIA_DVBT,
+ }
+};
+
+static int __init init_rc_map_avermedia_dvbt(void)
+{
+ return ir_register_map(&avermedia_dvbt_map);
+}
+
+static void __exit exit_rc_map_avermedia_dvbt(void)
+{
+ ir_unregister_map(&avermedia_dvbt_map);
+}
+
+module_init(init_rc_map_avermedia_dvbt)
+module_exit(exit_rc_map_avermedia_dvbt)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-avermedia-m135a-rm-jx.c b/drivers/media/IR/keymaps/rc-avermedia-m135a-rm-jx.c
new file mode 100644
index 0000000..101e7ea
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-avermedia-m135a-rm-jx.c
@@ -0,0 +1,90 @@
+/* avermedia-m135a-rm-jx.h - Keytable for avermedia_m135a_rm_jx Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/*
+ * Avermedia M135A with IR model RM-JX
+ * The same codes exist on both Positivo (BR) and original IR
+ * Mauro Carvalho Chehab <mchehab@infradead.org>
+ */
+
+static struct ir_scancode avermedia_m135a_rm_jx[] = {
+ { 0x0200, KEY_POWER2 },
+ { 0x022e, KEY_DOT }, /* '.' */
+ { 0x0201, KEY_MODE }, /* TV/FM or SOURCE */
+
+ { 0x0205, KEY_1 },
+ { 0x0206, KEY_2 },
+ { 0x0207, KEY_3 },
+ { 0x0209, KEY_4 },
+ { 0x020a, KEY_5 },
+ { 0x020b, KEY_6 },
+ { 0x020d, KEY_7 },
+ { 0x020e, KEY_8 },
+ { 0x020f, KEY_9 },
+ { 0x0211, KEY_0 },
+
+ { 0x0213, KEY_RIGHT }, /* -> or L */
+ { 0x0212, KEY_LEFT }, /* <- or R */
+
+ { 0x0217, KEY_SLEEP }, /* Capturar Imagem or Snapshot */
+ { 0x0210, KEY_SHUFFLE }, /* Amostra or 16 chan prev */
+
+ { 0x0303, KEY_CHANNELUP },
+ { 0x0302, KEY_CHANNELDOWN },
+ { 0x021f, KEY_VOLUMEUP },
+ { 0x021e, KEY_VOLUMEDOWN },
+ { 0x020c, KEY_ENTER }, /* Full Screen */
+
+ { 0x0214, KEY_MUTE },
+ { 0x0208, KEY_AUDIO },
+
+ { 0x0203, KEY_TEXT }, /* Teletext */
+ { 0x0204, KEY_EPG },
+ { 0x022b, KEY_TV2 }, /* TV2 or PIP */
+
+ { 0x021d, KEY_RED },
+ { 0x021c, KEY_YELLOW },
+ { 0x0301, KEY_GREEN },
+ { 0x0300, KEY_BLUE },
+
+ { 0x021a, KEY_PLAYPAUSE },
+ { 0x0219, KEY_RECORD },
+ { 0x0218, KEY_PLAY },
+ { 0x021b, KEY_STOP },
+};
+
+static struct rc_keymap avermedia_m135a_rm_jx_map = {
+ .map = {
+ .scan = avermedia_m135a_rm_jx,
+ .size = ARRAY_SIZE(avermedia_m135a_rm_jx),
+ .ir_type = IR_TYPE_NEC,
+ .name = RC_MAP_AVERMEDIA_M135A_RM_JX,
+ }
+};
+
+static int __init init_rc_map_avermedia_m135a_rm_jx(void)
+{
+ return ir_register_map(&avermedia_m135a_rm_jx_map);
+}
+
+static void __exit exit_rc_map_avermedia_m135a_rm_jx(void)
+{
+ ir_unregister_map(&avermedia_m135a_rm_jx_map);
+}
+
+module_init(init_rc_map_avermedia_m135a_rm_jx)
+module_exit(exit_rc_map_avermedia_m135a_rm_jx)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-avermedia.c b/drivers/media/IR/keymaps/rc-avermedia.c
new file mode 100644
index 0000000..21effd5
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-avermedia.c
@@ -0,0 +1,86 @@
+/* avermedia.h - Keytable for avermedia Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Alex Hermann <gaaf@gmx.net> */
+
+static struct ir_scancode avermedia[] = {
+ { 0x28, KEY_1 },
+ { 0x18, KEY_2 },
+ { 0x38, KEY_3 },
+ { 0x24, KEY_4 },
+ { 0x14, KEY_5 },
+ { 0x34, KEY_6 },
+ { 0x2c, KEY_7 },
+ { 0x1c, KEY_8 },
+ { 0x3c, KEY_9 },
+ { 0x22, KEY_0 },
+
+ { 0x20, KEY_TV }, /* TV/FM */
+ { 0x10, KEY_CD }, /* CD */
+ { 0x30, KEY_TEXT }, /* TELETEXT */
+ { 0x00, KEY_POWER }, /* POWER */
+
+ { 0x08, KEY_VIDEO }, /* VIDEO */
+ { 0x04, KEY_AUDIO }, /* AUDIO */
+ { 0x0c, KEY_ZOOM }, /* FULL SCREEN */
+
+ { 0x12, KEY_SUBTITLE }, /* DISPLAY */
+ { 0x32, KEY_REWIND }, /* LOOP */
+ { 0x02, KEY_PRINT }, /* PREVIEW */
+
+ { 0x2a, KEY_SEARCH }, /* AUTOSCAN */
+ { 0x1a, KEY_SLEEP }, /* FREEZE */
+ { 0x3a, KEY_CAMERA }, /* SNAPSHOT */
+ { 0x0a, KEY_MUTE }, /* MUTE */
+
+ { 0x26, KEY_RECORD }, /* RECORD */
+ { 0x16, KEY_PAUSE }, /* PAUSE */
+ { 0x36, KEY_STOP }, /* STOP */
+ { 0x06, KEY_PLAY }, /* PLAY */
+
+ { 0x2e, KEY_RED }, /* RED */
+ { 0x21, KEY_GREEN }, /* GREEN */
+ { 0x0e, KEY_YELLOW }, /* YELLOW */
+ { 0x01, KEY_BLUE }, /* BLUE */
+
+ { 0x1e, KEY_VOLUMEDOWN }, /* VOLUME- */
+ { 0x3e, KEY_VOLUMEUP }, /* VOLUME+ */
+ { 0x11, KEY_CHANNELDOWN }, /* CHANNEL/PAGE- */
+ { 0x31, KEY_CHANNELUP } /* CHANNEL/PAGE+ */
+};
+
+static struct rc_keymap avermedia_map = {
+ .map = {
+ .scan = avermedia,
+ .size = ARRAY_SIZE(avermedia),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_AVERMEDIA,
+ }
+};
+
+static int __init init_rc_map_avermedia(void)
+{
+ return ir_register_map(&avermedia_map);
+}
+
+static void __exit exit_rc_map_avermedia(void)
+{
+ ir_unregister_map(&avermedia_map);
+}
+
+module_init(init_rc_map_avermedia)
+module_exit(exit_rc_map_avermedia)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-avertv-303.c b/drivers/media/IR/keymaps/rc-avertv-303.c
new file mode 100644
index 0000000..971c59d
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-avertv-303.c
@@ -0,0 +1,85 @@
+/* avertv-303.h - Keytable for avertv_303 Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* AVERTV STUDIO 303 Remote */
+
+static struct ir_scancode avertv_303[] = {
+ { 0x2a, KEY_1 },
+ { 0x32, KEY_2 },
+ { 0x3a, KEY_3 },
+ { 0x4a, KEY_4 },
+ { 0x52, KEY_5 },
+ { 0x5a, KEY_6 },
+ { 0x6a, KEY_7 },
+ { 0x72, KEY_8 },
+ { 0x7a, KEY_9 },
+ { 0x0e, KEY_0 },
+
+ { 0x02, KEY_POWER },
+ { 0x22, KEY_VIDEO },
+ { 0x42, KEY_AUDIO },
+ { 0x62, KEY_ZOOM },
+ { 0x0a, KEY_TV },
+ { 0x12, KEY_CD },
+ { 0x1a, KEY_TEXT },
+
+ { 0x16, KEY_SUBTITLE },
+ { 0x1e, KEY_REWIND },
+ { 0x06, KEY_PRINT },
+
+ { 0x2e, KEY_SEARCH },
+ { 0x36, KEY_SLEEP },
+ { 0x3e, KEY_SHUFFLE },
+ { 0x26, KEY_MUTE },
+
+ { 0x4e, KEY_RECORD },
+ { 0x56, KEY_PAUSE },
+ { 0x5e, KEY_STOP },
+ { 0x46, KEY_PLAY },
+
+ { 0x6e, KEY_RED },
+ { 0x0b, KEY_GREEN },
+ { 0x66, KEY_YELLOW },
+ { 0x03, KEY_BLUE },
+
+ { 0x76, KEY_LEFT },
+ { 0x7e, KEY_RIGHT },
+ { 0x13, KEY_DOWN },
+ { 0x1b, KEY_UP },
+};
+
+static struct rc_keymap avertv_303_map = {
+ .map = {
+ .scan = avertv_303,
+ .size = ARRAY_SIZE(avertv_303),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_AVERTV_303,
+ }
+};
+
+static int __init init_rc_map_avertv_303(void)
+{
+ return ir_register_map(&avertv_303_map);
+}
+
+static void __exit exit_rc_map_avertv_303(void)
+{
+ ir_unregister_map(&avertv_303_map);
+}
+
+module_init(init_rc_map_avertv_303)
+module_exit(exit_rc_map_avertv_303)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-behold-columbus.c b/drivers/media/IR/keymaps/rc-behold-columbus.c
new file mode 100644
index 0000000..9f56c98
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-behold-columbus.c
@@ -0,0 +1,108 @@
+/* behold-columbus.h - Keytable for behold_columbus Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Beholder Intl. Ltd. 2008
+ * Dmitry Belimov d.belimov@google.com
+ * Keytable is used by BeholdTV Columbus
+ * The "ascii-art picture" below (in comments, first row
+ * is the keycode in hex, and subsequent row(s) shows
+ * the button labels (several variants when appropriate)
+ * helps to descide which keycodes to assign to the buttons.
+ */
+
+static struct ir_scancode behold_columbus[] = {
+
+ /* 0x13 0x11 0x1C 0x12 *
+ * Mute Source TV/FM Power *
+ * */
+
+ { 0x13, KEY_MUTE },
+ { 0x11, KEY_PROPS },
+ { 0x1C, KEY_TUNER }, /* KEY_TV/KEY_RADIO */
+ { 0x12, KEY_POWER },
+
+ /* 0x01 0x02 0x03 0x0D *
+ * 1 2 3 Stereo *
+ * *
+ * 0x04 0x05 0x06 0x19 *
+ * 4 5 6 Snapshot *
+ * *
+ * 0x07 0x08 0x09 0x10 *
+ * 7 8 9 Zoom *
+ * */
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x0D, KEY_SETUP }, /* Setup key */
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x19, KEY_CAMERA }, /* Snapshot key */
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+ { 0x10, KEY_ZOOM },
+
+ /* 0x0A 0x00 0x0B 0x0C *
+ * RECALL 0 ChannelUp VolumeUp *
+ * */
+ { 0x0A, KEY_AGAIN },
+ { 0x00, KEY_0 },
+ { 0x0B, KEY_CHANNELUP },
+ { 0x0C, KEY_VOLUMEUP },
+
+ /* 0x1B 0x1D 0x15 0x18 *
+ * Timeshift Record ChannelDown VolumeDown *
+ * */
+
+ { 0x1B, KEY_TIME },
+ { 0x1D, KEY_RECORD },
+ { 0x15, KEY_CHANNELDOWN },
+ { 0x18, KEY_VOLUMEDOWN },
+
+ /* 0x0E 0x1E 0x0F 0x1A *
+ * Stop Pause Previouse Next *
+ * */
+
+ { 0x0E, KEY_STOP },
+ { 0x1E, KEY_PAUSE },
+ { 0x0F, KEY_PREVIOUS },
+ { 0x1A, KEY_NEXT },
+
+};
+
+static struct rc_keymap behold_columbus_map = {
+ .map = {
+ .scan = behold_columbus,
+ .size = ARRAY_SIZE(behold_columbus),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_BEHOLD_COLUMBUS,
+ }
+};
+
+static int __init init_rc_map_behold_columbus(void)
+{
+ return ir_register_map(&behold_columbus_map);
+}
+
+static void __exit exit_rc_map_behold_columbus(void)
+{
+ ir_unregister_map(&behold_columbus_map);
+}
+
+module_init(init_rc_map_behold_columbus)
+module_exit(exit_rc_map_behold_columbus)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-behold.c b/drivers/media/IR/keymaps/rc-behold.c
new file mode 100644
index 0000000..abc140b
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-behold.c
@@ -0,0 +1,141 @@
+/* behold.h - Keytable for behold Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/*
+ * Igor Kuznetsov <igk72@ya.ru>
+ * Andrey J. Melnikov <temnota@kmv.ru>
+ *
+ * Keytable is used by BeholdTV 60x series, M6 series at
+ * least, and probably other cards too.
+ * The "ascii-art picture" below (in comments, first row
+ * is the keycode in hex, and subsequent row(s) shows
+ * the button labels (several variants when appropriate)
+ * helps to descide which keycodes to assign to the buttons.
+ */
+
+static struct ir_scancode behold[] = {
+
+ /* 0x1c 0x12 *
+ * TV/FM POWER *
+ * */
+ { 0x1c, KEY_TUNER }, /* XXX KEY_TV / KEY_RADIO */
+ { 0x12, KEY_POWER },
+
+ /* 0x01 0x02 0x03 *
+ * 1 2 3 *
+ * *
+ * 0x04 0x05 0x06 *
+ * 4 5 6 *
+ * *
+ * 0x07 0x08 0x09 *
+ * 7 8 9 *
+ * */
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ /* 0x0a 0x00 0x17 *
+ * RECALL 0 MODE *
+ * */
+ { 0x0a, KEY_AGAIN },
+ { 0x00, KEY_0 },
+ { 0x17, KEY_MODE },
+
+ /* 0x14 0x10 *
+ * ASPECT FULLSCREEN *
+ * */
+ { 0x14, KEY_SCREEN },
+ { 0x10, KEY_ZOOM },
+
+ /* 0x0b *
+ * Up *
+ * *
+ * 0x18 0x16 0x0c *
+ * Left Ok Right *
+ * *
+ * 0x015 *
+ * Down *
+ * */
+ { 0x0b, KEY_CHANNELUP },
+ { 0x18, KEY_VOLUMEDOWN },
+ { 0x16, KEY_OK }, /* XXX KEY_ENTER */
+ { 0x0c, KEY_VOLUMEUP },
+ { 0x15, KEY_CHANNELDOWN },
+
+ /* 0x11 0x0d *
+ * MUTE INFO *
+ * */
+ { 0x11, KEY_MUTE },
+ { 0x0d, KEY_INFO },
+
+ /* 0x0f 0x1b 0x1a *
+ * RECORD PLAY/PAUSE STOP *
+ * *
+ * 0x0e 0x1f 0x1e *
+ *TELETEXT AUDIO SOURCE *
+ * RED YELLOW *
+ * */
+ { 0x0f, KEY_RECORD },
+ { 0x1b, KEY_PLAYPAUSE },
+ { 0x1a, KEY_STOP },
+ { 0x0e, KEY_TEXT },
+ { 0x1f, KEY_RED }, /*XXX KEY_AUDIO */
+ { 0x1e, KEY_YELLOW }, /*XXX KEY_SOURCE */
+
+ /* 0x1d 0x13 0x19 *
+ * SLEEP PREVIEW DVB *
+ * GREEN BLUE *
+ * */
+ { 0x1d, KEY_SLEEP },
+ { 0x13, KEY_GREEN },
+ { 0x19, KEY_BLUE }, /* XXX KEY_SAT */
+
+ /* 0x58 0x5c *
+ * FREEZE SNAPSHOT *
+ * */
+ { 0x58, KEY_SLOW },
+ { 0x5c, KEY_CAMERA },
+
+};
+
+static struct rc_keymap behold_map = {
+ .map = {
+ .scan = behold,
+ .size = ARRAY_SIZE(behold),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_BEHOLD,
+ }
+};
+
+static int __init init_rc_map_behold(void)
+{
+ return ir_register_map(&behold_map);
+}
+
+static void __exit exit_rc_map_behold(void)
+{
+ ir_unregister_map(&behold_map);
+}
+
+module_init(init_rc_map_behold)
+module_exit(exit_rc_map_behold)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-budget-ci-old.c b/drivers/media/IR/keymaps/rc-budget-ci-old.c
new file mode 100644
index 0000000..64c2ac9
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-budget-ci-old.c
@@ -0,0 +1,92 @@
+/* budget-ci-old.h - Keytable for budget_ci_old Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* From reading the following remotes:
+ * Zenith Universal 7 / TV Mode 807 / VCR Mode 837
+ * Hauppauge (from NOVA-CI-s box product)
+ * This is a "middle of the road" approach, differences are noted
+ */
+
+static struct ir_scancode budget_ci_old[] = {
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+ { 0x0a, KEY_ENTER },
+ { 0x0b, KEY_RED },
+ { 0x0c, KEY_POWER }, /* RADIO on Hauppauge */
+ { 0x0d, KEY_MUTE },
+ { 0x0f, KEY_A }, /* TV on Hauppauge */
+ { 0x10, KEY_VOLUMEUP },
+ { 0x11, KEY_VOLUMEDOWN },
+ { 0x14, KEY_B },
+ { 0x1c, KEY_UP },
+ { 0x1d, KEY_DOWN },
+ { 0x1e, KEY_OPTION }, /* RESERVED on Hauppauge */
+ { 0x1f, KEY_BREAK },
+ { 0x20, KEY_CHANNELUP },
+ { 0x21, KEY_CHANNELDOWN },
+ { 0x22, KEY_PREVIOUS }, /* Prev Ch on Zenith, SOURCE on Hauppauge */
+ { 0x24, KEY_RESTART },
+ { 0x25, KEY_OK },
+ { 0x26, KEY_CYCLEWINDOWS }, /* MINIMIZE on Hauppauge */
+ { 0x28, KEY_ENTER }, /* VCR mode on Zenith */
+ { 0x29, KEY_PAUSE },
+ { 0x2b, KEY_RIGHT },
+ { 0x2c, KEY_LEFT },
+ { 0x2e, KEY_MENU }, /* FULL SCREEN on Hauppauge */
+ { 0x30, KEY_SLOW },
+ { 0x31, KEY_PREVIOUS }, /* VCR mode on Zenith */
+ { 0x32, KEY_REWIND },
+ { 0x34, KEY_FASTFORWARD },
+ { 0x35, KEY_PLAY },
+ { 0x36, KEY_STOP },
+ { 0x37, KEY_RECORD },
+ { 0x38, KEY_TUNER }, /* TV/VCR on Zenith */
+ { 0x3a, KEY_C },
+ { 0x3c, KEY_EXIT },
+ { 0x3d, KEY_POWER2 },
+ { 0x3e, KEY_TUNER },
+};
+
+static struct rc_keymap budget_ci_old_map = {
+ .map = {
+ .scan = budget_ci_old,
+ .size = ARRAY_SIZE(budget_ci_old),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_BUDGET_CI_OLD,
+ }
+};
+
+static int __init init_rc_map_budget_ci_old(void)
+{
+ return ir_register_map(&budget_ci_old_map);
+}
+
+static void __exit exit_rc_map_budget_ci_old(void)
+{
+ ir_unregister_map(&budget_ci_old_map);
+}
+
+module_init(init_rc_map_budget_ci_old)
+module_exit(exit_rc_map_budget_ci_old)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-cinergy-1400.c b/drivers/media/IR/keymaps/rc-cinergy-1400.c
new file mode 100644
index 0000000..074f2c2
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-cinergy-1400.c
@@ -0,0 +1,84 @@
+/* cinergy-1400.h - Keytable for cinergy_1400 Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Cinergy 1400 DVB-T */
+
+static struct ir_scancode cinergy_1400[] = {
+ { 0x01, KEY_POWER },
+ { 0x02, KEY_1 },
+ { 0x03, KEY_2 },
+ { 0x04, KEY_3 },
+ { 0x05, KEY_4 },
+ { 0x06, KEY_5 },
+ { 0x07, KEY_6 },
+ { 0x08, KEY_7 },
+ { 0x09, KEY_8 },
+ { 0x0a, KEY_9 },
+ { 0x0c, KEY_0 },
+
+ { 0x0b, KEY_VIDEO },
+ { 0x0d, KEY_REFRESH },
+ { 0x0e, KEY_SELECT },
+ { 0x0f, KEY_EPG },
+ { 0x10, KEY_UP },
+ { 0x11, KEY_LEFT },
+ { 0x12, KEY_OK },
+ { 0x13, KEY_RIGHT },
+ { 0x14, KEY_DOWN },
+ { 0x15, KEY_TEXT },
+ { 0x16, KEY_INFO },
+
+ { 0x17, KEY_RED },
+ { 0x18, KEY_GREEN },
+ { 0x19, KEY_YELLOW },
+ { 0x1a, KEY_BLUE },
+
+ { 0x1b, KEY_CHANNELUP },
+ { 0x1c, KEY_VOLUMEUP },
+ { 0x1d, KEY_MUTE },
+ { 0x1e, KEY_VOLUMEDOWN },
+ { 0x1f, KEY_CHANNELDOWN },
+
+ { 0x40, KEY_PAUSE },
+ { 0x4c, KEY_PLAY },
+ { 0x58, KEY_RECORD },
+ { 0x54, KEY_PREVIOUS },
+ { 0x48, KEY_STOP },
+ { 0x5c, KEY_NEXT },
+};
+
+static struct rc_keymap cinergy_1400_map = {
+ .map = {
+ .scan = cinergy_1400,
+ .size = ARRAY_SIZE(cinergy_1400),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_CINERGY_1400,
+ }
+};
+
+static int __init init_rc_map_cinergy_1400(void)
+{
+ return ir_register_map(&cinergy_1400_map);
+}
+
+static void __exit exit_rc_map_cinergy_1400(void)
+{
+ ir_unregister_map(&cinergy_1400_map);
+}
+
+module_init(init_rc_map_cinergy_1400)
+module_exit(exit_rc_map_cinergy_1400)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-cinergy.c b/drivers/media/IR/keymaps/rc-cinergy.c
new file mode 100644
index 0000000..cf84c3d
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-cinergy.c
@@ -0,0 +1,78 @@
+/* cinergy.h - Keytable for cinergy Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+static struct ir_scancode cinergy[] = {
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x0a, KEY_POWER },
+ { 0x0b, KEY_PROG1 }, /* app */
+ { 0x0c, KEY_ZOOM }, /* zoom/fullscreen */
+ { 0x0d, KEY_CHANNELUP }, /* channel */
+ { 0x0e, KEY_CHANNELDOWN }, /* channel- */
+ { 0x0f, KEY_VOLUMEUP },
+ { 0x10, KEY_VOLUMEDOWN },
+ { 0x11, KEY_TUNER }, /* AV */
+ { 0x12, KEY_NUMLOCK }, /* -/-- */
+ { 0x13, KEY_AUDIO }, /* audio */
+ { 0x14, KEY_MUTE },
+ { 0x15, KEY_UP },
+ { 0x16, KEY_DOWN },
+ { 0x17, KEY_LEFT },
+ { 0x18, KEY_RIGHT },
+ { 0x19, BTN_LEFT, },
+ { 0x1a, BTN_RIGHT, },
+ { 0x1b, KEY_WWW }, /* text */
+ { 0x1c, KEY_REWIND },
+ { 0x1d, KEY_FORWARD },
+ { 0x1e, KEY_RECORD },
+ { 0x1f, KEY_PLAY },
+ { 0x20, KEY_PREVIOUSSONG },
+ { 0x21, KEY_NEXTSONG },
+ { 0x22, KEY_PAUSE },
+ { 0x23, KEY_STOP },
+};
+
+static struct rc_keymap cinergy_map = {
+ .map = {
+ .scan = cinergy,
+ .size = ARRAY_SIZE(cinergy),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_CINERGY,
+ }
+};
+
+static int __init init_rc_map_cinergy(void)
+{
+ return ir_register_map(&cinergy_map);
+}
+
+static void __exit exit_rc_map_cinergy(void)
+{
+ ir_unregister_map(&cinergy_map);
+}
+
+module_init(init_rc_map_cinergy)
+module_exit(exit_rc_map_cinergy)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-dm1105-nec.c b/drivers/media/IR/keymaps/rc-dm1105-nec.c
new file mode 100644
index 0000000..90684d0
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-dm1105-nec.c
@@ -0,0 +1,76 @@
+/* dm1105-nec.h - Keytable for dm1105_nec Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* DVBWorld remotes
+ Igor M. Liplianin <liplianin@me.by>
+ */
+
+static struct ir_scancode dm1105_nec[] = {
+ { 0x0a, KEY_POWER2}, /* power */
+ { 0x0c, KEY_MUTE}, /* mute */
+ { 0x11, KEY_1},
+ { 0x12, KEY_2},
+ { 0x13, KEY_3},
+ { 0x14, KEY_4},
+ { 0x15, KEY_5},
+ { 0x16, KEY_6},
+ { 0x17, KEY_7},
+ { 0x18, KEY_8},
+ { 0x19, KEY_9},
+ { 0x10, KEY_0},
+ { 0x1c, KEY_CHANNELUP}, /* ch+ */
+ { 0x0f, KEY_CHANNELDOWN}, /* ch- */
+ { 0x1a, KEY_VOLUMEUP}, /* vol+ */
+ { 0x0e, KEY_VOLUMEDOWN}, /* vol- */
+ { 0x04, KEY_RECORD}, /* rec */
+ { 0x09, KEY_CHANNEL}, /* fav */
+ { 0x08, KEY_BACKSPACE}, /* rewind */
+ { 0x07, KEY_FASTFORWARD}, /* fast */
+ { 0x0b, KEY_PAUSE}, /* pause */
+ { 0x02, KEY_ESC}, /* cancel */
+ { 0x03, KEY_TAB}, /* tab */
+ { 0x00, KEY_UP}, /* up */
+ { 0x1f, KEY_ENTER}, /* ok */
+ { 0x01, KEY_DOWN}, /* down */
+ { 0x05, KEY_RECORD}, /* cap */
+ { 0x06, KEY_STOP}, /* stop */
+ { 0x40, KEY_ZOOM}, /* full */
+ { 0x1e, KEY_TV}, /* tvmode */
+ { 0x1b, KEY_B}, /* recall */
+};
+
+static struct rc_keymap dm1105_nec_map = {
+ .map = {
+ .scan = dm1105_nec,
+ .size = ARRAY_SIZE(dm1105_nec),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_DM1105_NEC,
+ }
+};
+
+static int __init init_rc_map_dm1105_nec(void)
+{
+ return ir_register_map(&dm1105_nec_map);
+}
+
+static void __exit exit_rc_map_dm1105_nec(void)
+{
+ ir_unregister_map(&dm1105_nec_map);
+}
+
+module_init(init_rc_map_dm1105_nec)
+module_exit(exit_rc_map_dm1105_nec)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-dntv-live-dvb-t.c b/drivers/media/IR/keymaps/rc-dntv-live-dvb-t.c
new file mode 100644
index 0000000..8a4027a
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-dntv-live-dvb-t.c
@@ -0,0 +1,78 @@
+/* dntv-live-dvb-t.h - Keytable for dntv_live_dvb_t Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* DigitalNow DNTV Live DVB-T Remote */
+
+static struct ir_scancode dntv_live_dvb_t[] = {
+ { 0x00, KEY_ESC }, /* 'go up a level?' */
+ /* Keys 0 to 9 */
+ { 0x0a, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x0b, KEY_TUNER }, /* tv/fm */
+ { 0x0c, KEY_SEARCH }, /* scan */
+ { 0x0d, KEY_STOP },
+ { 0x0e, KEY_PAUSE },
+ { 0x0f, KEY_LIST }, /* source */
+
+ { 0x10, KEY_MUTE },
+ { 0x11, KEY_REWIND }, /* backward << */
+ { 0x12, KEY_POWER },
+ { 0x13, KEY_CAMERA }, /* snap */
+ { 0x14, KEY_AUDIO }, /* stereo */
+ { 0x15, KEY_CLEAR }, /* reset */
+ { 0x16, KEY_PLAY },
+ { 0x17, KEY_ENTER },
+ { 0x18, KEY_ZOOM }, /* full screen */
+ { 0x19, KEY_FASTFORWARD }, /* forward >> */
+ { 0x1a, KEY_CHANNELUP },
+ { 0x1b, KEY_VOLUMEUP },
+ { 0x1c, KEY_INFO }, /* preview */
+ { 0x1d, KEY_RECORD }, /* record */
+ { 0x1e, KEY_CHANNELDOWN },
+ { 0x1f, KEY_VOLUMEDOWN },
+};
+
+static struct rc_keymap dntv_live_dvb_t_map = {
+ .map = {
+ .scan = dntv_live_dvb_t,
+ .size = ARRAY_SIZE(dntv_live_dvb_t),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_DNTV_LIVE_DVB_T,
+ }
+};
+
+static int __init init_rc_map_dntv_live_dvb_t(void)
+{
+ return ir_register_map(&dntv_live_dvb_t_map);
+}
+
+static void __exit exit_rc_map_dntv_live_dvb_t(void)
+{
+ ir_unregister_map(&dntv_live_dvb_t_map);
+}
+
+module_init(init_rc_map_dntv_live_dvb_t)
+module_exit(exit_rc_map_dntv_live_dvb_t)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-dntv-live-dvbt-pro.c b/drivers/media/IR/keymaps/rc-dntv-live-dvbt-pro.c
new file mode 100644
index 0000000..6f4d607
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-dntv-live-dvbt-pro.c
@@ -0,0 +1,97 @@
+/* dntv-live-dvbt-pro.h - Keytable for dntv_live_dvbt_pro Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* DigitalNow DNTV Live! DVB-T Pro Remote */
+
+static struct ir_scancode dntv_live_dvbt_pro[] = {
+ { 0x16, KEY_POWER },
+ { 0x5b, KEY_HOME },
+
+ { 0x55, KEY_TV }, /* live tv */
+ { 0x58, KEY_TUNER }, /* digital Radio */
+ { 0x5a, KEY_RADIO }, /* FM radio */
+ { 0x59, KEY_DVD }, /* dvd menu */
+ { 0x03, KEY_1 },
+ { 0x01, KEY_2 },
+ { 0x06, KEY_3 },
+ { 0x09, KEY_4 },
+ { 0x1d, KEY_5 },
+ { 0x1f, KEY_6 },
+ { 0x0d, KEY_7 },
+ { 0x19, KEY_8 },
+ { 0x1b, KEY_9 },
+ { 0x0c, KEY_CANCEL },
+ { 0x15, KEY_0 },
+ { 0x4a, KEY_CLEAR },
+ { 0x13, KEY_BACK },
+ { 0x00, KEY_TAB },
+ { 0x4b, KEY_UP },
+ { 0x4e, KEY_LEFT },
+ { 0x4f, KEY_OK },
+ { 0x52, KEY_RIGHT },
+ { 0x51, KEY_DOWN },
+ { 0x1e, KEY_VOLUMEUP },
+ { 0x0a, KEY_VOLUMEDOWN },
+ { 0x02, KEY_CHANNELDOWN },
+ { 0x05, KEY_CHANNELUP },
+ { 0x11, KEY_RECORD },
+ { 0x14, KEY_PLAY },
+ { 0x4c, KEY_PAUSE },
+ { 0x1a, KEY_STOP },
+ { 0x40, KEY_REWIND },
+ { 0x12, KEY_FASTFORWARD },
+ { 0x41, KEY_PREVIOUSSONG }, /* replay |< */
+ { 0x42, KEY_NEXTSONG }, /* skip >| */
+ { 0x54, KEY_CAMERA }, /* capture */
+ { 0x50, KEY_LANGUAGE }, /* sap */
+ { 0x47, KEY_TV2 }, /* pip */
+ { 0x4d, KEY_SCREEN },
+ { 0x43, KEY_SUBTITLE },
+ { 0x10, KEY_MUTE },
+ { 0x49, KEY_AUDIO }, /* l/r */
+ { 0x07, KEY_SLEEP },
+ { 0x08, KEY_VIDEO }, /* a/v */
+ { 0x0e, KEY_PREVIOUS }, /* recall */
+ { 0x45, KEY_ZOOM }, /* zoom + */
+ { 0x46, KEY_ANGLE }, /* zoom - */
+ { 0x56, KEY_RED },
+ { 0x57, KEY_GREEN },
+ { 0x5c, KEY_YELLOW },
+ { 0x5d, KEY_BLUE },
+};
+
+static struct rc_keymap dntv_live_dvbt_pro_map = {
+ .map = {
+ .scan = dntv_live_dvbt_pro,
+ .size = ARRAY_SIZE(dntv_live_dvbt_pro),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_DNTV_LIVE_DVBT_PRO,
+ }
+};
+
+static int __init init_rc_map_dntv_live_dvbt_pro(void)
+{
+ return ir_register_map(&dntv_live_dvbt_pro_map);
+}
+
+static void __exit exit_rc_map_dntv_live_dvbt_pro(void)
+{
+ ir_unregister_map(&dntv_live_dvbt_pro_map);
+}
+
+module_init(init_rc_map_dntv_live_dvbt_pro)
+module_exit(exit_rc_map_dntv_live_dvbt_pro)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-em-terratec.c b/drivers/media/IR/keymaps/rc-em-terratec.c
new file mode 100644
index 0000000..3130c9c
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-em-terratec.c
@@ -0,0 +1,69 @@
+/* em-terratec.h - Keytable for em_terratec Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+static struct ir_scancode em_terratec[] = {
+ { 0x01, KEY_CHANNEL },
+ { 0x02, KEY_SELECT },
+ { 0x03, KEY_MUTE },
+ { 0x04, KEY_POWER },
+ { 0x05, KEY_1 },
+ { 0x06, KEY_2 },
+ { 0x07, KEY_3 },
+ { 0x08, KEY_CHANNELUP },
+ { 0x09, KEY_4 },
+ { 0x0a, KEY_5 },
+ { 0x0b, KEY_6 },
+ { 0x0c, KEY_CHANNELDOWN },
+ { 0x0d, KEY_7 },
+ { 0x0e, KEY_8 },
+ { 0x0f, KEY_9 },
+ { 0x10, KEY_VOLUMEUP },
+ { 0x11, KEY_0 },
+ { 0x12, KEY_MENU },
+ { 0x13, KEY_PRINT },
+ { 0x14, KEY_VOLUMEDOWN },
+ { 0x16, KEY_PAUSE },
+ { 0x18, KEY_RECORD },
+ { 0x19, KEY_REWIND },
+ { 0x1a, KEY_PLAY },
+ { 0x1b, KEY_FORWARD },
+ { 0x1c, KEY_BACKSPACE },
+ { 0x1e, KEY_STOP },
+ { 0x40, KEY_ZOOM },
+};
+
+static struct rc_keymap em_terratec_map = {
+ .map = {
+ .scan = em_terratec,
+ .size = ARRAY_SIZE(em_terratec),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_EM_TERRATEC,
+ }
+};
+
+static int __init init_rc_map_em_terratec(void)
+{
+ return ir_register_map(&em_terratec_map);
+}
+
+static void __exit exit_rc_map_em_terratec(void)
+{
+ ir_unregister_map(&em_terratec_map);
+}
+
+module_init(init_rc_map_em_terratec)
+module_exit(exit_rc_map_em_terratec)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-empty.c b/drivers/media/IR/keymaps/rc-empty.c
new file mode 100644
index 0000000..3b338d8
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-empty.c
@@ -0,0 +1,44 @@
+/* empty.h - Keytable for empty Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* empty keytable, can be used as placeholder for not-yet created keytables */
+
+static struct ir_scancode empty[] = {
+ { 0x2a, KEY_COFFEE },
+};
+
+static struct rc_keymap empty_map = {
+ .map = {
+ .scan = empty,
+ .size = ARRAY_SIZE(empty),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_EMPTY,
+ }
+};
+
+static int __init init_rc_map_empty(void)
+{
+ return ir_register_map(&empty_map);
+}
+
+static void __exit exit_rc_map_empty(void)
+{
+ ir_unregister_map(&empty_map);
+}
+
+module_init(init_rc_map_empty)
+module_exit(exit_rc_map_empty)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-encore-enltv-fm53.c b/drivers/media/IR/keymaps/rc-encore-enltv-fm53.c
new file mode 100644
index 0000000..4b81696
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-encore-enltv-fm53.c
@@ -0,0 +1,81 @@
+/* encore-enltv-fm53.h - Keytable for encore_enltv_fm53 Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Encore ENLTV-FM v5.3
+ Mauro Carvalho Chehab <mchehab@infradead.org>
+ */
+
+static struct ir_scancode encore_enltv_fm53[] = {
+ { 0x10, KEY_POWER2},
+ { 0x06, KEY_MUTE},
+
+ { 0x09, KEY_1},
+ { 0x1d, KEY_2},
+ { 0x1f, KEY_3},
+ { 0x19, KEY_4},
+ { 0x1b, KEY_5},
+ { 0x11, KEY_6},
+ { 0x17, KEY_7},
+ { 0x12, KEY_8},
+ { 0x16, KEY_9},
+ { 0x48, KEY_0},
+
+ { 0x04, KEY_LIST}, /* -/-- */
+ { 0x40, KEY_LAST}, /* recall */
+
+ { 0x02, KEY_MODE}, /* TV/AV */
+ { 0x05, KEY_CAMERA}, /* SNAPSHOT */
+
+ { 0x4c, KEY_CHANNELUP}, /* UP */
+ { 0x00, KEY_CHANNELDOWN}, /* DOWN */
+ { 0x0d, KEY_VOLUMEUP}, /* RIGHT */
+ { 0x15, KEY_VOLUMEDOWN}, /* LEFT */
+ { 0x49, KEY_ENTER}, /* OK */
+
+ { 0x54, KEY_RECORD},
+ { 0x4d, KEY_PLAY}, /* pause */
+
+ { 0x1e, KEY_MENU}, /* video setting */
+ { 0x0e, KEY_RIGHT}, /* <- */
+ { 0x1a, KEY_LEFT}, /* -> */
+
+ { 0x0a, KEY_CLEAR}, /* video default */
+ { 0x0c, KEY_ZOOM}, /* hide pannel */
+ { 0x47, KEY_SLEEP}, /* shutdown */
+};
+
+static struct rc_keymap encore_enltv_fm53_map = {
+ .map = {
+ .scan = encore_enltv_fm53,
+ .size = ARRAY_SIZE(encore_enltv_fm53),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_ENCORE_ENLTV_FM53,
+ }
+};
+
+static int __init init_rc_map_encore_enltv_fm53(void)
+{
+ return ir_register_map(&encore_enltv_fm53_map);
+}
+
+static void __exit exit_rc_map_encore_enltv_fm53(void)
+{
+ ir_unregister_map(&encore_enltv_fm53_map);
+}
+
+module_init(init_rc_map_encore_enltv_fm53)
+module_exit(exit_rc_map_encore_enltv_fm53)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-encore-enltv.c b/drivers/media/IR/keymaps/rc-encore-enltv.c
new file mode 100644
index 0000000..9fabffd
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-encore-enltv.c
@@ -0,0 +1,112 @@
+/* encore-enltv.h - Keytable for encore_enltv Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Encore ENLTV-FM - black plastic, white front cover with white glowing buttons
+ Juan Pablo Sormani <sorman@gmail.com> */
+
+static struct ir_scancode encore_enltv[] = {
+
+ /* Power button does nothing, neither in Windows app,
+ although it sends data (used for BIOS wakeup?) */
+ { 0x0d, KEY_MUTE },
+
+ { 0x1e, KEY_TV },
+ { 0x00, KEY_VIDEO },
+ { 0x01, KEY_AUDIO }, /* music */
+ { 0x02, KEY_MHP }, /* picture */
+
+ { 0x1f, KEY_1 },
+ { 0x03, KEY_2 },
+ { 0x04, KEY_3 },
+ { 0x05, KEY_4 },
+ { 0x1c, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x1d, KEY_9 },
+ { 0x0a, KEY_0 },
+
+ { 0x09, KEY_LIST }, /* -/-- */
+ { 0x0b, KEY_LAST }, /* recall */
+
+ { 0x14, KEY_HOME }, /* win start menu */
+ { 0x15, KEY_EXIT }, /* exit */
+ { 0x16, KEY_CHANNELUP }, /* UP */
+ { 0x12, KEY_CHANNELDOWN }, /* DOWN */
+ { 0x0c, KEY_VOLUMEUP }, /* RIGHT */
+ { 0x17, KEY_VOLUMEDOWN }, /* LEFT */
+
+ { 0x18, KEY_ENTER }, /* OK */
+
+ { 0x0e, KEY_ESC },
+ { 0x13, KEY_CYCLEWINDOWS }, /* desktop */
+ { 0x11, KEY_TAB },
+ { 0x19, KEY_SWITCHVIDEOMODE }, /* switch */
+
+ { 0x1a, KEY_MENU },
+ { 0x1b, KEY_ZOOM }, /* fullscreen */
+ { 0x44, KEY_TIME }, /* time shift */
+ { 0x40, KEY_MODE }, /* source */
+
+ { 0x5a, KEY_RECORD },
+ { 0x42, KEY_PLAY }, /* play/pause */
+ { 0x45, KEY_STOP },
+ { 0x43, KEY_CAMERA }, /* camera icon */
+
+ { 0x48, KEY_REWIND },
+ { 0x4a, KEY_FASTFORWARD },
+ { 0x49, KEY_PREVIOUS },
+ { 0x4b, KEY_NEXT },
+
+ { 0x4c, KEY_FAVORITES }, /* tv wall */
+ { 0x4d, KEY_SOUND }, /* DVD sound */
+ { 0x4e, KEY_LANGUAGE }, /* DVD lang */
+ { 0x4f, KEY_TEXT }, /* DVD text */
+
+ { 0x50, KEY_SLEEP }, /* shutdown */
+ { 0x51, KEY_MODE }, /* stereo > main */
+ { 0x52, KEY_SELECT }, /* stereo > sap */
+ { 0x53, KEY_PROG1 }, /* teletext */
+
+
+ { 0x59, KEY_RED }, /* AP1 */
+ { 0x41, KEY_GREEN }, /* AP2 */
+ { 0x47, KEY_YELLOW }, /* AP3 */
+ { 0x57, KEY_BLUE }, /* AP4 */
+};
+
+static struct rc_keymap encore_enltv_map = {
+ .map = {
+ .scan = encore_enltv,
+ .size = ARRAY_SIZE(encore_enltv),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_ENCORE_ENLTV,
+ }
+};
+
+static int __init init_rc_map_encore_enltv(void)
+{
+ return ir_register_map(&encore_enltv_map);
+}
+
+static void __exit exit_rc_map_encore_enltv(void)
+{
+ ir_unregister_map(&encore_enltv_map);
+}
+
+module_init(init_rc_map_encore_enltv)
+module_exit(exit_rc_map_encore_enltv)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-encore-enltv2.c b/drivers/media/IR/keymaps/rc-encore-enltv2.c
new file mode 100644
index 0000000..efefd51
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-encore-enltv2.c
@@ -0,0 +1,90 @@
+/* encore-enltv2.h - Keytable for encore_enltv2 Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Encore ENLTV2-FM - silver plastic - "Wand Media" written at the botton
+ Mauro Carvalho Chehab <mchehab@infradead.org> */
+
+static struct ir_scancode encore_enltv2[] = {
+ { 0x4c, KEY_POWER2 },
+ { 0x4a, KEY_TUNER },
+ { 0x40, KEY_1 },
+ { 0x60, KEY_2 },
+ { 0x50, KEY_3 },
+ { 0x70, KEY_4 },
+ { 0x48, KEY_5 },
+ { 0x68, KEY_6 },
+ { 0x58, KEY_7 },
+ { 0x78, KEY_8 },
+ { 0x44, KEY_9 },
+ { 0x54, KEY_0 },
+
+ { 0x64, KEY_LAST }, /* +100 */
+ { 0x4e, KEY_AGAIN }, /* Recall */
+
+ { 0x6c, KEY_SWITCHVIDEOMODE }, /* Video Source */
+ { 0x5e, KEY_MENU },
+ { 0x56, KEY_SCREEN },
+ { 0x7a, KEY_SETUP },
+
+ { 0x46, KEY_MUTE },
+ { 0x5c, KEY_MODE }, /* Stereo */
+ { 0x74, KEY_INFO },
+ { 0x7c, KEY_CLEAR },
+
+ { 0x55, KEY_UP },
+ { 0x49, KEY_DOWN },
+ { 0x7e, KEY_LEFT },
+ { 0x59, KEY_RIGHT },
+ { 0x6a, KEY_ENTER },
+
+ { 0x42, KEY_VOLUMEUP },
+ { 0x62, KEY_VOLUMEDOWN },
+ { 0x52, KEY_CHANNELUP },
+ { 0x72, KEY_CHANNELDOWN },
+
+ { 0x41, KEY_RECORD },
+ { 0x51, KEY_CAMERA }, /* Snapshot */
+ { 0x75, KEY_TIME }, /* Timeshift */
+ { 0x71, KEY_TV2 }, /* PIP */
+
+ { 0x45, KEY_REWIND },
+ { 0x6f, KEY_PAUSE },
+ { 0x7d, KEY_FORWARD },
+ { 0x79, KEY_STOP },
+};
+
+static struct rc_keymap encore_enltv2_map = {
+ .map = {
+ .scan = encore_enltv2,
+ .size = ARRAY_SIZE(encore_enltv2),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_ENCORE_ENLTV2,
+ }
+};
+
+static int __init init_rc_map_encore_enltv2(void)
+{
+ return ir_register_map(&encore_enltv2_map);
+}
+
+static void __exit exit_rc_map_encore_enltv2(void)
+{
+ ir_unregister_map(&encore_enltv2_map);
+}
+
+module_init(init_rc_map_encore_enltv2)
+module_exit(exit_rc_map_encore_enltv2)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-evga-indtube.c b/drivers/media/IR/keymaps/rc-evga-indtube.c
new file mode 100644
index 0000000..3f3fb13
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-evga-indtube.c
@@ -0,0 +1,61 @@
+/* evga-indtube.h - Keytable for evga_indtube Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* EVGA inDtube
+ Devin Heitmueller <devin.heitmueller@gmail.com>
+ */
+
+static struct ir_scancode evga_indtube[] = {
+ { 0x12, KEY_POWER},
+ { 0x02, KEY_MODE}, /* TV */
+ { 0x14, KEY_MUTE},
+ { 0x1a, KEY_CHANNELUP},
+ { 0x16, KEY_TV2}, /* PIP */
+ { 0x1d, KEY_VOLUMEUP},
+ { 0x05, KEY_CHANNELDOWN},
+ { 0x0f, KEY_PLAYPAUSE},
+ { 0x19, KEY_VOLUMEDOWN},
+ { 0x1c, KEY_REWIND},
+ { 0x0d, KEY_RECORD},
+ { 0x18, KEY_FORWARD},
+ { 0x1e, KEY_PREVIOUS},
+ { 0x1b, KEY_STOP},
+ { 0x1f, KEY_NEXT},
+ { 0x13, KEY_CAMERA},
+};
+
+static struct rc_keymap evga_indtube_map = {
+ .map = {
+ .scan = evga_indtube,
+ .size = ARRAY_SIZE(evga_indtube),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_EVGA_INDTUBE,
+ }
+};
+
+static int __init init_rc_map_evga_indtube(void)
+{
+ return ir_register_map(&evga_indtube_map);
+}
+
+static void __exit exit_rc_map_evga_indtube(void)
+{
+ ir_unregister_map(&evga_indtube_map);
+}
+
+module_init(init_rc_map_evga_indtube)
+module_exit(exit_rc_map_evga_indtube)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-eztv.c b/drivers/media/IR/keymaps/rc-eztv.c
new file mode 100644
index 0000000..660907a
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-eztv.c
@@ -0,0 +1,96 @@
+/* eztv.h - Keytable for eztv Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Alfons Geser <a.geser@cox.net>
+ * updates from Job D. R. Borges <jobdrb@ig.com.br> */
+
+static struct ir_scancode eztv[] = {
+ { 0x12, KEY_POWER },
+ { 0x01, KEY_TV }, /* DVR */
+ { 0x15, KEY_DVD }, /* DVD */
+ { 0x17, KEY_AUDIO }, /* music */
+ /* DVR mode / DVD mode / music mode */
+
+ { 0x1b, KEY_MUTE }, /* mute */
+ { 0x02, KEY_LANGUAGE }, /* MTS/SAP / audio / autoseek */
+ { 0x1e, KEY_SUBTITLE }, /* closed captioning / subtitle / seek */
+ { 0x16, KEY_ZOOM }, /* full screen */
+ { 0x1c, KEY_VIDEO }, /* video source / eject / delall */
+ { 0x1d, KEY_RESTART }, /* playback / angle / del */
+ { 0x2f, KEY_SEARCH }, /* scan / menu / playlist */
+ { 0x30, KEY_CHANNEL }, /* CH surfing / bookmark / memo */
+
+ { 0x31, KEY_HELP }, /* help */
+ { 0x32, KEY_MODE }, /* num/memo */
+ { 0x33, KEY_ESC }, /* cancel */
+
+ { 0x0c, KEY_UP }, /* up */
+ { 0x10, KEY_DOWN }, /* down */
+ { 0x08, KEY_LEFT }, /* left */
+ { 0x04, KEY_RIGHT }, /* right */
+ { 0x03, KEY_SELECT }, /* select */
+
+ { 0x1f, KEY_REWIND }, /* rewind */
+ { 0x20, KEY_PLAYPAUSE },/* play/pause */
+ { 0x29, KEY_FORWARD }, /* forward */
+ { 0x14, KEY_AGAIN }, /* repeat */
+ { 0x2b, KEY_RECORD }, /* recording */
+ { 0x2c, KEY_STOP }, /* stop */
+ { 0x2d, KEY_PLAY }, /* play */
+ { 0x2e, KEY_CAMERA }, /* snapshot / shuffle */
+
+ { 0x00, KEY_0 },
+ { 0x05, KEY_1 },
+ { 0x06, KEY_2 },
+ { 0x07, KEY_3 },
+ { 0x09, KEY_4 },
+ { 0x0a, KEY_5 },
+ { 0x0b, KEY_6 },
+ { 0x0d, KEY_7 },
+ { 0x0e, KEY_8 },
+ { 0x0f, KEY_9 },
+
+ { 0x2a, KEY_VOLUMEUP },
+ { 0x11, KEY_VOLUMEDOWN },
+ { 0x18, KEY_CHANNELUP },/* CH.tracking up */
+ { 0x19, KEY_CHANNELDOWN },/* CH.tracking down */
+
+ { 0x13, KEY_ENTER }, /* enter */
+ { 0x21, KEY_DOT }, /* . (decimal dot) */
+};
+
+static struct rc_keymap eztv_map = {
+ .map = {
+ .scan = eztv,
+ .size = ARRAY_SIZE(eztv),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_EZTV,
+ }
+};
+
+static int __init init_rc_map_eztv(void)
+{
+ return ir_register_map(&eztv_map);
+}
+
+static void __exit exit_rc_map_eztv(void)
+{
+ ir_unregister_map(&eztv_map);
+}
+
+module_init(init_rc_map_eztv)
+module_exit(exit_rc_map_eztv)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-flydvb.c b/drivers/media/IR/keymaps/rc-flydvb.c
new file mode 100644
index 0000000..a173c81
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-flydvb.c
@@ -0,0 +1,77 @@
+/* flydvb.h - Keytable for flydvb Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+static struct ir_scancode flydvb[] = {
+ { 0x01, KEY_ZOOM }, /* Full Screen */
+ { 0x00, KEY_POWER }, /* Power */
+
+ { 0x03, KEY_1 },
+ { 0x04, KEY_2 },
+ { 0x05, KEY_3 },
+ { 0x07, KEY_4 },
+ { 0x08, KEY_5 },
+ { 0x09, KEY_6 },
+ { 0x0b, KEY_7 },
+ { 0x0c, KEY_8 },
+ { 0x0d, KEY_9 },
+ { 0x06, KEY_AGAIN }, /* Recall */
+ { 0x0f, KEY_0 },
+ { 0x10, KEY_MUTE }, /* Mute */
+ { 0x02, KEY_RADIO }, /* TV/Radio */
+ { 0x1b, KEY_LANGUAGE }, /* SAP (Second Audio Program) */
+
+ { 0x14, KEY_VOLUMEUP }, /* VOL+ */
+ { 0x17, KEY_VOLUMEDOWN }, /* VOL- */
+ { 0x12, KEY_CHANNELUP }, /* CH+ */
+ { 0x13, KEY_CHANNELDOWN }, /* CH- */
+ { 0x1d, KEY_ENTER }, /* Enter */
+
+ { 0x1a, KEY_MODE }, /* PIP */
+ { 0x18, KEY_TUNER }, /* Source */
+
+ { 0x1e, KEY_RECORD }, /* Record/Pause */
+ { 0x15, KEY_ANGLE }, /* Swap (no label on key) */
+ { 0x1c, KEY_PAUSE }, /* Timeshift/Pause */
+ { 0x19, KEY_BACK }, /* Rewind << */
+ { 0x0a, KEY_PLAYPAUSE }, /* Play/Pause */
+ { 0x1f, KEY_FORWARD }, /* Forward >> */
+ { 0x16, KEY_PREVIOUS }, /* Back |<< */
+ { 0x11, KEY_STOP }, /* Stop */
+ { 0x0e, KEY_NEXT }, /* End >>| */
+};
+
+static struct rc_keymap flydvb_map = {
+ .map = {
+ .scan = flydvb,
+ .size = ARRAY_SIZE(flydvb),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_FLYDVB,
+ }
+};
+
+static int __init init_rc_map_flydvb(void)
+{
+ return ir_register_map(&flydvb_map);
+}
+
+static void __exit exit_rc_map_flydvb(void)
+{
+ ir_unregister_map(&flydvb_map);
+}
+
+module_init(init_rc_map_flydvb)
+module_exit(exit_rc_map_flydvb)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-flyvideo.c b/drivers/media/IR/keymaps/rc-flyvideo.c
new file mode 100644
index 0000000..9c73043
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-flyvideo.c
@@ -0,0 +1,70 @@
+/* flyvideo.h - Keytable for flyvideo Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+static struct ir_scancode flyvideo[] = {
+ { 0x0f, KEY_0 },
+ { 0x03, KEY_1 },
+ { 0x04, KEY_2 },
+ { 0x05, KEY_3 },
+ { 0x07, KEY_4 },
+ { 0x08, KEY_5 },
+ { 0x09, KEY_6 },
+ { 0x0b, KEY_7 },
+ { 0x0c, KEY_8 },
+ { 0x0d, KEY_9 },
+
+ { 0x0e, KEY_MODE }, /* Air/Cable */
+ { 0x11, KEY_VIDEO }, /* Video */
+ { 0x15, KEY_AUDIO }, /* Audio */
+ { 0x00, KEY_POWER }, /* Power */
+ { 0x18, KEY_TUNER }, /* AV Source */
+ { 0x02, KEY_ZOOM }, /* Fullscreen */
+ { 0x1a, KEY_LANGUAGE }, /* Stereo */
+ { 0x1b, KEY_MUTE }, /* Mute */
+ { 0x14, KEY_VOLUMEUP }, /* Volume + */
+ { 0x17, KEY_VOLUMEDOWN },/* Volume - */
+ { 0x12, KEY_CHANNELUP },/* Channel + */
+ { 0x13, KEY_CHANNELDOWN },/* Channel - */
+ { 0x06, KEY_AGAIN }, /* Recall */
+ { 0x10, KEY_ENTER }, /* Enter */
+
+ { 0x19, KEY_BACK }, /* Rewind ( <<< ) */
+ { 0x1f, KEY_FORWARD }, /* Forward ( >>> ) */
+ { 0x0a, KEY_ANGLE }, /* no label, may be used as the PAUSE button */
+};
+
+static struct rc_keymap flyvideo_map = {
+ .map = {
+ .scan = flyvideo,
+ .size = ARRAY_SIZE(flyvideo),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_FLYVIDEO,
+ }
+};
+
+static int __init init_rc_map_flyvideo(void)
+{
+ return ir_register_map(&flyvideo_map);
+}
+
+static void __exit exit_rc_map_flyvideo(void)
+{
+ ir_unregister_map(&flyvideo_map);
+}
+
+module_init(init_rc_map_flyvideo)
+module_exit(exit_rc_map_flyvideo)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-fusionhdtv-mce.c b/drivers/media/IR/keymaps/rc-fusionhdtv-mce.c
new file mode 100644
index 0000000..cdb1038
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-fusionhdtv-mce.c
@@ -0,0 +1,98 @@
+/* fusionhdtv-mce.h - Keytable for fusionhdtv_mce Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* DViCO FUSION HDTV MCE remote */
+
+static struct ir_scancode fusionhdtv_mce[] = {
+
+ { 0x0b, KEY_1 },
+ { 0x17, KEY_2 },
+ { 0x1b, KEY_3 },
+ { 0x07, KEY_4 },
+ { 0x50, KEY_5 },
+ { 0x54, KEY_6 },
+ { 0x48, KEY_7 },
+ { 0x4c, KEY_8 },
+ { 0x58, KEY_9 },
+ { 0x03, KEY_0 },
+
+ { 0x5e, KEY_OK },
+ { 0x51, KEY_UP },
+ { 0x53, KEY_DOWN },
+ { 0x5b, KEY_LEFT },
+ { 0x5f, KEY_RIGHT },
+
+ { 0x02, KEY_TV }, /* Labeled DTV on remote */
+ { 0x0e, KEY_MP3 },
+ { 0x1a, KEY_DVD },
+ { 0x1e, KEY_FAVORITES }, /* Labeled CPF on remote */
+ { 0x16, KEY_SETUP },
+ { 0x46, KEY_POWER2 }, /* TV On/Off button on remote */
+ { 0x0a, KEY_EPG }, /* Labeled Guide on remote */
+
+ { 0x49, KEY_BACK },
+ { 0x59, KEY_INFO }, /* Labeled MORE on remote */
+ { 0x4d, KEY_MENU }, /* Labeled DVDMENU on remote */
+ { 0x55, KEY_CYCLEWINDOWS }, /* Labeled ALT-TAB on remote */
+
+ { 0x0f, KEY_PREVIOUSSONG }, /* Labeled |<< REPLAY on remote */
+ { 0x12, KEY_NEXTSONG }, /* Labeled >>| SKIP on remote */
+ { 0x42, KEY_ENTER }, /* Labeled START with a green
+ MS windows logo on remote */
+
+ { 0x15, KEY_VOLUMEUP },
+ { 0x05, KEY_VOLUMEDOWN },
+ { 0x11, KEY_CHANNELUP },
+ { 0x09, KEY_CHANNELDOWN },
+
+ { 0x52, KEY_CAMERA },
+ { 0x5a, KEY_TUNER },
+ { 0x19, KEY_OPEN },
+
+ { 0x13, KEY_MODE }, /* 4:3 16:9 select */
+ { 0x1f, KEY_ZOOM },
+
+ { 0x43, KEY_REWIND },
+ { 0x47, KEY_PLAYPAUSE },
+ { 0x4f, KEY_FASTFORWARD },
+ { 0x57, KEY_MUTE },
+ { 0x0d, KEY_STOP },
+ { 0x01, KEY_RECORD },
+ { 0x4e, KEY_POWER },
+};
+
+static struct rc_keymap fusionhdtv_mce_map = {
+ .map = {
+ .scan = fusionhdtv_mce,
+ .size = ARRAY_SIZE(fusionhdtv_mce),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_FUSIONHDTV_MCE,
+ }
+};
+
+static int __init init_rc_map_fusionhdtv_mce(void)
+{
+ return ir_register_map(&fusionhdtv_mce_map);
+}
+
+static void __exit exit_rc_map_fusionhdtv_mce(void)
+{
+ ir_unregister_map(&fusionhdtv_mce_map);
+}
+
+module_init(init_rc_map_fusionhdtv_mce)
+module_exit(exit_rc_map_fusionhdtv_mce)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-gadmei-rm008z.c b/drivers/media/IR/keymaps/rc-gadmei-rm008z.c
new file mode 100644
index 0000000..c16c0d1
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-gadmei-rm008z.c
@@ -0,0 +1,81 @@
+/* gadmei-rm008z.h - Keytable for gadmei_rm008z Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* GADMEI UTV330+ RM008Z remote
+ Shine Liu <shinel@foxmail.com>
+ */
+
+static struct ir_scancode gadmei_rm008z[] = {
+ { 0x14, KEY_POWER2}, /* POWER OFF */
+ { 0x0c, KEY_MUTE}, /* MUTE */
+
+ { 0x18, KEY_TV}, /* TV */
+ { 0x0e, KEY_VIDEO}, /* AV */
+ { 0x0b, KEY_AUDIO}, /* SV */
+ { 0x0f, KEY_RADIO}, /* FM */
+
+ { 0x00, KEY_1},
+ { 0x01, KEY_2},
+ { 0x02, KEY_3},
+ { 0x03, KEY_4},
+ { 0x04, KEY_5},
+ { 0x05, KEY_6},
+ { 0x06, KEY_7},
+ { 0x07, KEY_8},
+ { 0x08, KEY_9},
+ { 0x09, KEY_0},
+ { 0x0a, KEY_INFO}, /* OSD */
+ { 0x1c, KEY_BACKSPACE}, /* LAST */
+
+ { 0x0d, KEY_PLAY}, /* PLAY */
+ { 0x1e, KEY_CAMERA}, /* SNAPSHOT */
+ { 0x1a, KEY_RECORD}, /* RECORD */
+ { 0x17, KEY_STOP}, /* STOP */
+
+ { 0x1f, KEY_UP}, /* UP */
+ { 0x44, KEY_DOWN}, /* DOWN */
+ { 0x46, KEY_TAB}, /* BACK */
+ { 0x4a, KEY_ZOOM}, /* FULLSECREEN */
+
+ { 0x10, KEY_VOLUMEUP}, /* VOLUMEUP */
+ { 0x11, KEY_VOLUMEDOWN}, /* VOLUMEDOWN */
+ { 0x12, KEY_CHANNELUP}, /* CHANNELUP */
+ { 0x13, KEY_CHANNELDOWN}, /* CHANNELDOWN */
+ { 0x15, KEY_ENTER}, /* OK */
+};
+
+static struct rc_keymap gadmei_rm008z_map = {
+ .map = {
+ .scan = gadmei_rm008z,
+ .size = ARRAY_SIZE(gadmei_rm008z),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_GADMEI_RM008Z,
+ }
+};
+
+static int __init init_rc_map_gadmei_rm008z(void)
+{
+ return ir_register_map(&gadmei_rm008z_map);
+}
+
+static void __exit exit_rc_map_gadmei_rm008z(void)
+{
+ ir_unregister_map(&gadmei_rm008z_map);
+}
+
+module_init(init_rc_map_gadmei_rm008z)
+module_exit(exit_rc_map_gadmei_rm008z)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-genius-tvgo-a11mce.c b/drivers/media/IR/keymaps/rc-genius-tvgo-a11mce.c
new file mode 100644
index 0000000..89f8e38
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-genius-tvgo-a11mce.c
@@ -0,0 +1,84 @@
+/* genius-tvgo-a11mce.h - Keytable for genius_tvgo_a11mce Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/*
+ * Remote control for the Genius TVGO A11MCE
+ * Adrian Pardini <pardo.bsso@gmail.com>
+ */
+
+static struct ir_scancode genius_tvgo_a11mce[] = {
+ /* Keys 0 to 9 */
+ { 0x48, KEY_0 },
+ { 0x09, KEY_1 },
+ { 0x1d, KEY_2 },
+ { 0x1f, KEY_3 },
+ { 0x19, KEY_4 },
+ { 0x1b, KEY_5 },
+ { 0x11, KEY_6 },
+ { 0x17, KEY_7 },
+ { 0x12, KEY_8 },
+ { 0x16, KEY_9 },
+
+ { 0x54, KEY_RECORD }, /* recording */
+ { 0x06, KEY_MUTE }, /* mute */
+ { 0x10, KEY_POWER },
+ { 0x40, KEY_LAST }, /* recall */
+ { 0x4c, KEY_CHANNELUP }, /* channel / program + */
+ { 0x00, KEY_CHANNELDOWN }, /* channel / program - */
+ { 0x0d, KEY_VOLUMEUP },
+ { 0x15, KEY_VOLUMEDOWN },
+ { 0x4d, KEY_OK }, /* also labeled as Pause */
+ { 0x1c, KEY_ZOOM }, /* full screen and Stop*/
+ { 0x02, KEY_MODE }, /* AV Source or Rewind*/
+ { 0x04, KEY_LIST }, /* -/-- */
+ /* small arrows above numbers */
+ { 0x1a, KEY_NEXT }, /* also Fast Forward */
+ { 0x0e, KEY_PREVIOUS }, /* also Rewind */
+ /* these are in a rather non standard layout and have
+ an alternate name written */
+ { 0x1e, KEY_UP }, /* Video Setting */
+ { 0x0a, KEY_DOWN }, /* Video Default */
+ { 0x05, KEY_CAMERA }, /* Snapshot */
+ { 0x0c, KEY_RIGHT }, /* Hide Panel */
+ /* Four buttons without label */
+ { 0x49, KEY_RED },
+ { 0x0b, KEY_GREEN },
+ { 0x13, KEY_YELLOW },
+ { 0x50, KEY_BLUE },
+};
+
+static struct rc_keymap genius_tvgo_a11mce_map = {
+ .map = {
+ .scan = genius_tvgo_a11mce,
+ .size = ARRAY_SIZE(genius_tvgo_a11mce),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_GENIUS_TVGO_A11MCE,
+ }
+};
+
+static int __init init_rc_map_genius_tvgo_a11mce(void)
+{
+ return ir_register_map(&genius_tvgo_a11mce_map);
+}
+
+static void __exit exit_rc_map_genius_tvgo_a11mce(void)
+{
+ ir_unregister_map(&genius_tvgo_a11mce_map);
+}
+
+module_init(init_rc_map_genius_tvgo_a11mce)
+module_exit(exit_rc_map_genius_tvgo_a11mce)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-gotview7135.c b/drivers/media/IR/keymaps/rc-gotview7135.c
new file mode 100644
index 0000000..52f025b
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-gotview7135.c
@@ -0,0 +1,79 @@
+/* gotview7135.h - Keytable for gotview7135 Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Mike Baikov <mike@baikov.com> */
+
+static struct ir_scancode gotview7135[] = {
+
+ { 0x11, KEY_POWER },
+ { 0x35, KEY_TV },
+ { 0x1b, KEY_0 },
+ { 0x29, KEY_1 },
+ { 0x19, KEY_2 },
+ { 0x39, KEY_3 },
+ { 0x1f, KEY_4 },
+ { 0x2c, KEY_5 },
+ { 0x21, KEY_6 },
+ { 0x24, KEY_7 },
+ { 0x18, KEY_8 },
+ { 0x2b, KEY_9 },
+ { 0x3b, KEY_AGAIN }, /* LOOP */
+ { 0x06, KEY_AUDIO },
+ { 0x31, KEY_PRINT }, /* PREVIEW */
+ { 0x3e, KEY_VIDEO },
+ { 0x10, KEY_CHANNELUP },
+ { 0x20, KEY_CHANNELDOWN },
+ { 0x0c, KEY_VOLUMEDOWN },
+ { 0x28, KEY_VOLUMEUP },
+ { 0x08, KEY_MUTE },
+ { 0x26, KEY_SEARCH }, /* SCAN */
+ { 0x3f, KEY_CAMERA }, /* SNAPSHOT */
+ { 0x12, KEY_RECORD },
+ { 0x32, KEY_STOP },
+ { 0x3c, KEY_PLAY },
+ { 0x1d, KEY_REWIND },
+ { 0x2d, KEY_PAUSE },
+ { 0x0d, KEY_FORWARD },
+ { 0x05, KEY_ZOOM }, /*FULL*/
+
+ { 0x2a, KEY_F21 }, /* LIVE TIMESHIFT */
+ { 0x0e, KEY_F22 }, /* MIN TIMESHIFT */
+ { 0x1e, KEY_TIME }, /* TIMESHIFT */
+ { 0x38, KEY_F24 }, /* NORMAL TIMESHIFT */
+};
+
+static struct rc_keymap gotview7135_map = {
+ .map = {
+ .scan = gotview7135,
+ .size = ARRAY_SIZE(gotview7135),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_GOTVIEW7135,
+ }
+};
+
+static int __init init_rc_map_gotview7135(void)
+{
+ return ir_register_map(&gotview7135_map);
+}
+
+static void __exit exit_rc_map_gotview7135(void)
+{
+ ir_unregister_map(&gotview7135_map);
+}
+
+module_init(init_rc_map_gotview7135)
+module_exit(exit_rc_map_gotview7135)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-hauppauge-new.c b/drivers/media/IR/keymaps/rc-hauppauge-new.c
new file mode 100644
index 0000000..c6f8cd7
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-hauppauge-new.c
@@ -0,0 +1,100 @@
+/* hauppauge-new.h - Keytable for hauppauge_new Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Hauppauge: the newer, gray remotes (seems there are multiple
+ * slightly different versions), shipped with cx88+ivtv cards.
+ * almost rc5 coding, but some non-standard keys */
+
+static struct ir_scancode hauppauge_new[] = {
+ /* Keys 0 to 9 */
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x0a, KEY_TEXT }, /* keypad asterisk as well */
+ { 0x0b, KEY_RED }, /* red button */
+ { 0x0c, KEY_RADIO },
+ { 0x0d, KEY_MENU },
+ { 0x0e, KEY_SUBTITLE }, /* also the # key */
+ { 0x0f, KEY_MUTE },
+ { 0x10, KEY_VOLUMEUP },
+ { 0x11, KEY_VOLUMEDOWN },
+ { 0x12, KEY_PREVIOUS }, /* previous channel */
+ { 0x14, KEY_UP },
+ { 0x15, KEY_DOWN },
+ { 0x16, KEY_LEFT },
+ { 0x17, KEY_RIGHT },
+ { 0x18, KEY_VIDEO }, /* Videos */
+ { 0x19, KEY_AUDIO }, /* Music */
+ /* 0x1a: Pictures - presume this means
+ "Multimedia Home Platform" -
+ no "PICTURES" key in input.h
+ */
+ { 0x1a, KEY_MHP },
+
+ { 0x1b, KEY_EPG }, /* Guide */
+ { 0x1c, KEY_TV },
+ { 0x1e, KEY_NEXTSONG }, /* skip >| */
+ { 0x1f, KEY_EXIT }, /* back/exit */
+ { 0x20, KEY_CHANNELUP }, /* channel / program + */
+ { 0x21, KEY_CHANNELDOWN }, /* channel / program - */
+ { 0x22, KEY_CHANNEL }, /* source (old black remote) */
+ { 0x24, KEY_PREVIOUSSONG }, /* replay |< */
+ { 0x25, KEY_ENTER }, /* OK */
+ { 0x26, KEY_SLEEP }, /* minimize (old black remote) */
+ { 0x29, KEY_BLUE }, /* blue key */
+ { 0x2e, KEY_GREEN }, /* green button */
+ { 0x30, KEY_PAUSE }, /* pause */
+ { 0x32, KEY_REWIND }, /* backward << */
+ { 0x34, KEY_FASTFORWARD }, /* forward >> */
+ { 0x35, KEY_PLAY },
+ { 0x36, KEY_STOP },
+ { 0x37, KEY_RECORD }, /* recording */
+ { 0x38, KEY_YELLOW }, /* yellow key */
+ { 0x3b, KEY_SELECT }, /* top right button */
+ { 0x3c, KEY_ZOOM }, /* full */
+ { 0x3d, KEY_POWER }, /* system power (green button) */
+};
+
+static struct rc_keymap hauppauge_new_map = {
+ .map = {
+ .scan = hauppauge_new,
+ .size = ARRAY_SIZE(hauppauge_new),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_HAUPPAUGE_NEW,
+ }
+};
+
+static int __init init_rc_map_hauppauge_new(void)
+{
+ return ir_register_map(&hauppauge_new_map);
+}
+
+static void __exit exit_rc_map_hauppauge_new(void)
+{
+ ir_unregister_map(&hauppauge_new_map);
+}
+
+module_init(init_rc_map_hauppauge_new)
+module_exit(exit_rc_map_hauppauge_new)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-iodata-bctv7e.c b/drivers/media/IR/keymaps/rc-iodata-bctv7e.c
new file mode 100644
index 0000000..ef66002
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-iodata-bctv7e.c
@@ -0,0 +1,88 @@
+/* iodata-bctv7e.h - Keytable for iodata_bctv7e Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* IO-DATA BCTV7E Remote */
+
+static struct ir_scancode iodata_bctv7e[] = {
+ { 0x40, KEY_TV },
+ { 0x20, KEY_RADIO }, /* FM */
+ { 0x60, KEY_EPG },
+ { 0x00, KEY_POWER },
+
+ /* Keys 0 to 9 */
+ { 0x44, KEY_0 }, /* 10 */
+ { 0x50, KEY_1 },
+ { 0x30, KEY_2 },
+ { 0x70, KEY_3 },
+ { 0x48, KEY_4 },
+ { 0x28, KEY_5 },
+ { 0x68, KEY_6 },
+ { 0x58, KEY_7 },
+ { 0x38, KEY_8 },
+ { 0x78, KEY_9 },
+
+ { 0x10, KEY_L }, /* Live */
+ { 0x08, KEY_TIME }, /* Time Shift */
+
+ { 0x18, KEY_PLAYPAUSE }, /* Play */
+
+ { 0x24, KEY_ENTER }, /* 11 */
+ { 0x64, KEY_ESC }, /* 12 */
+ { 0x04, KEY_M }, /* Multi */
+
+ { 0x54, KEY_VIDEO },
+ { 0x34, KEY_CHANNELUP },
+ { 0x74, KEY_VOLUMEUP },
+ { 0x14, KEY_MUTE },
+
+ { 0x4c, KEY_VCR }, /* SVIDEO */
+ { 0x2c, KEY_CHANNELDOWN },
+ { 0x6c, KEY_VOLUMEDOWN },
+ { 0x0c, KEY_ZOOM },
+
+ { 0x5c, KEY_PAUSE },
+ { 0x3c, KEY_RED }, /* || (red) */
+ { 0x7c, KEY_RECORD }, /* recording */
+ { 0x1c, KEY_STOP },
+
+ { 0x41, KEY_REWIND }, /* backward << */
+ { 0x21, KEY_PLAY },
+ { 0x61, KEY_FASTFORWARD }, /* forward >> */
+ { 0x01, KEY_NEXT }, /* skip >| */
+};
+
+static struct rc_keymap iodata_bctv7e_map = {
+ .map = {
+ .scan = iodata_bctv7e,
+ .size = ARRAY_SIZE(iodata_bctv7e),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_IODATA_BCTV7E,
+ }
+};
+
+static int __init init_rc_map_iodata_bctv7e(void)
+{
+ return ir_register_map(&iodata_bctv7e_map);
+}
+
+static void __exit exit_rc_map_iodata_bctv7e(void)
+{
+ ir_unregister_map(&iodata_bctv7e_map);
+}
+
+module_init(init_rc_map_iodata_bctv7e)
+module_exit(exit_rc_map_iodata_bctv7e)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-kaiomy.c b/drivers/media/IR/keymaps/rc-kaiomy.c
new file mode 100644
index 0000000..4c7883b
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-kaiomy.c
@@ -0,0 +1,87 @@
+/* kaiomy.h - Keytable for kaiomy Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Kaiomy TVnPC U2
+ Mauro Carvalho Chehab <mchehab@infradead.org>
+ */
+
+static struct ir_scancode kaiomy[] = {
+ { 0x43, KEY_POWER2},
+ { 0x01, KEY_LIST},
+ { 0x0b, KEY_ZOOM},
+ { 0x03, KEY_POWER},
+
+ { 0x04, KEY_1},
+ { 0x08, KEY_2},
+ { 0x02, KEY_3},
+
+ { 0x0f, KEY_4},
+ { 0x05, KEY_5},
+ { 0x06, KEY_6},
+
+ { 0x0c, KEY_7},
+ { 0x0d, KEY_8},
+ { 0x0a, KEY_9},
+
+ { 0x11, KEY_0},
+
+ { 0x09, KEY_CHANNELUP},
+ { 0x07, KEY_CHANNELDOWN},
+
+ { 0x0e, KEY_VOLUMEUP},
+ { 0x13, KEY_VOLUMEDOWN},
+
+ { 0x10, KEY_HOME},
+ { 0x12, KEY_ENTER},
+
+ { 0x14, KEY_RECORD},
+ { 0x15, KEY_STOP},
+ { 0x16, KEY_PLAY},
+ { 0x17, KEY_MUTE},
+
+ { 0x18, KEY_UP},
+ { 0x19, KEY_DOWN},
+ { 0x1a, KEY_LEFT},
+ { 0x1b, KEY_RIGHT},
+
+ { 0x1c, KEY_RED},
+ { 0x1d, KEY_GREEN},
+ { 0x1e, KEY_YELLOW},
+ { 0x1f, KEY_BLUE},
+};
+
+static struct rc_keymap kaiomy_map = {
+ .map = {
+ .scan = kaiomy,
+ .size = ARRAY_SIZE(kaiomy),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_KAIOMY,
+ }
+};
+
+static int __init init_rc_map_kaiomy(void)
+{
+ return ir_register_map(&kaiomy_map);
+}
+
+static void __exit exit_rc_map_kaiomy(void)
+{
+ ir_unregister_map(&kaiomy_map);
+}
+
+module_init(init_rc_map_kaiomy)
+module_exit(exit_rc_map_kaiomy)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-kworld-315u.c b/drivers/media/IR/keymaps/rc-kworld-315u.c
new file mode 100644
index 0000000..618c817
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-kworld-315u.c
@@ -0,0 +1,83 @@
+/* kworld-315u.h - Keytable for kworld_315u Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Kworld 315U
+ */
+
+static struct ir_scancode kworld_315u[] = {
+ { 0x6143, KEY_POWER },
+ { 0x6101, KEY_TUNER }, /* source */
+ { 0x610b, KEY_ZOOM },
+ { 0x6103, KEY_POWER2 }, /* shutdown */
+
+ { 0x6104, KEY_1 },
+ { 0x6108, KEY_2 },
+ { 0x6102, KEY_3 },
+ { 0x6109, KEY_CHANNELUP },
+
+ { 0x610f, KEY_4 },
+ { 0x6105, KEY_5 },
+ { 0x6106, KEY_6 },
+ { 0x6107, KEY_CHANNELDOWN },
+
+ { 0x610c, KEY_7 },
+ { 0x610d, KEY_8 },
+ { 0x610a, KEY_9 },
+ { 0x610e, KEY_VOLUMEUP },
+
+ { 0x6110, KEY_LAST },
+ { 0x6111, KEY_0 },
+ { 0x6112, KEY_ENTER },
+ { 0x6113, KEY_VOLUMEDOWN },
+
+ { 0x6114, KEY_RECORD },
+ { 0x6115, KEY_STOP },
+ { 0x6116, KEY_PLAY },
+ { 0x6117, KEY_MUTE },
+
+ { 0x6118, KEY_UP },
+ { 0x6119, KEY_DOWN },
+ { 0x611a, KEY_LEFT },
+ { 0x611b, KEY_RIGHT },
+
+ { 0x611c, KEY_RED },
+ { 0x611d, KEY_GREEN },
+ { 0x611e, KEY_YELLOW },
+ { 0x611f, KEY_BLUE },
+};
+
+static struct rc_keymap kworld_315u_map = {
+ .map = {
+ .scan = kworld_315u,
+ .size = ARRAY_SIZE(kworld_315u),
+ .ir_type = IR_TYPE_NEC,
+ .name = RC_MAP_KWORLD_315U,
+ }
+};
+
+static int __init init_rc_map_kworld_315u(void)
+{
+ return ir_register_map(&kworld_315u_map);
+}
+
+static void __exit exit_rc_map_kworld_315u(void)
+{
+ ir_unregister_map(&kworld_315u_map);
+}
+
+module_init(init_rc_map_kworld_315u)
+module_exit(exit_rc_map_kworld_315u)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-kworld-plus-tv-analog.c b/drivers/media/IR/keymaps/rc-kworld-plus-tv-analog.c
new file mode 100644
index 0000000..366732f
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-kworld-plus-tv-analog.c
@@ -0,0 +1,99 @@
+/* kworld-plus-tv-analog.h - Keytable for kworld_plus_tv_analog Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Kworld Plus TV Analog Lite PCI IR
+ Mauro Carvalho Chehab <mchehab@infradead.org>
+ */
+
+static struct ir_scancode kworld_plus_tv_analog[] = {
+ { 0x0c, KEY_PROG1 }, /* Kworld key */
+ { 0x16, KEY_CLOSECD }, /* -> ) */
+ { 0x1d, KEY_POWER2 },
+
+ { 0x00, KEY_1 },
+ { 0x01, KEY_2 },
+ { 0x02, KEY_3 }, /* Two keys have the same code: 3 and left */
+ { 0x03, KEY_4 }, /* Two keys have the same code: 3 and right */
+ { 0x04, KEY_5 },
+ { 0x05, KEY_6 },
+ { 0x06, KEY_7 },
+ { 0x07, KEY_8 },
+ { 0x08, KEY_9 },
+ { 0x0a, KEY_0 },
+
+ { 0x09, KEY_AGAIN },
+ { 0x14, KEY_MUTE },
+
+ { 0x20, KEY_UP },
+ { 0x21, KEY_DOWN },
+ { 0x0b, KEY_ENTER },
+
+ { 0x10, KEY_CHANNELUP },
+ { 0x11, KEY_CHANNELDOWN },
+
+ /* Couldn't map key left/key right since those
+ conflict with '3' and '4' scancodes
+ I dunno what the original driver does
+ */
+
+ { 0x13, KEY_VOLUMEUP },
+ { 0x12, KEY_VOLUMEDOWN },
+
+ /* The lower part of the IR
+ There are several duplicated keycodes there.
+ Most of them conflict with digits.
+ Add mappings just to the unused scancodes.
+ Somehow, the original driver has a way to know,
+ but this doesn't seem to be on some GPIO.
+ Also, it is not related to the time between keyup
+ and keydown.
+ */
+ { 0x19, KEY_TIME}, /* Timeshift */
+ { 0x1a, KEY_STOP},
+ { 0x1b, KEY_RECORD},
+
+ { 0x22, KEY_TEXT},
+
+ { 0x15, KEY_AUDIO}, /* ((*)) */
+ { 0x0f, KEY_ZOOM},
+ { 0x1c, KEY_CAMERA}, /* snapshot */
+
+ { 0x18, KEY_RED}, /* B */
+ { 0x23, KEY_GREEN}, /* C */
+};
+
+static struct rc_keymap kworld_plus_tv_analog_map = {
+ .map = {
+ .scan = kworld_plus_tv_analog,
+ .size = ARRAY_SIZE(kworld_plus_tv_analog),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_KWORLD_PLUS_TV_ANALOG,
+ }
+};
+
+static int __init init_rc_map_kworld_plus_tv_analog(void)
+{
+ return ir_register_map(&kworld_plus_tv_analog_map);
+}
+
+static void __exit exit_rc_map_kworld_plus_tv_analog(void)
+{
+ ir_unregister_map(&kworld_plus_tv_analog_map);
+}
+
+module_init(init_rc_map_kworld_plus_tv_analog)
+module_exit(exit_rc_map_kworld_plus_tv_analog)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-manli.c b/drivers/media/IR/keymaps/rc-manli.c
new file mode 100644
index 0000000..1e9fbfa
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-manli.c
@@ -0,0 +1,135 @@
+/* manli.h - Keytable for manli Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Michael Tokarev <mjt@tls.msk.ru>
+ http://www.corpit.ru/mjt/beholdTV/remote_control.jpg
+ keytable is used by MANLI MTV00[0x0c] and BeholdTV 40[13] at
+ least, and probably other cards too.
+ The "ascii-art picture" below (in comments, first row
+ is the keycode in hex, and subsequent row(s) shows
+ the button labels (several variants when appropriate)
+ helps to descide which keycodes to assign to the buttons.
+ */
+
+static struct ir_scancode manli[] = {
+
+ /* 0x1c 0x12 *
+ * FUNCTION POWER *
+ * FM (|) *
+ * */
+ { 0x1c, KEY_RADIO }, /*XXX*/
+ { 0x12, KEY_POWER },
+
+ /* 0x01 0x02 0x03 *
+ * 1 2 3 *
+ * *
+ * 0x04 0x05 0x06 *
+ * 4 5 6 *
+ * *
+ * 0x07 0x08 0x09 *
+ * 7 8 9 *
+ * */
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ /* 0x0a 0x00 0x17 *
+ * RECALL 0 +100 *
+ * PLUS *
+ * */
+ { 0x0a, KEY_AGAIN }, /*XXX KEY_REWIND? */
+ { 0x00, KEY_0 },
+ { 0x17, KEY_DIGITS }, /*XXX*/
+
+ /* 0x14 0x10 *
+ * MENU INFO *
+ * OSD */
+ { 0x14, KEY_MENU },
+ { 0x10, KEY_INFO },
+
+ /* 0x0b *
+ * Up *
+ * *
+ * 0x18 0x16 0x0c *
+ * Left Ok Right *
+ * *
+ * 0x015 *
+ * Down *
+ * */
+ { 0x0b, KEY_UP },
+ { 0x18, KEY_LEFT },
+ { 0x16, KEY_OK }, /*XXX KEY_SELECT? KEY_ENTER? */
+ { 0x0c, KEY_RIGHT },
+ { 0x15, KEY_DOWN },
+
+ /* 0x11 0x0d *
+ * TV/AV MODE *
+ * SOURCE STEREO *
+ * */
+ { 0x11, KEY_TV }, /*XXX*/
+ { 0x0d, KEY_MODE }, /*XXX there's no KEY_STEREO */
+
+ /* 0x0f 0x1b 0x1a *
+ * AUDIO Vol+ Chan+ *
+ * TIMESHIFT??? *
+ * *
+ * 0x0e 0x1f 0x1e *
+ * SLEEP Vol- Chan- *
+ * */
+ { 0x0f, KEY_AUDIO },
+ { 0x1b, KEY_VOLUMEUP },
+ { 0x1a, KEY_CHANNELUP },
+ { 0x0e, KEY_TIME },
+ { 0x1f, KEY_VOLUMEDOWN },
+ { 0x1e, KEY_CHANNELDOWN },
+
+ /* 0x13 0x19 *
+ * MUTE SNAPSHOT*
+ * */
+ { 0x13, KEY_MUTE },
+ { 0x19, KEY_CAMERA },
+
+ /* 0x1d unused ? */
+};
+
+static struct rc_keymap manli_map = {
+ .map = {
+ .scan = manli,
+ .size = ARRAY_SIZE(manli),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_MANLI,
+ }
+};
+
+static int __init init_rc_map_manli(void)
+{
+ return ir_register_map(&manli_map);
+}
+
+static void __exit exit_rc_map_manli(void)
+{
+ ir_unregister_map(&manli_map);
+}
+
+module_init(init_rc_map_manli)
+module_exit(exit_rc_map_manli)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-msi-tvanywhere-plus.c b/drivers/media/IR/keymaps/rc-msi-tvanywhere-plus.c
new file mode 100644
index 0000000..eb8e42c
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-msi-tvanywhere-plus.c
@@ -0,0 +1,123 @@
+/* msi-tvanywhere-plus.h - Keytable for msi_tvanywhere_plus Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/*
+ Keycodes for remote on the MSI TV@nywhere Plus. The controller IC on the card
+ is marked "KS003". The controller is I2C at address 0x30, but does not seem
+ to respond to probes until a read is performed from a valid device.
+ I don't know why...
+
+ Note: This remote may be of similar or identical design to the
+ Pixelview remote (?). The raw codes and duplicate button codes
+ appear to be the same.
+
+ Henry Wong <henry@stuffedcow.net>
+ Some changes to formatting and keycodes by Mark Schultz <n9xmj@yahoo.com>
+*/
+
+static struct ir_scancode msi_tvanywhere_plus[] = {
+
+/* ---- Remote Button Layout ----
+
+ POWER SOURCE SCAN MUTE
+ TV/FM 1 2 3
+ |> 4 5 6
+ <| 7 8 9
+ ^^UP 0 + RECALL
+ vvDN RECORD STOP PLAY
+
+ MINIMIZE ZOOM
+
+ CH+
+ VOL- VOL+
+ CH-
+
+ SNAPSHOT MTS
+
+ << FUNC >> RESET
+*/
+
+ { 0x01, KEY_1 }, /* 1 */
+ { 0x0b, KEY_2 }, /* 2 */
+ { 0x1b, KEY_3 }, /* 3 */
+ { 0x05, KEY_4 }, /* 4 */
+ { 0x09, KEY_5 }, /* 5 */
+ { 0x15, KEY_6 }, /* 6 */
+ { 0x06, KEY_7 }, /* 7 */
+ { 0x0a, KEY_8 }, /* 8 */
+ { 0x12, KEY_9 }, /* 9 */
+ { 0x02, KEY_0 }, /* 0 */
+ { 0x10, KEY_KPPLUS }, /* + */
+ { 0x13, KEY_AGAIN }, /* Recall */
+
+ { 0x1e, KEY_POWER }, /* Power */
+ { 0x07, KEY_TUNER }, /* Source */
+ { 0x1c, KEY_SEARCH }, /* Scan */
+ { 0x18, KEY_MUTE }, /* Mute */
+
+ { 0x03, KEY_RADIO }, /* TV/FM */
+ /* The next four keys are duplicates that appear to send the
+ same IR code as Ch+, Ch-, >>, and << . The raw code assigned
+ to them is the actual code + 0x20 - they will never be
+ detected as such unless some way is discovered to distinguish
+ these buttons from those that have the same code. */
+ { 0x3f, KEY_RIGHT }, /* |> and Ch+ */
+ { 0x37, KEY_LEFT }, /* <| and Ch- */
+ { 0x2c, KEY_UP }, /* ^^Up and >> */
+ { 0x24, KEY_DOWN }, /* vvDn and << */
+
+ { 0x00, KEY_RECORD }, /* Record */
+ { 0x08, KEY_STOP }, /* Stop */
+ { 0x11, KEY_PLAY }, /* Play */
+
+ { 0x0f, KEY_CLOSE }, /* Minimize */
+ { 0x19, KEY_ZOOM }, /* Zoom */
+ { 0x1a, KEY_CAMERA }, /* Snapshot */
+ { 0x0d, KEY_LANGUAGE }, /* MTS */
+
+ { 0x14, KEY_VOLUMEDOWN }, /* Vol- */
+ { 0x16, KEY_VOLUMEUP }, /* Vol+ */
+ { 0x17, KEY_CHANNELDOWN }, /* Ch- */
+ { 0x1f, KEY_CHANNELUP }, /* Ch+ */
+
+ { 0x04, KEY_REWIND }, /* << */
+ { 0x0e, KEY_MENU }, /* Function */
+ { 0x0c, KEY_FASTFORWARD }, /* >> */
+ { 0x1d, KEY_RESTART }, /* Reset */
+};
+
+static struct rc_keymap msi_tvanywhere_plus_map = {
+ .map = {
+ .scan = msi_tvanywhere_plus,
+ .size = ARRAY_SIZE(msi_tvanywhere_plus),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_MSI_TVANYWHERE_PLUS,
+ }
+};
+
+static int __init init_rc_map_msi_tvanywhere_plus(void)
+{
+ return ir_register_map(&msi_tvanywhere_plus_map);
+}
+
+static void __exit exit_rc_map_msi_tvanywhere_plus(void)
+{
+ ir_unregister_map(&msi_tvanywhere_plus_map);
+}
+
+module_init(init_rc_map_msi_tvanywhere_plus)
+module_exit(exit_rc_map_msi_tvanywhere_plus)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-msi-tvanywhere.c b/drivers/media/IR/keymaps/rc-msi-tvanywhere.c
new file mode 100644
index 0000000..ef41185
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-msi-tvanywhere.c
@@ -0,0 +1,69 @@
+/* msi-tvanywhere.h - Keytable for msi_tvanywhere Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* MSI TV@nywhere MASTER remote */
+
+static struct ir_scancode msi_tvanywhere[] = {
+ /* Keys 0 to 9 */
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x0c, KEY_MUTE },
+ { 0x0f, KEY_SCREEN }, /* Full Screen */
+ { 0x10, KEY_FN }, /* Funtion */
+ { 0x11, KEY_TIME }, /* Time shift */
+ { 0x12, KEY_POWER },
+ { 0x13, KEY_MEDIA }, /* MTS */
+ { 0x14, KEY_SLOW },
+ { 0x16, KEY_REWIND }, /* backward << */
+ { 0x17, KEY_ENTER }, /* Return */
+ { 0x18, KEY_FASTFORWARD }, /* forward >> */
+ { 0x1a, KEY_CHANNELUP },
+ { 0x1b, KEY_VOLUMEUP },
+ { 0x1e, KEY_CHANNELDOWN },
+ { 0x1f, KEY_VOLUMEDOWN },
+};
+
+static struct rc_keymap msi_tvanywhere_map = {
+ .map = {
+ .scan = msi_tvanywhere,
+ .size = ARRAY_SIZE(msi_tvanywhere),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_MSI_TVANYWHERE,
+ }
+};
+
+static int __init init_rc_map_msi_tvanywhere(void)
+{
+ return ir_register_map(&msi_tvanywhere_map);
+}
+
+static void __exit exit_rc_map_msi_tvanywhere(void)
+{
+ ir_unregister_map(&msi_tvanywhere_map);
+}
+
+module_init(init_rc_map_msi_tvanywhere)
+module_exit(exit_rc_map_msi_tvanywhere)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-nebula.c b/drivers/media/IR/keymaps/rc-nebula.c
new file mode 100644
index 0000000..ccc50eb
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-nebula.c
@@ -0,0 +1,96 @@
+/* nebula.h - Keytable for nebula Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+static struct ir_scancode nebula[] = {
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+ { 0x0a, KEY_TV },
+ { 0x0b, KEY_AUX },
+ { 0x0c, KEY_DVD },
+ { 0x0d, KEY_POWER },
+ { 0x0e, KEY_MHP }, /* labelled 'Picture' */
+ { 0x0f, KEY_AUDIO },
+ { 0x10, KEY_INFO },
+ { 0x11, KEY_F13 }, /* 16:9 */
+ { 0x12, KEY_F14 }, /* 14:9 */
+ { 0x13, KEY_EPG },
+ { 0x14, KEY_EXIT },
+ { 0x15, KEY_MENU },
+ { 0x16, KEY_UP },
+ { 0x17, KEY_DOWN },
+ { 0x18, KEY_LEFT },
+ { 0x19, KEY_RIGHT },
+ { 0x1a, KEY_ENTER },
+ { 0x1b, KEY_CHANNELUP },
+ { 0x1c, KEY_CHANNELDOWN },
+ { 0x1d, KEY_VOLUMEUP },
+ { 0x1e, KEY_VOLUMEDOWN },
+ { 0x1f, KEY_RED },
+ { 0x20, KEY_GREEN },
+ { 0x21, KEY_YELLOW },
+ { 0x22, KEY_BLUE },
+ { 0x23, KEY_SUBTITLE },
+ { 0x24, KEY_F15 }, /* AD */
+ { 0x25, KEY_TEXT },
+ { 0x26, KEY_MUTE },
+ { 0x27, KEY_REWIND },
+ { 0x28, KEY_STOP },
+ { 0x29, KEY_PLAY },
+ { 0x2a, KEY_FASTFORWARD },
+ { 0x2b, KEY_F16 }, /* chapter */
+ { 0x2c, KEY_PAUSE },
+ { 0x2d, KEY_PLAY },
+ { 0x2e, KEY_RECORD },
+ { 0x2f, KEY_F17 }, /* picture in picture */
+ { 0x30, KEY_KPPLUS }, /* zoom in */
+ { 0x31, KEY_KPMINUS }, /* zoom out */
+ { 0x32, KEY_F18 }, /* capture */
+ { 0x33, KEY_F19 }, /* web */
+ { 0x34, KEY_EMAIL },
+ { 0x35, KEY_PHONE },
+ { 0x36, KEY_PC },
+};
+
+static struct rc_keymap nebula_map = {
+ .map = {
+ .scan = nebula,
+ .size = ARRAY_SIZE(nebula),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_NEBULA,
+ }
+};
+
+static int __init init_rc_map_nebula(void)
+{
+ return ir_register_map(&nebula_map);
+}
+
+static void __exit exit_rc_map_nebula(void)
+{
+ ir_unregister_map(&nebula_map);
+}
+
+module_init(init_rc_map_nebula)
+module_exit(exit_rc_map_nebula)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-nec-terratec-cinergy-xs.c b/drivers/media/IR/keymaps/rc-nec-terratec-cinergy-xs.c
new file mode 100644
index 0000000..e1b54d2
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-nec-terratec-cinergy-xs.c
@@ -0,0 +1,105 @@
+/* nec-terratec-cinergy-xs.h - Keytable for nec_terratec_cinergy_xs Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Terratec Cinergy Hybrid T USB XS FM
+ Mauro Carvalho Chehab <mchehab@redhat.com>
+ */
+
+static struct ir_scancode nec_terratec_cinergy_xs[] = {
+ { 0x1441, KEY_HOME},
+ { 0x1401, KEY_POWER2},
+
+ { 0x1442, KEY_MENU}, /* DVD menu */
+ { 0x1443, KEY_SUBTITLE},
+ { 0x1444, KEY_TEXT}, /* Teletext */
+ { 0x1445, KEY_DELETE},
+
+ { 0x1402, KEY_1},
+ { 0x1403, KEY_2},
+ { 0x1404, KEY_3},
+ { 0x1405, KEY_4},
+ { 0x1406, KEY_5},
+ { 0x1407, KEY_6},
+ { 0x1408, KEY_7},
+ { 0x1409, KEY_8},
+ { 0x140a, KEY_9},
+ { 0x140c, KEY_0},
+
+ { 0x140b, KEY_TUNER}, /* AV */
+ { 0x140d, KEY_MODE}, /* A.B */
+
+ { 0x1446, KEY_TV},
+ { 0x1447, KEY_DVD},
+ { 0x1449, KEY_VIDEO},
+ { 0x144a, KEY_RADIO}, /* Music */
+ { 0x144b, KEY_CAMERA}, /* PIC */
+
+ { 0x1410, KEY_UP},
+ { 0x1411, KEY_LEFT},
+ { 0x1412, KEY_OK},
+ { 0x1413, KEY_RIGHT},
+ { 0x1414, KEY_DOWN},
+
+ { 0x140f, KEY_EPG},
+ { 0x1416, KEY_INFO},
+ { 0x144d, KEY_BACKSPACE},
+
+ { 0x141c, KEY_VOLUMEUP},
+ { 0x141e, KEY_VOLUMEDOWN},
+
+ { 0x144c, KEY_PLAY},
+ { 0x141d, KEY_MUTE},
+
+ { 0x141b, KEY_CHANNELUP},
+ { 0x141f, KEY_CHANNELDOWN},
+
+ { 0x1417, KEY_RED},
+ { 0x1418, KEY_GREEN},
+ { 0x1419, KEY_YELLOW},
+ { 0x141a, KEY_BLUE},
+
+ { 0x1458, KEY_RECORD},
+ { 0x1448, KEY_STOP},
+ { 0x1440, KEY_PAUSE},
+
+ { 0x1454, KEY_LAST},
+ { 0x144e, KEY_REWIND},
+ { 0x144f, KEY_FASTFORWARD},
+ { 0x145c, KEY_NEXT},
+};
+
+static struct rc_keymap nec_terratec_cinergy_xs_map = {
+ .map = {
+ .scan = nec_terratec_cinergy_xs,
+ .size = ARRAY_SIZE(nec_terratec_cinergy_xs),
+ .ir_type = IR_TYPE_NEC,
+ .name = RC_MAP_NEC_TERRATEC_CINERGY_XS,
+ }
+};
+
+static int __init init_rc_map_nec_terratec_cinergy_xs(void)
+{
+ return ir_register_map(&nec_terratec_cinergy_xs_map);
+}
+
+static void __exit exit_rc_map_nec_terratec_cinergy_xs(void)
+{
+ ir_unregister_map(&nec_terratec_cinergy_xs_map);
+}
+
+module_init(init_rc_map_nec_terratec_cinergy_xs)
+module_exit(exit_rc_map_nec_terratec_cinergy_xs)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-norwood.c b/drivers/media/IR/keymaps/rc-norwood.c
new file mode 100644
index 0000000..e5849a6
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-norwood.c
@@ -0,0 +1,85 @@
+/* norwood.h - Keytable for norwood Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Norwood Micro (non-Pro) TV Tuner
+ By Peter Naulls <peter@chocky.org>
+ Key comments are the functions given in the manual */
+
+static struct ir_scancode norwood[] = {
+ /* Keys 0 to 9 */
+ { 0x20, KEY_0 },
+ { 0x21, KEY_1 },
+ { 0x22, KEY_2 },
+ { 0x23, KEY_3 },
+ { 0x24, KEY_4 },
+ { 0x25, KEY_5 },
+ { 0x26, KEY_6 },
+ { 0x27, KEY_7 },
+ { 0x28, KEY_8 },
+ { 0x29, KEY_9 },
+
+ { 0x78, KEY_TUNER }, /* Video Source */
+ { 0x2c, KEY_EXIT }, /* Open/Close software */
+ { 0x2a, KEY_SELECT }, /* 2 Digit Select */
+ { 0x69, KEY_AGAIN }, /* Recall */
+
+ { 0x32, KEY_BRIGHTNESSUP }, /* Brightness increase */
+ { 0x33, KEY_BRIGHTNESSDOWN }, /* Brightness decrease */
+ { 0x6b, KEY_KPPLUS }, /* (not named >>>>>) */
+ { 0x6c, KEY_KPMINUS }, /* (not named <<<<<) */
+
+ { 0x2d, KEY_MUTE }, /* Mute */
+ { 0x30, KEY_VOLUMEUP }, /* Volume up */
+ { 0x31, KEY_VOLUMEDOWN }, /* Volume down */
+ { 0x60, KEY_CHANNELUP }, /* Channel up */
+ { 0x61, KEY_CHANNELDOWN }, /* Channel down */
+
+ { 0x3f, KEY_RECORD }, /* Record */
+ { 0x37, KEY_PLAY }, /* Play */
+ { 0x36, KEY_PAUSE }, /* Pause */
+ { 0x2b, KEY_STOP }, /* Stop */
+ { 0x67, KEY_FASTFORWARD }, /* Foward */
+ { 0x66, KEY_REWIND }, /* Rewind */
+ { 0x3e, KEY_SEARCH }, /* Auto Scan */
+ { 0x2e, KEY_CAMERA }, /* Capture Video */
+ { 0x6d, KEY_MENU }, /* Show/Hide Control */
+ { 0x2f, KEY_ZOOM }, /* Full Screen */
+ { 0x34, KEY_RADIO }, /* FM */
+ { 0x65, KEY_POWER }, /* Computer power */
+};
+
+static struct rc_keymap norwood_map = {
+ .map = {
+ .scan = norwood,
+ .size = ARRAY_SIZE(norwood),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_NORWOOD,
+ }
+};
+
+static int __init init_rc_map_norwood(void)
+{
+ return ir_register_map(&norwood_map);
+}
+
+static void __exit exit_rc_map_norwood(void)
+{
+ ir_unregister_map(&norwood_map);
+}
+
+module_init(init_rc_map_norwood)
+module_exit(exit_rc_map_norwood)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-npgtech.c b/drivers/media/IR/keymaps/rc-npgtech.c
new file mode 100644
index 0000000..b9ece1e
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-npgtech.c
@@ -0,0 +1,80 @@
+/* npgtech.h - Keytable for npgtech Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+static struct ir_scancode npgtech[] = {
+ { 0x1d, KEY_SWITCHVIDEOMODE }, /* switch inputs */
+ { 0x2a, KEY_FRONT },
+
+ { 0x3e, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x06, KEY_3 },
+ { 0x0a, KEY_4 },
+ { 0x0e, KEY_5 },
+ { 0x12, KEY_6 },
+ { 0x16, KEY_7 },
+ { 0x1a, KEY_8 },
+ { 0x1e, KEY_9 },
+ { 0x3a, KEY_0 },
+ { 0x22, KEY_NUMLOCK }, /* -/-- */
+ { 0x20, KEY_REFRESH },
+
+ { 0x03, KEY_BRIGHTNESSDOWN },
+ { 0x28, KEY_AUDIO },
+ { 0x3c, KEY_CHANNELUP },
+ { 0x3f, KEY_VOLUMEDOWN },
+ { 0x2e, KEY_MUTE },
+ { 0x3b, KEY_VOLUMEUP },
+ { 0x00, KEY_CHANNELDOWN },
+ { 0x07, KEY_BRIGHTNESSUP },
+ { 0x2c, KEY_TEXT },
+
+ { 0x37, KEY_RECORD },
+ { 0x17, KEY_PLAY },
+ { 0x13, KEY_PAUSE },
+ { 0x26, KEY_STOP },
+ { 0x18, KEY_FASTFORWARD },
+ { 0x14, KEY_REWIND },
+ { 0x33, KEY_ZOOM },
+ { 0x32, KEY_KEYBOARD },
+ { 0x30, KEY_GOTO }, /* Pointing arrow */
+ { 0x36, KEY_MACRO }, /* Maximize/Minimize (yellow) */
+ { 0x0b, KEY_RADIO },
+ { 0x10, KEY_POWER },
+
+};
+
+static struct rc_keymap npgtech_map = {
+ .map = {
+ .scan = npgtech,
+ .size = ARRAY_SIZE(npgtech),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_NPGTECH,
+ }
+};
+
+static int __init init_rc_map_npgtech(void)
+{
+ return ir_register_map(&npgtech_map);
+}
+
+static void __exit exit_rc_map_npgtech(void)
+{
+ ir_unregister_map(&npgtech_map);
+}
+
+module_init(init_rc_map_npgtech)
+module_exit(exit_rc_map_npgtech)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-pctv-sedna.c b/drivers/media/IR/keymaps/rc-pctv-sedna.c
new file mode 100644
index 0000000..4129bb4
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-pctv-sedna.c
@@ -0,0 +1,80 @@
+/* pctv-sedna.h - Keytable for pctv_sedna Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Mapping for the 28 key remote control as seen at
+ http://www.sednacomputer.com/photo/cardbus-tv.jpg
+ Pavel Mihaylov <bin@bash.info>
+ Also for the remote bundled with Kozumi KTV-01C card */
+
+static struct ir_scancode pctv_sedna[] = {
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x0a, KEY_AGAIN }, /* Recall */
+ { 0x0b, KEY_CHANNELUP },
+ { 0x0c, KEY_VOLUMEUP },
+ { 0x0d, KEY_MODE }, /* Stereo */
+ { 0x0e, KEY_STOP },
+ { 0x0f, KEY_PREVIOUSSONG },
+ { 0x10, KEY_ZOOM },
+ { 0x11, KEY_TUNER }, /* Source */
+ { 0x12, KEY_POWER },
+ { 0x13, KEY_MUTE },
+ { 0x15, KEY_CHANNELDOWN },
+ { 0x18, KEY_VOLUMEDOWN },
+ { 0x19, KEY_CAMERA }, /* Snapshot */
+ { 0x1a, KEY_NEXTSONG },
+ { 0x1b, KEY_TIME }, /* Time Shift */
+ { 0x1c, KEY_RADIO }, /* FM Radio */
+ { 0x1d, KEY_RECORD },
+ { 0x1e, KEY_PAUSE },
+ /* additional codes for Kozumi's remote */
+ { 0x14, KEY_INFO }, /* OSD */
+ { 0x16, KEY_OK }, /* OK */
+ { 0x17, KEY_DIGITS }, /* Plus */
+ { 0x1f, KEY_PLAY }, /* Play */
+};
+
+static struct rc_keymap pctv_sedna_map = {
+ .map = {
+ .scan = pctv_sedna,
+ .size = ARRAY_SIZE(pctv_sedna),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_PCTV_SEDNA,
+ }
+};
+
+static int __init init_rc_map_pctv_sedna(void)
+{
+ return ir_register_map(&pctv_sedna_map);
+}
+
+static void __exit exit_rc_map_pctv_sedna(void)
+{
+ ir_unregister_map(&pctv_sedna_map);
+}
+
+module_init(init_rc_map_pctv_sedna)
+module_exit(exit_rc_map_pctv_sedna)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-pinnacle-color.c b/drivers/media/IR/keymaps/rc-pinnacle-color.c
new file mode 100644
index 0000000..326e023
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-pinnacle-color.c
@@ -0,0 +1,94 @@
+/* pinnacle-color.h - Keytable for pinnacle_color Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+static struct ir_scancode pinnacle_color[] = {
+ { 0x59, KEY_MUTE },
+ { 0x4a, KEY_POWER },
+
+ { 0x18, KEY_TEXT },
+ { 0x26, KEY_TV },
+ { 0x3d, KEY_PRINT },
+
+ { 0x48, KEY_RED },
+ { 0x04, KEY_GREEN },
+ { 0x11, KEY_YELLOW },
+ { 0x00, KEY_BLUE },
+
+ { 0x2d, KEY_VOLUMEUP },
+ { 0x1e, KEY_VOLUMEDOWN },
+
+ { 0x49, KEY_MENU },
+
+ { 0x16, KEY_CHANNELUP },
+ { 0x17, KEY_CHANNELDOWN },
+
+ { 0x20, KEY_UP },
+ { 0x21, KEY_DOWN },
+ { 0x22, KEY_LEFT },
+ { 0x23, KEY_RIGHT },
+ { 0x0d, KEY_SELECT },
+
+ { 0x08, KEY_BACK },
+ { 0x07, KEY_REFRESH },
+
+ { 0x2f, KEY_ZOOM },
+ { 0x29, KEY_RECORD },
+
+ { 0x4b, KEY_PAUSE },
+ { 0x4d, KEY_REWIND },
+ { 0x2e, KEY_PLAY },
+ { 0x4e, KEY_FORWARD },
+ { 0x53, KEY_PREVIOUS },
+ { 0x4c, KEY_STOP },
+ { 0x54, KEY_NEXT },
+
+ { 0x69, KEY_0 },
+ { 0x6a, KEY_1 },
+ { 0x6b, KEY_2 },
+ { 0x6c, KEY_3 },
+ { 0x6d, KEY_4 },
+ { 0x6e, KEY_5 },
+ { 0x6f, KEY_6 },
+ { 0x70, KEY_7 },
+ { 0x71, KEY_8 },
+ { 0x72, KEY_9 },
+
+ { 0x74, KEY_CHANNEL },
+ { 0x0a, KEY_BACKSPACE },
+};
+
+static struct rc_keymap pinnacle_color_map = {
+ .map = {
+ .scan = pinnacle_color,
+ .size = ARRAY_SIZE(pinnacle_color),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_PINNACLE_COLOR,
+ }
+};
+
+static int __init init_rc_map_pinnacle_color(void)
+{
+ return ir_register_map(&pinnacle_color_map);
+}
+
+static void __exit exit_rc_map_pinnacle_color(void)
+{
+ ir_unregister_map(&pinnacle_color_map);
+}
+
+module_init(init_rc_map_pinnacle_color)
+module_exit(exit_rc_map_pinnacle_color)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-pinnacle-grey.c b/drivers/media/IR/keymaps/rc-pinnacle-grey.c
new file mode 100644
index 0000000..14cb772
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-pinnacle-grey.c
@@ -0,0 +1,89 @@
+/* pinnacle-grey.h - Keytable for pinnacle_grey Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+static struct ir_scancode pinnacle_grey[] = {
+ { 0x3a, KEY_0 },
+ { 0x31, KEY_1 },
+ { 0x32, KEY_2 },
+ { 0x33, KEY_3 },
+ { 0x34, KEY_4 },
+ { 0x35, KEY_5 },
+ { 0x36, KEY_6 },
+ { 0x37, KEY_7 },
+ { 0x38, KEY_8 },
+ { 0x39, KEY_9 },
+
+ { 0x2f, KEY_POWER },
+
+ { 0x2e, KEY_P },
+ { 0x1f, KEY_L },
+ { 0x2b, KEY_I },
+
+ { 0x2d, KEY_SCREEN },
+ { 0x1e, KEY_ZOOM },
+ { 0x1b, KEY_VOLUMEUP },
+ { 0x0f, KEY_VOLUMEDOWN },
+ { 0x17, KEY_CHANNELUP },
+ { 0x1c, KEY_CHANNELDOWN },
+ { 0x25, KEY_INFO },
+
+ { 0x3c, KEY_MUTE },
+
+ { 0x3d, KEY_LEFT },
+ { 0x3b, KEY_RIGHT },
+
+ { 0x3f, KEY_UP },
+ { 0x3e, KEY_DOWN },
+ { 0x1a, KEY_ENTER },
+
+ { 0x1d, KEY_MENU },
+ { 0x19, KEY_AGAIN },
+ { 0x16, KEY_PREVIOUSSONG },
+ { 0x13, KEY_NEXTSONG },
+ { 0x15, KEY_PAUSE },
+ { 0x0e, KEY_REWIND },
+ { 0x0d, KEY_PLAY },
+ { 0x0b, KEY_STOP },
+ { 0x07, KEY_FORWARD },
+ { 0x27, KEY_RECORD },
+ { 0x26, KEY_TUNER },
+ { 0x29, KEY_TEXT },
+ { 0x2a, KEY_MEDIA },
+ { 0x18, KEY_EPG },
+};
+
+static struct rc_keymap pinnacle_grey_map = {
+ .map = {
+ .scan = pinnacle_grey,
+ .size = ARRAY_SIZE(pinnacle_grey),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_PINNACLE_GREY,
+ }
+};
+
+static int __init init_rc_map_pinnacle_grey(void)
+{
+ return ir_register_map(&pinnacle_grey_map);
+}
+
+static void __exit exit_rc_map_pinnacle_grey(void)
+{
+ ir_unregister_map(&pinnacle_grey_map);
+}
+
+module_init(init_rc_map_pinnacle_grey)
+module_exit(exit_rc_map_pinnacle_grey)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-pinnacle-pctv-hd.c b/drivers/media/IR/keymaps/rc-pinnacle-pctv-hd.c
new file mode 100644
index 0000000..835bf4e
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-pinnacle-pctv-hd.c
@@ -0,0 +1,73 @@
+/* pinnacle-pctv-hd.h - Keytable for pinnacle_pctv_hd Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Pinnacle PCTV HD 800i mini remote */
+
+static struct ir_scancode pinnacle_pctv_hd[] = {
+
+ { 0x0f, KEY_1 },
+ { 0x15, KEY_2 },
+ { 0x10, KEY_3 },
+ { 0x18, KEY_4 },
+ { 0x1b, KEY_5 },
+ { 0x1e, KEY_6 },
+ { 0x11, KEY_7 },
+ { 0x21, KEY_8 },
+ { 0x12, KEY_9 },
+ { 0x27, KEY_0 },
+
+ { 0x24, KEY_ZOOM },
+ { 0x2a, KEY_SUBTITLE },
+
+ { 0x00, KEY_MUTE },
+ { 0x01, KEY_ENTER }, /* Pinnacle Logo */
+ { 0x39, KEY_POWER },
+
+ { 0x03, KEY_VOLUMEUP },
+ { 0x09, KEY_VOLUMEDOWN },
+ { 0x06, KEY_CHANNELUP },
+ { 0x0c, KEY_CHANNELDOWN },
+
+ { 0x2d, KEY_REWIND },
+ { 0x30, KEY_PLAYPAUSE },
+ { 0x33, KEY_FASTFORWARD },
+ { 0x3c, KEY_STOP },
+ { 0x36, KEY_RECORD },
+ { 0x3f, KEY_EPG }, /* Labeled "?" */
+};
+
+static struct rc_keymap pinnacle_pctv_hd_map = {
+ .map = {
+ .scan = pinnacle_pctv_hd,
+ .size = ARRAY_SIZE(pinnacle_pctv_hd),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_PINNACLE_PCTV_HD,
+ }
+};
+
+static int __init init_rc_map_pinnacle_pctv_hd(void)
+{
+ return ir_register_map(&pinnacle_pctv_hd_map);
+}
+
+static void __exit exit_rc_map_pinnacle_pctv_hd(void)
+{
+ ir_unregister_map(&pinnacle_pctv_hd_map);
+}
+
+module_init(init_rc_map_pinnacle_pctv_hd)
+module_exit(exit_rc_map_pinnacle_pctv_hd)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-pixelview-new.c b/drivers/media/IR/keymaps/rc-pixelview-new.c
new file mode 100644
index 0000000..7bbbbf5
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-pixelview-new.c
@@ -0,0 +1,83 @@
+/* pixelview-new.h - Keytable for pixelview_new Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/*
+ Mauro Carvalho Chehab <mchehab@infradead.org>
+ present on PV MPEG 8000GT
+ */
+
+static struct ir_scancode pixelview_new[] = {
+ { 0x3c, KEY_TIME }, /* Timeshift */
+ { 0x12, KEY_POWER },
+
+ { 0x3d, KEY_1 },
+ { 0x38, KEY_2 },
+ { 0x18, KEY_3 },
+ { 0x35, KEY_4 },
+ { 0x39, KEY_5 },
+ { 0x15, KEY_6 },
+ { 0x36, KEY_7 },
+ { 0x3a, KEY_8 },
+ { 0x1e, KEY_9 },
+ { 0x3e, KEY_0 },
+
+ { 0x1c, KEY_AGAIN }, /* LOOP */
+ { 0x3f, KEY_MEDIA }, /* Source */
+ { 0x1f, KEY_LAST }, /* +100 */
+ { 0x1b, KEY_MUTE },
+
+ { 0x17, KEY_CHANNELDOWN },
+ { 0x16, KEY_CHANNELUP },
+ { 0x10, KEY_VOLUMEUP },
+ { 0x14, KEY_VOLUMEDOWN },
+ { 0x13, KEY_ZOOM },
+
+ { 0x19, KEY_CAMERA }, /* SNAPSHOT */
+ { 0x1a, KEY_SEARCH }, /* scan */
+
+ { 0x37, KEY_REWIND }, /* << */
+ { 0x32, KEY_RECORD }, /* o (red) */
+ { 0x33, KEY_FORWARD }, /* >> */
+ { 0x11, KEY_STOP }, /* square */
+ { 0x3b, KEY_PLAY }, /* > */
+ { 0x30, KEY_PLAYPAUSE }, /* || */
+
+ { 0x31, KEY_TV },
+ { 0x34, KEY_RADIO },
+};
+
+static struct rc_keymap pixelview_new_map = {
+ .map = {
+ .scan = pixelview_new,
+ .size = ARRAY_SIZE(pixelview_new),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_PIXELVIEW_NEW,
+ }
+};
+
+static int __init init_rc_map_pixelview_new(void)
+{
+ return ir_register_map(&pixelview_new_map);
+}
+
+static void __exit exit_rc_map_pixelview_new(void)
+{
+ ir_unregister_map(&pixelview_new_map);
+}
+
+module_init(init_rc_map_pixelview_new)
+module_exit(exit_rc_map_pixelview_new)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-pixelview.c b/drivers/media/IR/keymaps/rc-pixelview.c
new file mode 100644
index 0000000..82ff12e
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-pixelview.c
@@ -0,0 +1,82 @@
+/* pixelview.h - Keytable for pixelview Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+static struct ir_scancode pixelview[] = {
+
+ { 0x1e, KEY_POWER }, /* power */
+ { 0x07, KEY_MEDIA }, /* source */
+ { 0x1c, KEY_SEARCH }, /* scan */
+
+
+ { 0x03, KEY_TUNER }, /* TV/FM */
+
+ { 0x00, KEY_RECORD },
+ { 0x08, KEY_STOP },
+ { 0x11, KEY_PLAY },
+
+ { 0x1a, KEY_PLAYPAUSE }, /* freeze */
+ { 0x19, KEY_ZOOM }, /* zoom */
+ { 0x0f, KEY_TEXT }, /* min */
+
+ { 0x01, KEY_1 },
+ { 0x0b, KEY_2 },
+ { 0x1b, KEY_3 },
+ { 0x05, KEY_4 },
+ { 0x09, KEY_5 },
+ { 0x15, KEY_6 },
+ { 0x06, KEY_7 },
+ { 0x0a, KEY_8 },
+ { 0x12, KEY_9 },
+ { 0x02, KEY_0 },
+ { 0x10, KEY_LAST }, /* +100 */
+ { 0x13, KEY_LIST }, /* recall */
+
+ { 0x1f, KEY_CHANNELUP }, /* chn down */
+ { 0x17, KEY_CHANNELDOWN }, /* chn up */
+ { 0x16, KEY_VOLUMEUP }, /* vol down */
+ { 0x14, KEY_VOLUMEDOWN }, /* vol up */
+
+ { 0x04, KEY_KPMINUS }, /* <<< */
+ { 0x0e, KEY_SETUP }, /* function */
+ { 0x0c, KEY_KPPLUS }, /* >>> */
+
+ { 0x0d, KEY_GOTO }, /* mts */
+ { 0x1d, KEY_REFRESH }, /* reset */
+ { 0x18, KEY_MUTE }, /* mute/unmute */
+};
+
+static struct rc_keymap pixelview_map = {
+ .map = {
+ .scan = pixelview,
+ .size = ARRAY_SIZE(pixelview),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_PIXELVIEW,
+ }
+};
+
+static int __init init_rc_map_pixelview(void)
+{
+ return ir_register_map(&pixelview_map);
+}
+
+static void __exit exit_rc_map_pixelview(void)
+{
+ ir_unregister_map(&pixelview_map);
+}
+
+module_init(init_rc_map_pixelview)
+module_exit(exit_rc_map_pixelview)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-powercolor-real-angel.c b/drivers/media/IR/keymaps/rc-powercolor-real-angel.c
new file mode 100644
index 0000000..7cef819
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-powercolor-real-angel.c
@@ -0,0 +1,81 @@
+/* powercolor-real-angel.h - Keytable for powercolor_real_angel Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/*
+ * Remote control for Powercolor Real Angel 330
+ * Daniel Fraga <fragabr@gmail.com>
+ */
+
+static struct ir_scancode powercolor_real_angel[] = {
+ { 0x38, KEY_SWITCHVIDEOMODE }, /* switch inputs */
+ { 0x0c, KEY_MEDIA }, /* Turn ON/OFF App */
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+ { 0x0a, KEY_DIGITS }, /* single, double, tripple digit */
+ { 0x29, KEY_PREVIOUS }, /* previous channel */
+ { 0x12, KEY_BRIGHTNESSUP },
+ { 0x13, KEY_BRIGHTNESSDOWN },
+ { 0x2b, KEY_MODE }, /* stereo/mono */
+ { 0x2c, KEY_TEXT }, /* teletext */
+ { 0x20, KEY_CHANNELUP }, /* channel up */
+ { 0x21, KEY_CHANNELDOWN }, /* channel down */
+ { 0x10, KEY_VOLUMEUP }, /* volume up */
+ { 0x11, KEY_VOLUMEDOWN }, /* volume down */
+ { 0x0d, KEY_MUTE },
+ { 0x1f, KEY_RECORD },
+ { 0x17, KEY_PLAY },
+ { 0x16, KEY_PAUSE },
+ { 0x0b, KEY_STOP },
+ { 0x27, KEY_FASTFORWARD },
+ { 0x26, KEY_REWIND },
+ { 0x1e, KEY_SEARCH }, /* autoscan */
+ { 0x0e, KEY_CAMERA }, /* snapshot */
+ { 0x2d, KEY_SETUP },
+ { 0x0f, KEY_SCREEN }, /* full screen */
+ { 0x14, KEY_RADIO }, /* FM radio */
+ { 0x25, KEY_POWER }, /* power */
+};
+
+static struct rc_keymap powercolor_real_angel_map = {
+ .map = {
+ .scan = powercolor_real_angel,
+ .size = ARRAY_SIZE(powercolor_real_angel),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_POWERCOLOR_REAL_ANGEL,
+ }
+};
+
+static int __init init_rc_map_powercolor_real_angel(void)
+{
+ return ir_register_map(&powercolor_real_angel_map);
+}
+
+static void __exit exit_rc_map_powercolor_real_angel(void)
+{
+ ir_unregister_map(&powercolor_real_angel_map);
+}
+
+module_init(init_rc_map_powercolor_real_angel)
+module_exit(exit_rc_map_powercolor_real_angel)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-proteus-2309.c b/drivers/media/IR/keymaps/rc-proteus-2309.c
new file mode 100644
index 0000000..22e92d3
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-proteus-2309.c
@@ -0,0 +1,69 @@
+/* proteus-2309.h - Keytable for proteus_2309 Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Michal Majchrowicz <mmajchrowicz@gmail.com> */
+
+static struct ir_scancode proteus_2309[] = {
+ /* numeric */
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x5c, KEY_POWER }, /* power */
+ { 0x20, KEY_ZOOM }, /* full screen */
+ { 0x0f, KEY_BACKSPACE }, /* recall */
+ { 0x1b, KEY_ENTER }, /* mute */
+ { 0x41, KEY_RECORD }, /* record */
+ { 0x43, KEY_STOP }, /* stop */
+ { 0x16, KEY_S },
+ { 0x1a, KEY_POWER2 }, /* off */
+ { 0x2e, KEY_RED },
+ { 0x1f, KEY_CHANNELDOWN }, /* channel - */
+ { 0x1c, KEY_CHANNELUP }, /* channel + */
+ { 0x10, KEY_VOLUMEDOWN }, /* volume - */
+ { 0x1e, KEY_VOLUMEUP }, /* volume + */
+ { 0x14, KEY_F1 },
+};
+
+static struct rc_keymap proteus_2309_map = {
+ .map = {
+ .scan = proteus_2309,
+ .size = ARRAY_SIZE(proteus_2309),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_PROTEUS_2309,
+ }
+};
+
+static int __init init_rc_map_proteus_2309(void)
+{
+ return ir_register_map(&proteus_2309_map);
+}
+
+static void __exit exit_rc_map_proteus_2309(void)
+{
+ ir_unregister_map(&proteus_2309_map);
+}
+
+module_init(init_rc_map_proteus_2309)
+module_exit(exit_rc_map_proteus_2309)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-purpletv.c b/drivers/media/IR/keymaps/rc-purpletv.c
new file mode 100644
index 0000000..4e20fc2
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-purpletv.c
@@ -0,0 +1,81 @@
+/* purpletv.h - Keytable for purpletv Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+static struct ir_scancode purpletv[] = {
+ { 0x03, KEY_POWER },
+ { 0x6f, KEY_MUTE },
+ { 0x10, KEY_BACKSPACE }, /* Recall */
+
+ { 0x11, KEY_0 },
+ { 0x04, KEY_1 },
+ { 0x05, KEY_2 },
+ { 0x06, KEY_3 },
+ { 0x08, KEY_4 },
+ { 0x09, KEY_5 },
+ { 0x0a, KEY_6 },
+ { 0x0c, KEY_7 },
+ { 0x0d, KEY_8 },
+ { 0x0e, KEY_9 },
+ { 0x12, KEY_DOT }, /* 100+ */
+
+ { 0x07, KEY_VOLUMEUP },
+ { 0x0b, KEY_VOLUMEDOWN },
+ { 0x1a, KEY_KPPLUS },
+ { 0x18, KEY_KPMINUS },
+ { 0x15, KEY_UP },
+ { 0x1d, KEY_DOWN },
+ { 0x0f, KEY_CHANNELUP },
+ { 0x13, KEY_CHANNELDOWN },
+ { 0x48, KEY_ZOOM },
+
+ { 0x1b, KEY_VIDEO }, /* Video source */
+ { 0x1f, KEY_CAMERA }, /* Snapshot */
+ { 0x49, KEY_LANGUAGE }, /* MTS Select */
+ { 0x19, KEY_SEARCH }, /* Auto Scan */
+
+ { 0x4b, KEY_RECORD },
+ { 0x46, KEY_PLAY },
+ { 0x45, KEY_PAUSE }, /* Pause */
+ { 0x44, KEY_STOP },
+ { 0x43, KEY_TIME }, /* Time Shift */
+ { 0x17, KEY_CHANNEL }, /* SURF CH */
+ { 0x40, KEY_FORWARD }, /* Forward ? */
+ { 0x42, KEY_REWIND }, /* Backward ? */
+
+};
+
+static struct rc_keymap purpletv_map = {
+ .map = {
+ .scan = purpletv,
+ .size = ARRAY_SIZE(purpletv),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_PURPLETV,
+ }
+};
+
+static int __init init_rc_map_purpletv(void)
+{
+ return ir_register_map(&purpletv_map);
+}
+
+static void __exit exit_rc_map_purpletv(void)
+{
+ ir_unregister_map(&purpletv_map);
+}
+
+module_init(init_rc_map_purpletv)
+module_exit(exit_rc_map_purpletv)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-pv951.c b/drivers/media/IR/keymaps/rc-pv951.c
new file mode 100644
index 0000000..36679e7
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-pv951.c
@@ -0,0 +1,78 @@
+/* pv951.h - Keytable for pv951 Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Mark Phalan <phalanm@o2.ie> */
+
+static struct ir_scancode pv951[] = {
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x12, KEY_POWER },
+ { 0x10, KEY_MUTE },
+ { 0x1f, KEY_VOLUMEDOWN },
+ { 0x1b, KEY_VOLUMEUP },
+ { 0x1a, KEY_CHANNELUP },
+ { 0x1e, KEY_CHANNELDOWN },
+ { 0x0e, KEY_PAGEUP },
+ { 0x1d, KEY_PAGEDOWN },
+ { 0x13, KEY_SOUND },
+
+ { 0x18, KEY_KPPLUSMINUS }, /* CH +/- */
+ { 0x16, KEY_SUBTITLE }, /* CC */
+ { 0x0d, KEY_TEXT }, /* TTX */
+ { 0x0b, KEY_TV }, /* AIR/CBL */
+ { 0x11, KEY_PC }, /* PC/TV */
+ { 0x17, KEY_OK }, /* CH RTN */
+ { 0x19, KEY_MODE }, /* FUNC */
+ { 0x0c, KEY_SEARCH }, /* AUTOSCAN */
+
+ /* Not sure what to do with these ones! */
+ { 0x0f, KEY_SELECT }, /* SOURCE */
+ { 0x0a, KEY_KPPLUS }, /* +100 */
+ { 0x14, KEY_EQUAL }, /* SYNC */
+ { 0x1c, KEY_MEDIA }, /* PC/TV */
+};
+
+static struct rc_keymap pv951_map = {
+ .map = {
+ .scan = pv951,
+ .size = ARRAY_SIZE(pv951),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_PV951,
+ }
+};
+
+static int __init init_rc_map_pv951(void)
+{
+ return ir_register_map(&pv951_map);
+}
+
+static void __exit exit_rc_map_pv951(void)
+{
+ ir_unregister_map(&pv951_map);
+}
+
+module_init(init_rc_map_pv951)
+module_exit(exit_rc_map_pv951)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-rc5-hauppauge-new.c b/drivers/media/IR/keymaps/rc-rc5-hauppauge-new.c
new file mode 100644
index 0000000..cc6b8f5
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-rc5-hauppauge-new.c
@@ -0,0 +1,103 @@
+/* rc5-hauppauge-new.h - Keytable for rc5_hauppauge_new Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/*
+ * Hauppauge:the newer, gray remotes (seems there are multiple
+ * slightly different versions), shipped with cx88+ivtv cards.
+ *
+ * This table contains the complete RC5 code, instead of just the data part
+ */
+
+static struct ir_scancode rc5_hauppauge_new[] = {
+ /* Keys 0 to 9 */
+ { 0x1e00, KEY_0 },
+ { 0x1e01, KEY_1 },
+ { 0x1e02, KEY_2 },
+ { 0x1e03, KEY_3 },
+ { 0x1e04, KEY_4 },
+ { 0x1e05, KEY_5 },
+ { 0x1e06, KEY_6 },
+ { 0x1e07, KEY_7 },
+ { 0x1e08, KEY_8 },
+ { 0x1e09, KEY_9 },
+
+ { 0x1e0a, KEY_TEXT }, /* keypad asterisk as well */
+ { 0x1e0b, KEY_RED }, /* red button */
+ { 0x1e0c, KEY_RADIO },
+ { 0x1e0d, KEY_MENU },
+ { 0x1e0e, KEY_SUBTITLE }, /* also the # key */
+ { 0x1e0f, KEY_MUTE },
+ { 0x1e10, KEY_VOLUMEUP },
+ { 0x1e11, KEY_VOLUMEDOWN },
+ { 0x1e12, KEY_PREVIOUS }, /* previous channel */
+ { 0x1e14, KEY_UP },
+ { 0x1e15, KEY_DOWN },
+ { 0x1e16, KEY_LEFT },
+ { 0x1e17, KEY_RIGHT },
+ { 0x1e18, KEY_VIDEO }, /* Videos */
+ { 0x1e19, KEY_AUDIO }, /* Music */
+ /* 0x1e1a: Pictures - presume this means
+ "Multimedia Home Platform" -
+ no "PICTURES" key in input.h
+ */
+ { 0x1e1a, KEY_MHP },
+
+ { 0x1e1b, KEY_EPG }, /* Guide */
+ { 0x1e1c, KEY_TV },
+ { 0x1e1e, KEY_NEXTSONG }, /* skip >| */
+ { 0x1e1f, KEY_EXIT }, /* back/exit */
+ { 0x1e20, KEY_CHANNELUP }, /* channel / program + */
+ { 0x1e21, KEY_CHANNELDOWN }, /* channel / program - */
+ { 0x1e22, KEY_CHANNEL }, /* source (old black remote) */
+ { 0x1e24, KEY_PREVIOUSSONG }, /* replay |< */
+ { 0x1e25, KEY_ENTER }, /* OK */
+ { 0x1e26, KEY_SLEEP }, /* minimize (old black remote) */
+ { 0x1e29, KEY_BLUE }, /* blue key */
+ { 0x1e2e, KEY_GREEN }, /* green button */
+ { 0x1e30, KEY_PAUSE }, /* pause */
+ { 0x1e32, KEY_REWIND }, /* backward << */
+ { 0x1e34, KEY_FASTFORWARD }, /* forward >> */
+ { 0x1e35, KEY_PLAY },
+ { 0x1e36, KEY_STOP },
+ { 0x1e37, KEY_RECORD }, /* recording */
+ { 0x1e38, KEY_YELLOW }, /* yellow key */
+ { 0x1e3b, KEY_SELECT }, /* top right button */
+ { 0x1e3c, KEY_ZOOM }, /* full */
+ { 0x1e3d, KEY_POWER }, /* system power (green button) */
+};
+
+static struct rc_keymap rc5_hauppauge_new_map = {
+ .map = {
+ .scan = rc5_hauppauge_new,
+ .size = ARRAY_SIZE(rc5_hauppauge_new),
+ .ir_type = IR_TYPE_RC5,
+ .name = RC_MAP_RC5_HAUPPAUGE_NEW,
+ }
+};
+
+static int __init init_rc_map_rc5_hauppauge_new(void)
+{
+ return ir_register_map(&rc5_hauppauge_new_map);
+}
+
+static void __exit exit_rc_map_rc5_hauppauge_new(void)
+{
+ ir_unregister_map(&rc5_hauppauge_new_map);
+}
+
+module_init(init_rc_map_rc5_hauppauge_new)
+module_exit(exit_rc_map_rc5_hauppauge_new)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-rc5-tv.c b/drivers/media/IR/keymaps/rc-rc5-tv.c
new file mode 100644
index 0000000..73cce2f
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-rc5-tv.c
@@ -0,0 +1,81 @@
+/* rc5-tv.h - Keytable for rc5_tv Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* generic RC5 keytable */
+/* see http://users.pandora.be/nenya/electronics/rc5/codes00.htm */
+/* used by old (black) Hauppauge remotes */
+
+static struct ir_scancode rc5_tv[] = {
+ /* Keys 0 to 9 */
+ { 0x00, KEY_0 },
+ { 0x01, KEY_1 },
+ { 0x02, KEY_2 },
+ { 0x03, KEY_3 },
+ { 0x04, KEY_4 },
+ { 0x05, KEY_5 },
+ { 0x06, KEY_6 },
+ { 0x07, KEY_7 },
+ { 0x08, KEY_8 },
+ { 0x09, KEY_9 },
+
+ { 0x0b, KEY_CHANNEL }, /* channel / program (japan: 11) */
+ { 0x0c, KEY_POWER }, /* standby */
+ { 0x0d, KEY_MUTE }, /* mute / demute */
+ { 0x0f, KEY_TV }, /* display */
+ { 0x10, KEY_VOLUMEUP },
+ { 0x11, KEY_VOLUMEDOWN },
+ { 0x12, KEY_BRIGHTNESSUP },
+ { 0x13, KEY_BRIGHTNESSDOWN },
+ { 0x1e, KEY_SEARCH }, /* search + */
+ { 0x20, KEY_CHANNELUP }, /* channel / program + */
+ { 0x21, KEY_CHANNELDOWN }, /* channel / program - */
+ { 0x22, KEY_CHANNEL }, /* alt / channel */
+ { 0x23, KEY_LANGUAGE }, /* 1st / 2nd language */
+ { 0x26, KEY_SLEEP }, /* sleeptimer */
+ { 0x2e, KEY_MENU }, /* 2nd controls (USA: menu) */
+ { 0x30, KEY_PAUSE },
+ { 0x32, KEY_REWIND },
+ { 0x33, KEY_GOTO },
+ { 0x35, KEY_PLAY },
+ { 0x36, KEY_STOP },
+ { 0x37, KEY_RECORD }, /* recording */
+ { 0x3c, KEY_TEXT }, /* teletext submode (Japan: 12) */
+ { 0x3d, KEY_SUSPEND }, /* system standby */
+
+};
+
+static struct rc_keymap rc5_tv_map = {
+ .map = {
+ .scan = rc5_tv,
+ .size = ARRAY_SIZE(rc5_tv),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_RC5_TV,
+ }
+};
+
+static int __init init_rc_map_rc5_tv(void)
+{
+ return ir_register_map(&rc5_tv_map);
+}
+
+static void __exit exit_rc_map_rc5_tv(void)
+{
+ ir_unregister_map(&rc5_tv_map);
+}
+
+module_init(init_rc_map_rc5_tv)
+module_exit(exit_rc_map_rc5_tv)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-real-audio-220-32-keys.c b/drivers/media/IR/keymaps/rc-real-audio-220-32-keys.c
new file mode 100644
index 0000000..ab1a6d2
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-real-audio-220-32-keys.c
@@ -0,0 +1,78 @@
+/* real-audio-220-32-keys.h - Keytable for real_audio_220_32_keys Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Zogis Real Audio 220 - 32 keys IR */
+
+static struct ir_scancode real_audio_220_32_keys[] = {
+ { 0x1c, KEY_RADIO},
+ { 0x12, KEY_POWER2},
+
+ { 0x01, KEY_1},
+ { 0x02, KEY_2},
+ { 0x03, KEY_3},
+ { 0x04, KEY_4},
+ { 0x05, KEY_5},
+ { 0x06, KEY_6},
+ { 0x07, KEY_7},
+ { 0x08, KEY_8},
+ { 0x09, KEY_9},
+ { 0x00, KEY_0},
+
+ { 0x0c, KEY_VOLUMEUP},
+ { 0x18, KEY_VOLUMEDOWN},
+ { 0x0b, KEY_CHANNELUP},
+ { 0x15, KEY_CHANNELDOWN},
+ { 0x16, KEY_ENTER},
+
+ { 0x11, KEY_LIST}, /* Source */
+ { 0x0d, KEY_AUDIO}, /* stereo */
+
+ { 0x0f, KEY_PREVIOUS}, /* Prev */
+ { 0x1b, KEY_TIME}, /* Timeshift */
+ { 0x1a, KEY_NEXT}, /* Next */
+
+ { 0x0e, KEY_STOP},
+ { 0x1f, KEY_PLAY},
+ { 0x1e, KEY_PLAYPAUSE}, /* Pause */
+
+ { 0x1d, KEY_RECORD},
+ { 0x13, KEY_MUTE},
+ { 0x19, KEY_CAMERA}, /* Snapshot */
+
+};
+
+static struct rc_keymap real_audio_220_32_keys_map = {
+ .map = {
+ .scan = real_audio_220_32_keys,
+ .size = ARRAY_SIZE(real_audio_220_32_keys),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_REAL_AUDIO_220_32_KEYS,
+ }
+};
+
+static int __init init_rc_map_real_audio_220_32_keys(void)
+{
+ return ir_register_map(&real_audio_220_32_keys_map);
+}
+
+static void __exit exit_rc_map_real_audio_220_32_keys(void)
+{
+ ir_unregister_map(&real_audio_220_32_keys_map);
+}
+
+module_init(init_rc_map_real_audio_220_32_keys)
+module_exit(exit_rc_map_real_audio_220_32_keys)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-tbs-nec.c b/drivers/media/IR/keymaps/rc-tbs-nec.c
new file mode 100644
index 0000000..3309631
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-tbs-nec.c
@@ -0,0 +1,73 @@
+/* tbs-nec.h - Keytable for tbs_nec Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+static struct ir_scancode tbs_nec[] = {
+ { 0x04, KEY_POWER2}, /*power*/
+ { 0x14, KEY_MUTE}, /*mute*/
+ { 0x07, KEY_1},
+ { 0x06, KEY_2},
+ { 0x05, KEY_3},
+ { 0x0b, KEY_4},
+ { 0x0a, KEY_5},
+ { 0x09, KEY_6},
+ { 0x0f, KEY_7},
+ { 0x0e, KEY_8},
+ { 0x0d, KEY_9},
+ { 0x12, KEY_0},
+ { 0x16, KEY_CHANNELUP}, /*ch+*/
+ { 0x11, KEY_CHANNELDOWN},/*ch-*/
+ { 0x13, KEY_VOLUMEUP}, /*vol+*/
+ { 0x0c, KEY_VOLUMEDOWN},/*vol-*/
+ { 0x03, KEY_RECORD}, /*rec*/
+ { 0x18, KEY_PAUSE}, /*pause*/
+ { 0x19, KEY_OK}, /*ok*/
+ { 0x1a, KEY_CAMERA}, /* snapshot */
+ { 0x01, KEY_UP},
+ { 0x10, KEY_LEFT},
+ { 0x02, KEY_RIGHT},
+ { 0x08, KEY_DOWN},
+ { 0x15, KEY_FAVORITES},
+ { 0x17, KEY_SUBTITLE},
+ { 0x1d, KEY_ZOOM},
+ { 0x1f, KEY_EXIT},
+ { 0x1e, KEY_MENU},
+ { 0x1c, KEY_EPG},
+ { 0x00, KEY_PREVIOUS},
+ { 0x1b, KEY_MODE},
+};
+
+static struct rc_keymap tbs_nec_map = {
+ .map = {
+ .scan = tbs_nec,
+ .size = ARRAY_SIZE(tbs_nec),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_TBS_NEC,
+ }
+};
+
+static int __init init_rc_map_tbs_nec(void)
+{
+ return ir_register_map(&tbs_nec_map);
+}
+
+static void __exit exit_rc_map_tbs_nec(void)
+{
+ ir_unregister_map(&tbs_nec_map);
+}
+
+module_init(init_rc_map_tbs_nec)
+module_exit(exit_rc_map_tbs_nec)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-terratec-cinergy-xs.c b/drivers/media/IR/keymaps/rc-terratec-cinergy-xs.c
new file mode 100644
index 0000000..5326a0b
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-terratec-cinergy-xs.c
@@ -0,0 +1,92 @@
+/* terratec-cinergy-xs.h - Keytable for terratec_cinergy_xs Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Terratec Cinergy Hybrid T USB XS
+ Devin Heitmueller <dheitmueller@linuxtv.org>
+ */
+
+static struct ir_scancode terratec_cinergy_xs[] = {
+ { 0x41, KEY_HOME},
+ { 0x01, KEY_POWER},
+ { 0x42, KEY_MENU},
+ { 0x02, KEY_1},
+ { 0x03, KEY_2},
+ { 0x04, KEY_3},
+ { 0x43, KEY_SUBTITLE},
+ { 0x05, KEY_4},
+ { 0x06, KEY_5},
+ { 0x07, KEY_6},
+ { 0x44, KEY_TEXT},
+ { 0x08, KEY_7},
+ { 0x09, KEY_8},
+ { 0x0a, KEY_9},
+ { 0x45, KEY_DELETE},
+ { 0x0b, KEY_TUNER},
+ { 0x0c, KEY_0},
+ { 0x0d, KEY_MODE},
+ { 0x46, KEY_TV},
+ { 0x47, KEY_DVD},
+ { 0x49, KEY_VIDEO},
+ { 0x4b, KEY_AUX},
+ { 0x10, KEY_UP},
+ { 0x11, KEY_LEFT},
+ { 0x12, KEY_OK},
+ { 0x13, KEY_RIGHT},
+ { 0x14, KEY_DOWN},
+ { 0x0f, KEY_EPG},
+ { 0x16, KEY_INFO},
+ { 0x4d, KEY_BACKSPACE},
+ { 0x1c, KEY_VOLUMEUP},
+ { 0x4c, KEY_PLAY},
+ { 0x1b, KEY_CHANNELUP},
+ { 0x1e, KEY_VOLUMEDOWN},
+ { 0x1d, KEY_MUTE},
+ { 0x1f, KEY_CHANNELDOWN},
+ { 0x17, KEY_RED},
+ { 0x18, KEY_GREEN},
+ { 0x19, KEY_YELLOW},
+ { 0x1a, KEY_BLUE},
+ { 0x58, KEY_RECORD},
+ { 0x48, KEY_STOP},
+ { 0x40, KEY_PAUSE},
+ { 0x54, KEY_LAST},
+ { 0x4e, KEY_REWIND},
+ { 0x4f, KEY_FASTFORWARD},
+ { 0x5c, KEY_NEXT},
+};
+
+static struct rc_keymap terratec_cinergy_xs_map = {
+ .map = {
+ .scan = terratec_cinergy_xs,
+ .size = ARRAY_SIZE(terratec_cinergy_xs),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_TERRATEC_CINERGY_XS,
+ }
+};
+
+static int __init init_rc_map_terratec_cinergy_xs(void)
+{
+ return ir_register_map(&terratec_cinergy_xs_map);
+}
+
+static void __exit exit_rc_map_terratec_cinergy_xs(void)
+{
+ ir_unregister_map(&terratec_cinergy_xs_map);
+}
+
+module_init(init_rc_map_terratec_cinergy_xs)
+module_exit(exit_rc_map_terratec_cinergy_xs)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-tevii-nec.c b/drivers/media/IR/keymaps/rc-tevii-nec.c
new file mode 100644
index 0000000..e30d411
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-tevii-nec.c
@@ -0,0 +1,88 @@
+/* tevii-nec.h - Keytable for tevii_nec Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+static struct ir_scancode tevii_nec[] = {
+ { 0x0a, KEY_POWER2},
+ { 0x0c, KEY_MUTE},
+ { 0x11, KEY_1},
+ { 0x12, KEY_2},
+ { 0x13, KEY_3},
+ { 0x14, KEY_4},
+ { 0x15, KEY_5},
+ { 0x16, KEY_6},
+ { 0x17, KEY_7},
+ { 0x18, KEY_8},
+ { 0x19, KEY_9},
+ { 0x10, KEY_0},
+ { 0x1c, KEY_MENU},
+ { 0x0f, KEY_VOLUMEDOWN},
+ { 0x1a, KEY_LAST},
+ { 0x0e, KEY_OPEN},
+ { 0x04, KEY_RECORD},
+ { 0x09, KEY_VOLUMEUP},
+ { 0x08, KEY_CHANNELUP},
+ { 0x07, KEY_PVR},
+ { 0x0b, KEY_TIME},
+ { 0x02, KEY_RIGHT},
+ { 0x03, KEY_LEFT},
+ { 0x00, KEY_UP},
+ { 0x1f, KEY_OK},
+ { 0x01, KEY_DOWN},
+ { 0x05, KEY_TUNER},
+ { 0x06, KEY_CHANNELDOWN},
+ { 0x40, KEY_PLAYPAUSE},
+ { 0x1e, KEY_REWIND},
+ { 0x1b, KEY_FAVORITES},
+ { 0x1d, KEY_BACK},
+ { 0x4d, KEY_FASTFORWARD},
+ { 0x44, KEY_EPG},
+ { 0x4c, KEY_INFO},
+ { 0x41, KEY_AB},
+ { 0x43, KEY_AUDIO},
+ { 0x45, KEY_SUBTITLE},
+ { 0x4a, KEY_LIST},
+ { 0x46, KEY_F1},
+ { 0x47, KEY_F2},
+ { 0x5e, KEY_F3},
+ { 0x5c, KEY_F4},
+ { 0x52, KEY_F5},
+ { 0x5a, KEY_F6},
+ { 0x56, KEY_MODE},
+ { 0x58, KEY_SWITCHVIDEOMODE},
+};
+
+static struct rc_keymap tevii_nec_map = {
+ .map = {
+ .scan = tevii_nec,
+ .size = ARRAY_SIZE(tevii_nec),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_TEVII_NEC,
+ }
+};
+
+static int __init init_rc_map_tevii_nec(void)
+{
+ return ir_register_map(&tevii_nec_map);
+}
+
+static void __exit exit_rc_map_tevii_nec(void)
+{
+ ir_unregister_map(&tevii_nec_map);
+}
+
+module_init(init_rc_map_tevii_nec)
+module_exit(exit_rc_map_tevii_nec)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-tt-1500.c b/drivers/media/IR/keymaps/rc-tt-1500.c
new file mode 100644
index 0000000..bc88de0
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-tt-1500.c
@@ -0,0 +1,82 @@
+/* tt-1500.h - Keytable for tt_1500 Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* for the Technotrend 1500 bundled remotes (grey and black): */
+
+static struct ir_scancode tt_1500[] = {
+ { 0x01, KEY_POWER },
+ { 0x02, KEY_SHUFFLE }, /* ? double-arrow key */
+ { 0x03, KEY_1 },
+ { 0x04, KEY_2 },
+ { 0x05, KEY_3 },
+ { 0x06, KEY_4 },
+ { 0x07, KEY_5 },
+ { 0x08, KEY_6 },
+ { 0x09, KEY_7 },
+ { 0x0a, KEY_8 },
+ { 0x0b, KEY_9 },
+ { 0x0c, KEY_0 },
+ { 0x0d, KEY_UP },
+ { 0x0e, KEY_LEFT },
+ { 0x0f, KEY_OK },
+ { 0x10, KEY_RIGHT },
+ { 0x11, KEY_DOWN },
+ { 0x12, KEY_INFO },
+ { 0x13, KEY_EXIT },
+ { 0x14, KEY_RED },
+ { 0x15, KEY_GREEN },
+ { 0x16, KEY_YELLOW },
+ { 0x17, KEY_BLUE },
+ { 0x18, KEY_MUTE },
+ { 0x19, KEY_TEXT },
+ { 0x1a, KEY_MODE }, /* ? TV/Radio */
+ { 0x21, KEY_OPTION },
+ { 0x22, KEY_EPG },
+ { 0x23, KEY_CHANNELUP },
+ { 0x24, KEY_CHANNELDOWN },
+ { 0x25, KEY_VOLUMEUP },
+ { 0x26, KEY_VOLUMEDOWN },
+ { 0x27, KEY_SETUP },
+ { 0x3a, KEY_RECORD }, /* these keys are only in the black remote */
+ { 0x3b, KEY_PLAY },
+ { 0x3c, KEY_STOP },
+ { 0x3d, KEY_REWIND },
+ { 0x3e, KEY_PAUSE },
+ { 0x3f, KEY_FORWARD },
+};
+
+static struct rc_keymap tt_1500_map = {
+ .map = {
+ .scan = tt_1500,
+ .size = ARRAY_SIZE(tt_1500),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_TT_1500,
+ }
+};
+
+static int __init init_rc_map_tt_1500(void)
+{
+ return ir_register_map(&tt_1500_map);
+}
+
+static void __exit exit_rc_map_tt_1500(void)
+{
+ ir_unregister_map(&tt_1500_map);
+}
+
+module_init(init_rc_map_tt_1500)
+module_exit(exit_rc_map_tt_1500)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-videomate-s350.c b/drivers/media/IR/keymaps/rc-videomate-s350.c
new file mode 100644
index 0000000..4df7fcd
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-videomate-s350.c
@@ -0,0 +1,85 @@
+/* videomate-s350.h - Keytable for videomate_s350 Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+static struct ir_scancode videomate_s350[] = {
+ { 0x00, KEY_TV},
+ { 0x01, KEY_DVD},
+ { 0x04, KEY_RECORD},
+ { 0x05, KEY_VIDEO}, /* TV/Video */
+ { 0x07, KEY_STOP},
+ { 0x08, KEY_PLAYPAUSE},
+ { 0x0a, KEY_REWIND},
+ { 0x0f, KEY_FASTFORWARD},
+ { 0x10, KEY_CHANNELUP},
+ { 0x12, KEY_VOLUMEUP},
+ { 0x13, KEY_CHANNELDOWN},
+ { 0x14, KEY_MUTE},
+ { 0x15, KEY_VOLUMEDOWN},
+ { 0x16, KEY_1},
+ { 0x17, KEY_2},
+ { 0x18, KEY_3},
+ { 0x19, KEY_4},
+ { 0x1a, KEY_5},
+ { 0x1b, KEY_6},
+ { 0x1c, KEY_7},
+ { 0x1d, KEY_8},
+ { 0x1e, KEY_9},
+ { 0x1f, KEY_0},
+ { 0x21, KEY_SLEEP},
+ { 0x24, KEY_ZOOM},
+ { 0x25, KEY_LAST}, /* Recall */
+ { 0x26, KEY_SUBTITLE}, /* CC */
+ { 0x27, KEY_LANGUAGE}, /* MTS */
+ { 0x29, KEY_CHANNEL}, /* SURF */
+ { 0x2b, KEY_A},
+ { 0x2c, KEY_B},
+ { 0x2f, KEY_CAMERA}, /* Snapshot */
+ { 0x23, KEY_RADIO},
+ { 0x02, KEY_PREVIOUSSONG},
+ { 0x06, KEY_NEXTSONG},
+ { 0x03, KEY_EPG},
+ { 0x09, KEY_SETUP},
+ { 0x22, KEY_BACKSPACE},
+ { 0x0c, KEY_UP},
+ { 0x0e, KEY_DOWN},
+ { 0x0b, KEY_LEFT},
+ { 0x0d, KEY_RIGHT},
+ { 0x11, KEY_ENTER},
+ { 0x20, KEY_TEXT},
+};
+
+static struct rc_keymap videomate_s350_map = {
+ .map = {
+ .scan = videomate_s350,
+ .size = ARRAY_SIZE(videomate_s350),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_VIDEOMATE_S350,
+ }
+};
+
+static int __init init_rc_map_videomate_s350(void)
+{
+ return ir_register_map(&videomate_s350_map);
+}
+
+static void __exit exit_rc_map_videomate_s350(void)
+{
+ ir_unregister_map(&videomate_s350_map);
+}
+
+module_init(init_rc_map_videomate_s350)
+module_exit(exit_rc_map_videomate_s350)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-videomate-tv-pvr.c b/drivers/media/IR/keymaps/rc-videomate-tv-pvr.c
new file mode 100644
index 0000000..776b0a6
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-videomate-tv-pvr.c
@@ -0,0 +1,87 @@
+/* videomate-tv-pvr.h - Keytable for videomate_tv_pvr Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+static struct ir_scancode videomate_tv_pvr[] = {
+ { 0x14, KEY_MUTE },
+ { 0x24, KEY_ZOOM },
+
+ { 0x01, KEY_DVD },
+ { 0x23, KEY_RADIO },
+ { 0x00, KEY_TV },
+
+ { 0x0a, KEY_REWIND },
+ { 0x08, KEY_PLAYPAUSE },
+ { 0x0f, KEY_FORWARD },
+
+ { 0x02, KEY_PREVIOUS },
+ { 0x07, KEY_STOP },
+ { 0x06, KEY_NEXT },
+
+ { 0x0c, KEY_UP },
+ { 0x0e, KEY_DOWN },
+ { 0x0b, KEY_LEFT },
+ { 0x0d, KEY_RIGHT },
+ { 0x11, KEY_OK },
+
+ { 0x03, KEY_MENU },
+ { 0x09, KEY_SETUP },
+ { 0x05, KEY_VIDEO },
+ { 0x22, KEY_CHANNEL },
+
+ { 0x12, KEY_VOLUMEUP },
+ { 0x15, KEY_VOLUMEDOWN },
+ { 0x10, KEY_CHANNELUP },
+ { 0x13, KEY_CHANNELDOWN },
+
+ { 0x04, KEY_RECORD },
+
+ { 0x16, KEY_1 },
+ { 0x17, KEY_2 },
+ { 0x18, KEY_3 },
+ { 0x19, KEY_4 },
+ { 0x1a, KEY_5 },
+ { 0x1b, KEY_6 },
+ { 0x1c, KEY_7 },
+ { 0x1d, KEY_8 },
+ { 0x1e, KEY_9 },
+ { 0x1f, KEY_0 },
+
+ { 0x20, KEY_LANGUAGE },
+ { 0x21, KEY_SLEEP },
+};
+
+static struct rc_keymap videomate_tv_pvr_map = {
+ .map = {
+ .scan = videomate_tv_pvr,
+ .size = ARRAY_SIZE(videomate_tv_pvr),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_VIDEOMATE_TV_PVR,
+ }
+};
+
+static int __init init_rc_map_videomate_tv_pvr(void)
+{
+ return ir_register_map(&videomate_tv_pvr_map);
+}
+
+static void __exit exit_rc_map_videomate_tv_pvr(void)
+{
+ ir_unregister_map(&videomate_tv_pvr_map);
+}
+
+module_init(init_rc_map_videomate_tv_pvr)
+module_exit(exit_rc_map_videomate_tv_pvr)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-winfast-usbii-deluxe.c b/drivers/media/IR/keymaps/rc-winfast-usbii-deluxe.c
new file mode 100644
index 0000000..9d2d550
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-winfast-usbii-deluxe.c
@@ -0,0 +1,82 @@
+/* winfast-usbii-deluxe.h - Keytable for winfast_usbii_deluxe Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Leadtek Winfast TV USB II Deluxe remote
+ Magnus Alm <magnus.alm@gmail.com>
+ */
+
+static struct ir_scancode winfast_usbii_deluxe[] = {
+ { 0x62, KEY_0},
+ { 0x75, KEY_1},
+ { 0x76, KEY_2},
+ { 0x77, KEY_3},
+ { 0x79, KEY_4},
+ { 0x7a, KEY_5},
+ { 0x7b, KEY_6},
+ { 0x7d, KEY_7},
+ { 0x7e, KEY_8},
+ { 0x7f, KEY_9},
+
+ { 0x38, KEY_CAMERA}, /* SNAPSHOT */
+ { 0x37, KEY_RECORD}, /* RECORD */
+ { 0x35, KEY_TIME}, /* TIMESHIFT */
+
+ { 0x74, KEY_VOLUMEUP}, /* VOLUMEUP */
+ { 0x78, KEY_VOLUMEDOWN}, /* VOLUMEDOWN */
+ { 0x64, KEY_MUTE}, /* MUTE */
+
+ { 0x21, KEY_CHANNEL}, /* SURF */
+ { 0x7c, KEY_CHANNELUP}, /* CHANNELUP */
+ { 0x60, KEY_CHANNELDOWN}, /* CHANNELDOWN */
+ { 0x61, KEY_LAST}, /* LAST CHANNEL (RECALL) */
+
+ { 0x72, KEY_VIDEO}, /* INPUT MODES (TV/FM) */
+
+ { 0x70, KEY_POWER2}, /* TV ON/OFF */
+
+ { 0x39, KEY_CYCLEWINDOWS}, /* MINIMIZE (BOSS) */
+ { 0x3a, KEY_NEW}, /* PIP */
+ { 0x73, KEY_ZOOM}, /* FULLSECREEN */
+
+ { 0x66, KEY_INFO}, /* OSD (DISPLAY) */
+
+ { 0x31, KEY_DOT}, /* '.' */
+ { 0x63, KEY_ENTER}, /* ENTER */
+
+};
+
+static struct rc_keymap winfast_usbii_deluxe_map = {
+ .map = {
+ .scan = winfast_usbii_deluxe,
+ .size = ARRAY_SIZE(winfast_usbii_deluxe),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_WINFAST_USBII_DELUXE,
+ }
+};
+
+static int __init init_rc_map_winfast_usbii_deluxe(void)
+{
+ return ir_register_map(&winfast_usbii_deluxe_map);
+}
+
+static void __exit exit_rc_map_winfast_usbii_deluxe(void)
+{
+ ir_unregister_map(&winfast_usbii_deluxe_map);
+}
+
+module_init(init_rc_map_winfast_usbii_deluxe)
+module_exit(exit_rc_map_winfast_usbii_deluxe)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/keymaps/rc-winfast.c b/drivers/media/IR/keymaps/rc-winfast.c
new file mode 100644
index 0000000..0e90a3b
--- /dev/null
+++ b/drivers/media/IR/keymaps/rc-winfast.c
@@ -0,0 +1,102 @@
+/* winfast.h - Keytable for winfast Remote Controller
+ *
+ * keymap imported from ir-keymaps.c
+ *
+ * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#include <media/rc-map.h>
+
+/* Table for Leadtek Winfast Remote Controls - used by both bttv and cx88 */
+
+static struct ir_scancode winfast[] = {
+ /* Keys 0 to 9 */
+ { 0x12, KEY_0 },
+ { 0x05, KEY_1 },
+ { 0x06, KEY_2 },
+ { 0x07, KEY_3 },
+ { 0x09, KEY_4 },
+ { 0x0a, KEY_5 },
+ { 0x0b, KEY_6 },
+ { 0x0d, KEY_7 },
+ { 0x0e, KEY_8 },
+ { 0x0f, KEY_9 },
+
+ { 0x00, KEY_POWER },
+ { 0x1b, KEY_AUDIO }, /* Audio Source */
+ { 0x02, KEY_TUNER }, /* TV/FM, not on Y0400052 */
+ { 0x1e, KEY_VIDEO }, /* Video Source */
+ { 0x16, KEY_INFO }, /* Display information */
+ { 0x04, KEY_VOLUMEUP },
+ { 0x08, KEY_VOLUMEDOWN },
+ { 0x0c, KEY_CHANNELUP },
+ { 0x10, KEY_CHANNELDOWN },
+ { 0x03, KEY_ZOOM }, /* fullscreen */
+ { 0x1f, KEY_TEXT }, /* closed caption/teletext */
+ { 0x20, KEY_SLEEP },
+ { 0x29, KEY_CLEAR }, /* boss key */
+ { 0x14, KEY_MUTE },
+ { 0x2b, KEY_RED },
+ { 0x2c, KEY_GREEN },
+ { 0x2d, KEY_YELLOW },
+ { 0x2e, KEY_BLUE },
+ { 0x18, KEY_KPPLUS }, /* fine tune + , not on Y040052 */
+ { 0x19, KEY_KPMINUS }, /* fine tune - , not on Y040052 */
+ { 0x2a, KEY_MEDIA }, /* PIP (Picture in picture */
+ { 0x21, KEY_DOT },
+ { 0x13, KEY_ENTER },
+ { 0x11, KEY_LAST }, /* Recall (last channel */
+ { 0x22, KEY_PREVIOUS },
+ { 0x23, KEY_PLAYPAUSE },
+ { 0x24, KEY_NEXT },
+ { 0x25, KEY_TIME }, /* Time Shifting */
+ { 0x26, KEY_STOP },
+ { 0x27, KEY_RECORD },
+ { 0x28, KEY_SAVE }, /* Screenshot */
+ { 0x2f, KEY_MENU },
+ { 0x30, KEY_CANCEL },
+ { 0x31, KEY_CHANNEL }, /* Channel Surf */
+ { 0x32, KEY_SUBTITLE },
+ { 0x33, KEY_LANGUAGE },
+ { 0x34, KEY_REWIND },
+ { 0x35, KEY_FASTFORWARD },
+ { 0x36, KEY_TV },
+ { 0x37, KEY_RADIO }, /* FM */
+ { 0x38, KEY_DVD },
+
+ { 0x1a, KEY_MODE}, /* change to MCE mode on Y04G0051 */
+ { 0x3e, KEY_F21 }, /* MCE +VOL, on Y04G0033 */
+ { 0x3a, KEY_F22 }, /* MCE -VOL, on Y04G0033 */
+ { 0x3b, KEY_F23 }, /* MCE +CH, on Y04G0033 */
+ { 0x3f, KEY_F24 } /* MCE -CH, on Y04G0033 */
+};
+
+static struct rc_keymap winfast_map = {
+ .map = {
+ .scan = winfast,
+ .size = ARRAY_SIZE(winfast),
+ .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
+ .name = RC_MAP_WINFAST,
+ }
+};
+
+static int __init init_rc_map_winfast(void)
+{
+ return ir_register_map(&winfast_map);
+}
+
+static void __exit exit_rc_map_winfast(void)
+{
+ ir_unregister_map(&winfast_map);
+}
+
+module_init(init_rc_map_winfast)
+module_exit(exit_rc_map_winfast)
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
diff --git a/drivers/media/IR/rc-map.c b/drivers/media/IR/rc-map.c
index aa269f5..02c72f0 100644
--- a/drivers/media/IR/rc-map.c
+++ b/drivers/media/IR/rc-map.c
@@ -64,7 +64,7 @@ int ir_register_map(struct rc_keymap *map)
spin_unlock(&rc_map_lock);
return 0;
}
-EXPORT_SYMBOL_GPL(ir_raw_handler_register);
+EXPORT_SYMBOL_GPL(ir_register_map);
void ir_unregister_map(struct rc_keymap *map)
{
@@ -72,4 +72,4 @@ void ir_unregister_map(struct rc_keymap *map)
list_del(&map->list);
spin_unlock(&rc_map_lock);
}
-EXPORT_SYMBOL_GPL(ir_raw_handler_unregister);
+EXPORT_SYMBOL_GPL(ir_unregister_map);
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 05/26] V4L/DVB: ir-common: Use macros to define the keytables
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (17 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 07/26] V4L/DVB: ir-core: Add support for RC map code register Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 09/26] V4L/DVB: ir: prepare IR code for a parameter change at register function Mauro Carvalho Chehab
` (6 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
The usage of macros ensures that the proper namespace is being used
by all tables. It also makes easier to associate a keytable with
the name used inside the drivers.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/IR/ir-keymaps.c b/drivers/media/IR/ir-keymaps.c
index 55e7acd..1ba9285 100644
--- a/drivers/media/IR/ir-keymaps.c
+++ b/drivers/media/IR/ir-keymaps.c
@@ -35,24 +35,15 @@
* to define the proper IR_TYPE (IR_TYPE_RC5/IR_TYPE_NEC).
* The deprecated tables should use IR_TYPE_UNKNOWN
*/
-#define IR_TABLE(irname, type, tabname) \
-struct ir_scancode_table tabname ## _table = { \
- .scan = tabname, \
- .size = ARRAY_SIZE(tabname), \
- .ir_type = type, \
- .name = #irname, \
-}; \
-EXPORT_SYMBOL_GPL(tabname ## _table)
-
/* empty keytable, can be used as placeholder for not-yet created keytables */
-static struct ir_scancode ir_codes_empty[] = {
+static struct ir_scancode empty[] = {
{ 0x2a, KEY_COFFEE },
};
-IR_TABLE(empty, IR_TYPE_UNKNOWN, ir_codes_empty);
+DEFINE_LEGACY_IR_KEYTABLE(empty);
/* Michal Majchrowicz <mmajchrowicz@gmail.com> */
-static struct ir_scancode ir_codes_proteus_2309[] = {
+static struct ir_scancode proteus_2309[] = {
/* numeric */
{ 0x00, KEY_0 },
{ 0x01, KEY_1 },
@@ -80,10 +71,10 @@ static struct ir_scancode ir_codes_proteus_2309[] = {
{ 0x1e, KEY_VOLUMEUP }, /* volume + */
{ 0x14, KEY_F1 },
};
-IR_TABLE(proteus_2309, IR_TYPE_UNKNOWN, ir_codes_proteus_2309);
+DEFINE_LEGACY_IR_KEYTABLE(proteus_2309);
/* Matt Jesson <dvb@jesson.eclipse.co.uk */
-static struct ir_scancode ir_codes_avermedia_dvbt[] = {
+static struct ir_scancode avermedia_dvbt[] = {
{ 0x28, KEY_0 }, /* '0' / 'enter' */
{ 0x22, KEY_1 }, /* '1' */
{ 0x12, KEY_2 }, /* '2' / 'up arrow' */
@@ -120,14 +111,14 @@ static struct ir_scancode ir_codes_avermedia_dvbt[] = {
{ 0x1e, KEY_VOLUMEDOWN }, /* 'volume -' */
{ 0x3e, KEY_VOLUMEUP }, /* 'volume +' */
};
-IR_TABLE(avermedia_dvbt, IR_TYPE_UNKNOWN, ir_codes_avermedia_dvbt);
+DEFINE_LEGACY_IR_KEYTABLE(avermedia_dvbt);
/*
* Avermedia M135A with IR model RM-JX
* The same codes exist on both Positivo (BR) and original IR
* Mauro Carvalho Chehab <mchehab@infradead.org>
*/
-static struct ir_scancode ir_codes_avermedia_m135a_rm_jx[] = {
+static struct ir_scancode avermedia_m135a_rm_jx[] = {
{ 0x0200, KEY_POWER2 },
{ 0x022e, KEY_DOT }, /* '.' */
{ 0x0201, KEY_MODE }, /* TV/FM or SOURCE */
@@ -172,10 +163,10 @@ static struct ir_scancode ir_codes_avermedia_m135a_rm_jx[] = {
{ 0x0218, KEY_PLAY },
{ 0x021b, KEY_STOP },
};
-IR_TABLE(aver-m135a-RM-JX, IR_TYPE_NEC, ir_codes_avermedia_m135a_rm_jx);
+DEFINE_IR_KEYTABLE(avermedia_m135a_rm_jx, IR_TYPE_NEC);
/* Oldrich Jedlicka <oldium.pro@seznam.cz> */
-static struct ir_scancode ir_codes_avermedia_cardbus[] = {
+static struct ir_scancode avermedia_cardbus[] = {
{ 0x00, KEY_POWER },
{ 0x01, KEY_TUNER }, /* TV/FM */
{ 0x03, KEY_TEXT }, /* Teletext */
@@ -231,10 +222,10 @@ static struct ir_scancode ir_codes_avermedia_cardbus[] = {
{ 0x42, KEY_CHANNELDOWN }, /* Channel down */
{ 0x43, KEY_CHANNELUP }, /* Channel up */
};
-IR_TABLE(avermedia_cardbus, IR_TYPE_UNKNOWN, ir_codes_avermedia_cardbus);
+DEFINE_LEGACY_IR_KEYTABLE(avermedia_cardbus);
/* Attila Kondoros <attila.kondoros@chello.hu> */
-static struct ir_scancode ir_codes_apac_viewcomp[] = {
+static struct ir_scancode apac_viewcomp[] = {
{ 0x01, KEY_1 },
{ 0x02, KEY_2 },
@@ -273,11 +264,11 @@ static struct ir_scancode ir_codes_apac_viewcomp[] = {
{ 0x0c, KEY_KPPLUS }, /* fine tune >>>> */
{ 0x18, KEY_KPMINUS }, /* fine tune <<<< */
};
-IR_TABLE(apac_viewcomp, IR_TYPE_UNKNOWN, ir_codes_apac_viewcomp);
+DEFINE_LEGACY_IR_KEYTABLE(apac_viewcomp);
/* ---------------------------------------------------------------------- */
-static struct ir_scancode ir_codes_pixelview[] = {
+static struct ir_scancode pixelview[] = {
{ 0x1e, KEY_POWER }, /* power */
{ 0x07, KEY_MEDIA }, /* source */
@@ -320,13 +311,13 @@ static struct ir_scancode ir_codes_pixelview[] = {
{ 0x1d, KEY_REFRESH }, /* reset */
{ 0x18, KEY_MUTE }, /* mute/unmute */
};
-IR_TABLE(pixelview, IR_TYPE_UNKNOWN, ir_codes_pixelview);
+DEFINE_LEGACY_IR_KEYTABLE(pixelview);
/*
Mauro Carvalho Chehab <mchehab@infradead.org>
present on PV MPEG 8000GT
*/
-static struct ir_scancode ir_codes_pixelview_new[] = {
+static struct ir_scancode pixelview_new[] = {
{ 0x3c, KEY_TIME }, /* Timeshift */
{ 0x12, KEY_POWER },
@@ -365,9 +356,9 @@ static struct ir_scancode ir_codes_pixelview_new[] = {
{ 0x31, KEY_TV },
{ 0x34, KEY_RADIO },
};
-IR_TABLE(pixelview_new, IR_TYPE_UNKNOWN, ir_codes_pixelview_new);
+DEFINE_LEGACY_IR_KEYTABLE(pixelview_new);
-static struct ir_scancode ir_codes_nebula[] = {
+static struct ir_scancode nebula[] = {
{ 0x00, KEY_0 },
{ 0x01, KEY_1 },
{ 0x02, KEY_2 },
@@ -424,10 +415,10 @@ static struct ir_scancode ir_codes_nebula[] = {
{ 0x35, KEY_PHONE },
{ 0x36, KEY_PC },
};
-IR_TABLE(nebula, IR_TYPE_UNKNOWN, ir_codes_nebula);
+DEFINE_LEGACY_IR_KEYTABLE(nebula);
/* DigitalNow DNTV Live DVB-T Remote */
-static struct ir_scancode ir_codes_dntv_live_dvb_t[] = {
+static struct ir_scancode dntv_live_dvb_t[] = {
{ 0x00, KEY_ESC }, /* 'go up a level?' */
/* Keys 0 to 9 */
{ 0x0a, KEY_0 },
@@ -464,12 +455,12 @@ static struct ir_scancode ir_codes_dntv_live_dvb_t[] = {
{ 0x1e, KEY_CHANNELDOWN },
{ 0x1f, KEY_VOLUMEDOWN },
};
-IR_TABLE(dntv_live_dvb_t, IR_TYPE_UNKNOWN, ir_codes_dntv_live_dvb_t);
+DEFINE_LEGACY_IR_KEYTABLE(dntv_live_dvb_t);
/* ---------------------------------------------------------------------- */
/* IO-DATA BCTV7E Remote */
-static struct ir_scancode ir_codes_iodata_bctv7e[] = {
+static struct ir_scancode iodata_bctv7e[] = {
{ 0x40, KEY_TV },
{ 0x20, KEY_RADIO }, /* FM */
{ 0x60, KEY_EPG },
@@ -516,12 +507,12 @@ static struct ir_scancode ir_codes_iodata_bctv7e[] = {
{ 0x61, KEY_FASTFORWARD }, /* forward >> */
{ 0x01, KEY_NEXT }, /* skip >| */
};
-IR_TABLE(iodata_bctv7e, IR_TYPE_UNKNOWN, ir_codes_iodata_bctv7e);
+DEFINE_LEGACY_IR_KEYTABLE(iodata_bctv7e);
/* ---------------------------------------------------------------------- */
/* ADS Tech Instant TV DVB-T PCI Remote */
-static struct ir_scancode ir_codes_adstech_dvb_t_pci[] = {
+static struct ir_scancode adstech_dvb_t_pci[] = {
/* Keys 0 to 9 */
{ 0x4d, KEY_0 },
{ 0x57, KEY_1 },
@@ -569,13 +560,13 @@ static struct ir_scancode ir_codes_adstech_dvb_t_pci[] = {
{ 0x15, KEY_VOLUMEUP },
{ 0x1c, KEY_VOLUMEDOWN },
};
-IR_TABLE(adstech_dvb_t_pci, IR_TYPE_UNKNOWN, ir_codes_adstech_dvb_t_pci);
+DEFINE_LEGACY_IR_KEYTABLE(adstech_dvb_t_pci);
/* ---------------------------------------------------------------------- */
/* MSI TV@nywhere MASTER remote */
-static struct ir_scancode ir_codes_msi_tvanywhere[] = {
+static struct ir_scancode msi_tvanywhere[] = {
/* Keys 0 to 9 */
{ 0x00, KEY_0 },
{ 0x01, KEY_1 },
@@ -603,7 +594,7 @@ static struct ir_scancode ir_codes_msi_tvanywhere[] = {
{ 0x1e, KEY_CHANNELDOWN },
{ 0x1f, KEY_VOLUMEDOWN },
};
-IR_TABLE(msi_tvanywhere, IR_TYPE_UNKNOWN, ir_codes_msi_tvanywhere);
+DEFINE_LEGACY_IR_KEYTABLE(msi_tvanywhere);
/* ---------------------------------------------------------------------- */
@@ -622,7 +613,7 @@ IR_TABLE(msi_tvanywhere, IR_TYPE_UNKNOWN, ir_codes_msi_tvanywhere);
*/
-static struct ir_scancode ir_codes_msi_tvanywhere_plus[] = {
+static struct ir_scancode msi_tvanywhere_plus[] = {
/* ---- Remote Button Layout ----
@@ -692,12 +683,12 @@ static struct ir_scancode ir_codes_msi_tvanywhere_plus[] = {
{ 0x0c, KEY_FASTFORWARD }, /* >> */
{ 0x1d, KEY_RESTART }, /* Reset */
};
-IR_TABLE(msi_tvanywhere_plus, IR_TYPE_UNKNOWN, ir_codes_msi_tvanywhere_plus);
+DEFINE_LEGACY_IR_KEYTABLE(msi_tvanywhere_plus);
/* ---------------------------------------------------------------------- */
/* Cinergy 1400 DVB-T */
-static struct ir_scancode ir_codes_cinergy_1400[] = {
+static struct ir_scancode cinergy_1400[] = {
{ 0x01, KEY_POWER },
{ 0x02, KEY_1 },
{ 0x03, KEY_2 },
@@ -740,12 +731,12 @@ static struct ir_scancode ir_codes_cinergy_1400[] = {
{ 0x48, KEY_STOP },
{ 0x5c, KEY_NEXT },
};
-IR_TABLE(cinergy_1400, IR_TYPE_UNKNOWN, ir_codes_cinergy_1400);
+DEFINE_LEGACY_IR_KEYTABLE(cinergy_1400);
/* ---------------------------------------------------------------------- */
/* AVERTV STUDIO 303 Remote */
-static struct ir_scancode ir_codes_avertv_303[] = {
+static struct ir_scancode avertv_303[] = {
{ 0x2a, KEY_1 },
{ 0x32, KEY_2 },
{ 0x3a, KEY_3 },
@@ -789,12 +780,12 @@ static struct ir_scancode ir_codes_avertv_303[] = {
{ 0x13, KEY_DOWN },
{ 0x1b, KEY_UP },
};
-IR_TABLE(avertv_303, IR_TYPE_UNKNOWN, ir_codes_avertv_303);
+DEFINE_LEGACY_IR_KEYTABLE(avertv_303);
/* ---------------------------------------------------------------------- */
/* DigitalNow DNTV Live! DVB-T Pro Remote */
-static struct ir_scancode ir_codes_dntv_live_dvbt_pro[] = {
+static struct ir_scancode dntv_live_dvbt_pro[] = {
{ 0x16, KEY_POWER },
{ 0x5b, KEY_HOME },
@@ -850,9 +841,9 @@ static struct ir_scancode ir_codes_dntv_live_dvbt_pro[] = {
{ 0x5c, KEY_YELLOW },
{ 0x5d, KEY_BLUE },
};
-IR_TABLE(dntv_live_dvbt_pro, IR_TYPE_UNKNOWN, ir_codes_dntv_live_dvbt_pro);
+DEFINE_LEGACY_IR_KEYTABLE(dntv_live_dvbt_pro);
-static struct ir_scancode ir_codes_em_terratec[] = {
+static struct ir_scancode em_terratec[] = {
{ 0x01, KEY_CHANNEL },
{ 0x02, KEY_SELECT },
{ 0x03, KEY_MUTE },
@@ -882,9 +873,9 @@ static struct ir_scancode ir_codes_em_terratec[] = {
{ 0x1e, KEY_STOP },
{ 0x40, KEY_ZOOM },
};
-IR_TABLE(em_terratec, IR_TYPE_UNKNOWN, ir_codes_em_terratec);
+DEFINE_LEGACY_IR_KEYTABLE(em_terratec);
-static struct ir_scancode ir_codes_pinnacle_grey[] = {
+static struct ir_scancode pinnacle_grey[] = {
{ 0x3a, KEY_0 },
{ 0x31, KEY_1 },
{ 0x32, KEY_2 },
@@ -934,9 +925,9 @@ static struct ir_scancode ir_codes_pinnacle_grey[] = {
{ 0x2a, KEY_MEDIA },
{ 0x18, KEY_EPG },
};
-IR_TABLE(pinnacle_grey, IR_TYPE_UNKNOWN, ir_codes_pinnacle_grey);
+DEFINE_LEGACY_IR_KEYTABLE(pinnacle_grey);
-static struct ir_scancode ir_codes_flyvideo[] = {
+static struct ir_scancode flyvideo[] = {
{ 0x0f, KEY_0 },
{ 0x03, KEY_1 },
{ 0x04, KEY_2 },
@@ -967,9 +958,9 @@ static struct ir_scancode ir_codes_flyvideo[] = {
{ 0x1f, KEY_FORWARD }, /* Forward ( >>> ) */
{ 0x0a, KEY_ANGLE }, /* no label, may be used as the PAUSE button */
};
-IR_TABLE(flyvideo, IR_TYPE_UNKNOWN, ir_codes_flyvideo);
+DEFINE_LEGACY_IR_KEYTABLE(flyvideo);
-static struct ir_scancode ir_codes_flydvb[] = {
+static struct ir_scancode flydvb[] = {
{ 0x01, KEY_ZOOM }, /* Full Screen */
{ 0x00, KEY_POWER }, /* Power */
@@ -1007,9 +998,9 @@ static struct ir_scancode ir_codes_flydvb[] = {
{ 0x11, KEY_STOP }, /* Stop */
{ 0x0e, KEY_NEXT }, /* End >>| */
};
-IR_TABLE(flydvb, IR_TYPE_UNKNOWN, ir_codes_flydvb);
+DEFINE_LEGACY_IR_KEYTABLE(flydvb);
-static struct ir_scancode ir_codes_cinergy[] = {
+static struct ir_scancode cinergy[] = {
{ 0x00, KEY_0 },
{ 0x01, KEY_1 },
{ 0x02, KEY_2 },
@@ -1048,11 +1039,11 @@ static struct ir_scancode ir_codes_cinergy[] = {
{ 0x22, KEY_PAUSE },
{ 0x23, KEY_STOP },
};
-IR_TABLE(cinergy, IR_TYPE_UNKNOWN, ir_codes_cinergy);
+DEFINE_LEGACY_IR_KEYTABLE(cinergy);
/* Alfons Geser <a.geser@cox.net>
* updates from Job D. R. Borges <jobdrb@ig.com.br> */
-static struct ir_scancode ir_codes_eztv[] = {
+static struct ir_scancode eztv[] = {
{ 0x12, KEY_POWER },
{ 0x01, KEY_TV }, /* DVR */
{ 0x15, KEY_DVD }, /* DVD */
@@ -1106,10 +1097,10 @@ static struct ir_scancode ir_codes_eztv[] = {
{ 0x13, KEY_ENTER }, /* enter */
{ 0x21, KEY_DOT }, /* . (decimal dot) */
};
-IR_TABLE(eztv, IR_TYPE_UNKNOWN, ir_codes_eztv);
+DEFINE_LEGACY_IR_KEYTABLE(eztv);
/* Alex Hermann <gaaf@gmx.net> */
-static struct ir_scancode ir_codes_avermedia[] = {
+static struct ir_scancode avermedia[] = {
{ 0x28, KEY_1 },
{ 0x18, KEY_2 },
{ 0x38, KEY_3 },
@@ -1154,9 +1145,9 @@ static struct ir_scancode ir_codes_avermedia[] = {
{ 0x11, KEY_CHANNELDOWN }, /* CHANNEL/PAGE- */
{ 0x31, KEY_CHANNELUP } /* CHANNEL/PAGE+ */
};
-IR_TABLE(avermedia, IR_TYPE_UNKNOWN, ir_codes_avermedia);
+DEFINE_LEGACY_IR_KEYTABLE(avermedia);
-static struct ir_scancode ir_codes_videomate_tv_pvr[] = {
+static struct ir_scancode videomate_tv_pvr[] = {
{ 0x14, KEY_MUTE },
{ 0x24, KEY_ZOOM },
@@ -1204,7 +1195,7 @@ static struct ir_scancode ir_codes_videomate_tv_pvr[] = {
{ 0x20, KEY_LANGUAGE },
{ 0x21, KEY_SLEEP },
};
-IR_TABLE(videomate_tv_pvr, IR_TYPE_UNKNOWN, ir_codes_videomate_tv_pvr);
+DEFINE_LEGACY_IR_KEYTABLE(videomate_tv_pvr);
/* Michael Tokarev <mjt@tls.msk.ru>
http://www.corpit.ru/mjt/beholdTV/remote_control.jpg
@@ -1215,7 +1206,7 @@ IR_TABLE(videomate_tv_pvr, IR_TYPE_UNKNOWN, ir_codes_videomate_tv_pvr);
the button labels (several variants when appropriate)
helps to descide which keycodes to assign to the buttons.
*/
-static struct ir_scancode ir_codes_manli[] = {
+static struct ir_scancode manli[] = {
/* 0x1c 0x12 *
* FUNCTION POWER *
@@ -1301,10 +1292,10 @@ static struct ir_scancode ir_codes_manli[] = {
/* 0x1d unused ? */
};
-IR_TABLE(manli, IR_TYPE_UNKNOWN, ir_codes_manli);
+DEFINE_LEGACY_IR_KEYTABLE(manli);
/* Mike Baikov <mike@baikov.com> */
-static struct ir_scancode ir_codes_gotview7135[] = {
+static struct ir_scancode gotview7135[] = {
{ 0x11, KEY_POWER },
{ 0x35, KEY_TV },
@@ -1342,9 +1333,9 @@ static struct ir_scancode ir_codes_gotview7135[] = {
{ 0x1e, KEY_TIME }, /* TIMESHIFT */
{ 0x38, KEY_F24 }, /* NORMAL TIMESHIFT */
};
-IR_TABLE(gotview7135, IR_TYPE_UNKNOWN, ir_codes_gotview7135);
+DEFINE_LEGACY_IR_KEYTABLE(gotview7135);
-static struct ir_scancode ir_codes_purpletv[] = {
+static struct ir_scancode purpletv[] = {
{ 0x03, KEY_POWER },
{ 0x6f, KEY_MUTE },
{ 0x10, KEY_BACKSPACE }, /* Recall */
@@ -1386,13 +1377,13 @@ static struct ir_scancode ir_codes_purpletv[] = {
{ 0x42, KEY_REWIND }, /* Backward ? */
};
-IR_TABLE(purpletv, IR_TYPE_UNKNOWN, ir_codes_purpletv);
+DEFINE_LEGACY_IR_KEYTABLE(purpletv);
/* Mapping for the 28 key remote control as seen at
http://www.sednacomputer.com/photo/cardbus-tv.jpg
Pavel Mihaylov <bin@bash.info>
Also for the remote bundled with Kozumi KTV-01C card */
-static struct ir_scancode ir_codes_pctv_sedna[] = {
+static struct ir_scancode pctv_sedna[] = {
{ 0x00, KEY_0 },
{ 0x01, KEY_1 },
{ 0x02, KEY_2 },
@@ -1428,10 +1419,10 @@ static struct ir_scancode ir_codes_pctv_sedna[] = {
{ 0x17, KEY_DIGITS }, /* Plus */
{ 0x1f, KEY_PLAY }, /* Play */
};
-IR_TABLE(pctv_sedna, IR_TYPE_UNKNOWN, ir_codes_pctv_sedna);
+DEFINE_LEGACY_IR_KEYTABLE(pctv_sedna);
/* Mark Phalan <phalanm@o2.ie> */
-static struct ir_scancode ir_codes_pv951[] = {
+static struct ir_scancode pv951[] = {
{ 0x00, KEY_0 },
{ 0x01, KEY_1 },
{ 0x02, KEY_2 },
@@ -1468,12 +1459,12 @@ static struct ir_scancode ir_codes_pv951[] = {
{ 0x14, KEY_EQUAL }, /* SYNC */
{ 0x1c, KEY_MEDIA }, /* PC/TV */
};
-IR_TABLE(pv951, IR_TYPE_UNKNOWN, ir_codes_pv951);
+DEFINE_LEGACY_IR_KEYTABLE(pv951);
/* generic RC5 keytable */
/* see http://users.pandora.be/nenya/electronics/rc5/codes00.htm */
/* used by old (black) Hauppauge remotes */
-static struct ir_scancode ir_codes_rc5_tv[] = {
+static struct ir_scancode rc5_tv[] = {
/* Keys 0 to 9 */
{ 0x00, KEY_0 },
{ 0x01, KEY_1 },
@@ -1511,10 +1502,10 @@ static struct ir_scancode ir_codes_rc5_tv[] = {
{ 0x3d, KEY_SUSPEND }, /* system standby */
};
-IR_TABLE(rc5_tv, IR_TYPE_UNKNOWN, ir_codes_rc5_tv);
+DEFINE_LEGACY_IR_KEYTABLE(rc5_tv);
/* Table for Leadtek Winfast Remote Controls - used by both bttv and cx88 */
-static struct ir_scancode ir_codes_winfast[] = {
+static struct ir_scancode winfast[] = {
/* Keys 0 to 9 */
{ 0x12, KEY_0 },
{ 0x05, KEY_1 },
@@ -1575,9 +1566,9 @@ static struct ir_scancode ir_codes_winfast[] = {
{ 0x3b, KEY_F23 }, /* MCE +CH, on Y04G0033 */
{ 0x3f, KEY_F24 } /* MCE -CH, on Y04G0033 */
};
-IR_TABLE(winfast, IR_TYPE_UNKNOWN, ir_codes_winfast);
+DEFINE_LEGACY_IR_KEYTABLE(winfast);
-static struct ir_scancode ir_codes_pinnacle_color[] = {
+static struct ir_scancode pinnacle_color[] = {
{ 0x59, KEY_MUTE },
{ 0x4a, KEY_POWER },
@@ -1632,12 +1623,12 @@ static struct ir_scancode ir_codes_pinnacle_color[] = {
{ 0x74, KEY_CHANNEL },
{ 0x0a, KEY_BACKSPACE },
};
-IR_TABLE(pinnacle_color, IR_TYPE_UNKNOWN, ir_codes_pinnacle_color);
+DEFINE_LEGACY_IR_KEYTABLE(pinnacle_color);
/* Hauppauge: the newer, gray remotes (seems there are multiple
* slightly different versions), shipped with cx88+ivtv cards.
* almost rc5 coding, but some non-standard keys */
-static struct ir_scancode ir_codes_hauppauge_new[] = {
+static struct ir_scancode hauppauge_new[] = {
/* Keys 0 to 9 */
{ 0x00, KEY_0 },
{ 0x01, KEY_1 },
@@ -1694,9 +1685,9 @@ static struct ir_scancode ir_codes_hauppauge_new[] = {
{ 0x3c, KEY_ZOOM }, /* full */
{ 0x3d, KEY_POWER }, /* system power (green button) */
};
-IR_TABLE(hauppauge_new, IR_TYPE_UNKNOWN, ir_codes_hauppauge_new);
+DEFINE_LEGACY_IR_KEYTABLE(hauppauge_new);
-static struct ir_scancode ir_codes_npgtech[] = {
+static struct ir_scancode npgtech[] = {
{ 0x1d, KEY_SWITCHVIDEOMODE }, /* switch inputs */
{ 0x2a, KEY_FRONT },
@@ -1737,12 +1728,12 @@ static struct ir_scancode ir_codes_npgtech[] = {
{ 0x10, KEY_POWER },
};
-IR_TABLE(npgtech, IR_TYPE_UNKNOWN, ir_codes_npgtech);
+DEFINE_LEGACY_IR_KEYTABLE(npgtech);
/* Norwood Micro (non-Pro) TV Tuner
By Peter Naulls <peter@chocky.org>
Key comments are the functions given in the manual */
-static struct ir_scancode ir_codes_norwood[] = {
+static struct ir_scancode norwood[] = {
/* Keys 0 to 9 */
{ 0x20, KEY_0 },
{ 0x21, KEY_1 },
@@ -1784,14 +1775,14 @@ static struct ir_scancode ir_codes_norwood[] = {
{ 0x34, KEY_RADIO }, /* FM */
{ 0x65, KEY_POWER }, /* Computer power */
};
-IR_TABLE(norwood, IR_TYPE_UNKNOWN, ir_codes_norwood);
+DEFINE_LEGACY_IR_KEYTABLE(norwood);
/* From reading the following remotes:
* Zenith Universal 7 / TV Mode 807 / VCR Mode 837
* Hauppauge (from NOVA-CI-s box product)
* This is a "middle of the road" approach, differences are noted
*/
-static struct ir_scancode ir_codes_budget_ci_old[] = {
+static struct ir_scancode budget_ci_old[] = {
{ 0x00, KEY_0 },
{ 0x01, KEY_1 },
{ 0x02, KEY_2 },
@@ -1838,14 +1829,14 @@ static struct ir_scancode ir_codes_budget_ci_old[] = {
{ 0x3d, KEY_POWER2 },
{ 0x3e, KEY_TUNER },
};
-IR_TABLE(budget_ci_old, IR_TYPE_UNKNOWN, ir_codes_budget_ci_old);
+DEFINE_LEGACY_IR_KEYTABLE(budget_ci_old);
/*
* Marc Fargas <telenieko@telenieko.com>
* this is the remote control that comes with the asus p7131
* which has a label saying is "Model PC-39"
*/
-static struct ir_scancode ir_codes_asus_pc39[] = {
+static struct ir_scancode asus_pc39[] = {
/* Keys 0 to 9 */
{ 0x15, KEY_0 },
{ 0x29, KEY_1 },
@@ -1891,11 +1882,11 @@ static struct ir_scancode ir_codes_asus_pc39[] = {
{ 0x3d, KEY_MUTE }, /* mute */
{ 0x01, KEY_DVD }, /* dvd */
};
-IR_TABLE(asus_pc39, IR_TYPE_UNKNOWN, ir_codes_asus_pc39);
+DEFINE_LEGACY_IR_KEYTABLE(asus_pc39);
/* Encore ENLTV-FM - black plastic, white front cover with white glowing buttons
Juan Pablo Sormani <sorman@gmail.com> */
-static struct ir_scancode ir_codes_encore_enltv[] = {
+static struct ir_scancode encore_enltv[] = {
/* Power button does nothing, neither in Windows app,
although it sends data (used for BIOS wakeup?) */
@@ -1965,11 +1956,11 @@ static struct ir_scancode ir_codes_encore_enltv[] = {
{ 0x47, KEY_YELLOW }, /* AP3 */
{ 0x57, KEY_BLUE }, /* AP4 */
};
-IR_TABLE(encore_enltv, IR_TYPE_UNKNOWN, ir_codes_encore_enltv);
+DEFINE_LEGACY_IR_KEYTABLE(encore_enltv);
/* Encore ENLTV2-FM - silver plastic - "Wand Media" written at the botton
Mauro Carvalho Chehab <mchehab@infradead.org> */
-static struct ir_scancode ir_codes_encore_enltv2[] = {
+static struct ir_scancode encore_enltv2[] = {
{ 0x4c, KEY_POWER2 },
{ 0x4a, KEY_TUNER },
{ 0x40, KEY_1 },
@@ -2017,10 +2008,10 @@ static struct ir_scancode ir_codes_encore_enltv2[] = {
{ 0x7d, KEY_FORWARD },
{ 0x79, KEY_STOP },
};
-IR_TABLE(encore_enltv2, IR_TYPE_UNKNOWN, ir_codes_encore_enltv2);
+DEFINE_LEGACY_IR_KEYTABLE(encore_enltv2);
/* for the Technotrend 1500 bundled remotes (grey and black): */
-static struct ir_scancode ir_codes_tt_1500[] = {
+static struct ir_scancode tt_1500[] = {
{ 0x01, KEY_POWER },
{ 0x02, KEY_SHUFFLE }, /* ? double-arrow key */
{ 0x03, KEY_1 },
@@ -2061,10 +2052,10 @@ static struct ir_scancode ir_codes_tt_1500[] = {
{ 0x3e, KEY_PAUSE },
{ 0x3f, KEY_FORWARD },
};
-IR_TABLE(tt_1500, IR_TYPE_UNKNOWN, ir_codes_tt_1500);
+DEFINE_LEGACY_IR_KEYTABLE(tt_1500);
/* DViCO FUSION HDTV MCE remote */
-static struct ir_scancode ir_codes_fusionhdtv_mce[] = {
+static struct ir_scancode fusionhdtv_mce[] = {
{ 0x0b, KEY_1 },
{ 0x17, KEY_2 },
@@ -2121,10 +2112,10 @@ static struct ir_scancode ir_codes_fusionhdtv_mce[] = {
{ 0x01, KEY_RECORD },
{ 0x4e, KEY_POWER },
};
-IR_TABLE(fusionhdtv_mce, IR_TYPE_UNKNOWN, ir_codes_fusionhdtv_mce);
+DEFINE_LEGACY_IR_KEYTABLE(fusionhdtv_mce);
/* Pinnacle PCTV HD 800i mini remote */
-static struct ir_scancode ir_codes_pinnacle_pctv_hd[] = {
+static struct ir_scancode pinnacle_pctv_hd[] = {
{ 0x0f, KEY_1 },
{ 0x15, KEY_2 },
@@ -2156,7 +2147,7 @@ static struct ir_scancode ir_codes_pinnacle_pctv_hd[] = {
{ 0x36, KEY_RECORD },
{ 0x3f, KEY_EPG }, /* Labeled "?" */
};
-IR_TABLE(pinnacle_pctv_hd, IR_TYPE_UNKNOWN, ir_codes_pinnacle_pctv_hd);
+DEFINE_LEGACY_IR_KEYTABLE(pinnacle_pctv_hd);
/*
* Igor Kuznetsov <igk72@ya.ru>
@@ -2169,7 +2160,7 @@ IR_TABLE(pinnacle_pctv_hd, IR_TYPE_UNKNOWN, ir_codes_pinnacle_pctv_hd);
* the button labels (several variants when appropriate)
* helps to descide which keycodes to assign to the buttons.
*/
-static struct ir_scancode ir_codes_behold[] = {
+static struct ir_scancode behold[] = {
/* 0x1c 0x12 *
* TV/FM POWER *
@@ -2259,7 +2250,7 @@ static struct ir_scancode ir_codes_behold[] = {
{ 0x5c, KEY_CAMERA },
};
-IR_TABLE(behold, IR_TYPE_UNKNOWN, ir_codes_behold);
+DEFINE_LEGACY_IR_KEYTABLE(behold);
/* Beholder Intl. Ltd. 2008
* Dmitry Belimov d.belimov@google.com
@@ -2269,7 +2260,7 @@ IR_TABLE(behold, IR_TYPE_UNKNOWN, ir_codes_behold);
* the button labels (several variants when appropriate)
* helps to descide which keycodes to assign to the buttons.
*/
-static struct ir_scancode ir_codes_behold_columbus[] = {
+static struct ir_scancode behold_columbus[] = {
/* 0x13 0x11 0x1C 0x12 *
* Mute Source TV/FM Power *
@@ -2329,13 +2320,13 @@ static struct ir_scancode ir_codes_behold_columbus[] = {
{ 0x1A, KEY_NEXT },
};
-IR_TABLE(behold_columbus, IR_TYPE_UNKNOWN, ir_codes_behold_columbus);
+DEFINE_LEGACY_IR_KEYTABLE(behold_columbus);
/*
* Remote control for the Genius TVGO A11MCE
* Adrian Pardini <pardo.bsso@gmail.com>
*/
-static struct ir_scancode ir_codes_genius_tvgo_a11mce[] = {
+static struct ir_scancode genius_tvgo_a11mce[] = {
/* Keys 0 to 9 */
{ 0x48, KEY_0 },
{ 0x09, KEY_1 },
@@ -2375,13 +2366,13 @@ static struct ir_scancode ir_codes_genius_tvgo_a11mce[] = {
{ 0x13, KEY_YELLOW },
{ 0x50, KEY_BLUE },
};
-IR_TABLE(genius_tvgo_a11mce, IR_TYPE_UNKNOWN, ir_codes_genius_tvgo_a11mce);
+DEFINE_LEGACY_IR_KEYTABLE(genius_tvgo_a11mce);
/*
* Remote control for Powercolor Real Angel 330
* Daniel Fraga <fragabr@gmail.com>
*/
-static struct ir_scancode ir_codes_powercolor_real_angel[] = {
+static struct ir_scancode powercolor_real_angel[] = {
{ 0x38, KEY_SWITCHVIDEOMODE }, /* switch inputs */
{ 0x0c, KEY_MEDIA }, /* Turn ON/OFF App */
{ 0x00, KEY_0 },
@@ -2418,12 +2409,12 @@ static struct ir_scancode ir_codes_powercolor_real_angel[] = {
{ 0x14, KEY_RADIO }, /* FM radio */
{ 0x25, KEY_POWER }, /* power */
};
-IR_TABLE(powercolor_real_angel, IR_TYPE_UNKNOWN, ir_codes_powercolor_real_angel);
+DEFINE_LEGACY_IR_KEYTABLE(powercolor_real_angel);
/* Kworld Plus TV Analog Lite PCI IR
Mauro Carvalho Chehab <mchehab@infradead.org>
*/
-static struct ir_scancode ir_codes_kworld_plus_tv_analog[] = {
+static struct ir_scancode kworld_plus_tv_analog[] = {
{ 0x0c, KEY_PROG1 }, /* Kworld key */
{ 0x16, KEY_CLOSECD }, /* -> ) */
{ 0x1d, KEY_POWER2 },
@@ -2479,12 +2470,12 @@ static struct ir_scancode ir_codes_kworld_plus_tv_analog[] = {
{ 0x18, KEY_RED}, /* B */
{ 0x23, KEY_GREEN}, /* C */
};
-IR_TABLE(kworld_plus_tv_analog, IR_TYPE_UNKNOWN, ir_codes_kworld_plus_tv_analog);
+DEFINE_LEGACY_IR_KEYTABLE(kworld_plus_tv_analog);
/* Kaiomy TVnPC U2
Mauro Carvalho Chehab <mchehab@infradead.org>
*/
-static struct ir_scancode ir_codes_kaiomy[] = {
+static struct ir_scancode kaiomy[] = {
{ 0x43, KEY_POWER2},
{ 0x01, KEY_LIST},
{ 0x0b, KEY_ZOOM},
@@ -2528,9 +2519,9 @@ static struct ir_scancode ir_codes_kaiomy[] = {
{ 0x1e, KEY_YELLOW},
{ 0x1f, KEY_BLUE},
};
-IR_TABLE(kaiomy, IR_TYPE_UNKNOWN, ir_codes_kaiomy);
+DEFINE_LEGACY_IR_KEYTABLE(kaiomy);
-static struct ir_scancode ir_codes_avermedia_a16d[] = {
+static struct ir_scancode avermedia_a16d[] = {
{ 0x20, KEY_LIST},
{ 0x00, KEY_POWER},
{ 0x28, KEY_1},
@@ -2566,12 +2557,12 @@ static struct ir_scancode ir_codes_avermedia_a16d[] = {
{ 0x08, KEY_EPG},
{ 0x2a, KEY_MENU},
};
-IR_TABLE(avermedia_a16d, IR_TYPE_UNKNOWN, ir_codes_avermedia_a16d);
+DEFINE_LEGACY_IR_KEYTABLE(avermedia_a16d);
/* Encore ENLTV-FM v5.3
Mauro Carvalho Chehab <mchehab@infradead.org>
*/
-static struct ir_scancode ir_codes_encore_enltv_fm53[] = {
+static struct ir_scancode encore_enltv_fm53[] = {
{ 0x10, KEY_POWER2},
{ 0x06, KEY_MUTE},
@@ -2609,10 +2600,10 @@ static struct ir_scancode ir_codes_encore_enltv_fm53[] = {
{ 0x0c, KEY_ZOOM}, /* hide pannel */
{ 0x47, KEY_SLEEP}, /* shutdown */
};
-IR_TABLE(encore_enltv_fm53, IR_TYPE_UNKNOWN, ir_codes_encore_enltv_fm53);
+DEFINE_LEGACY_IR_KEYTABLE(encore_enltv_fm53);
/* Zogis Real Audio 220 - 32 keys IR */
-static struct ir_scancode ir_codes_real_audio_220_32_keys[] = {
+static struct ir_scancode real_audio_220_32_keys[] = {
{ 0x1c, KEY_RADIO},
{ 0x12, KEY_POWER2},
@@ -2649,12 +2640,12 @@ static struct ir_scancode ir_codes_real_audio_220_32_keys[] = {
{ 0x19, KEY_CAMERA}, /* Snapshot */
};
-IR_TABLE(real_audio_220_32_keys, IR_TYPE_UNKNOWN, ir_codes_real_audio_220_32_keys);
+DEFINE_LEGACY_IR_KEYTABLE(real_audio_220_32_keys);
/* ATI TV Wonder HD 600 USB
Devin Heitmueller <devin.heitmueller@gmail.com>
*/
-static struct ir_scancode ir_codes_ati_tv_wonder_hd_600[] = {
+static struct ir_scancode ati_tv_wonder_hd_600[] = {
{ 0x00, KEY_RECORD}, /* Row 1 */
{ 0x01, KEY_PLAYPAUSE},
{ 0x02, KEY_STOP},
@@ -2680,12 +2671,12 @@ static struct ir_scancode ir_codes_ati_tv_wonder_hd_600[] = {
{ 0x16, KEY_MUTE},
{ 0x17, KEY_VOLUMEDOWN},
};
-IR_TABLE(ati_tv_wonder_hd_600, IR_TYPE_UNKNOWN, ir_codes_ati_tv_wonder_hd_600);
+DEFINE_LEGACY_IR_KEYTABLE(ati_tv_wonder_hd_600);
/* DVBWorld remotes
Igor M. Liplianin <liplianin@me.by>
*/
-static struct ir_scancode ir_codes_dm1105_nec[] = {
+static struct ir_scancode dm1105_nec[] = {
{ 0x0a, KEY_POWER2}, /* power */
{ 0x0c, KEY_MUTE}, /* mute */
{ 0x11, KEY_1},
@@ -2718,9 +2709,9 @@ static struct ir_scancode ir_codes_dm1105_nec[] = {
{ 0x1e, KEY_TV}, /* tvmode */
{ 0x1b, KEY_B}, /* recall */
};
-IR_TABLE(dm1105_nec, IR_TYPE_UNKNOWN, ir_codes_dm1105_nec);
+DEFINE_LEGACY_IR_KEYTABLE(dm1105_nec);
-static struct ir_scancode ir_codes_tevii_nec[] = {
+static struct ir_scancode tevii_nec[] = {
{ 0x0a, KEY_POWER2},
{ 0x0c, KEY_MUTE},
{ 0x11, KEY_1},
@@ -2769,9 +2760,9 @@ static struct ir_scancode ir_codes_tevii_nec[] = {
{ 0x56, KEY_MODE},
{ 0x58, KEY_SWITCHVIDEOMODE},
};
-IR_TABLE(tevii_nec, IR_TYPE_UNKNOWN, ir_codes_tevii_nec);
+DEFINE_LEGACY_IR_KEYTABLE(tevii_nec);
-static struct ir_scancode ir_codes_tbs_nec[] = {
+static struct ir_scancode tbs_nec[] = {
{ 0x04, KEY_POWER2}, /*power*/
{ 0x14, KEY_MUTE}, /*mute*/
{ 0x07, KEY_1},
@@ -2805,12 +2796,12 @@ static struct ir_scancode ir_codes_tbs_nec[] = {
{ 0x00, KEY_PREVIOUS},
{ 0x1b, KEY_MODE},
};
-IR_TABLE(tbs_nec, IR_TYPE_UNKNOWN, ir_codes_tbs_nec);
+DEFINE_LEGACY_IR_KEYTABLE(tbs_nec);
/* Terratec Cinergy Hybrid T USB XS
Devin Heitmueller <dheitmueller@linuxtv.org>
*/
-static struct ir_scancode ir_codes_terratec_cinergy_xs[] = {
+static struct ir_scancode terratec_cinergy_xs[] = {
{ 0x41, KEY_HOME},
{ 0x01, KEY_POWER},
{ 0x42, KEY_MENU},
@@ -2859,12 +2850,12 @@ static struct ir_scancode ir_codes_terratec_cinergy_xs[] = {
{ 0x4f, KEY_FASTFORWARD},
{ 0x5c, KEY_NEXT},
};
-IR_TABLE(terratec_cinergy_xs, IR_TYPE_UNKNOWN, ir_codes_terratec_cinergy_xs);
+DEFINE_LEGACY_IR_KEYTABLE(terratec_cinergy_xs);
/* EVGA inDtube
Devin Heitmueller <devin.heitmueller@gmail.com>
*/
-static struct ir_scancode ir_codes_evga_indtube[] = {
+static struct ir_scancode evga_indtube[] = {
{ 0x12, KEY_POWER},
{ 0x02, KEY_MODE}, /* TV */
{ 0x14, KEY_MUTE},
@@ -2882,9 +2873,9 @@ static struct ir_scancode ir_codes_evga_indtube[] = {
{ 0x1f, KEY_NEXT},
{ 0x13, KEY_CAMERA},
};
-IR_TABLE(evga_indtube, IR_TYPE_UNKNOWN, ir_codes_evga_indtube);
+DEFINE_LEGACY_IR_KEYTABLE(evga_indtube);
-static struct ir_scancode ir_codes_videomate_s350[] = {
+static struct ir_scancode videomate_s350[] = {
{ 0x00, KEY_TV},
{ 0x01, KEY_DVD},
{ 0x04, KEY_RECORD},
@@ -2930,12 +2921,12 @@ static struct ir_scancode ir_codes_videomate_s350[] = {
{ 0x11, KEY_ENTER},
{ 0x20, KEY_TEXT},
};
-IR_TABLE(videomate_s350, IR_TYPE_UNKNOWN, ir_codes_videomate_s350);
+DEFINE_LEGACY_IR_KEYTABLE(videomate_s350);
/* GADMEI UTV330+ RM008Z remote
Shine Liu <shinel@foxmail.com>
*/
-static struct ir_scancode ir_codes_gadmei_rm008z[] = {
+static struct ir_scancode gadmei_rm008z[] = {
{ 0x14, KEY_POWER2}, /* POWER OFF */
{ 0x0c, KEY_MUTE}, /* MUTE */
@@ -2973,7 +2964,7 @@ static struct ir_scancode ir_codes_gadmei_rm008z[] = {
{ 0x13, KEY_CHANNELDOWN}, /* CHANNELDOWN */
{ 0x15, KEY_ENTER}, /* OK */
};
-IR_TABLE(gadmei_rm008z, IR_TYPE_UNKNOWN, ir_codes_gadmei_rm008z);
+DEFINE_LEGACY_IR_KEYTABLE(gadmei_rm008z);
/*************************************************************
* COMPLETE SCANCODE TABLES
@@ -2987,7 +2978,7 @@ IR_TABLE(gadmei_rm008z, IR_TYPE_UNKNOWN, ir_codes_gadmei_rm008z);
*
* This table contains the complete RC5 code, instead of just the data part
*/
-static struct ir_scancode ir_codes_rc5_hauppauge_new[] = {
+static struct ir_scancode rc5_hauppauge_new[] = {
/* Keys 0 to 9 */
{ 0x1e00, KEY_0 },
{ 0x1e01, KEY_1 },
@@ -3044,12 +3035,12 @@ static struct ir_scancode ir_codes_rc5_hauppauge_new[] = {
{ 0x1e3c, KEY_ZOOM }, /* full */
{ 0x1e3d, KEY_POWER }, /* system power (green button) */
};
-IR_TABLE(rc5_hauppauge_new, IR_TYPE_RC5, ir_codes_rc5_hauppauge_new);
+DEFINE_IR_KEYTABLE(rc5_hauppauge_new, IR_TYPE_RC5);
/* Terratec Cinergy Hybrid T USB XS FM
Mauro Carvalho Chehab <mchehab@redhat.com>
*/
-static struct ir_scancode ir_codes_nec_terratec_cinergy_xs[] = {
+static struct ir_scancode nec_terratec_cinergy_xs[] = {
{ 0x1441, KEY_HOME},
{ 0x1401, KEY_POWER2},
@@ -3111,12 +3102,12 @@ static struct ir_scancode ir_codes_nec_terratec_cinergy_xs[] = {
{ 0x144f, KEY_FASTFORWARD},
{ 0x145c, KEY_NEXT},
};
-IR_TABLE(nec_terratec_cinergy_xs, IR_TYPE_NEC, ir_codes_nec_terratec_cinergy_xs);
+DEFINE_IR_KEYTABLE(nec_terratec_cinergy_xs, IR_TYPE_NEC);
/* Leadtek Winfast TV USB II Deluxe remote
Magnus Alm <magnus.alm@gmail.com>
*/
-static struct ir_scancode ir_codes_winfast_usbii_deluxe[] = {
+static struct ir_scancode winfast_usbii_deluxe[] = {
{ 0x62, KEY_0},
{ 0x75, KEY_1},
{ 0x76, KEY_2},
@@ -3155,11 +3146,11 @@ static struct ir_scancode ir_codes_winfast_usbii_deluxe[] = {
{ 0x63, KEY_ENTER}, /* ENTER */
};
-IR_TABLE(winfast_usbii_deluxe, IR_TYPE_UNKNOWN, ir_codes_winfast_usbii_deluxe);
+DEFINE_LEGACY_IR_KEYTABLE(winfast_usbii_deluxe);
/* Kworld 315U
*/
-static struct ir_scancode ir_codes_kworld_315u[] = {
+static struct ir_scancode kworld_315u[] = {
{ 0x6143, KEY_POWER },
{ 0x6101, KEY_TUNER }, /* source */
{ 0x610b, KEY_ZOOM },
@@ -3200,4 +3191,4 @@ static struct ir_scancode ir_codes_kworld_315u[] = {
{ 0x611e, KEY_YELLOW },
{ 0x611f, KEY_BLUE },
};
-IR_TABLE(kworld_315u, IR_TYPE_NEC, ir_codes_kworld_315u);
+DEFINE_IR_KEYTABLE(kworld_315u, IR_TYPE_NEC);
diff --git a/include/media/ir-common.h b/include/media/ir-common.h
index 2e27515..e8a6476 100644
--- a/include/media/ir-common.h
+++ b/include/media/ir-common.h
@@ -107,11 +107,23 @@ void ir_rc5_timer_keyup(unsigned long data);
/* scancode->keycode map tables from ir-keymaps.c */
#define IR_KEYTABLE(a) \
-(ir_codes_ ## a ## _table)
+ir_codes_ ## a ## _table
#define DECLARE_IR_KEYTABLE(a) \
extern struct ir_scancode_table IR_KEYTABLE(a)
+#define DEFINE_IR_KEYTABLE(tabname, type) \
+struct ir_scancode_table IR_KEYTABLE(tabname) = { \
+ .scan = tabname, \
+ .size = ARRAY_SIZE(tabname), \
+ .ir_type = type, \
+ .name = #tabname, \
+}; \
+EXPORT_SYMBOL_GPL(IR_KEYTABLE(tabname))
+
+#define DEFINE_LEGACY_IR_KEYTABLE(tabname) \
+ DEFINE_IR_KEYTABLE(tabname, IR_TYPE_UNKNOWN)
+
DECLARE_IR_KEYTABLE(adstech_dvb_t_pci);
DECLARE_IR_KEYTABLE(apac_viewcomp);
DECLARE_IR_KEYTABLE(asus_pc39);
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 04/26] V4L/DVB: rename all *_rc_keys to ir_codes_*_nec_table
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (19 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 09/26] V4L/DVB: ir: prepare IR code for a parameter change at register function Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 06/26] V4L/DVB: ir-common: move IR tables from ir-keymaps.c to a separate file Mauro Carvalho Chehab
` (4 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
Several DVB drivers use a different name convention. As we're moving
the keytables, we need to use the same convention on all places.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/dvb/dvb-usb/a800.c b/drivers/media/dvb/dvb-usb/a800.c
index 6247239..b6cbb1d 100644
--- a/drivers/media/dvb/dvb-usb/a800.c
+++ b/drivers/media/dvb/dvb-usb/a800.c
@@ -37,7 +37,7 @@ static int a800_identify_state(struct usb_device *udev, struct dvb_usb_device_pr
return 0;
}
-static struct dvb_usb_rc_key a800_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_a800_table[] = {
{ 0x0201, KEY_PROG1 }, /* SOURCE */
{ 0x0200, KEY_POWER }, /* POWER */
{ 0x0205, KEY_1 }, /* 1 */
@@ -147,8 +147,8 @@ static struct dvb_usb_device_properties a800_properties = {
.identify_state = a800_identify_state,
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = a800_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(a800_rc_keys),
+ .rc_key_map = ir_codes_a800_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_a800_table),
.rc_query = a800_rc_query,
.i2c_algo = &dibusb_i2c_algo,
diff --git a/drivers/media/dvb/dvb-usb/af9005-remote.c b/drivers/media/dvb/dvb-usb/af9005-remote.c
index f4379c6..b41fa87 100644
--- a/drivers/media/dvb/dvb-usb/af9005-remote.c
+++ b/drivers/media/dvb/dvb-usb/af9005-remote.c
@@ -33,7 +33,7 @@ MODULE_PARM_DESC(debug,
#define deb_decode(args...) dprintk(dvb_usb_af9005_remote_debug,0x01,args)
-struct dvb_usb_rc_key af9005_rc_keys[] = {
+struct dvb_usb_rc_key ir_codes_af9005_table[] = {
{0x01b7, KEY_POWER},
{0x01a7, KEY_VOLUMEUP},
@@ -74,7 +74,7 @@ struct dvb_usb_rc_key af9005_rc_keys[] = {
{0x00d5, KEY_GOTO}, /* marked jump on the remote */
};
-int af9005_rc_keys_size = ARRAY_SIZE(af9005_rc_keys);
+int ir_codes_af9005_table_size = ARRAY_SIZE(ir_codes_af9005_table);
static int repeatable_keys[] = {
KEY_VOLUMEUP,
@@ -130,10 +130,10 @@ int af9005_rc_decode(struct dvb_usb_device *d, u8 * data, int len, u32 * event,
deb_decode("code != inverted code\n");
return 0;
}
- for (i = 0; i < af9005_rc_keys_size; i++) {
- if (rc5_custom(&af9005_rc_keys[i]) == cust
- && rc5_data(&af9005_rc_keys[i]) == dat) {
- *event = af9005_rc_keys[i].event;
+ for (i = 0; i < ir_codes_af9005_table_size; i++) {
+ if (rc5_custom(&ir_codes_af9005_table[i]) == cust
+ && rc5_data(&ir_codes_af9005_table[i]) == dat) {
+ *event = ir_codes_af9005_table[i].event;
*state = REMOTE_KEY_PRESSED;
deb_decode
("key pressed, event %x\n", *event);
@@ -146,8 +146,8 @@ int af9005_rc_decode(struct dvb_usb_device *d, u8 * data, int len, u32 * event,
return 0;
}
-EXPORT_SYMBOL(af9005_rc_keys);
-EXPORT_SYMBOL(af9005_rc_keys_size);
+EXPORT_SYMBOL(ir_codes_af9005_table);
+EXPORT_SYMBOL(ir_codes_af9005_table_size);
EXPORT_SYMBOL(af9005_rc_decode);
MODULE_AUTHOR("Luca Olivetti <luca@ventoso.org>");
diff --git a/drivers/media/dvb/dvb-usb/af9005.c b/drivers/media/dvb/dvb-usb/af9005.c
index ca5a0a4..cfd6107 100644
--- a/drivers/media/dvb/dvb-usb/af9005.c
+++ b/drivers/media/dvb/dvb-usb/af9005.c
@@ -1109,8 +1109,8 @@ static int __init af9005_usb_module_init(void)
return result;
}
rc_decode = symbol_request(af9005_rc_decode);
- rc_keys = symbol_request(af9005_rc_keys);
- rc_keys_size = symbol_request(af9005_rc_keys_size);
+ rc_keys = symbol_request(ir_codes_af9005_table);
+ rc_keys_size = symbol_request(ir_codes_af9005_table_size);
if (rc_decode == NULL || rc_keys == NULL || rc_keys_size == NULL) {
err("af9005_rc_decode function not found, disabling remote");
af9005_properties.rc_query = NULL;
@@ -1128,9 +1128,9 @@ static void __exit af9005_usb_module_exit(void)
if (rc_decode != NULL)
symbol_put(af9005_rc_decode);
if (rc_keys != NULL)
- symbol_put(af9005_rc_keys);
+ symbol_put(ir_codes_af9005_table);
if (rc_keys_size != NULL)
- symbol_put(af9005_rc_keys_size);
+ symbol_put(ir_codes_af9005_table_size);
/* deregister this driver from the USB subsystem */
usb_deregister(&af9005_usb_driver);
}
diff --git a/drivers/media/dvb/dvb-usb/af9005.h b/drivers/media/dvb/dvb-usb/af9005.h
index 0bc48a0..088e708 100644
--- a/drivers/media/dvb/dvb-usb/af9005.h
+++ b/drivers/media/dvb/dvb-usb/af9005.h
@@ -3490,7 +3490,7 @@ extern u8 regmask[8];
/* remote control decoder */
extern int af9005_rc_decode(struct dvb_usb_device *d, u8 * data, int len,
u32 * event, int *state);
-extern struct dvb_usb_rc_key af9005_rc_keys[];
-extern int af9005_rc_keys_size;
+extern struct dvb_usb_rc_key ir_codes_af9005_table[];
+extern int ir_codes_af9005_table_size;
#endif
diff --git a/drivers/media/dvb/dvb-usb/af9015.c b/drivers/media/dvb/dvb-usb/af9015.c
index c0c999b..1580997 100644
--- a/drivers/media/dvb/dvb-usb/af9015.c
+++ b/drivers/media/dvb/dvb-usb/af9015.c
@@ -751,19 +751,19 @@ static const struct af9015_setup *af9015_setup_match(unsigned int id,
static const struct af9015_setup af9015_setup_modparam[] = {
{ AF9015_REMOTE_A_LINK_DTU_M,
- af9015_rc_keys_a_link, ARRAY_SIZE(af9015_rc_keys_a_link),
+ ir_codes_af9015_table_a_link, ARRAY_SIZE(ir_codes_af9015_table_a_link),
af9015_ir_table_a_link, ARRAY_SIZE(af9015_ir_table_a_link) },
{ AF9015_REMOTE_MSI_DIGIVOX_MINI_II_V3,
- af9015_rc_keys_msi, ARRAY_SIZE(af9015_rc_keys_msi),
+ ir_codes_af9015_table_msi, ARRAY_SIZE(ir_codes_af9015_table_msi),
af9015_ir_table_msi, ARRAY_SIZE(af9015_ir_table_msi) },
{ AF9015_REMOTE_MYGICTV_U718,
- af9015_rc_keys_mygictv, ARRAY_SIZE(af9015_rc_keys_mygictv),
+ ir_codes_af9015_table_mygictv, ARRAY_SIZE(ir_codes_af9015_table_mygictv),
af9015_ir_table_mygictv, ARRAY_SIZE(af9015_ir_table_mygictv) },
{ AF9015_REMOTE_DIGITTRADE_DVB_T,
- af9015_rc_keys_digittrade, ARRAY_SIZE(af9015_rc_keys_digittrade),
+ ir_codes_af9015_table_digittrade, ARRAY_SIZE(ir_codes_af9015_table_digittrade),
af9015_ir_table_digittrade, ARRAY_SIZE(af9015_ir_table_digittrade) },
{ AF9015_REMOTE_AVERMEDIA_KS,
- af9015_rc_keys_avermedia, ARRAY_SIZE(af9015_rc_keys_avermedia),
+ ir_codes_af9015_table_avermedia, ARRAY_SIZE(ir_codes_af9015_table_avermedia),
af9015_ir_table_avermedia_ks, ARRAY_SIZE(af9015_ir_table_avermedia_ks) },
{ }
};
@@ -771,32 +771,32 @@ static const struct af9015_setup af9015_setup_modparam[] = {
/* don't add new entries here anymore, use hashes instead */
static const struct af9015_setup af9015_setup_usbids[] = {
{ USB_VID_LEADTEK,
- af9015_rc_keys_leadtek, ARRAY_SIZE(af9015_rc_keys_leadtek),
+ ir_codes_af9015_table_leadtek, ARRAY_SIZE(ir_codes_af9015_table_leadtek),
af9015_ir_table_leadtek, ARRAY_SIZE(af9015_ir_table_leadtek) },
{ USB_VID_VISIONPLUS,
- af9015_rc_keys_twinhan, ARRAY_SIZE(af9015_rc_keys_twinhan),
+ ir_codes_af9015_table_twinhan, ARRAY_SIZE(ir_codes_af9015_table_twinhan),
af9015_ir_table_twinhan, ARRAY_SIZE(af9015_ir_table_twinhan) },
{ USB_VID_KWORLD_2, /* TODO: use correct rc keys */
- af9015_rc_keys_twinhan, ARRAY_SIZE(af9015_rc_keys_twinhan),
+ ir_codes_af9015_table_twinhan, ARRAY_SIZE(ir_codes_af9015_table_twinhan),
af9015_ir_table_kworld, ARRAY_SIZE(af9015_ir_table_kworld) },
{ USB_VID_AVERMEDIA,
- af9015_rc_keys_avermedia, ARRAY_SIZE(af9015_rc_keys_avermedia),
+ ir_codes_af9015_table_avermedia, ARRAY_SIZE(ir_codes_af9015_table_avermedia),
af9015_ir_table_avermedia, ARRAY_SIZE(af9015_ir_table_avermedia) },
{ USB_VID_MSI_2,
- af9015_rc_keys_msi_digivox_iii, ARRAY_SIZE(af9015_rc_keys_msi_digivox_iii),
+ ir_codes_af9015_table_msi_digivox_iii, ARRAY_SIZE(ir_codes_af9015_table_msi_digivox_iii),
af9015_ir_table_msi_digivox_iii, ARRAY_SIZE(af9015_ir_table_msi_digivox_iii) },
{ }
};
static const struct af9015_setup af9015_setup_hashes[] = {
{ 0xb8feb708,
- af9015_rc_keys_msi, ARRAY_SIZE(af9015_rc_keys_msi),
+ ir_codes_af9015_table_msi, ARRAY_SIZE(ir_codes_af9015_table_msi),
af9015_ir_table_msi, ARRAY_SIZE(af9015_ir_table_msi) },
{ 0xa3703d00,
- af9015_rc_keys_a_link, ARRAY_SIZE(af9015_rc_keys_a_link),
+ ir_codes_af9015_table_a_link, ARRAY_SIZE(ir_codes_af9015_table_a_link),
af9015_ir_table_a_link, ARRAY_SIZE(af9015_ir_table_a_link) },
{ 0x9b7dc64e,
- af9015_rc_keys_mygictv, ARRAY_SIZE(af9015_rc_keys_mygictv),
+ ir_codes_af9015_table_mygictv, ARRAY_SIZE(ir_codes_af9015_table_mygictv),
af9015_ir_table_mygictv, ARRAY_SIZE(af9015_ir_table_mygictv) },
{ }
};
@@ -835,8 +835,8 @@ static void af9015_set_remote_config(struct usb_device *udev,
} else if (udev->descriptor.idProduct ==
cpu_to_le16(USB_PID_TREKSTOR_DVBT)) {
table = &(const struct af9015_setup){ 0,
- af9015_rc_keys_trekstor,
- ARRAY_SIZE(af9015_rc_keys_trekstor),
+ ir_codes_af9015_table_trekstor,
+ ARRAY_SIZE(ir_codes_af9015_table_trekstor),
af9015_ir_table_trekstor,
ARRAY_SIZE(af9015_ir_table_trekstor)
};
diff --git a/drivers/media/dvb/dvb-usb/af9015.h b/drivers/media/dvb/dvb-usb/af9015.h
index ef36b18..63b2a49 100644
--- a/drivers/media/dvb/dvb-usb/af9015.h
+++ b/drivers/media/dvb/dvb-usb/af9015.h
@@ -123,7 +123,7 @@ enum af9015_remote {
/* LeadTek - Y04G0051 */
/* Leadtek WinFast DTV Dongle Gold */
-static struct dvb_usb_rc_key af9015_rc_keys_leadtek[] = {
+static struct dvb_usb_rc_key ir_codes_af9015_table_leadtek[] = {
{ 0x001e, KEY_1 },
{ 0x001f, KEY_2 },
{ 0x0020, KEY_3 },
@@ -227,7 +227,7 @@ static u8 af9015_ir_table_leadtek[] = {
};
/* TwinHan AzureWave AD-TU700(704J) */
-static struct dvb_usb_rc_key af9015_rc_keys_twinhan[] = {
+static struct dvb_usb_rc_key ir_codes_af9015_table_twinhan[] = {
{ 0x053f, KEY_POWER },
{ 0x0019, KEY_FAVORITES }, /* Favorite List */
{ 0x0004, KEY_TEXT }, /* Teletext */
@@ -338,7 +338,7 @@ static u8 af9015_ir_table_twinhan[] = {
};
/* A-Link DTU(m) */
-static struct dvb_usb_rc_key af9015_rc_keys_a_link[] = {
+static struct dvb_usb_rc_key ir_codes_af9015_table_a_link[] = {
{ 0x001e, KEY_1 },
{ 0x001f, KEY_2 },
{ 0x0020, KEY_3 },
@@ -381,7 +381,7 @@ static u8 af9015_ir_table_a_link[] = {
};
/* MSI DIGIVOX mini II V3.0 */
-static struct dvb_usb_rc_key af9015_rc_keys_msi[] = {
+static struct dvb_usb_rc_key ir_codes_af9015_table_msi[] = {
{ 0x001e, KEY_1 },
{ 0x001f, KEY_2 },
{ 0x0020, KEY_3 },
@@ -424,7 +424,7 @@ static u8 af9015_ir_table_msi[] = {
};
/* MYGICTV U718 */
-static struct dvb_usb_rc_key af9015_rc_keys_mygictv[] = {
+static struct dvb_usb_rc_key ir_codes_af9015_table_mygictv[] = {
{ 0x003d, KEY_SWITCHVIDEOMODE },
/* TV / AV */
{ 0x0545, KEY_POWER },
@@ -550,7 +550,7 @@ static u8 af9015_ir_table_kworld[] = {
};
/* AverMedia Volar X */
-static struct dvb_usb_rc_key af9015_rc_keys_avermedia[] = {
+static struct dvb_usb_rc_key ir_codes_af9015_table_avermedia[] = {
{ 0x053d, KEY_PROG1 }, /* SOURCE */
{ 0x0512, KEY_POWER }, /* POWER */
{ 0x051e, KEY_1 }, /* 1 */
@@ -656,7 +656,7 @@ static u8 af9015_ir_table_avermedia_ks[] = {
};
/* Digittrade DVB-T USB Stick */
-static struct dvb_usb_rc_key af9015_rc_keys_digittrade[] = {
+static struct dvb_usb_rc_key ir_codes_af9015_table_digittrade[] = {
{ 0x010f, KEY_LAST }, /* RETURN */
{ 0x0517, KEY_TEXT }, /* TELETEXT */
{ 0x0108, KEY_EPG }, /* EPG */
@@ -719,7 +719,7 @@ static u8 af9015_ir_table_digittrade[] = {
};
/* TREKSTOR DVB-T USB Stick */
-static struct dvb_usb_rc_key af9015_rc_keys_trekstor[] = {
+static struct dvb_usb_rc_key ir_codes_af9015_table_trekstor[] = {
{ 0x0704, KEY_AGAIN }, /* Home */
{ 0x0705, KEY_MUTE }, /* Mute */
{ 0x0706, KEY_UP }, /* Up */
@@ -782,7 +782,7 @@ static u8 af9015_ir_table_trekstor[] = {
};
/* MSI DIGIVOX mini III */
-static struct dvb_usb_rc_key af9015_rc_keys_msi_digivox_iii[] = {
+static struct dvb_usb_rc_key ir_codes_af9015_table_msi_digivox_iii[] = {
{ 0x0713, KEY_POWER }, /* [red power button] */
{ 0x073b, KEY_VIDEO }, /* Source */
{ 0x073e, KEY_ZOOM }, /* Zoom */
diff --git a/drivers/media/dvb/dvb-usb/anysee.c b/drivers/media/dvb/dvb-usb/anysee.c
index bb69f37..faca1ad 100644
--- a/drivers/media/dvb/dvb-usb/anysee.c
+++ b/drivers/media/dvb/dvb-usb/anysee.c
@@ -399,7 +399,7 @@ static int anysee_rc_query(struct dvb_usb_device *d, u32 *event, int *state)
return 0;
}
-static struct dvb_usb_rc_key anysee_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_anysee_table[] = {
{ 0x0100, KEY_0 },
{ 0x0101, KEY_1 },
{ 0x0102, KEY_2 },
@@ -518,8 +518,8 @@ static struct dvb_usb_device_properties anysee_properties = {
}
},
- .rc_key_map = anysee_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(anysee_rc_keys),
+ .rc_key_map = ir_codes_anysee_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_anysee_table),
.rc_query = anysee_rc_query,
.rc_interval = 200, /* windows driver uses 500ms */
diff --git a/drivers/media/dvb/dvb-usb/az6027.c b/drivers/media/dvb/dvb-usb/az6027.c
index 30ea3ef..8934788 100644
--- a/drivers/media/dvb/dvb-usb/az6027.c
+++ b/drivers/media/dvb/dvb-usb/az6027.c
@@ -386,7 +386,7 @@ static int az6027_streaming_ctrl(struct dvb_usb_adapter *adap, int onoff)
}
/* keys for the enclosed remote control */
-static struct dvb_usb_rc_key az6027_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_az6027_table[] = {
{ 0x01, KEY_1 },
{ 0x02, KEY_2 },
};
@@ -1096,8 +1096,8 @@ static struct dvb_usb_device_properties az6027_properties = {
.power_ctrl = az6027_power_ctrl,
.read_mac_address = az6027_read_mac_addr,
*/
- .rc_key_map = az6027_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(az6027_rc_keys),
+ .rc_key_map = ir_codes_az6027_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_az6027_table),
.rc_interval = 400,
.rc_query = az6027_rc_query,
.i2c_algo = &az6027_i2c_algo,
diff --git a/drivers/media/dvb/dvb-usb/cinergyT2-core.c b/drivers/media/dvb/dvb-usb/cinergyT2-core.c
index e37ac4d..5a9c14b 100644
--- a/drivers/media/dvb/dvb-usb/cinergyT2-core.c
+++ b/drivers/media/dvb/dvb-usb/cinergyT2-core.c
@@ -84,7 +84,7 @@ static int cinergyt2_frontend_attach(struct dvb_usb_adapter *adap)
return 0;
}
-static struct dvb_usb_rc_key cinergyt2_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_cinergyt2_table[] = {
{ 0x0401, KEY_POWER },
{ 0x0402, KEY_1 },
{ 0x0403, KEY_2 },
@@ -218,8 +218,8 @@ static struct dvb_usb_device_properties cinergyt2_properties = {
.power_ctrl = cinergyt2_power_ctrl,
.rc_interval = 50,
- .rc_key_map = cinergyt2_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(cinergyt2_rc_keys),
+ .rc_key_map = ir_codes_cinergyt2_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_cinergyt2_table),
.rc_query = cinergyt2_rc_query,
.generic_bulk_ctrl_endpoint = 1,
diff --git a/drivers/media/dvb/dvb-usb/cxusb.c b/drivers/media/dvb/dvb-usb/cxusb.c
index a7b8405..60de386 100644
--- a/drivers/media/dvb/dvb-usb/cxusb.c
+++ b/drivers/media/dvb/dvb-usb/cxusb.c
@@ -460,7 +460,7 @@ static int cxusb_d680_dmb_rc_query(struct dvb_usb_device *d, u32 *event,
return 0;
}
-static struct dvb_usb_rc_key dvico_mce_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_dvico_mce_table[] = {
{ 0xfe02, KEY_TV },
{ 0xfe0e, KEY_MP3 },
{ 0xfe1a, KEY_DVD },
@@ -508,7 +508,7 @@ static struct dvb_usb_rc_key dvico_mce_rc_keys[] = {
{ 0xfe4e, KEY_POWER },
};
-static struct dvb_usb_rc_key dvico_portable_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_dvico_portable_table[] = {
{ 0xfc02, KEY_SETUP }, /* Profile */
{ 0xfc43, KEY_POWER2 },
{ 0xfc06, KEY_EPG },
@@ -547,7 +547,7 @@ static struct dvb_usb_rc_key dvico_portable_rc_keys[] = {
{ 0xfc00, KEY_UNKNOWN }, /* HD */
};
-static struct dvb_usb_rc_key d680_dmb_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_d680_dmb_table[] = {
{ 0x0038, KEY_UNKNOWN }, /* TV/AV */
{ 0x080c, KEY_ZOOM },
{ 0x0800, KEY_0 },
@@ -1448,8 +1448,8 @@ static struct dvb_usb_device_properties cxusb_bluebird_lgh064f_properties = {
.i2c_algo = &cxusb_i2c_algo,
.rc_interval = 100,
- .rc_key_map = dvico_portable_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dvico_portable_rc_keys),
+ .rc_key_map = ir_codes_dvico_portable_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dvico_portable_table),
.rc_query = cxusb_rc_query,
.generic_bulk_ctrl_endpoint = 0x01,
@@ -1499,8 +1499,8 @@ static struct dvb_usb_device_properties cxusb_bluebird_dee1601_properties = {
.i2c_algo = &cxusb_i2c_algo,
.rc_interval = 150,
- .rc_key_map = dvico_mce_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dvico_mce_rc_keys),
+ .rc_key_map = ir_codes_dvico_mce_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dvico_mce_table),
.rc_query = cxusb_rc_query,
.generic_bulk_ctrl_endpoint = 0x01,
@@ -1558,8 +1558,8 @@ static struct dvb_usb_device_properties cxusb_bluebird_lgz201_properties = {
.i2c_algo = &cxusb_i2c_algo,
.rc_interval = 100,
- .rc_key_map = dvico_portable_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dvico_portable_rc_keys),
+ .rc_key_map = ir_codes_dvico_portable_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dvico_portable_table),
.rc_query = cxusb_rc_query,
.generic_bulk_ctrl_endpoint = 0x01,
@@ -1608,8 +1608,8 @@ static struct dvb_usb_device_properties cxusb_bluebird_dtt7579_properties = {
.i2c_algo = &cxusb_i2c_algo,
.rc_interval = 100,
- .rc_key_map = dvico_portable_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dvico_portable_rc_keys),
+ .rc_key_map = ir_codes_dvico_portable_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dvico_portable_table),
.rc_query = cxusb_rc_query,
.generic_bulk_ctrl_endpoint = 0x01,
@@ -1657,8 +1657,8 @@ static struct dvb_usb_device_properties cxusb_bluebird_dualdig4_properties = {
.generic_bulk_ctrl_endpoint = 0x01,
.rc_interval = 100,
- .rc_key_map = dvico_mce_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dvico_mce_rc_keys),
+ .rc_key_map = ir_codes_dvico_mce_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dvico_mce_table),
.rc_query = cxusb_bluebird2_rc_query,
.num_device_descs = 1,
@@ -1705,8 +1705,8 @@ static struct dvb_usb_device_properties cxusb_bluebird_nano2_properties = {
.generic_bulk_ctrl_endpoint = 0x01,
.rc_interval = 100,
- .rc_key_map = dvico_portable_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dvico_portable_rc_keys),
+ .rc_key_map = ir_codes_dvico_portable_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dvico_portable_table),
.rc_query = cxusb_bluebird2_rc_query,
.num_device_descs = 1,
@@ -1755,8 +1755,8 @@ static struct dvb_usb_device_properties cxusb_bluebird_nano2_needsfirmware_prope
.generic_bulk_ctrl_endpoint = 0x01,
.rc_interval = 100,
- .rc_key_map = dvico_portable_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dvico_portable_rc_keys),
+ .rc_key_map = ir_codes_dvico_portable_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dvico_portable_table),
.rc_query = cxusb_rc_query,
.num_device_descs = 1,
@@ -1846,8 +1846,8 @@ struct dvb_usb_device_properties cxusb_bluebird_dualdig4_rev2_properties = {
.generic_bulk_ctrl_endpoint = 0x01,
.rc_interval = 100,
- .rc_key_map = dvico_mce_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dvico_mce_rc_keys),
+ .rc_key_map = ir_codes_dvico_mce_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dvico_mce_table),
.rc_query = cxusb_rc_query,
.num_device_descs = 1,
@@ -1894,8 +1894,8 @@ static struct dvb_usb_device_properties cxusb_d680_dmb_properties = {
.generic_bulk_ctrl_endpoint = 0x01,
.rc_interval = 100,
- .rc_key_map = d680_dmb_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(d680_dmb_rc_keys),
+ .rc_key_map = ir_codes_d680_dmb_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_d680_dmb_table),
.rc_query = cxusb_d680_dmb_rc_query,
.num_device_descs = 1,
@@ -1943,8 +1943,8 @@ static struct dvb_usb_device_properties cxusb_mygica_d689_properties = {
.generic_bulk_ctrl_endpoint = 0x01,
.rc_interval = 100,
- .rc_key_map = d680_dmb_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(d680_dmb_rc_keys),
+ .rc_key_map = ir_codes_d680_dmb_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_d680_dmb_table),
.rc_query = cxusb_d680_dmb_rc_query,
.num_device_descs = 1,
diff --git a/drivers/media/dvb/dvb-usb/dib0700_devices.c b/drivers/media/dvb/dvb-usb/dib0700_devices.c
index 34eab05..2deca21 100644
--- a/drivers/media/dvb/dvb-usb/dib0700_devices.c
+++ b/drivers/media/dvb/dvb-usb/dib0700_devices.c
@@ -562,7 +562,7 @@ static int dib0700_rc_query(struct dvb_usb_device *d, u32 *event, int *state)
return 0;
}
-static struct dvb_usb_rc_key dib0700_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_dib0700_table[] = {
/* Key codes for the tiny Pinnacle remote*/
{ 0x0700, KEY_MUTE },
{ 0x0701, KEY_MENU }, /* Pinnacle logo */
@@ -2131,8 +2131,8 @@ struct dvb_usb_device_properties dib0700_devices[] = {
},
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dib0700_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dib0700_rc_keys),
+ .rc_key_map = ir_codes_dib0700_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dib0700_table),
.rc_query = dib0700_rc_query
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
@@ -2160,8 +2160,8 @@ struct dvb_usb_device_properties dib0700_devices[] = {
},
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dib0700_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dib0700_rc_keys),
+ .rc_key_map = ir_codes_dib0700_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dib0700_table),
.rc_query = dib0700_rc_query
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
@@ -2214,8 +2214,8 @@ struct dvb_usb_device_properties dib0700_devices[] = {
},
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dib0700_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dib0700_rc_keys),
+ .rc_key_map = ir_codes_dib0700_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dib0700_table),
.rc_query = dib0700_rc_query
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
@@ -2251,8 +2251,8 @@ struct dvb_usb_device_properties dib0700_devices[] = {
},
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dib0700_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dib0700_rc_keys),
+ .rc_key_map = ir_codes_dib0700_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dib0700_table),
.rc_query = dib0700_rc_query
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
@@ -2321,8 +2321,8 @@ struct dvb_usb_device_properties dib0700_devices[] = {
},
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dib0700_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dib0700_rc_keys),
+ .rc_key_map = ir_codes_dib0700_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dib0700_table),
.rc_query = dib0700_rc_query
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
@@ -2360,8 +2360,8 @@ struct dvb_usb_device_properties dib0700_devices[] = {
},
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dib0700_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dib0700_rc_keys),
+ .rc_key_map = ir_codes_dib0700_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dib0700_table),
.rc_query = dib0700_rc_query
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
@@ -2422,8 +2422,8 @@ struct dvb_usb_device_properties dib0700_devices[] = {
}
},
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dib0700_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dib0700_rc_keys),
+ .rc_key_map = ir_codes_dib0700_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dib0700_table),
.rc_query = dib0700_rc_query
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
@@ -2484,8 +2484,8 @@ struct dvb_usb_device_properties dib0700_devices[] = {
},
},
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dib0700_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dib0700_rc_keys),
+ .rc_key_map = ir_codes_dib0700_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dib0700_table),
.rc_query = dib0700_rc_query
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
.num_adapters = 1,
@@ -2513,8 +2513,8 @@ struct dvb_usb_device_properties dib0700_devices[] = {
},
},
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dib0700_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dib0700_rc_keys),
+ .rc_key_map = ir_codes_dib0700_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dib0700_table),
.rc_query = dib0700_rc_query
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
.num_adapters = 1,
@@ -2574,8 +2574,8 @@ struct dvb_usb_device_properties dib0700_devices[] = {
},
},
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dib0700_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dib0700_rc_keys),
+ .rc_key_map = ir_codes_dib0700_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dib0700_table),
.rc_query = dib0700_rc_query
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
.num_adapters = 1,
@@ -2612,8 +2612,8 @@ struct dvb_usb_device_properties dib0700_devices[] = {
},
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dib0700_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dib0700_rc_keys),
+ .rc_key_map = ir_codes_dib0700_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dib0700_table),
.rc_query = dib0700_rc_query
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
@@ -2656,8 +2656,8 @@ struct dvb_usb_device_properties dib0700_devices[] = {
},
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dib0700_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dib0700_rc_keys),
+ .rc_key_map = ir_codes_dib0700_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dib0700_table),
.rc_query = dib0700_rc_query
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
.num_adapters = 1,
@@ -2687,8 +2687,8 @@ struct dvb_usb_device_properties dib0700_devices[] = {
},
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dib0700_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dib0700_rc_keys),
+ .rc_key_map = ir_codes_dib0700_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dib0700_table),
.rc_query = dib0700_rc_query
},
};
diff --git a/drivers/media/dvb/dvb-usb/dibusb-common.c b/drivers/media/dvb/dvb-usb/dibusb-common.c
index 9143b56..bc08bc0 100644
--- a/drivers/media/dvb/dvb-usb/dibusb-common.c
+++ b/drivers/media/dvb/dvb-usb/dibusb-common.c
@@ -327,7 +327,7 @@ EXPORT_SYMBOL(dibusb_dib3000mc_tuner_attach);
/*
* common remote control stuff
*/
-struct dvb_usb_rc_key dibusb_rc_keys[] = {
+struct dvb_usb_rc_key ir_codes_dibusb_table[] = {
/* Key codes for the little Artec T1/Twinhan/HAMA/ remote. */
{ 0x0016, KEY_POWER },
{ 0x0010, KEY_MUTE },
@@ -456,7 +456,7 @@ struct dvb_usb_rc_key dibusb_rc_keys[] = {
{ 0x804e, KEY_ENTER },
{ 0x804f, KEY_VOLUMEDOWN },
};
-EXPORT_SYMBOL(dibusb_rc_keys);
+EXPORT_SYMBOL(ir_codes_dibusb_table);
int dibusb_rc_query(struct dvb_usb_device *d, u32 *event, int *state)
{
diff --git a/drivers/media/dvb/dvb-usb/dibusb-mb.c b/drivers/media/dvb/dvb-usb/dibusb-mb.c
index 5c0126d..eb2e6f0 100644
--- a/drivers/media/dvb/dvb-usb/dibusb-mb.c
+++ b/drivers/media/dvb/dvb-usb/dibusb-mb.c
@@ -212,7 +212,7 @@ static struct dvb_usb_device_properties dibusb1_1_properties = {
.power_ctrl = dibusb_power_ctrl,
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dibusb_rc_keys,
+ .rc_key_map = ir_codes_dibusb_table,
.rc_key_map_size = 111, /* wow, that is ugly ... I want to load it to the driver dynamically */
.rc_query = dibusb_rc_query,
@@ -296,7 +296,7 @@ static struct dvb_usb_device_properties dibusb1_1_an2235_properties = {
.power_ctrl = dibusb_power_ctrl,
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dibusb_rc_keys,
+ .rc_key_map = ir_codes_dibusb_table,
.rc_key_map_size = 111, /* wow, that is ugly ... I want to load it to the driver dynamically */
.rc_query = dibusb_rc_query,
@@ -360,7 +360,7 @@ static struct dvb_usb_device_properties dibusb2_0b_properties = {
.power_ctrl = dibusb2_0_power_ctrl,
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dibusb_rc_keys,
+ .rc_key_map = ir_codes_dibusb_table,
.rc_key_map_size = 111, /* wow, that is ugly ... I want to load it to the driver dynamically */
.rc_query = dibusb_rc_query,
@@ -417,7 +417,7 @@ static struct dvb_usb_device_properties artec_t1_usb2_properties = {
.power_ctrl = dibusb2_0_power_ctrl,
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dibusb_rc_keys,
+ .rc_key_map = ir_codes_dibusb_table,
.rc_key_map_size = 111, /* wow, that is ugly ... I want to load it to the driver dynamically */
.rc_query = dibusb_rc_query,
diff --git a/drivers/media/dvb/dvb-usb/dibusb-mc.c b/drivers/media/dvb/dvb-usb/dibusb-mc.c
index a05b9f8..588308e 100644
--- a/drivers/media/dvb/dvb-usb/dibusb-mc.c
+++ b/drivers/media/dvb/dvb-usb/dibusb-mc.c
@@ -82,7 +82,7 @@ static struct dvb_usb_device_properties dibusb_mc_properties = {
.power_ctrl = dibusb2_0_power_ctrl,
.rc_interval = DEFAULT_RC_INTERVAL,
- .rc_key_map = dibusb_rc_keys,
+ .rc_key_map = ir_codes_dibusb_table,
.rc_key_map_size = 111, /* FIXME */
.rc_query = dibusb_rc_query,
diff --git a/drivers/media/dvb/dvb-usb/dibusb.h b/drivers/media/dvb/dvb-usb/dibusb.h
index 8e847aa..3d50ac5 100644
--- a/drivers/media/dvb/dvb-usb/dibusb.h
+++ b/drivers/media/dvb/dvb-usb/dibusb.h
@@ -124,7 +124,7 @@ extern int dibusb2_0_power_ctrl(struct dvb_usb_device *, int);
#define DEFAULT_RC_INTERVAL 150
//#define DEFAULT_RC_INTERVAL 100000
-extern struct dvb_usb_rc_key dibusb_rc_keys[];
+extern struct dvb_usb_rc_key ir_codes_dibusb_table[];
extern int dibusb_rc_query(struct dvb_usb_device *, u32 *, int *);
extern int dibusb_read_eeprom_byte(struct dvb_usb_device *, u8, u8 *);
diff --git a/drivers/media/dvb/dvb-usb/digitv.c b/drivers/media/dvb/dvb-usb/digitv.c
index 955147d..e826077 100644
--- a/drivers/media/dvb/dvb-usb/digitv.c
+++ b/drivers/media/dvb/dvb-usb/digitv.c
@@ -161,7 +161,7 @@ static int digitv_tuner_attach(struct dvb_usb_adapter *adap)
return 0;
}
-static struct dvb_usb_rc_key digitv_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_digitv_table[] = {
{ 0x5f55, KEY_0 },
{ 0x6f55, KEY_1 },
{ 0x9f55, KEY_2 },
@@ -311,8 +311,8 @@ static struct dvb_usb_device_properties digitv_properties = {
.identify_state = digitv_identify_state,
.rc_interval = 1000,
- .rc_key_map = digitv_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(digitv_rc_keys),
+ .rc_key_map = ir_codes_digitv_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_digitv_table),
.rc_query = digitv_rc_query,
.i2c_algo = &digitv_i2c_algo,
diff --git a/drivers/media/dvb/dvb-usb/dtt200u.c b/drivers/media/dvb/dvb-usb/dtt200u.c
index a1b12b0..f57e590 100644
--- a/drivers/media/dvb/dvb-usb/dtt200u.c
+++ b/drivers/media/dvb/dvb-usb/dtt200u.c
@@ -57,7 +57,7 @@ static int dtt200u_pid_filter(struct dvb_usb_adapter *adap, int index, u16 pid,
/* remote control */
/* key list for the tiny remote control (Yakumo, don't know about the others) */
-static struct dvb_usb_rc_key dtt200u_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_dtt200u_table[] = {
{ 0x8001, KEY_MUTE },
{ 0x8002, KEY_CHANNELDOWN },
{ 0x8003, KEY_VOLUMEDOWN },
@@ -162,8 +162,8 @@ static struct dvb_usb_device_properties dtt200u_properties = {
.power_ctrl = dtt200u_power_ctrl,
.rc_interval = 300,
- .rc_key_map = dtt200u_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dtt200u_rc_keys),
+ .rc_key_map = ir_codes_dtt200u_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dtt200u_table),
.rc_query = dtt200u_rc_query,
.generic_bulk_ctrl_endpoint = 0x01,
@@ -207,8 +207,8 @@ static struct dvb_usb_device_properties wt220u_properties = {
.power_ctrl = dtt200u_power_ctrl,
.rc_interval = 300,
- .rc_key_map = dtt200u_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dtt200u_rc_keys),
+ .rc_key_map = ir_codes_dtt200u_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dtt200u_table),
.rc_query = dtt200u_rc_query,
.generic_bulk_ctrl_endpoint = 0x01,
@@ -252,8 +252,8 @@ static struct dvb_usb_device_properties wt220u_fc_properties = {
.power_ctrl = dtt200u_power_ctrl,
.rc_interval = 300,
- .rc_key_map = dtt200u_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dtt200u_rc_keys),
+ .rc_key_map = ir_codes_dtt200u_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dtt200u_table),
.rc_query = dtt200u_rc_query,
.generic_bulk_ctrl_endpoint = 0x01,
@@ -297,8 +297,8 @@ static struct dvb_usb_device_properties wt220u_zl0353_properties = {
.power_ctrl = dtt200u_power_ctrl,
.rc_interval = 300,
- .rc_key_map = dtt200u_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dtt200u_rc_keys),
+ .rc_key_map = ir_codes_dtt200u_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dtt200u_table),
.rc_query = dtt200u_rc_query,
.generic_bulk_ctrl_endpoint = 0x01,
diff --git a/drivers/media/dvb/dvb-usb/dw2102.c b/drivers/media/dvb/dvb-usb/dw2102.c
index accc655..e8fb853 100644
--- a/drivers/media/dvb/dvb-usb/dw2102.c
+++ b/drivers/media/dvb/dvb-usb/dw2102.c
@@ -73,7 +73,7 @@
"Please see linux/Documentation/dvb/ for more details " \
"on firmware-problems."
-struct dvb_usb_rc_keys_table {
+struct ir_codes_dvb_usb_table_table {
struct dvb_usb_rc_key *rc_keys;
int rc_keys_size;
};
@@ -948,7 +948,7 @@ static int dw3101_tuner_attach(struct dvb_usb_adapter *adap)
return 0;
}
-static struct dvb_usb_rc_key dw210x_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_dw210x_table[] = {
{ 0xf80a, KEY_Q }, /*power*/
{ 0xf80c, KEY_M }, /*mute*/
{ 0xf811, KEY_1 },
@@ -982,7 +982,7 @@ static struct dvb_usb_rc_key dw210x_rc_keys[] = {
{ 0xf81b, KEY_B }, /*recall*/
};
-static struct dvb_usb_rc_key tevii_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_tevii_table[] = {
{ 0xf80a, KEY_POWER },
{ 0xf80c, KEY_MUTE },
{ 0xf811, KEY_1 },
@@ -1032,7 +1032,7 @@ static struct dvb_usb_rc_key tevii_rc_keys[] = {
{ 0xf858, KEY_SWITCHVIDEOMODE },
};
-static struct dvb_usb_rc_key tbs_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_tbs_table[] = {
{ 0xf884, KEY_POWER },
{ 0xf894, KEY_MUTE },
{ 0xf887, KEY_1 },
@@ -1067,10 +1067,10 @@ static struct dvb_usb_rc_key tbs_rc_keys[] = {
{ 0xf89b, KEY_MODE }
};
-static struct dvb_usb_rc_keys_table keys_tables[] = {
- { dw210x_rc_keys, ARRAY_SIZE(dw210x_rc_keys) },
- { tevii_rc_keys, ARRAY_SIZE(tevii_rc_keys) },
- { tbs_rc_keys, ARRAY_SIZE(tbs_rc_keys) },
+static struct ir_codes_dvb_usb_table_table keys_tables[] = {
+ { ir_codes_dw210x_table, ARRAY_SIZE(ir_codes_dw210x_table) },
+ { ir_codes_tevii_table, ARRAY_SIZE(ir_codes_tevii_table) },
+ { ir_codes_tbs_table, ARRAY_SIZE(ir_codes_tbs_table) },
};
static int dw2102_rc_query(struct dvb_usb_device *d, u32 *event, int *state)
@@ -1185,14 +1185,14 @@ static int dw2102_load_firmware(struct usb_device *dev,
/* init registers */
switch (dev->descriptor.idProduct) {
case USB_PID_PROF_1100:
- s6x0_properties.rc_key_map = tbs_rc_keys;
+ s6x0_properties.rc_key_map = ir_codes_tbs_table;
s6x0_properties.rc_key_map_size =
- ARRAY_SIZE(tbs_rc_keys);
+ ARRAY_SIZE(ir_codes_tbs_table);
break;
case USB_PID_TEVII_S650:
- dw2104_properties.rc_key_map = tevii_rc_keys;
+ dw2104_properties.rc_key_map = ir_codes_tevii_table;
dw2104_properties.rc_key_map_size =
- ARRAY_SIZE(tevii_rc_keys);
+ ARRAY_SIZE(ir_codes_tevii_table);
case USB_PID_DW2104:
reset = 1;
dw210x_op_rw(dev, 0xc4, 0x0000, 0, &reset, 1,
@@ -1255,8 +1255,8 @@ static struct dvb_usb_device_properties dw2102_properties = {
.no_reconnect = 1,
.i2c_algo = &dw2102_serit_i2c_algo,
- .rc_key_map = dw210x_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dw210x_rc_keys),
+ .rc_key_map = ir_codes_dw210x_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dw210x_table),
.rc_interval = 150,
.rc_query = dw2102_rc_query,
@@ -1306,8 +1306,8 @@ static struct dvb_usb_device_properties dw2104_properties = {
.no_reconnect = 1,
.i2c_algo = &dw2104_i2c_algo,
- .rc_key_map = dw210x_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dw210x_rc_keys),
+ .rc_key_map = ir_codes_dw210x_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dw210x_table),
.rc_interval = 150,
.rc_query = dw2102_rc_query,
@@ -1353,8 +1353,8 @@ static struct dvb_usb_device_properties dw3101_properties = {
.no_reconnect = 1,
.i2c_algo = &dw3101_i2c_algo,
- .rc_key_map = dw210x_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(dw210x_rc_keys),
+ .rc_key_map = ir_codes_dw210x_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_dw210x_table),
.rc_interval = 150,
.rc_query = dw2102_rc_query,
@@ -1396,8 +1396,8 @@ static struct dvb_usb_device_properties s6x0_properties = {
.no_reconnect = 1,
.i2c_algo = &s6x0_i2c_algo,
- .rc_key_map = tevii_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(tevii_rc_keys),
+ .rc_key_map = ir_codes_tevii_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_tevii_table),
.rc_interval = 150,
.rc_query = dw2102_rc_query,
@@ -1459,8 +1459,8 @@ static int dw2102_probe(struct usb_interface *intf,
/* fill only different fields */
p7500->firmware = "dvb-usb-p7500.fw";
p7500->devices[0] = d7500;
- p7500->rc_key_map = tbs_rc_keys;
- p7500->rc_key_map_size = ARRAY_SIZE(tbs_rc_keys);
+ p7500->rc_key_map = ir_codes_tbs_table;
+ p7500->rc_key_map_size = ARRAY_SIZE(ir_codes_tbs_table);
p7500->adapter->frontend_attach = prof_7500_frontend_attach;
if (0 == dvb_usb_device_init(intf, &dw2102_properties,
diff --git a/drivers/media/dvb/dvb-usb/m920x.c b/drivers/media/dvb/dvb-usb/m920x.c
index 737ffa3..c211fef 100644
--- a/drivers/media/dvb/dvb-usb/m920x.c
+++ b/drivers/media/dvb/dvb-usb/m920x.c
@@ -589,7 +589,7 @@ static struct m920x_inits pinnacle310e_init[] = {
};
/* ir keymaps */
-static struct dvb_usb_rc_key megasky_rc_keys [] = {
+static struct dvb_usb_rc_key ir_codes_megasky_table [] = {
{ 0x0012, KEY_POWER },
{ 0x001e, KEY_CYCLEWINDOWS }, /* min/max */
{ 0x0002, KEY_CHANNELUP },
@@ -608,7 +608,7 @@ static struct dvb_usb_rc_key megasky_rc_keys [] = {
{ 0x000e, KEY_COFFEE }, /* "MTS" */
};
-static struct dvb_usb_rc_key tvwalkertwin_rc_keys [] = {
+static struct dvb_usb_rc_key ir_codes_tvwalkertwin_table [] = {
{ 0x0001, KEY_ZOOM }, /* Full Screen */
{ 0x0002, KEY_CAMERA }, /* snapshot */
{ 0x0003, KEY_MUTE },
@@ -628,7 +628,7 @@ static struct dvb_usb_rc_key tvwalkertwin_rc_keys [] = {
{ 0x001e, KEY_VOLUMEUP },
};
-static struct dvb_usb_rc_key pinnacle310e_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_pinnacle310e_table[] = {
{ 0x16, KEY_POWER },
{ 0x17, KEY_FAVORITES },
{ 0x0f, KEY_TEXT },
@@ -785,8 +785,8 @@ static struct dvb_usb_device_properties megasky_properties = {
.download_firmware = m920x_firmware_download,
.rc_interval = 100,
- .rc_key_map = megasky_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(megasky_rc_keys),
+ .rc_key_map = ir_codes_megasky_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_megasky_table),
.rc_query = m920x_rc_query,
.size_of_priv = sizeof(struct m920x_state),
@@ -886,8 +886,8 @@ static struct dvb_usb_device_properties tvwalkertwin_properties = {
.download_firmware = m920x_firmware_download,
.rc_interval = 100,
- .rc_key_map = tvwalkertwin_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(tvwalkertwin_rc_keys),
+ .rc_key_map = ir_codes_tvwalkertwin_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_tvwalkertwin_table),
.rc_query = m920x_rc_query,
.size_of_priv = sizeof(struct m920x_state),
@@ -993,8 +993,8 @@ static struct dvb_usb_device_properties pinnacle_pctv310e_properties = {
.download_firmware = NULL,
.rc_interval = 100,
- .rc_key_map = pinnacle310e_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(pinnacle310e_rc_keys),
+ .rc_key_map = ir_codes_pinnacle310e_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_pinnacle310e_table),
.rc_query = m920x_rc_query,
.size_of_priv = sizeof(struct m920x_state),
diff --git a/drivers/media/dvb/dvb-usb/nova-t-usb2.c b/drivers/media/dvb/dvb-usb/nova-t-usb2.c
index b41d66e..d195a58 100644
--- a/drivers/media/dvb/dvb-usb/nova-t-usb2.c
+++ b/drivers/media/dvb/dvb-usb/nova-t-usb2.c
@@ -21,7 +21,7 @@ DVB_DEFINE_MOD_OPT_ADAPTER_NR(adapter_nr);
#define deb_ee(args...) dprintk(debug,0x02,args)
/* Hauppauge NOVA-T USB2 keys */
-static struct dvb_usb_rc_key haupp_rc_keys [] = {
+static struct dvb_usb_rc_key ir_codes_haupp_table [] = {
{ 0x1e00, KEY_0 },
{ 0x1e01, KEY_1 },
{ 0x1e02, KEY_2 },
@@ -91,14 +91,14 @@ static int nova_t_rc_query(struct dvb_usb_device *d, u32 *event, int *state)
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 < ARRAY_SIZE(haupp_rc_keys); i++) {
- if (rc5_data(&haupp_rc_keys[i]) == data &&
- rc5_custom(&haupp_rc_keys[i]) == custom) {
+ for (i = 0; i < ARRAY_SIZE(ir_codes_haupp_table); i++) {
+ if (rc5_data(&ir_codes_haupp_table[i]) == data &&
+ rc5_custom(&ir_codes_haupp_table[i]) == custom) {
- deb_rc("c: %x, d: %x\n", rc5_data(&haupp_rc_keys[i]),
- rc5_custom(&haupp_rc_keys[i]));
+ deb_rc("c: %x, d: %x\n", rc5_data(&ir_codes_haupp_table[i]),
+ rc5_custom(&ir_codes_haupp_table[i]));
- *event = haupp_rc_keys[i].event;
+ *event = ir_codes_haupp_table[i].event;
*state = REMOTE_KEY_PRESSED;
if (st->old_toggle == toggle) {
if (st->last_repeat_count++ < 2)
@@ -196,8 +196,8 @@ static struct dvb_usb_device_properties nova_t_properties = {
.read_mac_address = nova_t_read_mac_address,
.rc_interval = 100,
- .rc_key_map = haupp_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(haupp_rc_keys),
+ .rc_key_map = ir_codes_haupp_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_haupp_table),
.rc_query = nova_t_rc_query,
.i2c_algo = &dibusb_i2c_algo,
diff --git a/drivers/media/dvb/dvb-usb/opera1.c b/drivers/media/dvb/dvb-usb/opera1.c
index 8305576..dfb81ff 100644
--- a/drivers/media/dvb/dvb-usb/opera1.c
+++ b/drivers/media/dvb/dvb-usb/opera1.c
@@ -35,7 +35,7 @@
struct opera1_state {
u32 last_key_pressed;
};
-struct opera_rc_keys {
+struct ir_codes_opera_table {
u32 keycode;
u32 event;
};
@@ -331,7 +331,7 @@ static int opera1_pid_filter_control(struct dvb_usb_adapter *adap, int onoff)
return 0;
}
-static struct dvb_usb_rc_key opera1_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_opera1_table[] = {
{0x5fa0, KEY_1},
{0x51af, KEY_2},
{0x5da2, KEY_3},
@@ -404,12 +404,12 @@ static int opera1_rc_query(struct dvb_usb_device *dev, u32 * event, int *state)
send_key = (send_key & 0xffff) | 0x0100;
- for (i = 0; i < ARRAY_SIZE(opera1_rc_keys); i++) {
- if (rc5_scan(&opera1_rc_keys[i]) == (send_key & 0xffff)) {
+ for (i = 0; i < ARRAY_SIZE(ir_codes_opera1_table); i++) {
+ if (rc5_scan(&ir_codes_opera1_table[i]) == (send_key & 0xffff)) {
*state = REMOTE_KEY_PRESSED;
- *event = opera1_rc_keys[i].event;
+ *event = ir_codes_opera1_table[i].event;
opst->last_key_pressed =
- opera1_rc_keys[i].event;
+ ir_codes_opera1_table[i].event;
break;
}
opst->last_key_pressed = 0;
@@ -498,8 +498,8 @@ static struct dvb_usb_device_properties opera1_properties = {
.power_ctrl = opera1_power_ctrl,
.i2c_algo = &opera1_i2c_algo,
- .rc_key_map = opera1_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(opera1_rc_keys),
+ .rc_key_map = ir_codes_opera1_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_opera1_table),
.rc_interval = 200,
.rc_query = opera1_rc_query,
.read_mac_address = opera1_read_mac_address,
diff --git a/drivers/media/dvb/dvb-usb/vp702x.c b/drivers/media/dvb/dvb-usb/vp702x.c
index ef4e37d..4d33245 100644
--- a/drivers/media/dvb/dvb-usb/vp702x.c
+++ b/drivers/media/dvb/dvb-usb/vp702x.c
@@ -174,7 +174,7 @@ static int vp702x_streaming_ctrl(struct dvb_usb_adapter *adap, int onoff)
}
/* keys for the enclosed remote control */
-static struct dvb_usb_rc_key vp702x_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_vp702x_table[] = {
{ 0x0001, KEY_1 },
{ 0x0002, KEY_2 },
};
@@ -197,10 +197,10 @@ static int vp702x_rc_query(struct dvb_usb_device *d, u32 *event, int *state)
return 0;
}
- for (i = 0; i < ARRAY_SIZE(vp702x_rc_keys); i++)
- if (rc5_custom(&vp702x_rc_keys[i]) == key[1]) {
+ for (i = 0; i < ARRAY_SIZE(ir_codes_vp702x_table); i++)
+ if (rc5_custom(&ir_codes_vp702x_table[i]) == key[1]) {
*state = REMOTE_KEY_PRESSED;
- *event = vp702x_rc_keys[i].event;
+ *event = ir_codes_vp702x_table[i].event;
break;
}
return 0;
@@ -283,8 +283,8 @@ static struct dvb_usb_device_properties vp702x_properties = {
},
.read_mac_address = vp702x_read_mac_addr,
- .rc_key_map = vp702x_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(vp702x_rc_keys),
+ .rc_key_map = ir_codes_vp702x_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_vp702x_table),
.rc_interval = 400,
.rc_query = vp702x_rc_query,
diff --git a/drivers/media/dvb/dvb-usb/vp7045.c b/drivers/media/dvb/dvb-usb/vp7045.c
index a59faa2..036893f 100644
--- a/drivers/media/dvb/dvb-usb/vp7045.c
+++ b/drivers/media/dvb/dvb-usb/vp7045.c
@@ -99,7 +99,7 @@ static int vp7045_power_ctrl(struct dvb_usb_device *d, int onoff)
/* The keymapping struct. Somehow this should be loaded to the driver, but
* currently it is hardcoded. */
-static struct dvb_usb_rc_key vp7045_rc_keys[] = {
+static struct dvb_usb_rc_key ir_codes_vp7045_table[] = {
{ 0x0016, KEY_POWER },
{ 0x0010, KEY_MUTE },
{ 0x0003, KEY_1 },
@@ -165,10 +165,10 @@ static int vp7045_rc_query(struct dvb_usb_device *d, u32 *event, int *state)
return 0;
}
- for (i = 0; i < ARRAY_SIZE(vp7045_rc_keys); i++)
- if (rc5_data(&vp7045_rc_keys[i]) == key) {
+ for (i = 0; i < ARRAY_SIZE(ir_codes_vp7045_table); i++)
+ if (rc5_data(&ir_codes_vp7045_table[i]) == key) {
*state = REMOTE_KEY_PRESSED;
- *event = vp7045_rc_keys[i].event;
+ *event = ir_codes_vp7045_table[i].event;
break;
}
return 0;
@@ -260,8 +260,8 @@ static struct dvb_usb_device_properties vp7045_properties = {
.read_mac_address = vp7045_read_mac_addr,
.rc_interval = 400,
- .rc_key_map = vp7045_rc_keys,
- .rc_key_map_size = ARRAY_SIZE(vp7045_rc_keys),
+ .rc_key_map = ir_codes_vp7045_table,
+ .rc_key_map_size = ARRAY_SIZE(ir_codes_vp7045_table),
.rc_query = vp7045_rc_query,
.num_device_descs = 2,
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 09/26] V4L/DVB: ir: prepare IR code for a parameter change at register function
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (18 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 05/26] V4L/DVB: ir-common: Use macros to define the keytables Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 04/26] V4L/DVB: rename all *_rc_keys to ir_codes_*_nec_table Mauro Carvalho Chehab
` (5 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
A latter patch will reuse the ir_input_register with a different meaning.
Before it, change all occurrences to a temporary name.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/IR/ir-keytable.c b/drivers/media/IR/ir-keytable.c
index db54562..1d9c467 100644
--- a/drivers/media/IR/ir-keytable.c
+++ b/drivers/media/IR/ir-keytable.c
@@ -460,7 +460,7 @@ static void ir_close(struct input_dev *input_dev)
}
/**
- * ir_input_register() - sets the IR keycode table and add the handlers
+ * __ir_input_register() - sets the IR keycode table and add the handlers
* for keymap table get/set
* @input_dev: the struct input_dev descriptor of the device
* @rc_tab: the struct ir_scancode_table table of scancode/keymap
@@ -470,7 +470,7 @@ static void ir_close(struct input_dev *input_dev)
* It will register the input/evdev interface for the device and
* register the syfs code for IR class
*/
-int ir_input_register(struct input_dev *input_dev,
+int __ir_input_register(struct input_dev *input_dev,
const struct ir_scancode_table *rc_tab,
const struct ir_dev_props *props,
const char *driver_name)
@@ -538,7 +538,7 @@ err:
kfree(ir_dev);
return rc;
}
-EXPORT_SYMBOL_GPL(ir_input_register);
+EXPORT_SYMBOL_GPL(__ir_input_register);
/**
* ir_input_unregister() - unregisters IR and frees resources
diff --git a/drivers/media/dvb/dm1105/dm1105.c b/drivers/media/dvb/dm1105/dm1105.c
index 17003ed..3a67f30 100644
--- a/drivers/media/dvb/dm1105/dm1105.c
+++ b/drivers/media/dvb/dm1105/dm1105.c
@@ -629,7 +629,7 @@ int __devinit dm1105_ir_init(struct dm1105_dev *dm1105)
INIT_WORK(&dm1105->ir.work, dm1105_emit_key);
- err = ir_input_register(input_dev, ir_codes, NULL, MODULE_NAME);
+ err = __ir_input_register(input_dev, ir_codes, NULL, MODULE_NAME);
return err;
}
diff --git a/drivers/media/dvb/mantis/mantis_input.c b/drivers/media/dvb/mantis/mantis_input.c
index 6baf302..3d4e466 100644
--- a/drivers/media/dvb/mantis/mantis_input.c
+++ b/drivers/media/dvb/mantis/mantis_input.c
@@ -128,7 +128,7 @@ int mantis_input_init(struct mantis_pci *mantis)
rc->id.version = 1;
rc->dev = mantis->pdev->dev;
- err = ir_input_register(rc, &ir_mantis, NULL, MODULE_NAME);
+ err = __ir_input_register(rc, &ir_mantis, NULL, MODULE_NAME);
if (err) {
dprintk(MANTIS_ERROR, 1, "IR device registration failed, ret = %d", err);
input_free_device(rc);
diff --git a/drivers/media/dvb/ttpci/budget-ci.c b/drivers/media/dvb/ttpci/budget-ci.c
index 75c640e..ab7479a 100644
--- a/drivers/media/dvb/ttpci/budget-ci.c
+++ b/drivers/media/dvb/ttpci/budget-ci.c
@@ -256,7 +256,7 @@ static int msp430_ir_init(struct budget_ci *budget_ci)
budget_ci->ir.timer_keyup.function = msp430_ir_keyup;
budget_ci->ir.timer_keyup.data = (unsigned long) &budget_ci->ir;
budget_ci->ir.last_raw = 0xffff; /* An impossible value */
- error = ir_input_register(input_dev, ir_codes, NULL, MODULE_NAME);
+ error = __ir_input_register(input_dev, ir_codes, NULL, MODULE_NAME);
if (error) {
printk(KERN_ERR "budget_ci: could not init driver for IR device (code %d)\n", error);
return error;
diff --git a/drivers/media/video/bt8xx/bttv-input.c b/drivers/media/video/bt8xx/bttv-input.c
index d5d26e6..eae4925 100644
--- a/drivers/media/video/bt8xx/bttv-input.c
+++ b/drivers/media/video/bt8xx/bttv-input.c
@@ -391,7 +391,7 @@ int bttv_input_init(struct bttv *btv)
bttv_ir_start(btv, ir);
/* all done */
- err = ir_input_register(btv->remote->dev, ir_codes, NULL, MODULE_NAME);
+ err = __ir_input_register(btv->remote->dev, ir_codes, NULL, MODULE_NAME);
if (err)
goto err_out_stop;
diff --git a/drivers/media/video/cx231xx/cx231xx-input.c b/drivers/media/video/cx231xx/cx231xx-input.c
index 1cbfba1..dbd6218 100644
--- a/drivers/media/video/cx231xx/cx231xx-input.c
+++ b/drivers/media/video/cx231xx/cx231xx-input.c
@@ -218,7 +218,7 @@ int cx231xx_ir_init(struct cx231xx *dev)
cx231xx_ir_start(ir);
/* all done */
- err = ir_input_register(ir->input, dev->board.ir_codes,
+ err = __ir_input_register(ir->input, dev->board.ir_codes,
NULL, MODULE_NAME);
if (err)
goto err_out_stop;
diff --git a/drivers/media/video/cx23885/cx23885-input.c b/drivers/media/video/cx23885/cx23885-input.c
index c7e854d..5767d3e 100644
--- a/drivers/media/video/cx23885/cx23885-input.c
+++ b/drivers/media/video/cx23885/cx23885-input.c
@@ -399,7 +399,7 @@ int cx23885_input_init(struct cx23885_dev *dev)
dev->ir_input = ir;
cx23885_input_ir_start(dev);
- ret = ir_input_register(ir->dev, ir_codes, NULL, MODULE_NAME);
+ ret = __ir_input_register(ir->dev, ir_codes, NULL, MODULE_NAME);
if (ret)
goto err_out_stop;
diff --git a/drivers/media/video/cx88/cx88-input.c b/drivers/media/video/cx88/cx88-input.c
index b73b9e3..638e599 100644
--- a/drivers/media/video/cx88/cx88-input.c
+++ b/drivers/media/video/cx88/cx88-input.c
@@ -438,7 +438,7 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
ir->props.close = cx88_ir_close;
/* all done */
- err = ir_input_register(ir->input, ir_codes, &ir->props, MODULE_NAME);
+ err = __ir_input_register(ir->input, ir_codes, &ir->props, MODULE_NAME);
if (err)
goto err_out_free;
diff --git a/drivers/media/video/em28xx/em28xx-input.c b/drivers/media/video/em28xx/em28xx-input.c
index 5a1850a..c237c72 100644
--- a/drivers/media/video/em28xx/em28xx-input.c
+++ b/drivers/media/video/em28xx/em28xx-input.c
@@ -474,7 +474,7 @@ int em28xx_ir_init(struct em28xx *dev)
em28xx_ir_start(ir);
/* all done */
- err = ir_input_register(ir->input, dev->board.ir_codes,
+ err = __ir_input_register(ir->input, dev->board.ir_codes,
&ir->props, MODULE_NAME);
if (err)
goto err_out_stop;
diff --git a/drivers/media/video/ir-kbd-i2c.c b/drivers/media/video/ir-kbd-i2c.c
index 607a0be..e6ada5e 100644
--- a/drivers/media/video/ir-kbd-i2c.c
+++ b/drivers/media/video/ir-kbd-i2c.c
@@ -447,7 +447,7 @@ static int ir_probe(struct i2c_client *client, const struct i2c_device_id *id)
input_dev->name = ir->name;
input_dev->phys = ir->phys;
- err = ir_input_register(ir->input, ir->ir_codes, NULL, MODULE_NAME);
+ err = __ir_input_register(ir->input, ir->ir_codes, NULL, MODULE_NAME);
if (err)
goto err_out_free;
diff --git a/drivers/media/video/saa7134/saa7134-input.c b/drivers/media/video/saa7134/saa7134-input.c
index aac29a0..2a3cae9 100644
--- a/drivers/media/video/saa7134/saa7134-input.c
+++ b/drivers/media/video/saa7134/saa7134-input.c
@@ -877,7 +877,7 @@ int saa7134_input_init1(struct saa7134_dev *dev)
}
input_dev->dev.parent = &dev->pci->dev;
- err = ir_input_register(ir->dev, ir_codes, &ir->props, MODULE_NAME);
+ err = __ir_input_register(ir->dev, ir_codes, &ir->props, MODULE_NAME);
if (err)
goto err_out_free;
if (ir_codes->ir_type != IR_TYPE_OTHER) {
diff --git a/include/media/ir-core.h b/include/media/ir-core.h
index 39df3cf..8e975f2 100644
--- a/include/media/ir-core.h
+++ b/include/media/ir-core.h
@@ -119,23 +119,37 @@ EXPORT_SYMBOL_GPL(IR_KEYTABLE(tabname))
#define DEFINE_LEGACY_IR_KEYTABLE(tabname) \
DEFINE_IR_KEYTABLE(tabname, IR_TYPE_UNKNOWN)
+/* Routines from rc-map.c */
+
+int ir_register_map(struct rc_keymap *map);
+void ir_unregister_map(struct rc_keymap *map);
+struct ir_scancode_table *get_rc_map(const char *name);
+
/* Routines from ir-keytable.c */
u32 ir_g_keycode_from_table(struct input_dev *input_dev,
u32 scancode);
void ir_keyup(struct input_dev *dev);
void ir_keydown(struct input_dev *dev, int scancode);
-int ir_input_register(struct input_dev *dev,
+int __ir_input_register(struct input_dev *dev,
const struct ir_scancode_table *ir_codes,
const struct ir_dev_props *props,
const char *driver_name);
-void ir_input_unregister(struct input_dev *input_dev);
-/* Routines from rc-map.c */
+static inline int ir_input_register(struct input_dev *dev,
+ const char *map_name,
+ const struct ir_dev_props *props,
+ const char *driver_name) {
+ struct ir_scancode_table *ir_codes;
-int ir_register_map(struct rc_keymap *map);
-void ir_unregister_map(struct rc_keymap *map);
-struct ir_scancode_table *get_rc_map(const char *name);
+ ir_codes = get_rc_map(map_name);
+ if (!ir_codes)
+ return -EINVAL;
+
+ return __ir_input_register(dev, ir_codes, props, driver_name);
+}
+
+ void ir_input_unregister(struct input_dev *input_dev);
/* Routines from ir-sysfs.c */
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 03/26] V4L/DVB: IR: use IR_KEYTABLE where an IR table is needed
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (22 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 01/26] V4L/DVB: ir-common: Use a function to declare an IR table Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 02/26] V4L/DVB: ir-common: re-order keytables by name and remove duplicates Mauro Carvalho Chehab
2010-04-06 19:13 ` [PATCH 16/26] V4L/DVB: ir-core: improve keyup/keydown logic Mauro Carvalho Chehab
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
Replaces most of the occurences of IR keytables on V4L drivers by a macro
that evaluates to provide the name of the exported symbol.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/dvb/dm1105/dm1105.c b/drivers/media/dvb/dm1105/dm1105.c
index f1721e9..17003ed 100644
--- a/drivers/media/dvb/dm1105/dm1105.c
+++ b/drivers/media/dvb/dm1105/dm1105.c
@@ -595,7 +595,7 @@ static irqreturn_t dm1105_irq(int irq, void *dev_id)
int __devinit dm1105_ir_init(struct dm1105_dev *dm1105)
{
struct input_dev *input_dev;
- struct ir_scancode_table *ir_codes = &ir_codes_dm1105_nec_table;
+ struct ir_scancode_table *ir_codes = &IR_KEYTABLE(dm1105_nec);
u64 ir_type = IR_TYPE_OTHER;
int err = -ENOMEM;
diff --git a/drivers/media/dvb/ttpci/budget-ci.c b/drivers/media/dvb/ttpci/budget-ci.c
index ec89afd..75c640e 100644
--- a/drivers/media/dvb/ttpci/budget-ci.c
+++ b/drivers/media/dvb/ttpci/budget-ci.c
@@ -232,7 +232,7 @@ static int msp430_ir_init(struct budget_ci *budget_ci)
case 0x1011:
case 0x1012:
/* The hauppauge keymap is a superset of these remotes */
- ir_codes = &ir_codes_hauppauge_new_table;
+ ir_codes = &IR_KEYTABLE(hauppauge_new);
if (rc5_device < 0)
budget_ci->ir.rc5_device = 0x1f;
@@ -241,11 +241,11 @@ static int msp430_ir_init(struct budget_ci *budget_ci)
case 0x1017:
case 0x101a:
/* for the Technotrend 1500 bundled remote */
- ir_codes = &ir_codes_tt_1500_table;
+ ir_codes = &IR_KEYTABLE(tt_1500);
break;
default:
/* unknown remote */
- ir_codes = &ir_codes_budget_ci_old_table;
+ ir_codes = &IR_KEYTABLE(budget_ci_old);
break;
}
diff --git a/drivers/media/video/bt8xx/bttv-input.c b/drivers/media/video/bt8xx/bttv-input.c
index 6c11687..d5d26e6 100644
--- a/drivers/media/video/bt8xx/bttv-input.c
+++ b/drivers/media/video/bt8xx/bttv-input.c
@@ -265,7 +265,7 @@ int bttv_input_init(struct bttv *btv)
case BTTV_BOARD_AVERMEDIA:
case BTTV_BOARD_AVPHONE98:
case BTTV_BOARD_AVERMEDIA98:
- ir_codes = &ir_codes_avermedia_table;
+ ir_codes = &IR_KEYTABLE(avermedia);
ir->mask_keycode = 0xf88000;
ir->mask_keydown = 0x010000;
ir->polling = 50; // ms
@@ -273,14 +273,14 @@ int bttv_input_init(struct bttv *btv)
case BTTV_BOARD_AVDVBT_761:
case BTTV_BOARD_AVDVBT_771:
- ir_codes = &ir_codes_avermedia_dvbt_table;
+ ir_codes = &IR_KEYTABLE(avermedia_dvbt);
ir->mask_keycode = 0x0f00c0;
ir->mask_keydown = 0x000020;
ir->polling = 50; // ms
break;
case BTTV_BOARD_PXELVWPLTVPAK:
- ir_codes = &ir_codes_pixelview_table;
+ ir_codes = &IR_KEYTABLE(pixelview);
ir->mask_keycode = 0x003e00;
ir->mask_keyup = 0x010000;
ir->polling = 50; // ms
@@ -288,24 +288,24 @@ int bttv_input_init(struct bttv *btv)
case BTTV_BOARD_PV_M4900:
case BTTV_BOARD_PV_BT878P_9B:
case BTTV_BOARD_PV_BT878P_PLUS:
- ir_codes = &ir_codes_pixelview_table;
+ ir_codes = &IR_KEYTABLE(pixelview);
ir->mask_keycode = 0x001f00;
ir->mask_keyup = 0x008000;
ir->polling = 50; // ms
break;
case BTTV_BOARD_WINFAST2000:
- ir_codes = &ir_codes_winfast_table;
+ ir_codes = &IR_KEYTABLE(winfast);
ir->mask_keycode = 0x1f8;
break;
case BTTV_BOARD_MAGICTVIEW061:
case BTTV_BOARD_MAGICTVIEW063:
- ir_codes = &ir_codes_winfast_table;
+ ir_codes = &IR_KEYTABLE(winfast);
ir->mask_keycode = 0x0008e000;
ir->mask_keydown = 0x00200000;
break;
case BTTV_BOARD_APAC_VIEWCOMP:
- ir_codes = &ir_codes_apac_viewcomp_table;
+ ir_codes = &IR_KEYTABLE(apac_viewcomp);
ir->mask_keycode = 0x001f00;
ir->mask_keyup = 0x008000;
ir->polling = 50; // ms
@@ -313,30 +313,30 @@ int bttv_input_init(struct bttv *btv)
case BTTV_BOARD_ASKEY_CPH03X:
case BTTV_BOARD_CONCEPTRONIC_CTVFMI2:
case BTTV_BOARD_CONTVFMI:
- ir_codes = &ir_codes_pixelview_table;
+ ir_codes = &IR_KEYTABLE(pixelview);
ir->mask_keycode = 0x001F00;
ir->mask_keyup = 0x006000;
ir->polling = 50; // ms
break;
case BTTV_BOARD_NEBULA_DIGITV:
- ir_codes = &ir_codes_nebula_table;
+ ir_codes = &IR_KEYTABLE(nebula);
btv->custom_irq = bttv_rc5_irq;
ir->rc5_gpio = 1;
break;
case BTTV_BOARD_MACHTV_MAGICTV:
- ir_codes = &ir_codes_apac_viewcomp_table;
+ ir_codes = &IR_KEYTABLE(apac_viewcomp);
ir->mask_keycode = 0x001F00;
ir->mask_keyup = 0x004000;
ir->polling = 50; /* ms */
break;
case BTTV_BOARD_KOZUMI_KTV_01C:
- ir_codes = &ir_codes_pctv_sedna_table;
+ ir_codes = &IR_KEYTABLE(pctv_sedna);
ir->mask_keycode = 0x001f00;
ir->mask_keyup = 0x006000;
ir->polling = 50; /* ms */
break;
case BTTV_BOARD_ENLTV_FM_2:
- ir_codes = &ir_codes_encore_enltv2_table;
+ ir_codes = &IR_KEYTABLE(encore_enltv2);
ir->mask_keycode = 0x00fd00;
ir->mask_keyup = 0x000080;
ir->polling = 1; /* ms */
diff --git a/drivers/media/video/cx18/cx18-i2c.c b/drivers/media/video/cx18/cx18-i2c.c
index eecf29a..476c016 100644
--- a/drivers/media/video/cx18/cx18-i2c.c
+++ b/drivers/media/video/cx18/cx18-i2c.c
@@ -109,7 +109,7 @@ static int cx18_i2c_new_ir(struct cx18 *cx, struct i2c_adapter *adap, u32 hw,
/* Our default information for ir-kbd-i2c.c to use */
switch (hw) {
case CX18_HW_Z8F0811_IR_RX_HAUP:
- init_data->ir_codes = &ir_codes_hauppauge_new_table;
+ init_data->ir_codes = &IR_KEYTABLE(hauppauge_new);
init_data->internal_get_key_func = IR_KBD_GET_KEY_HAUP_XVR;
init_data->type = IR_TYPE_RC5;
init_data->name = cx->card_name;
diff --git a/drivers/media/video/cx23885/cx23885-input.c b/drivers/media/video/cx23885/cx23885-input.c
index 2e6c023..c7e854d 100644
--- a/drivers/media/video/cx23885/cx23885-input.c
+++ b/drivers/media/video/cx23885/cx23885-input.c
@@ -354,7 +354,7 @@ int cx23885_input_init(struct cx23885_dev *dev)
case CX23885_BOARD_HAUPPAUGE_HVR1850:
case CX23885_BOARD_HAUPPAUGE_HVR1290:
/* Parameters for the grey Hauppauge remote for the HVR-1850 */
- ir_codes = &ir_codes_hauppauge_new_table;
+ ir_codes = &IR_KEYTABLE(hauppauge_new);
ir_type = IR_TYPE_RC5;
ir_addr = 0x1e; /* RC-5 system bits emitted by the remote */
ir_start = RC5_START_BITS_NORMAL; /* A basic RC-5 remote */
diff --git a/drivers/media/video/cx88/cx88-input.c b/drivers/media/video/cx88/cx88-input.c
index a7214d0..b73b9e3 100644
--- a/drivers/media/video/cx88/cx88-input.c
+++ b/drivers/media/video/cx88/cx88-input.c
@@ -260,14 +260,14 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
case CX88_BOARD_DNTV_LIVE_DVB_T:
case CX88_BOARD_KWORLD_DVB_T:
case CX88_BOARD_KWORLD_DVB_T_CX22702:
- ir_codes = &ir_codes_dntv_live_dvb_t_table;
+ ir_codes = &IR_KEYTABLE(dntv_live_dvb_t);
ir->gpio_addr = MO_GP1_IO;
ir->mask_keycode = 0x1f;
ir->mask_keyup = 0x60;
ir->polling = 50; /* ms */
break;
case CX88_BOARD_TERRATEC_CINERGY_1400_DVB_T1:
- ir_codes = &ir_codes_cinergy_1400_table;
+ ir_codes = &IR_KEYTABLE(cinergy_1400);
ir_type = IR_TYPE_PD;
ir->sampling = 0xeb04; /* address */
break;
@@ -282,14 +282,14 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
case CX88_BOARD_PCHDTV_HD3000:
case CX88_BOARD_PCHDTV_HD5500:
case CX88_BOARD_HAUPPAUGE_IRONLY:
- ir_codes = &ir_codes_hauppauge_new_table;
+ ir_codes = &IR_KEYTABLE(hauppauge_new);
ir_type = IR_TYPE_RC5;
ir->sampling = 1;
break;
case CX88_BOARD_WINFAST_DTV2000H:
case CX88_BOARD_WINFAST_DTV2000H_J:
case CX88_BOARD_WINFAST_DTV1800H:
- ir_codes = &ir_codes_winfast_table;
+ ir_codes = &IR_KEYTABLE(winfast);
ir->gpio_addr = MO_GP0_IO;
ir->mask_keycode = 0x8f8;
ir->mask_keyup = 0x100;
@@ -298,14 +298,14 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
case CX88_BOARD_WINFAST2000XP_EXPERT:
case CX88_BOARD_WINFAST_DTV1000:
case CX88_BOARD_WINFAST_TV2000_XP_GLOBAL:
- ir_codes = &ir_codes_winfast_table;
+ ir_codes = &IR_KEYTABLE(winfast);
ir->gpio_addr = MO_GP0_IO;
ir->mask_keycode = 0x8f8;
ir->mask_keyup = 0x100;
ir->polling = 1; /* ms */
break;
case CX88_BOARD_IODATA_GVBCTV7E:
- ir_codes = &ir_codes_iodata_bctv7e_table;
+ ir_codes = &IR_KEYTABLE(iodata_bctv7e);
ir->gpio_addr = MO_GP0_IO;
ir->mask_keycode = 0xfd;
ir->mask_keydown = 0x02;
@@ -313,7 +313,7 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
break;
case CX88_BOARD_PROLINK_PLAYTVPVR:
case CX88_BOARD_PIXELVIEW_PLAYTV_ULTRA_PRO:
- ir_codes = &ir_codes_pixelview_table;
+ ir_codes = &IR_KEYTABLE(pixelview);
ir->gpio_addr = MO_GP1_IO;
ir->mask_keycode = 0x1f;
ir->mask_keyup = 0x80;
@@ -321,28 +321,28 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
break;
case CX88_BOARD_PROLINK_PV_8000GT:
case CX88_BOARD_PROLINK_PV_GLOBAL_XTREME:
- ir_codes = &ir_codes_pixelview_new_table;
+ ir_codes = &IR_KEYTABLE(pixelview_new);
ir->gpio_addr = MO_GP1_IO;
ir->mask_keycode = 0x3f;
ir->mask_keyup = 0x80;
ir->polling = 1; /* ms */
break;
case CX88_BOARD_KWORLD_LTV883:
- ir_codes = &ir_codes_pixelview_table;
+ ir_codes = &IR_KEYTABLE(pixelview);
ir->gpio_addr = MO_GP1_IO;
ir->mask_keycode = 0x1f;
ir->mask_keyup = 0x60;
ir->polling = 1; /* ms */
break;
case CX88_BOARD_ADSTECH_DVB_T_PCI:
- ir_codes = &ir_codes_adstech_dvb_t_pci_table;
+ ir_codes = &IR_KEYTABLE(adstech_dvb_t_pci);
ir->gpio_addr = MO_GP1_IO;
ir->mask_keycode = 0xbf;
ir->mask_keyup = 0x40;
ir->polling = 50; /* ms */
break;
case CX88_BOARD_MSI_TVANYWHERE_MASTER:
- ir_codes = &ir_codes_msi_tvanywhere_table;
+ ir_codes = &IR_KEYTABLE(msi_tvanywhere);
ir->gpio_addr = MO_GP1_IO;
ir->mask_keycode = 0x1f;
ir->mask_keyup = 0x40;
@@ -350,7 +350,7 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
break;
case CX88_BOARD_AVERTV_303:
case CX88_BOARD_AVERTV_STUDIO_303:
- ir_codes = &ir_codes_avertv_303_table;
+ ir_codes = &IR_KEYTABLE(avertv_303);
ir->gpio_addr = MO_GP2_IO;
ir->mask_keycode = 0xfb;
ir->mask_keydown = 0x02;
@@ -363,41 +363,41 @@ int cx88_ir_init(struct cx88_core *core, struct pci_dev *pci)
case CX88_BOARD_PROF_7300:
case CX88_BOARD_PROF_7301:
case CX88_BOARD_PROF_6200:
- ir_codes = &ir_codes_tbs_nec_table;
+ ir_codes = &IR_KEYTABLE(tbs_nec);
ir_type = IR_TYPE_PD;
ir->sampling = 0xff00; /* address */
break;
case CX88_BOARD_TEVII_S460:
case CX88_BOARD_TEVII_S420:
- ir_codes = &ir_codes_tevii_nec_table;
+ ir_codes = &IR_KEYTABLE(tevii_nec);
ir_type = IR_TYPE_PD;
ir->sampling = 0xff00; /* address */
break;
case CX88_BOARD_DNTV_LIVE_DVB_T_PRO:
- ir_codes = &ir_codes_dntv_live_dvbt_pro_table;
+ ir_codes = &IR_KEYTABLE(dntv_live_dvbt_pro);
ir_type = IR_TYPE_PD;
ir->sampling = 0xff00; /* address */
break;
case CX88_BOARD_NORWOOD_MICRO:
- ir_codes = &ir_codes_norwood_table;
+ ir_codes = &IR_KEYTABLE(norwood);
ir->gpio_addr = MO_GP1_IO;
ir->mask_keycode = 0x0e;
ir->mask_keyup = 0x80;
ir->polling = 50; /* ms */
break;
case CX88_BOARD_NPGTECH_REALTV_TOP10FM:
- ir_codes = &ir_codes_npgtech_table;
+ ir_codes = &IR_KEYTABLE(npgtech);
ir->gpio_addr = MO_GP0_IO;
ir->mask_keycode = 0xfa;
ir->polling = 50; /* ms */
break;
case CX88_BOARD_PINNACLE_PCTV_HD_800i:
- ir_codes = &ir_codes_pinnacle_pctv_hd_table;
+ ir_codes = &IR_KEYTABLE(pinnacle_pctv_hd);
ir_type = IR_TYPE_RC5;
ir->sampling = 1;
break;
case CX88_BOARD_POWERCOLOR_REAL_ANGEL:
- ir_codes = &ir_codes_powercolor_real_angel_table;
+ ir_codes = &IR_KEYTABLE(powercolor_real_angel);
ir->gpio_addr = MO_GP2_IO;
ir->mask_keycode = 0x7e;
ir->polling = 100; /* ms */
diff --git a/drivers/media/video/em28xx/em28xx-cards.c b/drivers/media/video/em28xx/em28xx-cards.c
index 92a28b8..55fcc2e 100644
--- a/drivers/media/video/em28xx/em28xx-cards.c
+++ b/drivers/media/video/em28xx/em28xx-cards.c
@@ -601,7 +601,7 @@ struct em28xx_board em28xx_boards[] = {
.name = "Gadmei UTV330+",
.tuner_type = TUNER_TNF_5335MF,
.tda9887_conf = TDA9887_PRESENT,
- .ir_codes = &ir_codes_gadmei_rm008z_table,
+ .ir_codes = &IR_KEYTABLE(gadmei_rm008z),
.decoder = EM28XX_SAA711X,
.xclk = EM28XX_XCLK_FREQUENCY_12MHZ,
.input = { {
@@ -790,7 +790,7 @@ struct em28xx_board em28xx_boards[] = {
.mts_firmware = 1,
.has_dvb = 1,
.dvb_gpio = hauppauge_wintv_hvr_900_digital,
- .ir_codes = &ir_codes_hauppauge_new_table,
+ .ir_codes = &IR_KEYTABLE(hauppauge_new),
.decoder = EM28XX_TVP5150,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -815,7 +815,7 @@ struct em28xx_board em28xx_boards[] = {
.tuner_type = TUNER_XC2028,
.tuner_gpio = default_tuner_gpio,
.mts_firmware = 1,
- .ir_codes = &ir_codes_hauppauge_new_table,
+ .ir_codes = &IR_KEYTABLE(hauppauge_new),
.decoder = EM28XX_TVP5150,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -841,7 +841,7 @@ struct em28xx_board em28xx_boards[] = {
.mts_firmware = 1,
.has_dvb = 1,
.dvb_gpio = hauppauge_wintv_hvr_900_digital,
- .ir_codes = &ir_codes_hauppauge_new_table,
+ .ir_codes = &IR_KEYTABLE(hauppauge_new),
.decoder = EM28XX_TVP5150,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -867,7 +867,7 @@ struct em28xx_board em28xx_boards[] = {
.mts_firmware = 1,
.has_dvb = 1,
.dvb_gpio = hauppauge_wintv_hvr_900_digital,
- .ir_codes = &ir_codes_rc5_hauppauge_new_table,
+ .ir_codes = &IR_KEYTABLE(rc5_hauppauge_new),
.decoder = EM28XX_TVP5150,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -893,7 +893,7 @@ struct em28xx_board em28xx_boards[] = {
.mts_firmware = 1,
.has_dvb = 1,
.dvb_gpio = hauppauge_wintv_hvr_900_digital,
- .ir_codes = &ir_codes_pinnacle_pctv_hd_table,
+ .ir_codes = &IR_KEYTABLE(pinnacle_pctv_hd),
.decoder = EM28XX_TVP5150,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -919,7 +919,7 @@ struct em28xx_board em28xx_boards[] = {
.mts_firmware = 1,
.has_dvb = 1,
.dvb_gpio = hauppauge_wintv_hvr_900_digital,
- .ir_codes = &ir_codes_ati_tv_wonder_hd_600_table,
+ .ir_codes = &IR_KEYTABLE(ati_tv_wonder_hd_600),
.decoder = EM28XX_TVP5150,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -945,7 +945,7 @@ struct em28xx_board em28xx_boards[] = {
.decoder = EM28XX_TVP5150,
.has_dvb = 1,
.dvb_gpio = default_digital,
- .ir_codes = &ir_codes_terratec_cinergy_xs_table,
+ .ir_codes = &IR_KEYTABLE(terratec_cinergy_xs),
.xclk = EM28XX_XCLK_FREQUENCY_12MHZ, /* NEC IR */
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -1295,7 +1295,7 @@ struct em28xx_board em28xx_boards[] = {
.decoder = EM28XX_SAA711X,
.has_dvb = 1,
.dvb_gpio = em2882_kworld_315u_digital,
- .ir_codes = &ir_codes_kworld_315u_table,
+ .ir_codes = &IR_KEYTABLE(kworld_315u),
.xclk = EM28XX_XCLK_FREQUENCY_12MHZ,
.i2c_speed = EM28XX_I2C_CLK_WAIT_ENABLE,
/* Analog mode - still not ready */
@@ -1424,7 +1424,7 @@ struct em28xx_board em28xx_boards[] = {
.has_dvb = 1,
.dvb_gpio = kworld_330u_digital,
.xclk = EM28XX_XCLK_FREQUENCY_12MHZ, /* NEC IR */
- .ir_codes = &ir_codes_kworld_315u_table,
+ .ir_codes = &IR_KEYTABLE(kworld_315u),
.input = { {
.type = EM28XX_VMUX_TELEVISION,
.vmux = TVP5150_COMPOSITE0,
@@ -1447,7 +1447,7 @@ struct em28xx_board em28xx_boards[] = {
.decoder = EM28XX_TVP5150,
.has_dvb = 1,
.dvb_gpio = hauppauge_wintv_hvr_900_digital,
- .ir_codes = &ir_codes_terratec_cinergy_xs_table,
+ .ir_codes = &IR_KEYTABLE(terratec_cinergy_xs),
.xclk = EM28XX_XCLK_FREQUENCY_12MHZ,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
@@ -1540,7 +1540,7 @@ struct em28xx_board em28xx_boards[] = {
.mts_firmware = 1,
.decoder = EM28XX_TVP5150,
.tuner_gpio = default_tuner_gpio,
- .ir_codes = &ir_codes_kaiomy_table,
+ .ir_codes = &IR_KEYTABLE(kaiomy),
.input = { {
.type = EM28XX_VMUX_TELEVISION,
.vmux = TVP5150_COMPOSITE0,
@@ -1640,7 +1640,7 @@ struct em28xx_board em28xx_boards[] = {
.mts_firmware = 1,
.has_dvb = 1,
.dvb_gpio = evga_indtube_digital,
- .ir_codes = &ir_codes_evga_indtube_table,
+ .ir_codes = &IR_KEYTABLE(evga_indtube),
.input = { {
.type = EM28XX_VMUX_TELEVISION,
.vmux = TVP5150_COMPOSITE0,
@@ -2334,21 +2334,21 @@ void em28xx_register_i2c_ir(struct em28xx *dev)
switch (dev->model) {
case EM2800_BOARD_TERRATEC_CINERGY_200:
case EM2820_BOARD_TERRATEC_CINERGY_250:
- dev->init_data.ir_codes = &ir_codes_em_terratec_table;
+ dev->init_data.ir_codes = &IR_KEYTABLE(em_terratec);
dev->init_data.get_key = em28xx_get_key_terratec;
dev->init_data.name = "i2c IR (EM28XX Terratec)";
break;
case EM2820_BOARD_PINNACLE_USB_2:
- dev->init_data.ir_codes = &ir_codes_pinnacle_grey_table;
+ dev->init_data.ir_codes = &IR_KEYTABLE(pinnacle_grey);
dev->init_data.get_key = em28xx_get_key_pinnacle_usb_grey;
dev->init_data.name = "i2c IR (EM28XX Pinnacle PCTV)";
break;
case EM2820_BOARD_HAUPPAUGE_WINTV_USB_2:
- dev->init_data.ir_codes = &ir_codes_rc5_hauppauge_new_table;
+ dev->init_data.ir_codes = &IR_KEYTABLE(rc5_hauppauge_new);
dev->init_data.get_key = em28xx_get_key_em_haup;
dev->init_data.name = "i2c IR (EM2840 Hauppauge)";
case EM2820_BOARD_LEADTEK_WINFAST_USBII_DELUXE:
- dev->init_data.ir_codes = &ir_codes_winfast_usbii_deluxe_table;;
+ dev->init_data.ir_codes = &IR_KEYTABLE(winfast_usbii_deluxe);;
dev->init_data.get_key = em28xx_get_key_winfast_usbii_deluxe;
dev->init_data.name = "i2c IR (EM2820 Winfast TV USBII Deluxe)";
break;
diff --git a/drivers/media/video/ir-kbd-i2c.c b/drivers/media/video/ir-kbd-i2c.c
index 6af69d5..607a0be 100644
--- a/drivers/media/video/ir-kbd-i2c.c
+++ b/drivers/media/video/ir-kbd-i2c.c
@@ -322,13 +322,13 @@ static int ir_probe(struct i2c_client *client, const struct i2c_device_id *id)
name = "Pixelview";
ir->get_key = get_key_pixelview;
ir_type = IR_TYPE_OTHER;
- ir_codes = &ir_codes_empty_table;
+ ir_codes = &IR_KEYTABLE(empty);
break;
case 0x4b:
name = "PV951";
ir->get_key = get_key_pv951;
ir_type = IR_TYPE_OTHER;
- ir_codes = &ir_codes_pv951_table;
+ ir_codes = &IR_KEYTABLE(pv951);
break;
case 0x18:
case 0x1f:
@@ -337,22 +337,22 @@ static int ir_probe(struct i2c_client *client, const struct i2c_device_id *id)
ir->get_key = get_key_haup;
ir_type = IR_TYPE_RC5;
if (hauppauge == 1) {
- ir_codes = &ir_codes_hauppauge_new_table;
+ ir_codes = &IR_KEYTABLE(hauppauge_new);
} else {
- ir_codes = &ir_codes_rc5_tv_table;
+ ir_codes = &IR_KEYTABLE(rc5_tv);
}
break;
case 0x30:
name = "KNC One";
ir->get_key = get_key_knc1;
ir_type = IR_TYPE_OTHER;
- ir_codes = &ir_codes_empty_table;
+ ir_codes = &IR_KEYTABLE(empty);
break;
case 0x6b:
name = "FusionHDTV";
ir->get_key = get_key_fusionhdtv;
ir_type = IR_TYPE_RC5;
- ir_codes = &ir_codes_fusionhdtv_mce_table;
+ ir_codes = &IR_KEYTABLE(fusionhdtv_mce);
break;
case 0x0b:
case 0x47:
@@ -365,9 +365,9 @@ static int ir_probe(struct i2c_client *client, const struct i2c_device_id *id)
ir_type = IR_TYPE_RC5;
ir->get_key = get_key_haup_xvr;
if (hauppauge == 1) {
- ir_codes = &ir_codes_hauppauge_new_table;
+ ir_codes = &IR_KEYTABLE(hauppauge_new);
} else {
- ir_codes = &ir_codes_rc5_tv_table;
+ ir_codes = &IR_KEYTABLE(rc5_tv);
}
} else {
/* Handled by saa7134-input */
@@ -379,7 +379,7 @@ static int ir_probe(struct i2c_client *client, const struct i2c_device_id *id)
name = "AVerMedia Cardbus remote";
ir->get_key = get_key_avermedia_cardbus;
ir_type = IR_TYPE_OTHER;
- ir_codes = &ir_codes_avermedia_cardbus_table;
+ ir_codes = &IR_KEYTABLE(avermedia_cardbus);
break;
}
diff --git a/drivers/media/video/ivtv/ivtv-i2c.c b/drivers/media/video/ivtv/ivtv-i2c.c
index 2ee03c2..a363e33 100644
--- a/drivers/media/video/ivtv/ivtv-i2c.c
+++ b/drivers/media/video/ivtv/ivtv-i2c.c
@@ -193,7 +193,7 @@ static int ivtv_i2c_new_ir(struct ivtv *itv, u32 hw, const char *type, u8 addr)
/* Our default information for ir-kbd-i2c.c to use */
switch (hw) {
case IVTV_HW_I2C_IR_RX_AVER:
- init_data->ir_codes = &ir_codes_avermedia_cardbus_table;
+ init_data->ir_codes = &IR_KEYTABLE(avermedia_cardbus);
init_data->internal_get_key_func =
IR_KBD_GET_KEY_AVERMEDIA_CARDBUS;
init_data->type = IR_TYPE_OTHER;
@@ -202,14 +202,14 @@ static int ivtv_i2c_new_ir(struct ivtv *itv, u32 hw, const char *type, u8 addr)
case IVTV_HW_I2C_IR_RX_HAUP_EXT:
case IVTV_HW_I2C_IR_RX_HAUP_INT:
/* Default to old black remote */
- init_data->ir_codes = &ir_codes_rc5_tv_table;
+ init_data->ir_codes = &IR_KEYTABLE(rc5_tv);
init_data->internal_get_key_func = IR_KBD_GET_KEY_HAUP;
init_data->type = IR_TYPE_RC5;
init_data->name = itv->card_name;
break;
case IVTV_HW_Z8F0811_IR_RX_HAUP:
/* Default to grey remote */
- init_data->ir_codes = &ir_codes_hauppauge_new_table;
+ init_data->ir_codes = &IR_KEYTABLE(hauppauge_new);
init_data->internal_get_key_func = IR_KBD_GET_KEY_HAUP_XVR;
init_data->type = IR_TYPE_RC5;
init_data->name = itv->card_name;
diff --git a/drivers/media/video/saa7134/saa7134-input.c b/drivers/media/video/saa7134/saa7134-input.c
index 9e2b32c..aac29a0 100644
--- a/drivers/media/video/saa7134/saa7134-input.c
+++ b/drivers/media/video/saa7134/saa7134-input.c
@@ -610,27 +610,27 @@ int saa7134_input_init1(struct saa7134_dev *dev)
case SAA7134_BOARD_FLYTVPLATINUM_FM:
case SAA7134_BOARD_FLYTVPLATINUM_MINI2:
case SAA7134_BOARD_ROVERMEDIA_LINK_PRO_FM:
- ir_codes = &ir_codes_flyvideo_table;
+ ir_codes = &IR_KEYTABLE(flyvideo);
mask_keycode = 0xEC00000;
mask_keydown = 0x0040000;
break;
case SAA7134_BOARD_CINERGY400:
case SAA7134_BOARD_CINERGY600:
case SAA7134_BOARD_CINERGY600_MK3:
- ir_codes = &ir_codes_cinergy_table;
+ ir_codes = &IR_KEYTABLE(cinergy);
mask_keycode = 0x00003f;
mask_keyup = 0x040000;
break;
case SAA7134_BOARD_ECS_TVP3XP:
case SAA7134_BOARD_ECS_TVP3XP_4CB5:
- ir_codes = &ir_codes_eztv_table;
+ ir_codes = &IR_KEYTABLE(eztv);
mask_keycode = 0x00017c;
mask_keyup = 0x000002;
polling = 50; // ms
break;
case SAA7134_BOARD_KWORLD_XPERT:
case SAA7134_BOARD_AVACSSMARTTV:
- ir_codes = &ir_codes_pixelview_table;
+ ir_codes = &IR_KEYTABLE(pixelview);
mask_keycode = 0x00001F;
mask_keyup = 0x000020;
polling = 50; // ms
@@ -647,7 +647,7 @@ int saa7134_input_init1(struct saa7134_dev *dev)
case SAA7134_BOARD_AVERMEDIA_GO_007_FM:
case SAA7134_BOARD_AVERMEDIA_M102:
case SAA7134_BOARD_AVERMEDIA_GO_007_FM_PLUS:
- ir_codes = &ir_codes_avermedia_table;
+ ir_codes = &IR_KEYTABLE(avermedia);
mask_keycode = 0x0007C8;
mask_keydown = 0x000010;
polling = 50; // ms
@@ -656,14 +656,14 @@ int saa7134_input_init1(struct saa7134_dev *dev)
saa_setb(SAA7134_GPIO_GPSTATUS0, 0x4);
break;
case SAA7134_BOARD_AVERMEDIA_M135A:
- ir_codes = &ir_codes_avermedia_m135a_rm_jx_table;
+ ir_codes = &IR_KEYTABLE(avermedia_m135a_rm_jx);
mask_keydown = 0x0040000;
mask_keycode = 0xffff;
raw_decode = 1;
break;
case SAA7134_BOARD_AVERMEDIA_777:
case SAA7134_BOARD_AVERMEDIA_A16AR:
- ir_codes = &ir_codes_avermedia_table;
+ ir_codes = &IR_KEYTABLE(avermedia);
mask_keycode = 0x02F200;
mask_keydown = 0x000400;
polling = 50; // ms
@@ -672,7 +672,7 @@ int saa7134_input_init1(struct saa7134_dev *dev)
saa_setb(SAA7134_GPIO_GPSTATUS1, 0x1);
break;
case SAA7134_BOARD_AVERMEDIA_A16D:
- ir_codes = &ir_codes_avermedia_a16d_table;
+ ir_codes = &IR_KEYTABLE(avermedia_a16d);
mask_keycode = 0x02F200;
mask_keydown = 0x000400;
polling = 50; /* ms */
@@ -681,14 +681,14 @@ int saa7134_input_init1(struct saa7134_dev *dev)
saa_setb(SAA7134_GPIO_GPSTATUS1, 0x1);
break;
case SAA7134_BOARD_KWORLD_TERMINATOR:
- ir_codes = &ir_codes_pixelview_table;
+ ir_codes = &IR_KEYTABLE(pixelview);
mask_keycode = 0x00001f;
mask_keyup = 0x000060;
polling = 50; // ms
break;
case SAA7134_BOARD_MANLI_MTV001:
case SAA7134_BOARD_MANLI_MTV002:
- ir_codes = &ir_codes_manli_table;
+ ir_codes = &IR_KEYTABLE(manli);
mask_keycode = 0x001f00;
mask_keyup = 0x004000;
polling = 50; /* ms */
@@ -708,25 +708,25 @@ int saa7134_input_init1(struct saa7134_dev *dev)
case SAA7134_BOARD_BEHOLD_507_9FM:
case SAA7134_BOARD_BEHOLD_507RDS_MK3:
case SAA7134_BOARD_BEHOLD_507RDS_MK5:
- ir_codes = &ir_codes_manli_table;
+ ir_codes = &IR_KEYTABLE(manli);
mask_keycode = 0x003f00;
mask_keyup = 0x004000;
polling = 50; /* ms */
break;
case SAA7134_BOARD_BEHOLD_COLUMBUS_TVFM:
- ir_codes = &ir_codes_behold_columbus_table;
+ ir_codes = &IR_KEYTABLE(behold_columbus);
mask_keycode = 0x003f00;
mask_keyup = 0x004000;
polling = 50; // ms
break;
case SAA7134_BOARD_SEDNA_PC_TV_CARDBUS:
- ir_codes = &ir_codes_pctv_sedna_table;
+ ir_codes = &IR_KEYTABLE(pctv_sedna);
mask_keycode = 0x001f00;
mask_keyup = 0x004000;
polling = 50; // ms
break;
case SAA7134_BOARD_GOTVIEW_7135:
- ir_codes = &ir_codes_gotview7135_table;
+ ir_codes = &IR_KEYTABLE(gotview7135);
mask_keycode = 0x0003CC;
mask_keydown = 0x000010;
polling = 5; /* ms */
@@ -735,80 +735,80 @@ int saa7134_input_init1(struct saa7134_dev *dev)
case SAA7134_BOARD_VIDEOMATE_TV_PVR:
case SAA7134_BOARD_VIDEOMATE_GOLD_PLUS:
case SAA7134_BOARD_VIDEOMATE_TV_GOLD_PLUSII:
- ir_codes = &ir_codes_videomate_tv_pvr_table;
+ ir_codes = &IR_KEYTABLE(videomate_tv_pvr);
mask_keycode = 0x00003F;
mask_keyup = 0x400000;
polling = 50; // ms
break;
case SAA7134_BOARD_PROTEUS_2309:
- ir_codes = &ir_codes_proteus_2309_table;
+ ir_codes = &IR_KEYTABLE(proteus_2309);
mask_keycode = 0x00007F;
mask_keyup = 0x000080;
polling = 50; // ms
break;
case SAA7134_BOARD_VIDEOMATE_DVBT_300:
case SAA7134_BOARD_VIDEOMATE_DVBT_200:
- ir_codes = &ir_codes_videomate_tv_pvr_table;
+ ir_codes = &IR_KEYTABLE(videomate_tv_pvr);
mask_keycode = 0x003F00;
mask_keyup = 0x040000;
break;
case SAA7134_BOARD_FLYDVBS_LR300:
case SAA7134_BOARD_FLYDVBT_LR301:
case SAA7134_BOARD_FLYDVBTDUO:
- ir_codes = &ir_codes_flydvb_table;
+ ir_codes = &IR_KEYTABLE(flydvb);
mask_keycode = 0x0001F00;
mask_keydown = 0x0040000;
break;
case SAA7134_BOARD_ASUSTeK_P7131_DUAL:
case SAA7134_BOARD_ASUSTeK_P7131_HYBRID_LNA:
case SAA7134_BOARD_ASUSTeK_P7131_ANALOG:
- ir_codes = &ir_codes_asus_pc39_table;
+ ir_codes = &IR_KEYTABLE(asus_pc39);
mask_keydown = 0x0040000;
rc5_gpio = 1;
break;
case SAA7134_BOARD_ENCORE_ENLTV:
case SAA7134_BOARD_ENCORE_ENLTV_FM:
- ir_codes = &ir_codes_encore_enltv_table;
+ ir_codes = &IR_KEYTABLE(encore_enltv);
mask_keycode = 0x00007f;
mask_keyup = 0x040000;
polling = 50; // ms
break;
case SAA7134_BOARD_ENCORE_ENLTV_FM53:
- ir_codes = &ir_codes_encore_enltv_fm53_table;
+ ir_codes = &IR_KEYTABLE(encore_enltv_fm53);
mask_keydown = 0x0040000;
mask_keycode = 0x00007f;
nec_gpio = 1;
break;
case SAA7134_BOARD_10MOONSTVMASTER3:
- ir_codes = &ir_codes_encore_enltv_table;
+ ir_codes = &IR_KEYTABLE(encore_enltv);
mask_keycode = 0x5f80000;
mask_keyup = 0x8000000;
polling = 50; //ms
break;
case SAA7134_BOARD_GENIUS_TVGO_A11MCE:
- ir_codes = &ir_codes_genius_tvgo_a11mce_table;
+ ir_codes = &IR_KEYTABLE(genius_tvgo_a11mce);
mask_keycode = 0xff;
mask_keydown = 0xf00000;
polling = 50; /* ms */
break;
case SAA7134_BOARD_REAL_ANGEL_220:
- ir_codes = &ir_codes_real_audio_220_32_keys_table;
+ ir_codes = &IR_KEYTABLE(real_audio_220_32_keys);
mask_keycode = 0x3f00;
mask_keyup = 0x4000;
polling = 50; /* ms */
break;
case SAA7134_BOARD_KWORLD_PLUS_TV_ANALOG:
- ir_codes = &ir_codes_kworld_plus_tv_analog_table;
+ ir_codes = &IR_KEYTABLE(kworld_plus_tv_analog);
mask_keycode = 0x7f;
polling = 40; /* ms */
break;
case SAA7134_BOARD_VIDEOMATE_S350:
- ir_codes = &ir_codes_videomate_s350_table;
+ ir_codes = &IR_KEYTABLE(videomate_s350);
mask_keycode = 0x003f00;
mask_keydown = 0x040000;
break;
case SAA7134_BOARD_LEADTEK_WINFAST_DTV1000S:
- ir_codes = &ir_codes_winfast_table;
+ ir_codes = &IR_KEYTABLE(winfast);
mask_keycode = 0x5f00;
mask_keyup = 0x020000;
polling = 50; /* ms */
@@ -938,24 +938,24 @@ void saa7134_probe_i2c_ir(struct saa7134_dev *dev)
dev->init_data.name = "Pinnacle PCTV";
if (pinnacle_remote == 0) {
dev->init_data.get_key = get_key_pinnacle_color;
- dev->init_data.ir_codes = &ir_codes_pinnacle_color_table;
+ dev->init_data.ir_codes = &IR_KEYTABLE(pinnacle_color);
info.addr = 0x47;
} else {
dev->init_data.get_key = get_key_pinnacle_grey;
- dev->init_data.ir_codes = &ir_codes_pinnacle_grey_table;
+ dev->init_data.ir_codes = &IR_KEYTABLE(pinnacle_grey);
info.addr = 0x47;
}
break;
case SAA7134_BOARD_UPMOST_PURPLE_TV:
dev->init_data.name = "Purple TV";
dev->init_data.get_key = get_key_purpletv;
- dev->init_data.ir_codes = &ir_codes_purpletv_table;
+ dev->init_data.ir_codes = &IR_KEYTABLE(purpletv);
info.addr = 0x7a;
break;
case SAA7134_BOARD_MSI_TVATANYWHERE_PLUS:
dev->init_data.name = "MSI TV@nywhere Plus";
dev->init_data.get_key = get_key_msi_tvanywhere_plus;
- dev->init_data.ir_codes = &ir_codes_msi_tvanywhere_plus_table;
+ dev->init_data.ir_codes = &IR_KEYTABLE(msi_tvanywhere_plus);
info.addr = 0x30;
/* MSI TV@nywhere Plus controller doesn't seem to
respond to probes unless we read something from
@@ -969,7 +969,7 @@ void saa7134_probe_i2c_ir(struct saa7134_dev *dev)
case SAA7134_BOARD_HAUPPAUGE_HVR1110:
dev->init_data.name = "HVR 1110";
dev->init_data.get_key = get_key_hvr1110;
- dev->init_data.ir_codes = &ir_codes_hauppauge_new_table;
+ dev->init_data.ir_codes = &IR_KEYTABLE(hauppauge_new);
info.addr = 0x71;
break;
case SAA7134_BOARD_BEHOLD_607FM_MK3:
@@ -987,7 +987,7 @@ void saa7134_probe_i2c_ir(struct saa7134_dev *dev)
case SAA7134_BOARD_BEHOLD_X7:
dev->init_data.name = "BeholdTV";
dev->init_data.get_key = get_key_beholdm6xx;
- dev->init_data.ir_codes = &ir_codes_behold_table;
+ dev->init_data.ir_codes = &IR_KEYTABLE(behold);
dev->init_data.type = IR_TYPE_NEC;
info.addr = 0x2d;
break;
@@ -998,7 +998,7 @@ void saa7134_probe_i2c_ir(struct saa7134_dev *dev)
case SAA7134_BOARD_FLYDVB_TRIO:
dev->init_data.name = "FlyDVB Trio";
dev->init_data.get_key = get_key_flydvb_trio;
- dev->init_data.ir_codes = &ir_codes_flydvb_table;
+ dev->init_data.ir_codes = &IR_KEYTABLE(flydvb);
info.addr = 0x0b;
break;
default:
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 02/26] V4L/DVB: ir-common: re-order keytables by name and remove duplicates
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (23 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 03/26] V4L/DVB: IR: use IR_KEYTABLE where an IR table is needed Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 19:13 ` [PATCH 16/26] V4L/DVB: ir-core: improve keyup/keydown logic Mauro Carvalho Chehab
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/include/media/ir-common.h b/include/media/ir-common.h
index 800fc98..2e27515 100644
--- a/include/media/ir-common.h
+++ b/include/media/ir-common.h
@@ -112,69 +112,69 @@ void ir_rc5_timer_keyup(unsigned long data);
#define DECLARE_IR_KEYTABLE(a) \
extern struct ir_scancode_table IR_KEYTABLE(a)
-DECLARE_IR_KEYTABLE(empty);
+DECLARE_IR_KEYTABLE(adstech_dvb_t_pci);
+DECLARE_IR_KEYTABLE(apac_viewcomp);
+DECLARE_IR_KEYTABLE(asus_pc39);
+DECLARE_IR_KEYTABLE(ati_tv_wonder_hd_600);
DECLARE_IR_KEYTABLE(avermedia);
+DECLARE_IR_KEYTABLE(avermedia_a16d);
+DECLARE_IR_KEYTABLE(avermedia_cardbus);
DECLARE_IR_KEYTABLE(avermedia_dvbt);
DECLARE_IR_KEYTABLE(avermedia_m135a_rm_jx);
-DECLARE_IR_KEYTABLE(avermedia_cardbus);
-DECLARE_IR_KEYTABLE(apac_viewcomp);
-DECLARE_IR_KEYTABLE(pixelview);
-DECLARE_IR_KEYTABLE(pixelview_new);
-DECLARE_IR_KEYTABLE(nebula);
-DECLARE_IR_KEYTABLE(dntv_live_dvb_t);
-DECLARE_IR_KEYTABLE(iodata_bctv7e);
-DECLARE_IR_KEYTABLE(adstech_dvb_t_pci);
-DECLARE_IR_KEYTABLE(msi_tvanywhere);
-DECLARE_IR_KEYTABLE(cinergy_1400);
DECLARE_IR_KEYTABLE(avertv_303);
+DECLARE_IR_KEYTABLE(behold);
+DECLARE_IR_KEYTABLE(behold_columbus);
+DECLARE_IR_KEYTABLE(budget_ci_old);
+DECLARE_IR_KEYTABLE(cinergy);
+DECLARE_IR_KEYTABLE(cinergy_1400);
+DECLARE_IR_KEYTABLE(dm1105_nec);
+DECLARE_IR_KEYTABLE(dntv_live_dvb_t);
DECLARE_IR_KEYTABLE(dntv_live_dvbt_pro);
+DECLARE_IR_KEYTABLE(empty);
DECLARE_IR_KEYTABLE(em_terratec);
-DECLARE_IR_KEYTABLE(pinnacle_grey);
-DECLARE_IR_KEYTABLE(flyvideo);
-DECLARE_IR_KEYTABLE(flydvb);
-DECLARE_IR_KEYTABLE(cinergy);
+DECLARE_IR_KEYTABLE(encore_enltv);
+DECLARE_IR_KEYTABLE(encore_enltv2);
+DECLARE_IR_KEYTABLE(encore_enltv_fm53);
+DECLARE_IR_KEYTABLE(evga_indtube);
DECLARE_IR_KEYTABLE(eztv);
-DECLARE_IR_KEYTABLE(avermedia);
-DECLARE_IR_KEYTABLE(videomate_tv_pvr);
-DECLARE_IR_KEYTABLE(manli);
+DECLARE_IR_KEYTABLE(flydvb);
+DECLARE_IR_KEYTABLE(flyvideo);
+DECLARE_IR_KEYTABLE(fusionhdtv_mce);
+DECLARE_IR_KEYTABLE(gadmei_rm008z);
+DECLARE_IR_KEYTABLE(genius_tvgo_a11mce);
DECLARE_IR_KEYTABLE(gotview7135);
-DECLARE_IR_KEYTABLE(purpletv);
-DECLARE_IR_KEYTABLE(pctv_sedna);
-DECLARE_IR_KEYTABLE(pv951);
-DECLARE_IR_KEYTABLE(rc5_tv);
-DECLARE_IR_KEYTABLE(winfast);
-DECLARE_IR_KEYTABLE(pinnacle_color);
DECLARE_IR_KEYTABLE(hauppauge_new);
-DECLARE_IR_KEYTABLE(rc5_hauppauge_new);
-DECLARE_IR_KEYTABLE(npgtech);
+DECLARE_IR_KEYTABLE(iodata_bctv7e);
+DECLARE_IR_KEYTABLE(kaiomy);
+DECLARE_IR_KEYTABLE(kworld_315u);
+DECLARE_IR_KEYTABLE(kworld_plus_tv_analog);
+DECLARE_IR_KEYTABLE(manli);
+DECLARE_IR_KEYTABLE(msi_tvanywhere);
+DECLARE_IR_KEYTABLE(msi_tvanywhere_plus);
+DECLARE_IR_KEYTABLE(nebula);
+DECLARE_IR_KEYTABLE(nec_terratec_cinergy_xs);
DECLARE_IR_KEYTABLE(norwood);
-DECLARE_IR_KEYTABLE(proteus_2309);
-DECLARE_IR_KEYTABLE(budget_ci_old);
-DECLARE_IR_KEYTABLE(asus_pc39);
-DECLARE_IR_KEYTABLE(encore_enltv);
-DECLARE_IR_KEYTABLE(encore_enltv2);
-DECLARE_IR_KEYTABLE(tt_1500);
-DECLARE_IR_KEYTABLE(fusionhdtv_mce);
-DECLARE_IR_KEYTABLE(behold);
-DECLARE_IR_KEYTABLE(behold_columbus);
+DECLARE_IR_KEYTABLE(npgtech);
+DECLARE_IR_KEYTABLE(pctv_sedna);
+DECLARE_IR_KEYTABLE(pinnacle_color);
+DECLARE_IR_KEYTABLE(pinnacle_grey);
DECLARE_IR_KEYTABLE(pinnacle_pctv_hd);
-DECLARE_IR_KEYTABLE(genius_tvgo_a11mce);
+DECLARE_IR_KEYTABLE(pixelview);
+DECLARE_IR_KEYTABLE(pixelview_new);
DECLARE_IR_KEYTABLE(powercolor_real_angel);
-DECLARE_IR_KEYTABLE(avermedia_a16d);
-DECLARE_IR_KEYTABLE(encore_enltv_fm53);
+DECLARE_IR_KEYTABLE(proteus_2309);
+DECLARE_IR_KEYTABLE(purpletv);
+DECLARE_IR_KEYTABLE(pv951);
+DECLARE_IR_KEYTABLE(rc5_hauppauge_new);
+DECLARE_IR_KEYTABLE(rc5_tv);
DECLARE_IR_KEYTABLE(real_audio_220_32_keys);
-DECLARE_IR_KEYTABLE(msi_tvanywhere_plus);
-DECLARE_IR_KEYTABLE(ati_tv_wonder_hd_600);
-DECLARE_IR_KEYTABLE(kworld_plus_tv_analog);
-DECLARE_IR_KEYTABLE(kaiomy);
-DECLARE_IR_KEYTABLE(dm1105_nec);
-DECLARE_IR_KEYTABLE(tevii_nec);
DECLARE_IR_KEYTABLE(tbs_nec);
-DECLARE_IR_KEYTABLE(evga_indtube);
DECLARE_IR_KEYTABLE(terratec_cinergy_xs);
+DECLARE_IR_KEYTABLE(tevii_nec);
+DECLARE_IR_KEYTABLE(tt_1500);
DECLARE_IR_KEYTABLE(videomate_s350);
-DECLARE_IR_KEYTABLE(gadmei_rm008z);
-DECLARE_IR_KEYTABLE(nec_terratec_cinergy_xs);
+DECLARE_IR_KEYTABLE(videomate_tv_pvr);
+DECLARE_IR_KEYTABLE(winfast);
DECLARE_IR_KEYTABLE(winfast_usbii_deluxe);
-DECLARE_IR_KEYTABLE(kworld_315u);
+
#endif
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 01/26] V4L/DVB: ir-common: Use a function to declare an IR table
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (21 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 06/26] V4L/DVB: ir-common: move IR tables from ir-keymaps.c to a separate file Mauro Carvalho Chehab
@ 2010-04-06 18:18 ` Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 03/26] V4L/DVB: IR: use IR_KEYTABLE where an IR table is needed Mauro Carvalho Chehab
` (2 subsequent siblings)
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 18:18 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
This is the first patch of a series of changes that will break the IR
tables into a series of small modules that can be dynamically loaded,
or just loaded from userspace.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/include/media/ir-common.h b/include/media/ir-common.h
index e403a9a..800fc98 100644
--- a/include/media/ir-common.h
+++ b/include/media/ir-common.h
@@ -106,69 +106,75 @@ void ir_rc5_timer_keyup(unsigned long data);
/* scancode->keycode map tables from ir-keymaps.c */
-extern struct ir_scancode_table ir_codes_empty_table;
-extern struct ir_scancode_table ir_codes_avermedia_table;
-extern struct ir_scancode_table ir_codes_avermedia_dvbt_table;
-extern struct ir_scancode_table ir_codes_avermedia_m135a_rm_jx_table;
-extern struct ir_scancode_table ir_codes_avermedia_cardbus_table;
-extern struct ir_scancode_table ir_codes_apac_viewcomp_table;
-extern struct ir_scancode_table ir_codes_pixelview_table;
-extern struct ir_scancode_table ir_codes_pixelview_new_table;
-extern struct ir_scancode_table ir_codes_nebula_table;
-extern struct ir_scancode_table ir_codes_dntv_live_dvb_t_table;
-extern struct ir_scancode_table ir_codes_iodata_bctv7e_table;
-extern struct ir_scancode_table ir_codes_adstech_dvb_t_pci_table;
-extern struct ir_scancode_table ir_codes_msi_tvanywhere_table;
-extern struct ir_scancode_table ir_codes_cinergy_1400_table;
-extern struct ir_scancode_table ir_codes_avertv_303_table;
-extern struct ir_scancode_table ir_codes_dntv_live_dvbt_pro_table;
-extern struct ir_scancode_table ir_codes_em_terratec_table;
-extern struct ir_scancode_table ir_codes_pinnacle_grey_table;
-extern struct ir_scancode_table ir_codes_flyvideo_table;
-extern struct ir_scancode_table ir_codes_flydvb_table;
-extern struct ir_scancode_table ir_codes_cinergy_table;
-extern struct ir_scancode_table ir_codes_eztv_table;
-extern struct ir_scancode_table ir_codes_avermedia_table;
-extern struct ir_scancode_table ir_codes_videomate_tv_pvr_table;
-extern struct ir_scancode_table ir_codes_manli_table;
-extern struct ir_scancode_table ir_codes_gotview7135_table;
-extern struct ir_scancode_table ir_codes_purpletv_table;
-extern struct ir_scancode_table ir_codes_pctv_sedna_table;
-extern struct ir_scancode_table ir_codes_pv951_table;
-extern struct ir_scancode_table ir_codes_rc5_tv_table;
-extern struct ir_scancode_table ir_codes_winfast_table;
-extern struct ir_scancode_table ir_codes_pinnacle_color_table;
-extern struct ir_scancode_table ir_codes_hauppauge_new_table;
-extern struct ir_scancode_table ir_codes_rc5_hauppauge_new_table;
-extern struct ir_scancode_table ir_codes_npgtech_table;
-extern struct ir_scancode_table ir_codes_norwood_table;
-extern struct ir_scancode_table ir_codes_proteus_2309_table;
-extern struct ir_scancode_table ir_codes_budget_ci_old_table;
-extern struct ir_scancode_table ir_codes_asus_pc39_table;
-extern struct ir_scancode_table ir_codes_encore_enltv_table;
-extern struct ir_scancode_table ir_codes_encore_enltv2_table;
-extern struct ir_scancode_table ir_codes_tt_1500_table;
-extern struct ir_scancode_table ir_codes_fusionhdtv_mce_table;
-extern struct ir_scancode_table ir_codes_behold_table;
-extern struct ir_scancode_table ir_codes_behold_columbus_table;
-extern struct ir_scancode_table ir_codes_pinnacle_pctv_hd_table;
-extern struct ir_scancode_table ir_codes_genius_tvgo_a11mce_table;
-extern struct ir_scancode_table ir_codes_powercolor_real_angel_table;
-extern struct ir_scancode_table ir_codes_avermedia_a16d_table;
-extern struct ir_scancode_table ir_codes_encore_enltv_fm53_table;
-extern struct ir_scancode_table ir_codes_real_audio_220_32_keys_table;
-extern struct ir_scancode_table ir_codes_msi_tvanywhere_plus_table;
-extern struct ir_scancode_table ir_codes_ati_tv_wonder_hd_600_table;
-extern struct ir_scancode_table ir_codes_kworld_plus_tv_analog_table;
-extern struct ir_scancode_table ir_codes_kaiomy_table;
-extern struct ir_scancode_table ir_codes_dm1105_nec_table;
-extern struct ir_scancode_table ir_codes_tevii_nec_table;
-extern struct ir_scancode_table ir_codes_tbs_nec_table;
-extern struct ir_scancode_table ir_codes_evga_indtube_table;
-extern struct ir_scancode_table ir_codes_terratec_cinergy_xs_table;
-extern struct ir_scancode_table ir_codes_videomate_s350_table;
-extern struct ir_scancode_table ir_codes_gadmei_rm008z_table;
-extern struct ir_scancode_table ir_codes_nec_terratec_cinergy_xs_table;
-extern struct ir_scancode_table ir_codes_winfast_usbii_deluxe_table;
-extern struct ir_scancode_table ir_codes_kworld_315u_table;
+#define IR_KEYTABLE(a) \
+(ir_codes_ ## a ## _table)
+
+#define DECLARE_IR_KEYTABLE(a) \
+extern struct ir_scancode_table IR_KEYTABLE(a)
+
+DECLARE_IR_KEYTABLE(empty);
+DECLARE_IR_KEYTABLE(avermedia);
+DECLARE_IR_KEYTABLE(avermedia_dvbt);
+DECLARE_IR_KEYTABLE(avermedia_m135a_rm_jx);
+DECLARE_IR_KEYTABLE(avermedia_cardbus);
+DECLARE_IR_KEYTABLE(apac_viewcomp);
+DECLARE_IR_KEYTABLE(pixelview);
+DECLARE_IR_KEYTABLE(pixelview_new);
+DECLARE_IR_KEYTABLE(nebula);
+DECLARE_IR_KEYTABLE(dntv_live_dvb_t);
+DECLARE_IR_KEYTABLE(iodata_bctv7e);
+DECLARE_IR_KEYTABLE(adstech_dvb_t_pci);
+DECLARE_IR_KEYTABLE(msi_tvanywhere);
+DECLARE_IR_KEYTABLE(cinergy_1400);
+DECLARE_IR_KEYTABLE(avertv_303);
+DECLARE_IR_KEYTABLE(dntv_live_dvbt_pro);
+DECLARE_IR_KEYTABLE(em_terratec);
+DECLARE_IR_KEYTABLE(pinnacle_grey);
+DECLARE_IR_KEYTABLE(flyvideo);
+DECLARE_IR_KEYTABLE(flydvb);
+DECLARE_IR_KEYTABLE(cinergy);
+DECLARE_IR_KEYTABLE(eztv);
+DECLARE_IR_KEYTABLE(avermedia);
+DECLARE_IR_KEYTABLE(videomate_tv_pvr);
+DECLARE_IR_KEYTABLE(manli);
+DECLARE_IR_KEYTABLE(gotview7135);
+DECLARE_IR_KEYTABLE(purpletv);
+DECLARE_IR_KEYTABLE(pctv_sedna);
+DECLARE_IR_KEYTABLE(pv951);
+DECLARE_IR_KEYTABLE(rc5_tv);
+DECLARE_IR_KEYTABLE(winfast);
+DECLARE_IR_KEYTABLE(pinnacle_color);
+DECLARE_IR_KEYTABLE(hauppauge_new);
+DECLARE_IR_KEYTABLE(rc5_hauppauge_new);
+DECLARE_IR_KEYTABLE(npgtech);
+DECLARE_IR_KEYTABLE(norwood);
+DECLARE_IR_KEYTABLE(proteus_2309);
+DECLARE_IR_KEYTABLE(budget_ci_old);
+DECLARE_IR_KEYTABLE(asus_pc39);
+DECLARE_IR_KEYTABLE(encore_enltv);
+DECLARE_IR_KEYTABLE(encore_enltv2);
+DECLARE_IR_KEYTABLE(tt_1500);
+DECLARE_IR_KEYTABLE(fusionhdtv_mce);
+DECLARE_IR_KEYTABLE(behold);
+DECLARE_IR_KEYTABLE(behold_columbus);
+DECLARE_IR_KEYTABLE(pinnacle_pctv_hd);
+DECLARE_IR_KEYTABLE(genius_tvgo_a11mce);
+DECLARE_IR_KEYTABLE(powercolor_real_angel);
+DECLARE_IR_KEYTABLE(avermedia_a16d);
+DECLARE_IR_KEYTABLE(encore_enltv_fm53);
+DECLARE_IR_KEYTABLE(real_audio_220_32_keys);
+DECLARE_IR_KEYTABLE(msi_tvanywhere_plus);
+DECLARE_IR_KEYTABLE(ati_tv_wonder_hd_600);
+DECLARE_IR_KEYTABLE(kworld_plus_tv_analog);
+DECLARE_IR_KEYTABLE(kaiomy);
+DECLARE_IR_KEYTABLE(dm1105_nec);
+DECLARE_IR_KEYTABLE(tevii_nec);
+DECLARE_IR_KEYTABLE(tbs_nec);
+DECLARE_IR_KEYTABLE(evga_indtube);
+DECLARE_IR_KEYTABLE(terratec_cinergy_xs);
+DECLARE_IR_KEYTABLE(videomate_s350);
+DECLARE_IR_KEYTABLE(gadmei_rm008z);
+DECLARE_IR_KEYTABLE(nec_terratec_cinergy_xs);
+DECLARE_IR_KEYTABLE(winfast_usbii_deluxe);
+DECLARE_IR_KEYTABLE(kworld_315u);
#endif
--
1.6.6.1
^ permalink raw reply related [flat|nested] 29+ messages in thread
* [PATCH 16/26] V4L/DVB: ir-core: improve keyup/keydown logic
[not found] <cover.1270577768.git.mchehab@redhat.com>
` (24 preceding siblings ...)
2010-04-06 18:18 ` [PATCH 02/26] V4L/DVB: ir-common: re-order keytables by name and remove duplicates Mauro Carvalho Chehab
@ 2010-04-06 19:13 ` Mauro Carvalho Chehab
25 siblings, 0 replies; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-06 19:13 UTC (permalink / raw)
To: linux-media, Linux Media Mailing List
From: David Härdeman <david@hardeman.nu>
Rewrites the keyup/keydown logic in drivers/media/IR/ir-keytable.c.
All knowledge of keystates etc is now internal to ir-keytable.c
and not scattered around ir-raw-event.c and ir-nec-decoder.c (where
it doesn't belong).
In addition, I've changed the API slightly so that ir_input_dev is
passed as the first argument rather than input_dev. If we're ever
going to support multiple keytables we need to move towards making
ir_input_dev the main interface from a driver POV and obscure away
the input_dev as an implementational detail in ir-core.
Signed-off-by: David Härdeman <david@hardeman.nu>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/IR/ir-keytable.c b/drivers/media/IR/ir-keytable.c
index 00db928..39d8fcb 100644
--- a/drivers/media/IR/ir-keytable.c
+++ b/drivers/media/IR/ir-keytable.c
@@ -20,6 +20,9 @@
#define IR_TAB_MIN_SIZE 256
#define IR_TAB_MAX_SIZE 8192
+/* FIXME: IR_KEYPRESS_TIMEOUT should be protocol specific */
+#define IR_KEYPRESS_TIMEOUT 250
+
/**
* ir_resize_table() - resizes a scancode table if necessary
* @rc_tab: the ir_scancode_table to resize
@@ -262,56 +265,124 @@ EXPORT_SYMBOL_GPL(ir_g_keycode_from_table);
/**
* ir_keyup() - generates input event to cleanup a key press
- * @input_dev: the struct input_dev descriptor of the device
+ * @ir: the struct ir_input_dev descriptor of the device
*
- * This routine is used by the input routines when a key is pressed at the
- * IR. It reports a keyup input event via input_report_key().
+ * This routine is used to signal that a key has been released on the
+ * remote control. It reports a keyup input event via input_report_key().
*/
-void ir_keyup(struct input_dev *dev)
+static void ir_keyup(struct ir_input_dev *ir)
{
- struct ir_input_dev *ir = input_get_drvdata(dev);
-
if (!ir->keypressed)
return;
- IR_dprintk(1, "keyup key 0x%04x\n", ir->keycode);
- input_report_key(dev, ir->keycode, 0);
- input_sync(dev);
- ir->keypressed = 0;
+ IR_dprintk(1, "keyup key 0x%04x\n", ir->last_keycode);
+ input_report_key(ir->input_dev, ir->last_keycode, 0);
+ input_sync(ir->input_dev);
+ ir->keypressed = false;
}
-EXPORT_SYMBOL_GPL(ir_keyup);
+
+/**
+ * ir_timer_keyup() - generates a keyup event after a timeout
+ * @cookie: a pointer to struct ir_input_dev passed to setup_timer()
+ *
+ * This routine will generate a keyup event some time after a keydown event
+ * is generated when no further activity has been detected.
+ */
+static void ir_timer_keyup(unsigned long cookie)
+{
+ struct ir_input_dev *ir = (struct ir_input_dev *)cookie;
+ unsigned long flags;
+
+ /*
+ * ir->keyup_jiffies is used to prevent a race condition if a
+ * hardware interrupt occurs at this point and the keyup timer
+ * event is moved further into the future as a result.
+ *
+ * The timer will then be reactivated and this function called
+ * again in the future. We need to exit gracefully in that case
+ * to allow the input subsystem to do its auto-repeat magic or
+ * a keyup event might follow immediately after the keydown.
+ */
+ spin_lock_irqsave(&ir->keylock, flags);
+ if (time_is_after_eq_jiffies(ir->keyup_jiffies))
+ ir_keyup(ir);
+ spin_unlock_irqrestore(&ir->keylock, flags);
+}
+
+/**
+ * ir_repeat() - notifies the IR core that a key is still pressed
+ * @dev: the struct input_dev descriptor of the device
+ *
+ * This routine is used by IR decoders when a repeat message which does
+ * not include the necessary bits to reproduce the scancode has been
+ * received.
+ */
+void ir_repeat(struct input_dev *dev)
+{
+ unsigned long flags;
+ struct ir_input_dev *ir = input_get_drvdata(dev);
+
+ spin_lock_irqsave(&ir->keylock, flags);
+
+ if (!ir->keypressed)
+ goto out;
+
+ ir->keyup_jiffies = jiffies + msecs_to_jiffies(IR_KEYPRESS_TIMEOUT);
+ mod_timer(&ir->timer_keyup, ir->keyup_jiffies);
+
+out:
+ spin_unlock_irqrestore(&ir->keylock, flags);
+}
+EXPORT_SYMBOL_GPL(ir_repeat);
/**
* ir_keydown() - generates input event for a key press
- * @input_dev: the struct input_dev descriptor of the device
- * @scancode: the scancode that we're seeking
+ * @dev: the struct input_dev descriptor of the device
+ * @scancode: the scancode that we're seeking
+ * @toggle: the toggle value (protocol dependent, if the protocol doesn't
+ * support toggle values, this should be set to zero)
*
* This routine is used by the input routines when a key is pressed at the
* IR. It gets the keycode for a scancode and reports an input event via
* input_report_key().
*/
-void ir_keydown(struct input_dev *dev, int scancode)
+void ir_keydown(struct input_dev *dev, int scancode, u8 toggle)
{
+ unsigned long flags;
struct ir_input_dev *ir = input_get_drvdata(dev);
u32 keycode = ir_g_keycode_from_table(dev, scancode);
- /* If already sent a keydown, do a keyup */
- if (ir->keypressed)
- ir_keyup(dev);
+ spin_lock_irqsave(&ir->keylock, flags);
- if (KEY_RESERVED == keycode)
- return;
+ /* Repeat event? */
+ if (ir->keypressed &&
+ ir->last_scancode == scancode &&
+ ir->last_toggle == toggle)
+ goto set_timer;
- ir->keycode = keycode;
- ir->keypressed = 1;
+ /* Release old keypress */
+ ir_keyup(ir);
+ ir->last_scancode = scancode;
+ ir->last_toggle = toggle;
+ ir->last_keycode = keycode;
+
+ if (keycode == KEY_RESERVED)
+ goto out;
+
+ /* Register a keypress */
+ ir->keypressed = true;
IR_dprintk(1, "%s: key down event, key 0x%04x, scancode 0x%04x\n",
- dev->name, keycode, scancode);
-
- input_report_key(dev, ir->keycode, 1);
+ dev->name, keycode, scancode);
+ input_report_key(dev, ir->last_keycode, 1);
input_sync(dev);
+set_timer:
+ ir->keyup_jiffies = jiffies + msecs_to_jiffies(IR_KEYPRESS_TIMEOUT);
+ mod_timer(&ir->timer_keyup, ir->keyup_jiffies);
+out:
+ spin_unlock_irqrestore(&ir->keylock, flags);
}
EXPORT_SYMBOL_GPL(ir_keydown);
@@ -364,8 +435,12 @@ int __ir_input_register(struct input_dev *input_dev,
input_dev->getkeycode = ir_getkeycode;
input_dev->setkeycode = ir_setkeycode;
input_set_drvdata(input_dev, ir_dev);
+ ir_dev->input_dev = input_dev;
spin_lock_init(&ir_dev->rc_tab.lock);
+ spin_lock_init(&ir_dev->keylock);
+ setup_timer(&ir_dev->timer_keyup, ir_timer_keyup, (unsigned long)ir_dev);
+
ir_dev->rc_tab.name = rc_tab->name;
ir_dev->rc_tab.ir_type = rc_tab->ir_type;
ir_dev->rc_tab.alloc = roundup_pow_of_two(rc_tab->size *
@@ -382,6 +457,8 @@ int __ir_input_register(struct input_dev *input_dev,
ir_dev->rc_tab.size, ir_dev->rc_tab.alloc);
set_bit(EV_KEY, input_dev->evbit);
+ set_bit(EV_REP, input_dev->evbit);
+
if (ir_setkeytable(input_dev, &ir_dev->rc_tab, rc_tab)) {
rc = -ENOMEM;
goto out_table;
@@ -427,7 +504,7 @@ void ir_input_unregister(struct input_dev *dev)
return;
IR_dprintk(1, "Freed keycode table\n");
-
+ del_timer_sync(&ir_dev->timer_keyup);
rc_tab = &ir_dev->rc_tab;
rc_tab->size = 0;
kfree(rc_tab->scan);
diff --git a/drivers/media/IR/ir-nec-decoder.c b/drivers/media/IR/ir-nec-decoder.c
index 83a9912..0b50060 100644
--- a/drivers/media/IR/ir-nec-decoder.c
+++ b/drivers/media/IR/ir-nec-decoder.c
@@ -180,8 +180,7 @@ static int __ir_nec_decode(struct input_dev *input_dev,
if (is_repeat(evs, len, *pos)) {
*pos += 2;
if (ir->keypressed) {
- mod_timer(&ir->raw->timer_keyup,
- jiffies + msecs_to_jiffies(REPEAT_TIME));
+ ir_repeat(input_dev);
IR_dprintk(1, "NEC repeat event\n");
return 1;
} else {
@@ -238,9 +237,7 @@ static int __ir_nec_decode(struct input_dev *input_dev,
}
IR_dprintk(1, "NEC scancode 0x%04x\n", ircode);
- ir_keydown(input_dev, ircode);
- mod_timer(&ir->raw->timer_keyup,
- jiffies + msecs_to_jiffies(REPEAT_TIME));
+ ir_keydown(input_dev, ircode, 0);
return 1;
err:
diff --git a/drivers/media/IR/ir-raw-event.c b/drivers/media/IR/ir-raw-event.c
index 371d88e..59f2054 100644
--- a/drivers/media/IR/ir-raw-event.c
+++ b/drivers/media/IR/ir-raw-event.c
@@ -53,13 +53,6 @@ static spinlock_t ir_raw_handler_lock;
/* Used to load the decoders */
static struct work_struct wq_load;
-static void ir_keyup_timer(unsigned long data)
-{
- struct input_dev *input_dev = (struct input_dev *)data;
-
- ir_keyup(input_dev);
-}
-
int ir_raw_event_register(struct input_dev *input_dev)
{
struct ir_input_dev *ir = input_get_drvdata(input_dev);
@@ -72,11 +65,6 @@ int ir_raw_event_register(struct input_dev *input_dev)
size = sizeof(struct ir_raw_event) * MAX_IR_EVENT_SIZE * 2;
size = roundup_pow_of_two(size);
- init_timer(&ir->raw->timer_keyup);
- ir->raw->timer_keyup.function = ir_keyup_timer;
- ir->raw->timer_keyup.data = (unsigned long)input_dev;
- set_bit(EV_REP, input_dev->evbit);
-
rc = kfifo_alloc(&ir->raw->kfifo, size, GFP_KERNEL);
if (rc < 0) {
kfree(ir->raw);
@@ -103,8 +91,6 @@ void ir_raw_event_unregister(struct input_dev *input_dev)
if (!ir->raw)
return;
- del_timer_sync(&ir->raw->timer_keyup);
-
RUN_DECODER(raw_unregister, input_dev);
kfifo_free(&ir->raw->kfifo);
diff --git a/include/media/ir-core.h b/include/media/ir-core.h
index 7a0be8d..b452a47 100644
--- a/include/media/ir-core.h
+++ b/include/media/ir-core.h
@@ -76,7 +76,6 @@ struct ir_raw_event {
struct ir_raw_event_ctrl {
struct kfifo kfifo; /* fifo for the pulse/space events */
struct timespec last_event; /* when last event occurred */
- struct timer_list timer_keyup; /* timer for key release */
};
struct ir_input_dev {
@@ -86,10 +85,16 @@ struct ir_input_dev {
unsigned long devno; /* device number */
const struct ir_dev_props *props; /* Device properties */
struct ir_raw_event_ctrl *raw; /* for raw pulse/space events */
+ struct input_dev *input_dev; /* the input device associated with this device */
/* key info - needed by IR keycode handlers */
- u32 keycode; /* linux key code */
- int keypressed; /* current state */
+ spinlock_t keylock; /* protects the below members */
+ bool keypressed; /* current state */
+ unsigned long keyup_jiffies; /* when should the current keypress be released? */
+ struct timer_list timer_keyup; /* timer for releasing a keypress */
+ u32 last_keycode; /* keycode of last command */
+ u32 last_scancode; /* scancode of last command */
+ u8 last_toggle; /* toggle of last command */
};
struct ir_raw_handler {
@@ -115,8 +120,8 @@ void rc_map_init(void);
u32 ir_g_keycode_from_table(struct input_dev *input_dev,
u32 scancode);
-void ir_keyup(struct input_dev *dev);
-void ir_keydown(struct input_dev *dev, int scancode);
+void ir_repeat(struct input_dev *dev);
+void ir_keydown(struct input_dev *dev, int scancode, u8 toggle);
int __ir_input_register(struct input_dev *dev,
const struct ir_scancode_table *ir_codes,
const struct ir_dev_props *props
--
Cheers,
Mauro
^ permalink raw reply related [flat|nested] 29+ messages in thread
* Re: [PATCH 08/26] V4L/DVB: Break Remote Controller keymaps into modules
2010-04-06 18:18 ` [PATCH 08/26] V4L/DVB: Break Remote Controller keymaps into modules Mauro Carvalho Chehab
@ 2010-04-10 12:27 ` Andy Walls
2010-04-10 16:06 ` Mauro Carvalho Chehab
0 siblings, 1 reply; 29+ messages in thread
From: Andy Walls @ 2010-04-10 12:27 UTC (permalink / raw)
To: Mauro Carvalho Chehab; +Cc: linux-media
On Tue, 2010-04-06 at 15:18 -0300, Mauro Carvalho Chehab wrote:
> The original Remote Controller approach were very messy: a big file,
> that were part of ir-common kernel module, containing 64 different
> RC keymap tables, used by the V4L/DVB drivers.
>
> Better to break each RC keymap table into a separate module,
> registering them into rc core on a process similar to the fs/nls tables.
>
> As an userspace program is now in charge of loading those tables,
> adds an option to allow the complete removal of those tables from
> kernelspace.
>
> Yet, on embedded devices like Set Top Boxes and TV sets, maybe the
> only available input device is the IR. So, we should keep allowing
> the usage of in-kernel tables, but a latter patch should change
> the default to 'n', after giving some time for distros to add
> the v4l-utils with the ir-keytable program, to allow the table
> load via userspace.
I know I'm probably late on commenting on this.
Although this is interesting, it seems like overkill.
1. How will this help move us to the "just works" case, if now userspace
has to help the kernel. Every distro is likely just going to bundle a
script which loads them all into the kernel and forgets about them.
2. How is a driver, which knows the bundled remote, supposed to convey
to userspace "load this map by default for my IR receiver"? Is that
covered in another portion of the patch?
3. If you're going to be so remote specific, why not add protocol
information in these regarding the remotes? You can tell the core
everything to expect from this remote: raw vs. hardware decoder and the
RC-5/NEC/RC-6/JVC/whatever raw protocol decoder to use. That gets us
closer to "just works" and avoids false input events from two of the raw
deoders both thinking they got a valid code.
4. /sbin/lsmod is now going to give a very long listing with lots of
noise. When these things are registered with the core, is the module's
use count incremented when the core knows a driver is using one of them?
5. Each module is going to consume a page of vmalloc address space and
ram, and an addtional page of vmalloc address as a gap behind it. These
maps are rather small in comparison. Is it really worth all the page
table entries to load all these as individual modules? Memory is cheap,
and small allocations can fill in fragmentation gaps in the vmalloc
address space, but page table entries are spent on better things.
I guess I'm not aware of what the return is here for the costs.
Regards,
Andy
> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
>
> create mode 100644 drivers/media/IR/keymaps/Kconfig
> create mode 100644 drivers/media/IR/keymaps/Makefile
> create mode 100644 drivers/media/IR/keymaps/rc-adstech-dvb-t-pci.c
> create mode 100644 drivers/media/IR/keymaps/rc-apac-viewcomp.c
> create mode 100644 drivers/media/IR/keymaps/rc-asus-pc39.c
> create mode 100644 drivers/media/IR/keymaps/rc-ati-tv-wonder-hd-600.c
> create mode 100644 drivers/media/IR/keymaps/rc-avermedia-a16d.c
> create mode 100644 drivers/media/IR/keymaps/rc-avermedia-cardbus.c
> create mode 100644 drivers/media/IR/keymaps/rc-avermedia-dvbt.c
> create mode 100644 drivers/media/IR/keymaps/rc-avermedia-m135a-rm-jx.c
> create mode 100644 drivers/media/IR/keymaps/rc-avermedia.c
> create mode 100644 drivers/media/IR/keymaps/rc-avertv-303.c
> create mode 100644 drivers/media/IR/keymaps/rc-behold-columbus.c
> create mode 100644 drivers/media/IR/keymaps/rc-behold.c
> create mode 100644 drivers/media/IR/keymaps/rc-budget-ci-old.c
> create mode 100644 drivers/media/IR/keymaps/rc-cinergy-1400.c
> create mode 100644 drivers/media/IR/keymaps/rc-cinergy.c
> create mode 100644 drivers/media/IR/keymaps/rc-dm1105-nec.c
> create mode 100644 drivers/media/IR/keymaps/rc-dntv-live-dvb-t.c
> create mode 100644 drivers/media/IR/keymaps/rc-dntv-live-dvbt-pro.c
> create mode 100644 drivers/media/IR/keymaps/rc-em-terratec.c
> create mode 100644 drivers/media/IR/keymaps/rc-empty.c
> create mode 100644 drivers/media/IR/keymaps/rc-encore-enltv-fm53.c
> create mode 100644 drivers/media/IR/keymaps/rc-encore-enltv.c
> create mode 100644 drivers/media/IR/keymaps/rc-encore-enltv2.c
> create mode 100644 drivers/media/IR/keymaps/rc-evga-indtube.c
> create mode 100644 drivers/media/IR/keymaps/rc-eztv.c
> create mode 100644 drivers/media/IR/keymaps/rc-flydvb.c
> create mode 100644 drivers/media/IR/keymaps/rc-flyvideo.c
> create mode 100644 drivers/media/IR/keymaps/rc-fusionhdtv-mce.c
> create mode 100644 drivers/media/IR/keymaps/rc-gadmei-rm008z.c
> create mode 100644 drivers/media/IR/keymaps/rc-genius-tvgo-a11mce.c
> create mode 100644 drivers/media/IR/keymaps/rc-gotview7135.c
> create mode 100644 drivers/media/IR/keymaps/rc-hauppauge-new.c
> create mode 100644 drivers/media/IR/keymaps/rc-iodata-bctv7e.c
> create mode 100644 drivers/media/IR/keymaps/rc-kaiomy.c
> create mode 100644 drivers/media/IR/keymaps/rc-kworld-315u.c
> create mode 100644 drivers/media/IR/keymaps/rc-kworld-plus-tv-analog.c
> create mode 100644 drivers/media/IR/keymaps/rc-manli.c
> create mode 100644 drivers/media/IR/keymaps/rc-msi-tvanywhere-plus.c
> create mode 100644 drivers/media/IR/keymaps/rc-msi-tvanywhere.c
> create mode 100644 drivers/media/IR/keymaps/rc-nebula.c
> create mode 100644 drivers/media/IR/keymaps/rc-nec-terratec-cinergy-xs.c
> create mode 100644 drivers/media/IR/keymaps/rc-norwood.c
> create mode 100644 drivers/media/IR/keymaps/rc-npgtech.c
> create mode 100644 drivers/media/IR/keymaps/rc-pctv-sedna.c
> create mode 100644 drivers/media/IR/keymaps/rc-pinnacle-color.c
> create mode 100644 drivers/media/IR/keymaps/rc-pinnacle-grey.c
> create mode 100644 drivers/media/IR/keymaps/rc-pinnacle-pctv-hd.c
> create mode 100644 drivers/media/IR/keymaps/rc-pixelview-new.c
> create mode 100644 drivers/media/IR/keymaps/rc-pixelview.c
> create mode 100644 drivers/media/IR/keymaps/rc-powercolor-real-angel.c
> create mode 100644 drivers/media/IR/keymaps/rc-proteus-2309.c
> create mode 100644 drivers/media/IR/keymaps/rc-purpletv.c
> create mode 100644 drivers/media/IR/keymaps/rc-pv951.c
> create mode 100644 drivers/media/IR/keymaps/rc-rc5-hauppauge-new.c
> create mode 100644 drivers/media/IR/keymaps/rc-rc5-tv.c
> create mode 100644 drivers/media/IR/keymaps/rc-real-audio-220-32-keys.c
> create mode 100644 drivers/media/IR/keymaps/rc-tbs-nec.c
> create mode 100644 drivers/media/IR/keymaps/rc-terratec-cinergy-xs.c
> create mode 100644 drivers/media/IR/keymaps/rc-tevii-nec.c
> create mode 100644 drivers/media/IR/keymaps/rc-tt-1500.c
> create mode 100644 drivers/media/IR/keymaps/rc-videomate-s350.c
> create mode 100644 drivers/media/IR/keymaps/rc-videomate-tv-pvr.c
> create mode 100644 drivers/media/IR/keymaps/rc-winfast-usbii-deluxe.c
> create mode 100644 drivers/media/IR/keymaps/rc-winfast.c
>
> diff --git a/drivers/media/IR/Kconfig b/drivers/media/IR/Kconfig
> index de410d4..0c557b8 100644
> --- a/drivers/media/IR/Kconfig
> +++ b/drivers/media/IR/Kconfig
> @@ -8,6 +8,8 @@ config VIDEO_IR
> depends on IR_CORE
> default IR_CORE
>
> +source "drivers/media/IR/keymaps/Kconfig"
> +
> config IR_NEC_DECODER
> tristate "Enable IR raw decoder for NEC protocol"
> depends on IR_CORE
> diff --git a/drivers/media/IR/keymaps/Kconfig b/drivers/media/IR/keymaps/Kconfig
> new file mode 100644
> index 0000000..14b22f5
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/Kconfig
> @@ -0,0 +1,15 @@
> +config RC_MAP
> + tristate "Compile Remote Controller keymap modules"
> + depends on IR_CORE
> + default y
> +
> + ---help---
> + This option enables the compilation of lots of Remote
> + Controller tables. They are short tables, but if you
> + don't use a remote controller, or prefer to load the
> + tables on userspace, you should disable it.
> +
> + The ir-keytable program, available at v4l-utils package
> + provide the tool and the same RC maps for load from
> + userspace. Its available at
> + http://git.linuxtv.org/v4l-utils
> diff --git a/drivers/media/IR/keymaps/Makefile b/drivers/media/IR/keymaps/Makefile
> new file mode 100644
> index 0000000..937b7db
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/Makefile
> @@ -0,0 +1,64 @@
> +obj-$(CONFIG_RC_MAP) += rc-adstech-dvb-t-pci.o \
> + rc-apac-viewcomp.o \
> + rc-asus-pc39.o \
> + rc-ati-tv-wonder-hd-600.o \
> + rc-avermedia-a16d.o \
> + rc-avermedia.o \
> + rc-avermedia-cardbus.o \
> + rc-avermedia-dvbt.o \
> + rc-avermedia-m135a-rm-jx.o \
> + rc-avertv-303.o \
> + rc-behold.o \
> + rc-behold-columbus.o \
> + rc-budget-ci-old.o \
> + rc-cinergy-1400.o \
> + rc-cinergy.o \
> + rc-dm1105-nec.o \
> + rc-dntv-live-dvb-t.o \
> + rc-dntv-live-dvbt-pro.o \
> + rc-empty.o \
> + rc-em-terratec.o \
> + rc-encore-enltv2.o \
> + rc-encore-enltv.o \
> + rc-encore-enltv-fm53.o \
> + rc-evga-indtube.o \
> + rc-eztv.o \
> + rc-flydvb.o \
> + rc-flyvideo.o \
> + rc-fusionhdtv-mce.o \
> + rc-gadmei-rm008z.o \
> + rc-genius-tvgo-a11mce.o \
> + rc-gotview7135.o \
> + rc-hauppauge-new.o \
> + rc-iodata-bctv7e.o \
> + rc-kaiomy.o \
> + rc-kworld-315u.o \
> + rc-kworld-plus-tv-analog.o \
> + rc-manli.o \
> + rc-msi-tvanywhere.o \
> + rc-msi-tvanywhere-plus.o \
> + rc-nebula.o \
> + rc-nec-terratec-cinergy-xs.o \
> + rc-norwood.o \
> + rc-npgtech.o \
> + rc-pctv-sedna.o \
> + rc-pinnacle-color.o \
> + rc-pinnacle-grey.o \
> + rc-pinnacle-pctv-hd.o \
> + rc-pixelview.o \
> + rc-pixelview-new.o \
> + rc-powercolor-real-angel.o \
> + rc-proteus-2309.o \
> + rc-purpletv.o \
> + rc-pv951.o \
> + rc-rc5-hauppauge-new.o \
> + rc-rc5-tv.o \
> + rc-real-audio-220-32-keys.o \
> + rc-tbs-nec.o \
> + rc-terratec-cinergy-xs.o \
> + rc-tevii-nec.o \
> + rc-tt-1500.o \
> + rc-videomate-s350.o \
> + rc-videomate-tv-pvr.o \
> + rc-winfast.o \
> + rc-winfast-usbii-deluxe.o
> diff --git a/drivers/media/IR/keymaps/rc-adstech-dvb-t-pci.c b/drivers/media/IR/keymaps/rc-adstech-dvb-t-pci.c
> new file mode 100644
> index 0000000..b172831
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-adstech-dvb-t-pci.c
> @@ -0,0 +1,89 @@
> +/* adstech-dvb-t-pci.h - Keytable for adstech_dvb_t_pci Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* ADS Tech Instant TV DVB-T PCI Remote */
> +
> +static struct ir_scancode adstech_dvb_t_pci[] = {
> + /* Keys 0 to 9 */
> + { 0x4d, KEY_0 },
> + { 0x57, KEY_1 },
> + { 0x4f, KEY_2 },
> + { 0x53, KEY_3 },
> + { 0x56, KEY_4 },
> + { 0x4e, KEY_5 },
> + { 0x5e, KEY_6 },
> + { 0x54, KEY_7 },
> + { 0x4c, KEY_8 },
> + { 0x5c, KEY_9 },
> +
> + { 0x5b, KEY_POWER },
> + { 0x5f, KEY_MUTE },
> + { 0x55, KEY_GOTO },
> + { 0x5d, KEY_SEARCH },
> + { 0x17, KEY_EPG }, /* Guide */
> + { 0x1f, KEY_MENU },
> + { 0x0f, KEY_UP },
> + { 0x46, KEY_DOWN },
> + { 0x16, KEY_LEFT },
> + { 0x1e, KEY_RIGHT },
> + { 0x0e, KEY_SELECT }, /* Enter */
> + { 0x5a, KEY_INFO },
> + { 0x52, KEY_EXIT },
> + { 0x59, KEY_PREVIOUS },
> + { 0x51, KEY_NEXT },
> + { 0x58, KEY_REWIND },
> + { 0x50, KEY_FORWARD },
> + { 0x44, KEY_PLAYPAUSE },
> + { 0x07, KEY_STOP },
> + { 0x1b, KEY_RECORD },
> + { 0x13, KEY_TUNER }, /* Live */
> + { 0x0a, KEY_A },
> + { 0x12, KEY_B },
> + { 0x03, KEY_PROG1 }, /* 1 */
> + { 0x01, KEY_PROG2 }, /* 2 */
> + { 0x00, KEY_PROG3 }, /* 3 */
> + { 0x06, KEY_DVD },
> + { 0x48, KEY_AUX }, /* Photo */
> + { 0x40, KEY_VIDEO },
> + { 0x19, KEY_AUDIO }, /* Music */
> + { 0x0b, KEY_CHANNELUP },
> + { 0x08, KEY_CHANNELDOWN },
> + { 0x15, KEY_VOLUMEUP },
> + { 0x1c, KEY_VOLUMEDOWN },
> +};
> +
> +static struct rc_keymap adstech_dvb_t_pci_map = {
> + .map = {
> + .scan = adstech_dvb_t_pci,
> + .size = ARRAY_SIZE(adstech_dvb_t_pci),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_ADSTECH_DVB_T_PCI,
> + }
> +};
> +
> +static int __init init_rc_map_adstech_dvb_t_pci(void)
> +{
> + return ir_register_map(&adstech_dvb_t_pci_map);
> +}
> +
> +static void __exit exit_rc_map_adstech_dvb_t_pci(void)
> +{
> + ir_unregister_map(&adstech_dvb_t_pci_map);
> +}
> +
> +module_init(init_rc_map_adstech_dvb_t_pci)
> +module_exit(exit_rc_map_adstech_dvb_t_pci)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-apac-viewcomp.c b/drivers/media/IR/keymaps/rc-apac-viewcomp.c
> new file mode 100644
> index 0000000..0ef2b56
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-apac-viewcomp.c
> @@ -0,0 +1,80 @@
> +/* apac-viewcomp.h - Keytable for apac_viewcomp Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Attila Kondoros <attila.kondoros@chello.hu> */
> +
> +static struct ir_scancode apac_viewcomp[] = {
> +
> + { 0x01, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x03, KEY_3 },
> + { 0x04, KEY_4 },
> + { 0x05, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x09, KEY_9 },
> + { 0x00, KEY_0 },
> + { 0x17, KEY_LAST }, /* +100 */
> + { 0x0a, KEY_LIST }, /* recall */
> +
> +
> + { 0x1c, KEY_TUNER }, /* TV/FM */
> + { 0x15, KEY_SEARCH }, /* scan */
> + { 0x12, KEY_POWER }, /* power */
> + { 0x1f, KEY_VOLUMEDOWN }, /* vol up */
> + { 0x1b, KEY_VOLUMEUP }, /* vol down */
> + { 0x1e, KEY_CHANNELDOWN }, /* chn up */
> + { 0x1a, KEY_CHANNELUP }, /* chn down */
> +
> + { 0x11, KEY_VIDEO }, /* video */
> + { 0x0f, KEY_ZOOM }, /* full screen */
> + { 0x13, KEY_MUTE }, /* mute/unmute */
> + { 0x10, KEY_TEXT }, /* min */
> +
> + { 0x0d, KEY_STOP }, /* freeze */
> + { 0x0e, KEY_RECORD }, /* record */
> + { 0x1d, KEY_PLAYPAUSE }, /* stop */
> + { 0x19, KEY_PLAY }, /* play */
> +
> + { 0x16, KEY_GOTO }, /* osd */
> + { 0x14, KEY_REFRESH }, /* default */
> + { 0x0c, KEY_KPPLUS }, /* fine tune >>>> */
> + { 0x18, KEY_KPMINUS }, /* fine tune <<<< */
> +};
> +
> +static struct rc_keymap apac_viewcomp_map = {
> + .map = {
> + .scan = apac_viewcomp,
> + .size = ARRAY_SIZE(apac_viewcomp),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_APAC_VIEWCOMP,
> + }
> +};
> +
> +static int __init init_rc_map_apac_viewcomp(void)
> +{
> + return ir_register_map(&apac_viewcomp_map);
> +}
> +
> +static void __exit exit_rc_map_apac_viewcomp(void)
> +{
> + ir_unregister_map(&apac_viewcomp_map);
> +}
> +
> +module_init(init_rc_map_apac_viewcomp)
> +module_exit(exit_rc_map_apac_viewcomp)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-asus-pc39.c b/drivers/media/IR/keymaps/rc-asus-pc39.c
> new file mode 100644
> index 0000000..2aa068c
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-asus-pc39.c
> @@ -0,0 +1,91 @@
> +/* asus-pc39.h - Keytable for asus_pc39 Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/*
> + * Marc Fargas <telenieko@telenieko.com>
> + * this is the remote control that comes with the asus p7131
> + * which has a label saying is "Model PC-39"
> + */
> +
> +static struct ir_scancode asus_pc39[] = {
> + /* Keys 0 to 9 */
> + { 0x15, KEY_0 },
> + { 0x29, KEY_1 },
> + { 0x2d, KEY_2 },
> + { 0x2b, KEY_3 },
> + { 0x09, KEY_4 },
> + { 0x0d, KEY_5 },
> + { 0x0b, KEY_6 },
> + { 0x31, KEY_7 },
> + { 0x35, KEY_8 },
> + { 0x33, KEY_9 },
> +
> + { 0x3e, KEY_RADIO }, /* radio */
> + { 0x03, KEY_MENU }, /* dvd/menu */
> + { 0x2a, KEY_VOLUMEUP },
> + { 0x19, KEY_VOLUMEDOWN },
> + { 0x37, KEY_UP },
> + { 0x3b, KEY_DOWN },
> + { 0x27, KEY_LEFT },
> + { 0x2f, KEY_RIGHT },
> + { 0x25, KEY_VIDEO }, /* video */
> + { 0x39, KEY_AUDIO }, /* music */
> +
> + { 0x21, KEY_TV }, /* tv */
> + { 0x1d, KEY_EXIT }, /* back */
> + { 0x0a, KEY_CHANNELUP }, /* channel / program + */
> + { 0x1b, KEY_CHANNELDOWN }, /* channel / program - */
> + { 0x1a, KEY_ENTER }, /* enter */
> +
> + { 0x06, KEY_PAUSE }, /* play/pause */
> + { 0x1e, KEY_PREVIOUS }, /* rew */
> + { 0x26, KEY_NEXT }, /* forward */
> + { 0x0e, KEY_REWIND }, /* backward << */
> + { 0x3a, KEY_FASTFORWARD }, /* forward >> */
> + { 0x36, KEY_STOP },
> + { 0x2e, KEY_RECORD }, /* recording */
> + { 0x16, KEY_POWER }, /* the button that reads "close" */
> +
> + { 0x11, KEY_ZOOM }, /* full screen */
> + { 0x13, KEY_MACRO }, /* recall */
> + { 0x23, KEY_HOME }, /* home */
> + { 0x05, KEY_PVR }, /* picture */
> + { 0x3d, KEY_MUTE }, /* mute */
> + { 0x01, KEY_DVD }, /* dvd */
> +};
> +
> +static struct rc_keymap asus_pc39_map = {
> + .map = {
> + .scan = asus_pc39,
> + .size = ARRAY_SIZE(asus_pc39),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_ASUS_PC39,
> + }
> +};
> +
> +static int __init init_rc_map_asus_pc39(void)
> +{
> + return ir_register_map(&asus_pc39_map);
> +}
> +
> +static void __exit exit_rc_map_asus_pc39(void)
> +{
> + ir_unregister_map(&asus_pc39_map);
> +}
> +
> +module_init(init_rc_map_asus_pc39)
> +module_exit(exit_rc_map_asus_pc39)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-ati-tv-wonder-hd-600.c b/drivers/media/IR/keymaps/rc-ati-tv-wonder-hd-600.c
> new file mode 100644
> index 0000000..8edfd29
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-ati-tv-wonder-hd-600.c
> @@ -0,0 +1,69 @@
> +/* ati-tv-wonder-hd-600.h - Keytable for ati_tv_wonder_hd_600 Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* ATI TV Wonder HD 600 USB
> + Devin Heitmueller <devin.heitmueller@gmail.com>
> + */
> +
> +static struct ir_scancode ati_tv_wonder_hd_600[] = {
> + { 0x00, KEY_RECORD}, /* Row 1 */
> + { 0x01, KEY_PLAYPAUSE},
> + { 0x02, KEY_STOP},
> + { 0x03, KEY_POWER},
> + { 0x04, KEY_PREVIOUS}, /* Row 2 */
> + { 0x05, KEY_REWIND},
> + { 0x06, KEY_FORWARD},
> + { 0x07, KEY_NEXT},
> + { 0x08, KEY_EPG}, /* Row 3 */
> + { 0x09, KEY_HOME},
> + { 0x0a, KEY_MENU},
> + { 0x0b, KEY_CHANNELUP},
> + { 0x0c, KEY_BACK}, /* Row 4 */
> + { 0x0d, KEY_UP},
> + { 0x0e, KEY_INFO},
> + { 0x0f, KEY_CHANNELDOWN},
> + { 0x10, KEY_LEFT}, /* Row 5 */
> + { 0x11, KEY_SELECT},
> + { 0x12, KEY_RIGHT},
> + { 0x13, KEY_VOLUMEUP},
> + { 0x14, KEY_LAST}, /* Row 6 */
> + { 0x15, KEY_DOWN},
> + { 0x16, KEY_MUTE},
> + { 0x17, KEY_VOLUMEDOWN},
> +};
> +
> +static struct rc_keymap ati_tv_wonder_hd_600_map = {
> + .map = {
> + .scan = ati_tv_wonder_hd_600,
> + .size = ARRAY_SIZE(ati_tv_wonder_hd_600),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_ATI_TV_WONDER_HD_600,
> + }
> +};
> +
> +static int __init init_rc_map_ati_tv_wonder_hd_600(void)
> +{
> + return ir_register_map(&ati_tv_wonder_hd_600_map);
> +}
> +
> +static void __exit exit_rc_map_ati_tv_wonder_hd_600(void)
> +{
> + ir_unregister_map(&ati_tv_wonder_hd_600_map);
> +}
> +
> +module_init(init_rc_map_ati_tv_wonder_hd_600)
> +module_exit(exit_rc_map_ati_tv_wonder_hd_600)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-avermedia-a16d.c b/drivers/media/IR/keymaps/rc-avermedia-a16d.c
> new file mode 100644
> index 0000000..12f0435
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-avermedia-a16d.c
> @@ -0,0 +1,75 @@
> +/* avermedia-a16d.h - Keytable for avermedia_a16d Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +static struct ir_scancode avermedia_a16d[] = {
> + { 0x20, KEY_LIST},
> + { 0x00, KEY_POWER},
> + { 0x28, KEY_1},
> + { 0x18, KEY_2},
> + { 0x38, KEY_3},
> + { 0x24, KEY_4},
> + { 0x14, KEY_5},
> + { 0x34, KEY_6},
> + { 0x2c, KEY_7},
> + { 0x1c, KEY_8},
> + { 0x3c, KEY_9},
> + { 0x12, KEY_SUBTITLE},
> + { 0x22, KEY_0},
> + { 0x32, KEY_REWIND},
> + { 0x3a, KEY_SHUFFLE},
> + { 0x02, KEY_PRINT},
> + { 0x11, KEY_CHANNELDOWN},
> + { 0x31, KEY_CHANNELUP},
> + { 0x0c, KEY_ZOOM},
> + { 0x1e, KEY_VOLUMEDOWN},
> + { 0x3e, KEY_VOLUMEUP},
> + { 0x0a, KEY_MUTE},
> + { 0x04, KEY_AUDIO},
> + { 0x26, KEY_RECORD},
> + { 0x06, KEY_PLAY},
> + { 0x36, KEY_STOP},
> + { 0x16, KEY_PAUSE},
> + { 0x2e, KEY_REWIND},
> + { 0x0e, KEY_FASTFORWARD},
> + { 0x30, KEY_TEXT},
> + { 0x21, KEY_GREEN},
> + { 0x01, KEY_BLUE},
> + { 0x08, KEY_EPG},
> + { 0x2a, KEY_MENU},
> +};
> +
> +static struct rc_keymap avermedia_a16d_map = {
> + .map = {
> + .scan = avermedia_a16d,
> + .size = ARRAY_SIZE(avermedia_a16d),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_AVERMEDIA_A16D,
> + }
> +};
> +
> +static int __init init_rc_map_avermedia_a16d(void)
> +{
> + return ir_register_map(&avermedia_a16d_map);
> +}
> +
> +static void __exit exit_rc_map_avermedia_a16d(void)
> +{
> + ir_unregister_map(&avermedia_a16d_map);
> +}
> +
> +module_init(init_rc_map_avermedia_a16d)
> +module_exit(exit_rc_map_avermedia_a16d)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-avermedia-cardbus.c b/drivers/media/IR/keymaps/rc-avermedia-cardbus.c
> new file mode 100644
> index 0000000..2a945b0
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-avermedia-cardbus.c
> @@ -0,0 +1,97 @@
> +/* avermedia-cardbus.h - Keytable for avermedia_cardbus Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Oldrich Jedlicka <oldium.pro@seznam.cz> */
> +
> +static struct ir_scancode avermedia_cardbus[] = {
> + { 0x00, KEY_POWER },
> + { 0x01, KEY_TUNER }, /* TV/FM */
> + { 0x03, KEY_TEXT }, /* Teletext */
> + { 0x04, KEY_EPG },
> + { 0x05, KEY_1 },
> + { 0x06, KEY_2 },
> + { 0x07, KEY_3 },
> + { 0x08, KEY_AUDIO },
> + { 0x09, KEY_4 },
> + { 0x0a, KEY_5 },
> + { 0x0b, KEY_6 },
> + { 0x0c, KEY_ZOOM }, /* Full screen */
> + { 0x0d, KEY_7 },
> + { 0x0e, KEY_8 },
> + { 0x0f, KEY_9 },
> + { 0x10, KEY_PAGEUP }, /* 16-CH PREV */
> + { 0x11, KEY_0 },
> + { 0x12, KEY_INFO },
> + { 0x13, KEY_AGAIN }, /* CH RTN - channel return */
> + { 0x14, KEY_MUTE },
> + { 0x15, KEY_EDIT }, /* Autoscan */
> + { 0x17, KEY_SAVE }, /* Screenshot */
> + { 0x18, KEY_PLAYPAUSE },
> + { 0x19, KEY_RECORD },
> + { 0x1a, KEY_PLAY },
> + { 0x1b, KEY_STOP },
> + { 0x1c, KEY_FASTFORWARD },
> + { 0x1d, KEY_REWIND },
> + { 0x1e, KEY_VOLUMEDOWN },
> + { 0x1f, KEY_VOLUMEUP },
> + { 0x22, KEY_SLEEP }, /* Sleep */
> + { 0x23, KEY_ZOOM }, /* Aspect */
> + { 0x26, KEY_SCREEN }, /* Pos */
> + { 0x27, KEY_ANGLE }, /* Size */
> + { 0x28, KEY_SELECT }, /* Select */
> + { 0x29, KEY_BLUE }, /* Blue/Picture */
> + { 0x2a, KEY_BACKSPACE }, /* Back */
> + { 0x2b, KEY_MEDIA }, /* PIP (Picture-in-picture) */
> + { 0x2c, KEY_DOWN },
> + { 0x2e, KEY_DOT },
> + { 0x2f, KEY_TV }, /* Live TV */
> + { 0x32, KEY_LEFT },
> + { 0x33, KEY_CLEAR }, /* Clear */
> + { 0x35, KEY_RED }, /* Red/TV */
> + { 0x36, KEY_UP },
> + { 0x37, KEY_HOME }, /* Home */
> + { 0x39, KEY_GREEN }, /* Green/Video */
> + { 0x3d, KEY_YELLOW }, /* Yellow/Music */
> + { 0x3e, KEY_OK }, /* Ok */
> + { 0x3f, KEY_RIGHT },
> + { 0x40, KEY_NEXT }, /* Next */
> + { 0x41, KEY_PREVIOUS }, /* Previous */
> + { 0x42, KEY_CHANNELDOWN }, /* Channel down */
> + { 0x43, KEY_CHANNELUP }, /* Channel up */
> +};
> +
> +static struct rc_keymap avermedia_cardbus_map = {
> + .map = {
> + .scan = avermedia_cardbus,
> + .size = ARRAY_SIZE(avermedia_cardbus),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_AVERMEDIA_CARDBUS,
> + }
> +};
> +
> +static int __init init_rc_map_avermedia_cardbus(void)
> +{
> + return ir_register_map(&avermedia_cardbus_map);
> +}
> +
> +static void __exit exit_rc_map_avermedia_cardbus(void)
> +{
> + ir_unregister_map(&avermedia_cardbus_map);
> +}
> +
> +module_init(init_rc_map_avermedia_cardbus)
> +module_exit(exit_rc_map_avermedia_cardbus)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-avermedia-dvbt.c b/drivers/media/IR/keymaps/rc-avermedia-dvbt.c
> new file mode 100644
> index 0000000..39dde62
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-avermedia-dvbt.c
> @@ -0,0 +1,78 @@
> +/* avermedia-dvbt.h - Keytable for avermedia_dvbt Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Matt Jesson <dvb@jesson.eclipse.co.uk */
> +
> +static struct ir_scancode avermedia_dvbt[] = {
> + { 0x28, KEY_0 }, /* '0' / 'enter' */
> + { 0x22, KEY_1 }, /* '1' */
> + { 0x12, KEY_2 }, /* '2' / 'up arrow' */
> + { 0x32, KEY_3 }, /* '3' */
> + { 0x24, KEY_4 }, /* '4' / 'left arrow' */
> + { 0x14, KEY_5 }, /* '5' */
> + { 0x34, KEY_6 }, /* '6' / 'right arrow' */
> + { 0x26, KEY_7 }, /* '7' */
> + { 0x16, KEY_8 }, /* '8' / 'down arrow' */
> + { 0x36, KEY_9 }, /* '9' */
> +
> + { 0x20, KEY_LIST }, /* 'source' */
> + { 0x10, KEY_TEXT }, /* 'teletext' */
> + { 0x00, KEY_POWER }, /* 'power' */
> + { 0x04, KEY_AUDIO }, /* 'audio' */
> + { 0x06, KEY_ZOOM }, /* 'full screen' */
> + { 0x18, KEY_VIDEO }, /* 'display' */
> + { 0x38, KEY_SEARCH }, /* 'loop' */
> + { 0x08, KEY_INFO }, /* 'preview' */
> + { 0x2a, KEY_REWIND }, /* 'backward <<' */
> + { 0x1a, KEY_FASTFORWARD }, /* 'forward >>' */
> + { 0x3a, KEY_RECORD }, /* 'capture' */
> + { 0x0a, KEY_MUTE }, /* 'mute' */
> + { 0x2c, KEY_RECORD }, /* 'record' */
> + { 0x1c, KEY_PAUSE }, /* 'pause' */
> + { 0x3c, KEY_STOP }, /* 'stop' */
> + { 0x0c, KEY_PLAY }, /* 'play' */
> + { 0x2e, KEY_RED }, /* 'red' */
> + { 0x01, KEY_BLUE }, /* 'blue' / 'cancel' */
> + { 0x0e, KEY_YELLOW }, /* 'yellow' / 'ok' */
> + { 0x21, KEY_GREEN }, /* 'green' */
> + { 0x11, KEY_CHANNELDOWN }, /* 'channel -' */
> + { 0x31, KEY_CHANNELUP }, /* 'channel +' */
> + { 0x1e, KEY_VOLUMEDOWN }, /* 'volume -' */
> + { 0x3e, KEY_VOLUMEUP }, /* 'volume +' */
> +};
> +
> +static struct rc_keymap avermedia_dvbt_map = {
> + .map = {
> + .scan = avermedia_dvbt,
> + .size = ARRAY_SIZE(avermedia_dvbt),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_AVERMEDIA_DVBT,
> + }
> +};
> +
> +static int __init init_rc_map_avermedia_dvbt(void)
> +{
> + return ir_register_map(&avermedia_dvbt_map);
> +}
> +
> +static void __exit exit_rc_map_avermedia_dvbt(void)
> +{
> + ir_unregister_map(&avermedia_dvbt_map);
> +}
> +
> +module_init(init_rc_map_avermedia_dvbt)
> +module_exit(exit_rc_map_avermedia_dvbt)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-avermedia-m135a-rm-jx.c b/drivers/media/IR/keymaps/rc-avermedia-m135a-rm-jx.c
> new file mode 100644
> index 0000000..101e7ea
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-avermedia-m135a-rm-jx.c
> @@ -0,0 +1,90 @@
> +/* avermedia-m135a-rm-jx.h - Keytable for avermedia_m135a_rm_jx Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/*
> + * Avermedia M135A with IR model RM-JX
> + * The same codes exist on both Positivo (BR) and original IR
> + * Mauro Carvalho Chehab <mchehab@infradead.org>
> + */
> +
> +static struct ir_scancode avermedia_m135a_rm_jx[] = {
> + { 0x0200, KEY_POWER2 },
> + { 0x022e, KEY_DOT }, /* '.' */
> + { 0x0201, KEY_MODE }, /* TV/FM or SOURCE */
> +
> + { 0x0205, KEY_1 },
> + { 0x0206, KEY_2 },
> + { 0x0207, KEY_3 },
> + { 0x0209, KEY_4 },
> + { 0x020a, KEY_5 },
> + { 0x020b, KEY_6 },
> + { 0x020d, KEY_7 },
> + { 0x020e, KEY_8 },
> + { 0x020f, KEY_9 },
> + { 0x0211, KEY_0 },
> +
> + { 0x0213, KEY_RIGHT }, /* -> or L */
> + { 0x0212, KEY_LEFT }, /* <- or R */
> +
> + { 0x0217, KEY_SLEEP }, /* Capturar Imagem or Snapshot */
> + { 0x0210, KEY_SHUFFLE }, /* Amostra or 16 chan prev */
> +
> + { 0x0303, KEY_CHANNELUP },
> + { 0x0302, KEY_CHANNELDOWN },
> + { 0x021f, KEY_VOLUMEUP },
> + { 0x021e, KEY_VOLUMEDOWN },
> + { 0x020c, KEY_ENTER }, /* Full Screen */
> +
> + { 0x0214, KEY_MUTE },
> + { 0x0208, KEY_AUDIO },
> +
> + { 0x0203, KEY_TEXT }, /* Teletext */
> + { 0x0204, KEY_EPG },
> + { 0x022b, KEY_TV2 }, /* TV2 or PIP */
> +
> + { 0x021d, KEY_RED },
> + { 0x021c, KEY_YELLOW },
> + { 0x0301, KEY_GREEN },
> + { 0x0300, KEY_BLUE },
> +
> + { 0x021a, KEY_PLAYPAUSE },
> + { 0x0219, KEY_RECORD },
> + { 0x0218, KEY_PLAY },
> + { 0x021b, KEY_STOP },
> +};
> +
> +static struct rc_keymap avermedia_m135a_rm_jx_map = {
> + .map = {
> + .scan = avermedia_m135a_rm_jx,
> + .size = ARRAY_SIZE(avermedia_m135a_rm_jx),
> + .ir_type = IR_TYPE_NEC,
> + .name = RC_MAP_AVERMEDIA_M135A_RM_JX,
> + }
> +};
> +
> +static int __init init_rc_map_avermedia_m135a_rm_jx(void)
> +{
> + return ir_register_map(&avermedia_m135a_rm_jx_map);
> +}
> +
> +static void __exit exit_rc_map_avermedia_m135a_rm_jx(void)
> +{
> + ir_unregister_map(&avermedia_m135a_rm_jx_map);
> +}
> +
> +module_init(init_rc_map_avermedia_m135a_rm_jx)
> +module_exit(exit_rc_map_avermedia_m135a_rm_jx)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-avermedia.c b/drivers/media/IR/keymaps/rc-avermedia.c
> new file mode 100644
> index 0000000..21effd5
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-avermedia.c
> @@ -0,0 +1,86 @@
> +/* avermedia.h - Keytable for avermedia Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Alex Hermann <gaaf@gmx.net> */
> +
> +static struct ir_scancode avermedia[] = {
> + { 0x28, KEY_1 },
> + { 0x18, KEY_2 },
> + { 0x38, KEY_3 },
> + { 0x24, KEY_4 },
> + { 0x14, KEY_5 },
> + { 0x34, KEY_6 },
> + { 0x2c, KEY_7 },
> + { 0x1c, KEY_8 },
> + { 0x3c, KEY_9 },
> + { 0x22, KEY_0 },
> +
> + { 0x20, KEY_TV }, /* TV/FM */
> + { 0x10, KEY_CD }, /* CD */
> + { 0x30, KEY_TEXT }, /* TELETEXT */
> + { 0x00, KEY_POWER }, /* POWER */
> +
> + { 0x08, KEY_VIDEO }, /* VIDEO */
> + { 0x04, KEY_AUDIO }, /* AUDIO */
> + { 0x0c, KEY_ZOOM }, /* FULL SCREEN */
> +
> + { 0x12, KEY_SUBTITLE }, /* DISPLAY */
> + { 0x32, KEY_REWIND }, /* LOOP */
> + { 0x02, KEY_PRINT }, /* PREVIEW */
> +
> + { 0x2a, KEY_SEARCH }, /* AUTOSCAN */
> + { 0x1a, KEY_SLEEP }, /* FREEZE */
> + { 0x3a, KEY_CAMERA }, /* SNAPSHOT */
> + { 0x0a, KEY_MUTE }, /* MUTE */
> +
> + { 0x26, KEY_RECORD }, /* RECORD */
> + { 0x16, KEY_PAUSE }, /* PAUSE */
> + { 0x36, KEY_STOP }, /* STOP */
> + { 0x06, KEY_PLAY }, /* PLAY */
> +
> + { 0x2e, KEY_RED }, /* RED */
> + { 0x21, KEY_GREEN }, /* GREEN */
> + { 0x0e, KEY_YELLOW }, /* YELLOW */
> + { 0x01, KEY_BLUE }, /* BLUE */
> +
> + { 0x1e, KEY_VOLUMEDOWN }, /* VOLUME- */
> + { 0x3e, KEY_VOLUMEUP }, /* VOLUME+ */
> + { 0x11, KEY_CHANNELDOWN }, /* CHANNEL/PAGE- */
> + { 0x31, KEY_CHANNELUP } /* CHANNEL/PAGE+ */
> +};
> +
> +static struct rc_keymap avermedia_map = {
> + .map = {
> + .scan = avermedia,
> + .size = ARRAY_SIZE(avermedia),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_AVERMEDIA,
> + }
> +};
> +
> +static int __init init_rc_map_avermedia(void)
> +{
> + return ir_register_map(&avermedia_map);
> +}
> +
> +static void __exit exit_rc_map_avermedia(void)
> +{
> + ir_unregister_map(&avermedia_map);
> +}
> +
> +module_init(init_rc_map_avermedia)
> +module_exit(exit_rc_map_avermedia)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-avertv-303.c b/drivers/media/IR/keymaps/rc-avertv-303.c
> new file mode 100644
> index 0000000..971c59d
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-avertv-303.c
> @@ -0,0 +1,85 @@
> +/* avertv-303.h - Keytable for avertv_303 Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* AVERTV STUDIO 303 Remote */
> +
> +static struct ir_scancode avertv_303[] = {
> + { 0x2a, KEY_1 },
> + { 0x32, KEY_2 },
> + { 0x3a, KEY_3 },
> + { 0x4a, KEY_4 },
> + { 0x52, KEY_5 },
> + { 0x5a, KEY_6 },
> + { 0x6a, KEY_7 },
> + { 0x72, KEY_8 },
> + { 0x7a, KEY_9 },
> + { 0x0e, KEY_0 },
> +
> + { 0x02, KEY_POWER },
> + { 0x22, KEY_VIDEO },
> + { 0x42, KEY_AUDIO },
> + { 0x62, KEY_ZOOM },
> + { 0x0a, KEY_TV },
> + { 0x12, KEY_CD },
> + { 0x1a, KEY_TEXT },
> +
> + { 0x16, KEY_SUBTITLE },
> + { 0x1e, KEY_REWIND },
> + { 0x06, KEY_PRINT },
> +
> + { 0x2e, KEY_SEARCH },
> + { 0x36, KEY_SLEEP },
> + { 0x3e, KEY_SHUFFLE },
> + { 0x26, KEY_MUTE },
> +
> + { 0x4e, KEY_RECORD },
> + { 0x56, KEY_PAUSE },
> + { 0x5e, KEY_STOP },
> + { 0x46, KEY_PLAY },
> +
> + { 0x6e, KEY_RED },
> + { 0x0b, KEY_GREEN },
> + { 0x66, KEY_YELLOW },
> + { 0x03, KEY_BLUE },
> +
> + { 0x76, KEY_LEFT },
> + { 0x7e, KEY_RIGHT },
> + { 0x13, KEY_DOWN },
> + { 0x1b, KEY_UP },
> +};
> +
> +static struct rc_keymap avertv_303_map = {
> + .map = {
> + .scan = avertv_303,
> + .size = ARRAY_SIZE(avertv_303),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_AVERTV_303,
> + }
> +};
> +
> +static int __init init_rc_map_avertv_303(void)
> +{
> + return ir_register_map(&avertv_303_map);
> +}
> +
> +static void __exit exit_rc_map_avertv_303(void)
> +{
> + ir_unregister_map(&avertv_303_map);
> +}
> +
> +module_init(init_rc_map_avertv_303)
> +module_exit(exit_rc_map_avertv_303)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-behold-columbus.c b/drivers/media/IR/keymaps/rc-behold-columbus.c
> new file mode 100644
> index 0000000..9f56c98
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-behold-columbus.c
> @@ -0,0 +1,108 @@
> +/* behold-columbus.h - Keytable for behold_columbus Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Beholder Intl. Ltd. 2008
> + * Dmitry Belimov d.belimov@google.com
> + * Keytable is used by BeholdTV Columbus
> + * The "ascii-art picture" below (in comments, first row
> + * is the keycode in hex, and subsequent row(s) shows
> + * the button labels (several variants when appropriate)
> + * helps to descide which keycodes to assign to the buttons.
> + */
> +
> +static struct ir_scancode behold_columbus[] = {
> +
> + /* 0x13 0x11 0x1C 0x12 *
> + * Mute Source TV/FM Power *
> + * */
> +
> + { 0x13, KEY_MUTE },
> + { 0x11, KEY_PROPS },
> + { 0x1C, KEY_TUNER }, /* KEY_TV/KEY_RADIO */
> + { 0x12, KEY_POWER },
> +
> + /* 0x01 0x02 0x03 0x0D *
> + * 1 2 3 Stereo *
> + * *
> + * 0x04 0x05 0x06 0x19 *
> + * 4 5 6 Snapshot *
> + * *
> + * 0x07 0x08 0x09 0x10 *
> + * 7 8 9 Zoom *
> + * */
> + { 0x01, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x03, KEY_3 },
> + { 0x0D, KEY_SETUP }, /* Setup key */
> + { 0x04, KEY_4 },
> + { 0x05, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x19, KEY_CAMERA }, /* Snapshot key */
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x09, KEY_9 },
> + { 0x10, KEY_ZOOM },
> +
> + /* 0x0A 0x00 0x0B 0x0C *
> + * RECALL 0 ChannelUp VolumeUp *
> + * */
> + { 0x0A, KEY_AGAIN },
> + { 0x00, KEY_0 },
> + { 0x0B, KEY_CHANNELUP },
> + { 0x0C, KEY_VOLUMEUP },
> +
> + /* 0x1B 0x1D 0x15 0x18 *
> + * Timeshift Record ChannelDown VolumeDown *
> + * */
> +
> + { 0x1B, KEY_TIME },
> + { 0x1D, KEY_RECORD },
> + { 0x15, KEY_CHANNELDOWN },
> + { 0x18, KEY_VOLUMEDOWN },
> +
> + /* 0x0E 0x1E 0x0F 0x1A *
> + * Stop Pause Previouse Next *
> + * */
> +
> + { 0x0E, KEY_STOP },
> + { 0x1E, KEY_PAUSE },
> + { 0x0F, KEY_PREVIOUS },
> + { 0x1A, KEY_NEXT },
> +
> +};
> +
> +static struct rc_keymap behold_columbus_map = {
> + .map = {
> + .scan = behold_columbus,
> + .size = ARRAY_SIZE(behold_columbus),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_BEHOLD_COLUMBUS,
> + }
> +};
> +
> +static int __init init_rc_map_behold_columbus(void)
> +{
> + return ir_register_map(&behold_columbus_map);
> +}
> +
> +static void __exit exit_rc_map_behold_columbus(void)
> +{
> + ir_unregister_map(&behold_columbus_map);
> +}
> +
> +module_init(init_rc_map_behold_columbus)
> +module_exit(exit_rc_map_behold_columbus)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-behold.c b/drivers/media/IR/keymaps/rc-behold.c
> new file mode 100644
> index 0000000..abc140b
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-behold.c
> @@ -0,0 +1,141 @@
> +/* behold.h - Keytable for behold Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/*
> + * Igor Kuznetsov <igk72@ya.ru>
> + * Andrey J. Melnikov <temnota@kmv.ru>
> + *
> + * Keytable is used by BeholdTV 60x series, M6 series at
> + * least, and probably other cards too.
> + * The "ascii-art picture" below (in comments, first row
> + * is the keycode in hex, and subsequent row(s) shows
> + * the button labels (several variants when appropriate)
> + * helps to descide which keycodes to assign to the buttons.
> + */
> +
> +static struct ir_scancode behold[] = {
> +
> + /* 0x1c 0x12 *
> + * TV/FM POWER *
> + * */
> + { 0x1c, KEY_TUNER }, /* XXX KEY_TV / KEY_RADIO */
> + { 0x12, KEY_POWER },
> +
> + /* 0x01 0x02 0x03 *
> + * 1 2 3 *
> + * *
> + * 0x04 0x05 0x06 *
> + * 4 5 6 *
> + * *
> + * 0x07 0x08 0x09 *
> + * 7 8 9 *
> + * */
> + { 0x01, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x03, KEY_3 },
> + { 0x04, KEY_4 },
> + { 0x05, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x09, KEY_9 },
> +
> + /* 0x0a 0x00 0x17 *
> + * RECALL 0 MODE *
> + * */
> + { 0x0a, KEY_AGAIN },
> + { 0x00, KEY_0 },
> + { 0x17, KEY_MODE },
> +
> + /* 0x14 0x10 *
> + * ASPECT FULLSCREEN *
> + * */
> + { 0x14, KEY_SCREEN },
> + { 0x10, KEY_ZOOM },
> +
> + /* 0x0b *
> + * Up *
> + * *
> + * 0x18 0x16 0x0c *
> + * Left Ok Right *
> + * *
> + * 0x015 *
> + * Down *
> + * */
> + { 0x0b, KEY_CHANNELUP },
> + { 0x18, KEY_VOLUMEDOWN },
> + { 0x16, KEY_OK }, /* XXX KEY_ENTER */
> + { 0x0c, KEY_VOLUMEUP },
> + { 0x15, KEY_CHANNELDOWN },
> +
> + /* 0x11 0x0d *
> + * MUTE INFO *
> + * */
> + { 0x11, KEY_MUTE },
> + { 0x0d, KEY_INFO },
> +
> + /* 0x0f 0x1b 0x1a *
> + * RECORD PLAY/PAUSE STOP *
> + * *
> + * 0x0e 0x1f 0x1e *
> + *TELETEXT AUDIO SOURCE *
> + * RED YELLOW *
> + * */
> + { 0x0f, KEY_RECORD },
> + { 0x1b, KEY_PLAYPAUSE },
> + { 0x1a, KEY_STOP },
> + { 0x0e, KEY_TEXT },
> + { 0x1f, KEY_RED }, /*XXX KEY_AUDIO */
> + { 0x1e, KEY_YELLOW }, /*XXX KEY_SOURCE */
> +
> + /* 0x1d 0x13 0x19 *
> + * SLEEP PREVIEW DVB *
> + * GREEN BLUE *
> + * */
> + { 0x1d, KEY_SLEEP },
> + { 0x13, KEY_GREEN },
> + { 0x19, KEY_BLUE }, /* XXX KEY_SAT */
> +
> + /* 0x58 0x5c *
> + * FREEZE SNAPSHOT *
> + * */
> + { 0x58, KEY_SLOW },
> + { 0x5c, KEY_CAMERA },
> +
> +};
> +
> +static struct rc_keymap behold_map = {
> + .map = {
> + .scan = behold,
> + .size = ARRAY_SIZE(behold),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_BEHOLD,
> + }
> +};
> +
> +static int __init init_rc_map_behold(void)
> +{
> + return ir_register_map(&behold_map);
> +}
> +
> +static void __exit exit_rc_map_behold(void)
> +{
> + ir_unregister_map(&behold_map);
> +}
> +
> +module_init(init_rc_map_behold)
> +module_exit(exit_rc_map_behold)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-budget-ci-old.c b/drivers/media/IR/keymaps/rc-budget-ci-old.c
> new file mode 100644
> index 0000000..64c2ac9
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-budget-ci-old.c
> @@ -0,0 +1,92 @@
> +/* budget-ci-old.h - Keytable for budget_ci_old Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* From reading the following remotes:
> + * Zenith Universal 7 / TV Mode 807 / VCR Mode 837
> + * Hauppauge (from NOVA-CI-s box product)
> + * This is a "middle of the road" approach, differences are noted
> + */
> +
> +static struct ir_scancode budget_ci_old[] = {
> + { 0x00, KEY_0 },
> + { 0x01, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x03, KEY_3 },
> + { 0x04, KEY_4 },
> + { 0x05, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x09, KEY_9 },
> + { 0x0a, KEY_ENTER },
> + { 0x0b, KEY_RED },
> + { 0x0c, KEY_POWER }, /* RADIO on Hauppauge */
> + { 0x0d, KEY_MUTE },
> + { 0x0f, KEY_A }, /* TV on Hauppauge */
> + { 0x10, KEY_VOLUMEUP },
> + { 0x11, KEY_VOLUMEDOWN },
> + { 0x14, KEY_B },
> + { 0x1c, KEY_UP },
> + { 0x1d, KEY_DOWN },
> + { 0x1e, KEY_OPTION }, /* RESERVED on Hauppauge */
> + { 0x1f, KEY_BREAK },
> + { 0x20, KEY_CHANNELUP },
> + { 0x21, KEY_CHANNELDOWN },
> + { 0x22, KEY_PREVIOUS }, /* Prev Ch on Zenith, SOURCE on Hauppauge */
> + { 0x24, KEY_RESTART },
> + { 0x25, KEY_OK },
> + { 0x26, KEY_CYCLEWINDOWS }, /* MINIMIZE on Hauppauge */
> + { 0x28, KEY_ENTER }, /* VCR mode on Zenith */
> + { 0x29, KEY_PAUSE },
> + { 0x2b, KEY_RIGHT },
> + { 0x2c, KEY_LEFT },
> + { 0x2e, KEY_MENU }, /* FULL SCREEN on Hauppauge */
> + { 0x30, KEY_SLOW },
> + { 0x31, KEY_PREVIOUS }, /* VCR mode on Zenith */
> + { 0x32, KEY_REWIND },
> + { 0x34, KEY_FASTFORWARD },
> + { 0x35, KEY_PLAY },
> + { 0x36, KEY_STOP },
> + { 0x37, KEY_RECORD },
> + { 0x38, KEY_TUNER }, /* TV/VCR on Zenith */
> + { 0x3a, KEY_C },
> + { 0x3c, KEY_EXIT },
> + { 0x3d, KEY_POWER2 },
> + { 0x3e, KEY_TUNER },
> +};
> +
> +static struct rc_keymap budget_ci_old_map = {
> + .map = {
> + .scan = budget_ci_old,
> + .size = ARRAY_SIZE(budget_ci_old),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_BUDGET_CI_OLD,
> + }
> +};
> +
> +static int __init init_rc_map_budget_ci_old(void)
> +{
> + return ir_register_map(&budget_ci_old_map);
> +}
> +
> +static void __exit exit_rc_map_budget_ci_old(void)
> +{
> + ir_unregister_map(&budget_ci_old_map);
> +}
> +
> +module_init(init_rc_map_budget_ci_old)
> +module_exit(exit_rc_map_budget_ci_old)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-cinergy-1400.c b/drivers/media/IR/keymaps/rc-cinergy-1400.c
> new file mode 100644
> index 0000000..074f2c2
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-cinergy-1400.c
> @@ -0,0 +1,84 @@
> +/* cinergy-1400.h - Keytable for cinergy_1400 Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Cinergy 1400 DVB-T */
> +
> +static struct ir_scancode cinergy_1400[] = {
> + { 0x01, KEY_POWER },
> + { 0x02, KEY_1 },
> + { 0x03, KEY_2 },
> + { 0x04, KEY_3 },
> + { 0x05, KEY_4 },
> + { 0x06, KEY_5 },
> + { 0x07, KEY_6 },
> + { 0x08, KEY_7 },
> + { 0x09, KEY_8 },
> + { 0x0a, KEY_9 },
> + { 0x0c, KEY_0 },
> +
> + { 0x0b, KEY_VIDEO },
> + { 0x0d, KEY_REFRESH },
> + { 0x0e, KEY_SELECT },
> + { 0x0f, KEY_EPG },
> + { 0x10, KEY_UP },
> + { 0x11, KEY_LEFT },
> + { 0x12, KEY_OK },
> + { 0x13, KEY_RIGHT },
> + { 0x14, KEY_DOWN },
> + { 0x15, KEY_TEXT },
> + { 0x16, KEY_INFO },
> +
> + { 0x17, KEY_RED },
> + { 0x18, KEY_GREEN },
> + { 0x19, KEY_YELLOW },
> + { 0x1a, KEY_BLUE },
> +
> + { 0x1b, KEY_CHANNELUP },
> + { 0x1c, KEY_VOLUMEUP },
> + { 0x1d, KEY_MUTE },
> + { 0x1e, KEY_VOLUMEDOWN },
> + { 0x1f, KEY_CHANNELDOWN },
> +
> + { 0x40, KEY_PAUSE },
> + { 0x4c, KEY_PLAY },
> + { 0x58, KEY_RECORD },
> + { 0x54, KEY_PREVIOUS },
> + { 0x48, KEY_STOP },
> + { 0x5c, KEY_NEXT },
> +};
> +
> +static struct rc_keymap cinergy_1400_map = {
> + .map = {
> + .scan = cinergy_1400,
> + .size = ARRAY_SIZE(cinergy_1400),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_CINERGY_1400,
> + }
> +};
> +
> +static int __init init_rc_map_cinergy_1400(void)
> +{
> + return ir_register_map(&cinergy_1400_map);
> +}
> +
> +static void __exit exit_rc_map_cinergy_1400(void)
> +{
> + ir_unregister_map(&cinergy_1400_map);
> +}
> +
> +module_init(init_rc_map_cinergy_1400)
> +module_exit(exit_rc_map_cinergy_1400)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-cinergy.c b/drivers/media/IR/keymaps/rc-cinergy.c
> new file mode 100644
> index 0000000..cf84c3d
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-cinergy.c
> @@ -0,0 +1,78 @@
> +/* cinergy.h - Keytable for cinergy Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +static struct ir_scancode cinergy[] = {
> + { 0x00, KEY_0 },
> + { 0x01, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x03, KEY_3 },
> + { 0x04, KEY_4 },
> + { 0x05, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x09, KEY_9 },
> +
> + { 0x0a, KEY_POWER },
> + { 0x0b, KEY_PROG1 }, /* app */
> + { 0x0c, KEY_ZOOM }, /* zoom/fullscreen */
> + { 0x0d, KEY_CHANNELUP }, /* channel */
> + { 0x0e, KEY_CHANNELDOWN }, /* channel- */
> + { 0x0f, KEY_VOLUMEUP },
> + { 0x10, KEY_VOLUMEDOWN },
> + { 0x11, KEY_TUNER }, /* AV */
> + { 0x12, KEY_NUMLOCK }, /* -/-- */
> + { 0x13, KEY_AUDIO }, /* audio */
> + { 0x14, KEY_MUTE },
> + { 0x15, KEY_UP },
> + { 0x16, KEY_DOWN },
> + { 0x17, KEY_LEFT },
> + { 0x18, KEY_RIGHT },
> + { 0x19, BTN_LEFT, },
> + { 0x1a, BTN_RIGHT, },
> + { 0x1b, KEY_WWW }, /* text */
> + { 0x1c, KEY_REWIND },
> + { 0x1d, KEY_FORWARD },
> + { 0x1e, KEY_RECORD },
> + { 0x1f, KEY_PLAY },
> + { 0x20, KEY_PREVIOUSSONG },
> + { 0x21, KEY_NEXTSONG },
> + { 0x22, KEY_PAUSE },
> + { 0x23, KEY_STOP },
> +};
> +
> +static struct rc_keymap cinergy_map = {
> + .map = {
> + .scan = cinergy,
> + .size = ARRAY_SIZE(cinergy),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_CINERGY,
> + }
> +};
> +
> +static int __init init_rc_map_cinergy(void)
> +{
> + return ir_register_map(&cinergy_map);
> +}
> +
> +static void __exit exit_rc_map_cinergy(void)
> +{
> + ir_unregister_map(&cinergy_map);
> +}
> +
> +module_init(init_rc_map_cinergy)
> +module_exit(exit_rc_map_cinergy)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-dm1105-nec.c b/drivers/media/IR/keymaps/rc-dm1105-nec.c
> new file mode 100644
> index 0000000..90684d0
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-dm1105-nec.c
> @@ -0,0 +1,76 @@
> +/* dm1105-nec.h - Keytable for dm1105_nec Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* DVBWorld remotes
> + Igor M. Liplianin <liplianin@me.by>
> + */
> +
> +static struct ir_scancode dm1105_nec[] = {
> + { 0x0a, KEY_POWER2}, /* power */
> + { 0x0c, KEY_MUTE}, /* mute */
> + { 0x11, KEY_1},
> + { 0x12, KEY_2},
> + { 0x13, KEY_3},
> + { 0x14, KEY_4},
> + { 0x15, KEY_5},
> + { 0x16, KEY_6},
> + { 0x17, KEY_7},
> + { 0x18, KEY_8},
> + { 0x19, KEY_9},
> + { 0x10, KEY_0},
> + { 0x1c, KEY_CHANNELUP}, /* ch+ */
> + { 0x0f, KEY_CHANNELDOWN}, /* ch- */
> + { 0x1a, KEY_VOLUMEUP}, /* vol+ */
> + { 0x0e, KEY_VOLUMEDOWN}, /* vol- */
> + { 0x04, KEY_RECORD}, /* rec */
> + { 0x09, KEY_CHANNEL}, /* fav */
> + { 0x08, KEY_BACKSPACE}, /* rewind */
> + { 0x07, KEY_FASTFORWARD}, /* fast */
> + { 0x0b, KEY_PAUSE}, /* pause */
> + { 0x02, KEY_ESC}, /* cancel */
> + { 0x03, KEY_TAB}, /* tab */
> + { 0x00, KEY_UP}, /* up */
> + { 0x1f, KEY_ENTER}, /* ok */
> + { 0x01, KEY_DOWN}, /* down */
> + { 0x05, KEY_RECORD}, /* cap */
> + { 0x06, KEY_STOP}, /* stop */
> + { 0x40, KEY_ZOOM}, /* full */
> + { 0x1e, KEY_TV}, /* tvmode */
> + { 0x1b, KEY_B}, /* recall */
> +};
> +
> +static struct rc_keymap dm1105_nec_map = {
> + .map = {
> + .scan = dm1105_nec,
> + .size = ARRAY_SIZE(dm1105_nec),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_DM1105_NEC,
> + }
> +};
> +
> +static int __init init_rc_map_dm1105_nec(void)
> +{
> + return ir_register_map(&dm1105_nec_map);
> +}
> +
> +static void __exit exit_rc_map_dm1105_nec(void)
> +{
> + ir_unregister_map(&dm1105_nec_map);
> +}
> +
> +module_init(init_rc_map_dm1105_nec)
> +module_exit(exit_rc_map_dm1105_nec)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-dntv-live-dvb-t.c b/drivers/media/IR/keymaps/rc-dntv-live-dvb-t.c
> new file mode 100644
> index 0000000..8a4027a
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-dntv-live-dvb-t.c
> @@ -0,0 +1,78 @@
> +/* dntv-live-dvb-t.h - Keytable for dntv_live_dvb_t Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* DigitalNow DNTV Live DVB-T Remote */
> +
> +static struct ir_scancode dntv_live_dvb_t[] = {
> + { 0x00, KEY_ESC }, /* 'go up a level?' */
> + /* Keys 0 to 9 */
> + { 0x0a, KEY_0 },
> + { 0x01, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x03, KEY_3 },
> + { 0x04, KEY_4 },
> + { 0x05, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x09, KEY_9 },
> +
> + { 0x0b, KEY_TUNER }, /* tv/fm */
> + { 0x0c, KEY_SEARCH }, /* scan */
> + { 0x0d, KEY_STOP },
> + { 0x0e, KEY_PAUSE },
> + { 0x0f, KEY_LIST }, /* source */
> +
> + { 0x10, KEY_MUTE },
> + { 0x11, KEY_REWIND }, /* backward << */
> + { 0x12, KEY_POWER },
> + { 0x13, KEY_CAMERA }, /* snap */
> + { 0x14, KEY_AUDIO }, /* stereo */
> + { 0x15, KEY_CLEAR }, /* reset */
> + { 0x16, KEY_PLAY },
> + { 0x17, KEY_ENTER },
> + { 0x18, KEY_ZOOM }, /* full screen */
> + { 0x19, KEY_FASTFORWARD }, /* forward >> */
> + { 0x1a, KEY_CHANNELUP },
> + { 0x1b, KEY_VOLUMEUP },
> + { 0x1c, KEY_INFO }, /* preview */
> + { 0x1d, KEY_RECORD }, /* record */
> + { 0x1e, KEY_CHANNELDOWN },
> + { 0x1f, KEY_VOLUMEDOWN },
> +};
> +
> +static struct rc_keymap dntv_live_dvb_t_map = {
> + .map = {
> + .scan = dntv_live_dvb_t,
> + .size = ARRAY_SIZE(dntv_live_dvb_t),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_DNTV_LIVE_DVB_T,
> + }
> +};
> +
> +static int __init init_rc_map_dntv_live_dvb_t(void)
> +{
> + return ir_register_map(&dntv_live_dvb_t_map);
> +}
> +
> +static void __exit exit_rc_map_dntv_live_dvb_t(void)
> +{
> + ir_unregister_map(&dntv_live_dvb_t_map);
> +}
> +
> +module_init(init_rc_map_dntv_live_dvb_t)
> +module_exit(exit_rc_map_dntv_live_dvb_t)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-dntv-live-dvbt-pro.c b/drivers/media/IR/keymaps/rc-dntv-live-dvbt-pro.c
> new file mode 100644
> index 0000000..6f4d607
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-dntv-live-dvbt-pro.c
> @@ -0,0 +1,97 @@
> +/* dntv-live-dvbt-pro.h - Keytable for dntv_live_dvbt_pro Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* DigitalNow DNTV Live! DVB-T Pro Remote */
> +
> +static struct ir_scancode dntv_live_dvbt_pro[] = {
> + { 0x16, KEY_POWER },
> + { 0x5b, KEY_HOME },
> +
> + { 0x55, KEY_TV }, /* live tv */
> + { 0x58, KEY_TUNER }, /* digital Radio */
> + { 0x5a, KEY_RADIO }, /* FM radio */
> + { 0x59, KEY_DVD }, /* dvd menu */
> + { 0x03, KEY_1 },
> + { 0x01, KEY_2 },
> + { 0x06, KEY_3 },
> + { 0x09, KEY_4 },
> + { 0x1d, KEY_5 },
> + { 0x1f, KEY_6 },
> + { 0x0d, KEY_7 },
> + { 0x19, KEY_8 },
> + { 0x1b, KEY_9 },
> + { 0x0c, KEY_CANCEL },
> + { 0x15, KEY_0 },
> + { 0x4a, KEY_CLEAR },
> + { 0x13, KEY_BACK },
> + { 0x00, KEY_TAB },
> + { 0x4b, KEY_UP },
> + { 0x4e, KEY_LEFT },
> + { 0x4f, KEY_OK },
> + { 0x52, KEY_RIGHT },
> + { 0x51, KEY_DOWN },
> + { 0x1e, KEY_VOLUMEUP },
> + { 0x0a, KEY_VOLUMEDOWN },
> + { 0x02, KEY_CHANNELDOWN },
> + { 0x05, KEY_CHANNELUP },
> + { 0x11, KEY_RECORD },
> + { 0x14, KEY_PLAY },
> + { 0x4c, KEY_PAUSE },
> + { 0x1a, KEY_STOP },
> + { 0x40, KEY_REWIND },
> + { 0x12, KEY_FASTFORWARD },
> + { 0x41, KEY_PREVIOUSSONG }, /* replay |< */
> + { 0x42, KEY_NEXTSONG }, /* skip >| */
> + { 0x54, KEY_CAMERA }, /* capture */
> + { 0x50, KEY_LANGUAGE }, /* sap */
> + { 0x47, KEY_TV2 }, /* pip */
> + { 0x4d, KEY_SCREEN },
> + { 0x43, KEY_SUBTITLE },
> + { 0x10, KEY_MUTE },
> + { 0x49, KEY_AUDIO }, /* l/r */
> + { 0x07, KEY_SLEEP },
> + { 0x08, KEY_VIDEO }, /* a/v */
> + { 0x0e, KEY_PREVIOUS }, /* recall */
> + { 0x45, KEY_ZOOM }, /* zoom + */
> + { 0x46, KEY_ANGLE }, /* zoom - */
> + { 0x56, KEY_RED },
> + { 0x57, KEY_GREEN },
> + { 0x5c, KEY_YELLOW },
> + { 0x5d, KEY_BLUE },
> +};
> +
> +static struct rc_keymap dntv_live_dvbt_pro_map = {
> + .map = {
> + .scan = dntv_live_dvbt_pro,
> + .size = ARRAY_SIZE(dntv_live_dvbt_pro),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_DNTV_LIVE_DVBT_PRO,
> + }
> +};
> +
> +static int __init init_rc_map_dntv_live_dvbt_pro(void)
> +{
> + return ir_register_map(&dntv_live_dvbt_pro_map);
> +}
> +
> +static void __exit exit_rc_map_dntv_live_dvbt_pro(void)
> +{
> + ir_unregister_map(&dntv_live_dvbt_pro_map);
> +}
> +
> +module_init(init_rc_map_dntv_live_dvbt_pro)
> +module_exit(exit_rc_map_dntv_live_dvbt_pro)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-em-terratec.c b/drivers/media/IR/keymaps/rc-em-terratec.c
> new file mode 100644
> index 0000000..3130c9c
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-em-terratec.c
> @@ -0,0 +1,69 @@
> +/* em-terratec.h - Keytable for em_terratec Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +static struct ir_scancode em_terratec[] = {
> + { 0x01, KEY_CHANNEL },
> + { 0x02, KEY_SELECT },
> + { 0x03, KEY_MUTE },
> + { 0x04, KEY_POWER },
> + { 0x05, KEY_1 },
> + { 0x06, KEY_2 },
> + { 0x07, KEY_3 },
> + { 0x08, KEY_CHANNELUP },
> + { 0x09, KEY_4 },
> + { 0x0a, KEY_5 },
> + { 0x0b, KEY_6 },
> + { 0x0c, KEY_CHANNELDOWN },
> + { 0x0d, KEY_7 },
> + { 0x0e, KEY_8 },
> + { 0x0f, KEY_9 },
> + { 0x10, KEY_VOLUMEUP },
> + { 0x11, KEY_0 },
> + { 0x12, KEY_MENU },
> + { 0x13, KEY_PRINT },
> + { 0x14, KEY_VOLUMEDOWN },
> + { 0x16, KEY_PAUSE },
> + { 0x18, KEY_RECORD },
> + { 0x19, KEY_REWIND },
> + { 0x1a, KEY_PLAY },
> + { 0x1b, KEY_FORWARD },
> + { 0x1c, KEY_BACKSPACE },
> + { 0x1e, KEY_STOP },
> + { 0x40, KEY_ZOOM },
> +};
> +
> +static struct rc_keymap em_terratec_map = {
> + .map = {
> + .scan = em_terratec,
> + .size = ARRAY_SIZE(em_terratec),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_EM_TERRATEC,
> + }
> +};
> +
> +static int __init init_rc_map_em_terratec(void)
> +{
> + return ir_register_map(&em_terratec_map);
> +}
> +
> +static void __exit exit_rc_map_em_terratec(void)
> +{
> + ir_unregister_map(&em_terratec_map);
> +}
> +
> +module_init(init_rc_map_em_terratec)
> +module_exit(exit_rc_map_em_terratec)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-empty.c b/drivers/media/IR/keymaps/rc-empty.c
> new file mode 100644
> index 0000000..3b338d8
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-empty.c
> @@ -0,0 +1,44 @@
> +/* empty.h - Keytable for empty Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* empty keytable, can be used as placeholder for not-yet created keytables */
> +
> +static struct ir_scancode empty[] = {
> + { 0x2a, KEY_COFFEE },
> +};
> +
> +static struct rc_keymap empty_map = {
> + .map = {
> + .scan = empty,
> + .size = ARRAY_SIZE(empty),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_EMPTY,
> + }
> +};
> +
> +static int __init init_rc_map_empty(void)
> +{
> + return ir_register_map(&empty_map);
> +}
> +
> +static void __exit exit_rc_map_empty(void)
> +{
> + ir_unregister_map(&empty_map);
> +}
> +
> +module_init(init_rc_map_empty)
> +module_exit(exit_rc_map_empty)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-encore-enltv-fm53.c b/drivers/media/IR/keymaps/rc-encore-enltv-fm53.c
> new file mode 100644
> index 0000000..4b81696
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-encore-enltv-fm53.c
> @@ -0,0 +1,81 @@
> +/* encore-enltv-fm53.h - Keytable for encore_enltv_fm53 Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Encore ENLTV-FM v5.3
> + Mauro Carvalho Chehab <mchehab@infradead.org>
> + */
> +
> +static struct ir_scancode encore_enltv_fm53[] = {
> + { 0x10, KEY_POWER2},
> + { 0x06, KEY_MUTE},
> +
> + { 0x09, KEY_1},
> + { 0x1d, KEY_2},
> + { 0x1f, KEY_3},
> + { 0x19, KEY_4},
> + { 0x1b, KEY_5},
> + { 0x11, KEY_6},
> + { 0x17, KEY_7},
> + { 0x12, KEY_8},
> + { 0x16, KEY_9},
> + { 0x48, KEY_0},
> +
> + { 0x04, KEY_LIST}, /* -/-- */
> + { 0x40, KEY_LAST}, /* recall */
> +
> + { 0x02, KEY_MODE}, /* TV/AV */
> + { 0x05, KEY_CAMERA}, /* SNAPSHOT */
> +
> + { 0x4c, KEY_CHANNELUP}, /* UP */
> + { 0x00, KEY_CHANNELDOWN}, /* DOWN */
> + { 0x0d, KEY_VOLUMEUP}, /* RIGHT */
> + { 0x15, KEY_VOLUMEDOWN}, /* LEFT */
> + { 0x49, KEY_ENTER}, /* OK */
> +
> + { 0x54, KEY_RECORD},
> + { 0x4d, KEY_PLAY}, /* pause */
> +
> + { 0x1e, KEY_MENU}, /* video setting */
> + { 0x0e, KEY_RIGHT}, /* <- */
> + { 0x1a, KEY_LEFT}, /* -> */
> +
> + { 0x0a, KEY_CLEAR}, /* video default */
> + { 0x0c, KEY_ZOOM}, /* hide pannel */
> + { 0x47, KEY_SLEEP}, /* shutdown */
> +};
> +
> +static struct rc_keymap encore_enltv_fm53_map = {
> + .map = {
> + .scan = encore_enltv_fm53,
> + .size = ARRAY_SIZE(encore_enltv_fm53),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_ENCORE_ENLTV_FM53,
> + }
> +};
> +
> +static int __init init_rc_map_encore_enltv_fm53(void)
> +{
> + return ir_register_map(&encore_enltv_fm53_map);
> +}
> +
> +static void __exit exit_rc_map_encore_enltv_fm53(void)
> +{
> + ir_unregister_map(&encore_enltv_fm53_map);
> +}
> +
> +module_init(init_rc_map_encore_enltv_fm53)
> +module_exit(exit_rc_map_encore_enltv_fm53)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-encore-enltv.c b/drivers/media/IR/keymaps/rc-encore-enltv.c
> new file mode 100644
> index 0000000..9fabffd
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-encore-enltv.c
> @@ -0,0 +1,112 @@
> +/* encore-enltv.h - Keytable for encore_enltv Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Encore ENLTV-FM - black plastic, white front cover with white glowing buttons
> + Juan Pablo Sormani <sorman@gmail.com> */
> +
> +static struct ir_scancode encore_enltv[] = {
> +
> + /* Power button does nothing, neither in Windows app,
> + although it sends data (used for BIOS wakeup?) */
> + { 0x0d, KEY_MUTE },
> +
> + { 0x1e, KEY_TV },
> + { 0x00, KEY_VIDEO },
> + { 0x01, KEY_AUDIO }, /* music */
> + { 0x02, KEY_MHP }, /* picture */
> +
> + { 0x1f, KEY_1 },
> + { 0x03, KEY_2 },
> + { 0x04, KEY_3 },
> + { 0x05, KEY_4 },
> + { 0x1c, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x1d, KEY_9 },
> + { 0x0a, KEY_0 },
> +
> + { 0x09, KEY_LIST }, /* -/-- */
> + { 0x0b, KEY_LAST }, /* recall */
> +
> + { 0x14, KEY_HOME }, /* win start menu */
> + { 0x15, KEY_EXIT }, /* exit */
> + { 0x16, KEY_CHANNELUP }, /* UP */
> + { 0x12, KEY_CHANNELDOWN }, /* DOWN */
> + { 0x0c, KEY_VOLUMEUP }, /* RIGHT */
> + { 0x17, KEY_VOLUMEDOWN }, /* LEFT */
> +
> + { 0x18, KEY_ENTER }, /* OK */
> +
> + { 0x0e, KEY_ESC },
> + { 0x13, KEY_CYCLEWINDOWS }, /* desktop */
> + { 0x11, KEY_TAB },
> + { 0x19, KEY_SWITCHVIDEOMODE }, /* switch */
> +
> + { 0x1a, KEY_MENU },
> + { 0x1b, KEY_ZOOM }, /* fullscreen */
> + { 0x44, KEY_TIME }, /* time shift */
> + { 0x40, KEY_MODE }, /* source */
> +
> + { 0x5a, KEY_RECORD },
> + { 0x42, KEY_PLAY }, /* play/pause */
> + { 0x45, KEY_STOP },
> + { 0x43, KEY_CAMERA }, /* camera icon */
> +
> + { 0x48, KEY_REWIND },
> + { 0x4a, KEY_FASTFORWARD },
> + { 0x49, KEY_PREVIOUS },
> + { 0x4b, KEY_NEXT },
> +
> + { 0x4c, KEY_FAVORITES }, /* tv wall */
> + { 0x4d, KEY_SOUND }, /* DVD sound */
> + { 0x4e, KEY_LANGUAGE }, /* DVD lang */
> + { 0x4f, KEY_TEXT }, /* DVD text */
> +
> + { 0x50, KEY_SLEEP }, /* shutdown */
> + { 0x51, KEY_MODE }, /* stereo > main */
> + { 0x52, KEY_SELECT }, /* stereo > sap */
> + { 0x53, KEY_PROG1 }, /* teletext */
> +
> +
> + { 0x59, KEY_RED }, /* AP1 */
> + { 0x41, KEY_GREEN }, /* AP2 */
> + { 0x47, KEY_YELLOW }, /* AP3 */
> + { 0x57, KEY_BLUE }, /* AP4 */
> +};
> +
> +static struct rc_keymap encore_enltv_map = {
> + .map = {
> + .scan = encore_enltv,
> + .size = ARRAY_SIZE(encore_enltv),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_ENCORE_ENLTV,
> + }
> +};
> +
> +static int __init init_rc_map_encore_enltv(void)
> +{
> + return ir_register_map(&encore_enltv_map);
> +}
> +
> +static void __exit exit_rc_map_encore_enltv(void)
> +{
> + ir_unregister_map(&encore_enltv_map);
> +}
> +
> +module_init(init_rc_map_encore_enltv)
> +module_exit(exit_rc_map_encore_enltv)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-encore-enltv2.c b/drivers/media/IR/keymaps/rc-encore-enltv2.c
> new file mode 100644
> index 0000000..efefd51
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-encore-enltv2.c
> @@ -0,0 +1,90 @@
> +/* encore-enltv2.h - Keytable for encore_enltv2 Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Encore ENLTV2-FM - silver plastic - "Wand Media" written at the botton
> + Mauro Carvalho Chehab <mchehab@infradead.org> */
> +
> +static struct ir_scancode encore_enltv2[] = {
> + { 0x4c, KEY_POWER2 },
> + { 0x4a, KEY_TUNER },
> + { 0x40, KEY_1 },
> + { 0x60, KEY_2 },
> + { 0x50, KEY_3 },
> + { 0x70, KEY_4 },
> + { 0x48, KEY_5 },
> + { 0x68, KEY_6 },
> + { 0x58, KEY_7 },
> + { 0x78, KEY_8 },
> + { 0x44, KEY_9 },
> + { 0x54, KEY_0 },
> +
> + { 0x64, KEY_LAST }, /* +100 */
> + { 0x4e, KEY_AGAIN }, /* Recall */
> +
> + { 0x6c, KEY_SWITCHVIDEOMODE }, /* Video Source */
> + { 0x5e, KEY_MENU },
> + { 0x56, KEY_SCREEN },
> + { 0x7a, KEY_SETUP },
> +
> + { 0x46, KEY_MUTE },
> + { 0x5c, KEY_MODE }, /* Stereo */
> + { 0x74, KEY_INFO },
> + { 0x7c, KEY_CLEAR },
> +
> + { 0x55, KEY_UP },
> + { 0x49, KEY_DOWN },
> + { 0x7e, KEY_LEFT },
> + { 0x59, KEY_RIGHT },
> + { 0x6a, KEY_ENTER },
> +
> + { 0x42, KEY_VOLUMEUP },
> + { 0x62, KEY_VOLUMEDOWN },
> + { 0x52, KEY_CHANNELUP },
> + { 0x72, KEY_CHANNELDOWN },
> +
> + { 0x41, KEY_RECORD },
> + { 0x51, KEY_CAMERA }, /* Snapshot */
> + { 0x75, KEY_TIME }, /* Timeshift */
> + { 0x71, KEY_TV2 }, /* PIP */
> +
> + { 0x45, KEY_REWIND },
> + { 0x6f, KEY_PAUSE },
> + { 0x7d, KEY_FORWARD },
> + { 0x79, KEY_STOP },
> +};
> +
> +static struct rc_keymap encore_enltv2_map = {
> + .map = {
> + .scan = encore_enltv2,
> + .size = ARRAY_SIZE(encore_enltv2),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_ENCORE_ENLTV2,
> + }
> +};
> +
> +static int __init init_rc_map_encore_enltv2(void)
> +{
> + return ir_register_map(&encore_enltv2_map);
> +}
> +
> +static void __exit exit_rc_map_encore_enltv2(void)
> +{
> + ir_unregister_map(&encore_enltv2_map);
> +}
> +
> +module_init(init_rc_map_encore_enltv2)
> +module_exit(exit_rc_map_encore_enltv2)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-evga-indtube.c b/drivers/media/IR/keymaps/rc-evga-indtube.c
> new file mode 100644
> index 0000000..3f3fb13
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-evga-indtube.c
> @@ -0,0 +1,61 @@
> +/* evga-indtube.h - Keytable for evga_indtube Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* EVGA inDtube
> + Devin Heitmueller <devin.heitmueller@gmail.com>
> + */
> +
> +static struct ir_scancode evga_indtube[] = {
> + { 0x12, KEY_POWER},
> + { 0x02, KEY_MODE}, /* TV */
> + { 0x14, KEY_MUTE},
> + { 0x1a, KEY_CHANNELUP},
> + { 0x16, KEY_TV2}, /* PIP */
> + { 0x1d, KEY_VOLUMEUP},
> + { 0x05, KEY_CHANNELDOWN},
> + { 0x0f, KEY_PLAYPAUSE},
> + { 0x19, KEY_VOLUMEDOWN},
> + { 0x1c, KEY_REWIND},
> + { 0x0d, KEY_RECORD},
> + { 0x18, KEY_FORWARD},
> + { 0x1e, KEY_PREVIOUS},
> + { 0x1b, KEY_STOP},
> + { 0x1f, KEY_NEXT},
> + { 0x13, KEY_CAMERA},
> +};
> +
> +static struct rc_keymap evga_indtube_map = {
> + .map = {
> + .scan = evga_indtube,
> + .size = ARRAY_SIZE(evga_indtube),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_EVGA_INDTUBE,
> + }
> +};
> +
> +static int __init init_rc_map_evga_indtube(void)
> +{
> + return ir_register_map(&evga_indtube_map);
> +}
> +
> +static void __exit exit_rc_map_evga_indtube(void)
> +{
> + ir_unregister_map(&evga_indtube_map);
> +}
> +
> +module_init(init_rc_map_evga_indtube)
> +module_exit(exit_rc_map_evga_indtube)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-eztv.c b/drivers/media/IR/keymaps/rc-eztv.c
> new file mode 100644
> index 0000000..660907a
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-eztv.c
> @@ -0,0 +1,96 @@
> +/* eztv.h - Keytable for eztv Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Alfons Geser <a.geser@cox.net>
> + * updates from Job D. R. Borges <jobdrb@ig.com.br> */
> +
> +static struct ir_scancode eztv[] = {
> + { 0x12, KEY_POWER },
> + { 0x01, KEY_TV }, /* DVR */
> + { 0x15, KEY_DVD }, /* DVD */
> + { 0x17, KEY_AUDIO }, /* music */
> + /* DVR mode / DVD mode / music mode */
> +
> + { 0x1b, KEY_MUTE }, /* mute */
> + { 0x02, KEY_LANGUAGE }, /* MTS/SAP / audio / autoseek */
> + { 0x1e, KEY_SUBTITLE }, /* closed captioning / subtitle / seek */
> + { 0x16, KEY_ZOOM }, /* full screen */
> + { 0x1c, KEY_VIDEO }, /* video source / eject / delall */
> + { 0x1d, KEY_RESTART }, /* playback / angle / del */
> + { 0x2f, KEY_SEARCH }, /* scan / menu / playlist */
> + { 0x30, KEY_CHANNEL }, /* CH surfing / bookmark / memo */
> +
> + { 0x31, KEY_HELP }, /* help */
> + { 0x32, KEY_MODE }, /* num/memo */
> + { 0x33, KEY_ESC }, /* cancel */
> +
> + { 0x0c, KEY_UP }, /* up */
> + { 0x10, KEY_DOWN }, /* down */
> + { 0x08, KEY_LEFT }, /* left */
> + { 0x04, KEY_RIGHT }, /* right */
> + { 0x03, KEY_SELECT }, /* select */
> +
> + { 0x1f, KEY_REWIND }, /* rewind */
> + { 0x20, KEY_PLAYPAUSE },/* play/pause */
> + { 0x29, KEY_FORWARD }, /* forward */
> + { 0x14, KEY_AGAIN }, /* repeat */
> + { 0x2b, KEY_RECORD }, /* recording */
> + { 0x2c, KEY_STOP }, /* stop */
> + { 0x2d, KEY_PLAY }, /* play */
> + { 0x2e, KEY_CAMERA }, /* snapshot / shuffle */
> +
> + { 0x00, KEY_0 },
> + { 0x05, KEY_1 },
> + { 0x06, KEY_2 },
> + { 0x07, KEY_3 },
> + { 0x09, KEY_4 },
> + { 0x0a, KEY_5 },
> + { 0x0b, KEY_6 },
> + { 0x0d, KEY_7 },
> + { 0x0e, KEY_8 },
> + { 0x0f, KEY_9 },
> +
> + { 0x2a, KEY_VOLUMEUP },
> + { 0x11, KEY_VOLUMEDOWN },
> + { 0x18, KEY_CHANNELUP },/* CH.tracking up */
> + { 0x19, KEY_CHANNELDOWN },/* CH.tracking down */
> +
> + { 0x13, KEY_ENTER }, /* enter */
> + { 0x21, KEY_DOT }, /* . (decimal dot) */
> +};
> +
> +static struct rc_keymap eztv_map = {
> + .map = {
> + .scan = eztv,
> + .size = ARRAY_SIZE(eztv),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_EZTV,
> + }
> +};
> +
> +static int __init init_rc_map_eztv(void)
> +{
> + return ir_register_map(&eztv_map);
> +}
> +
> +static void __exit exit_rc_map_eztv(void)
> +{
> + ir_unregister_map(&eztv_map);
> +}
> +
> +module_init(init_rc_map_eztv)
> +module_exit(exit_rc_map_eztv)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-flydvb.c b/drivers/media/IR/keymaps/rc-flydvb.c
> new file mode 100644
> index 0000000..a173c81
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-flydvb.c
> @@ -0,0 +1,77 @@
> +/* flydvb.h - Keytable for flydvb Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +static struct ir_scancode flydvb[] = {
> + { 0x01, KEY_ZOOM }, /* Full Screen */
> + { 0x00, KEY_POWER }, /* Power */
> +
> + { 0x03, KEY_1 },
> + { 0x04, KEY_2 },
> + { 0x05, KEY_3 },
> + { 0x07, KEY_4 },
> + { 0x08, KEY_5 },
> + { 0x09, KEY_6 },
> + { 0x0b, KEY_7 },
> + { 0x0c, KEY_8 },
> + { 0x0d, KEY_9 },
> + { 0x06, KEY_AGAIN }, /* Recall */
> + { 0x0f, KEY_0 },
> + { 0x10, KEY_MUTE }, /* Mute */
> + { 0x02, KEY_RADIO }, /* TV/Radio */
> + { 0x1b, KEY_LANGUAGE }, /* SAP (Second Audio Program) */
> +
> + { 0x14, KEY_VOLUMEUP }, /* VOL+ */
> + { 0x17, KEY_VOLUMEDOWN }, /* VOL- */
> + { 0x12, KEY_CHANNELUP }, /* CH+ */
> + { 0x13, KEY_CHANNELDOWN }, /* CH- */
> + { 0x1d, KEY_ENTER }, /* Enter */
> +
> + { 0x1a, KEY_MODE }, /* PIP */
> + { 0x18, KEY_TUNER }, /* Source */
> +
> + { 0x1e, KEY_RECORD }, /* Record/Pause */
> + { 0x15, KEY_ANGLE }, /* Swap (no label on key) */
> + { 0x1c, KEY_PAUSE }, /* Timeshift/Pause */
> + { 0x19, KEY_BACK }, /* Rewind << */
> + { 0x0a, KEY_PLAYPAUSE }, /* Play/Pause */
> + { 0x1f, KEY_FORWARD }, /* Forward >> */
> + { 0x16, KEY_PREVIOUS }, /* Back |<< */
> + { 0x11, KEY_STOP }, /* Stop */
> + { 0x0e, KEY_NEXT }, /* End >>| */
> +};
> +
> +static struct rc_keymap flydvb_map = {
> + .map = {
> + .scan = flydvb,
> + .size = ARRAY_SIZE(flydvb),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_FLYDVB,
> + }
> +};
> +
> +static int __init init_rc_map_flydvb(void)
> +{
> + return ir_register_map(&flydvb_map);
> +}
> +
> +static void __exit exit_rc_map_flydvb(void)
> +{
> + ir_unregister_map(&flydvb_map);
> +}
> +
> +module_init(init_rc_map_flydvb)
> +module_exit(exit_rc_map_flydvb)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-flyvideo.c b/drivers/media/IR/keymaps/rc-flyvideo.c
> new file mode 100644
> index 0000000..9c73043
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-flyvideo.c
> @@ -0,0 +1,70 @@
> +/* flyvideo.h - Keytable for flyvideo Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +static struct ir_scancode flyvideo[] = {
> + { 0x0f, KEY_0 },
> + { 0x03, KEY_1 },
> + { 0x04, KEY_2 },
> + { 0x05, KEY_3 },
> + { 0x07, KEY_4 },
> + { 0x08, KEY_5 },
> + { 0x09, KEY_6 },
> + { 0x0b, KEY_7 },
> + { 0x0c, KEY_8 },
> + { 0x0d, KEY_9 },
> +
> + { 0x0e, KEY_MODE }, /* Air/Cable */
> + { 0x11, KEY_VIDEO }, /* Video */
> + { 0x15, KEY_AUDIO }, /* Audio */
> + { 0x00, KEY_POWER }, /* Power */
> + { 0x18, KEY_TUNER }, /* AV Source */
> + { 0x02, KEY_ZOOM }, /* Fullscreen */
> + { 0x1a, KEY_LANGUAGE }, /* Stereo */
> + { 0x1b, KEY_MUTE }, /* Mute */
> + { 0x14, KEY_VOLUMEUP }, /* Volume + */
> + { 0x17, KEY_VOLUMEDOWN },/* Volume - */
> + { 0x12, KEY_CHANNELUP },/* Channel + */
> + { 0x13, KEY_CHANNELDOWN },/* Channel - */
> + { 0x06, KEY_AGAIN }, /* Recall */
> + { 0x10, KEY_ENTER }, /* Enter */
> +
> + { 0x19, KEY_BACK }, /* Rewind ( <<< ) */
> + { 0x1f, KEY_FORWARD }, /* Forward ( >>> ) */
> + { 0x0a, KEY_ANGLE }, /* no label, may be used as the PAUSE button */
> +};
> +
> +static struct rc_keymap flyvideo_map = {
> + .map = {
> + .scan = flyvideo,
> + .size = ARRAY_SIZE(flyvideo),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_FLYVIDEO,
> + }
> +};
> +
> +static int __init init_rc_map_flyvideo(void)
> +{
> + return ir_register_map(&flyvideo_map);
> +}
> +
> +static void __exit exit_rc_map_flyvideo(void)
> +{
> + ir_unregister_map(&flyvideo_map);
> +}
> +
> +module_init(init_rc_map_flyvideo)
> +module_exit(exit_rc_map_flyvideo)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-fusionhdtv-mce.c b/drivers/media/IR/keymaps/rc-fusionhdtv-mce.c
> new file mode 100644
> index 0000000..cdb1038
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-fusionhdtv-mce.c
> @@ -0,0 +1,98 @@
> +/* fusionhdtv-mce.h - Keytable for fusionhdtv_mce Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* DViCO FUSION HDTV MCE remote */
> +
> +static struct ir_scancode fusionhdtv_mce[] = {
> +
> + { 0x0b, KEY_1 },
> + { 0x17, KEY_2 },
> + { 0x1b, KEY_3 },
> + { 0x07, KEY_4 },
> + { 0x50, KEY_5 },
> + { 0x54, KEY_6 },
> + { 0x48, KEY_7 },
> + { 0x4c, KEY_8 },
> + { 0x58, KEY_9 },
> + { 0x03, KEY_0 },
> +
> + { 0x5e, KEY_OK },
> + { 0x51, KEY_UP },
> + { 0x53, KEY_DOWN },
> + { 0x5b, KEY_LEFT },
> + { 0x5f, KEY_RIGHT },
> +
> + { 0x02, KEY_TV }, /* Labeled DTV on remote */
> + { 0x0e, KEY_MP3 },
> + { 0x1a, KEY_DVD },
> + { 0x1e, KEY_FAVORITES }, /* Labeled CPF on remote */
> + { 0x16, KEY_SETUP },
> + { 0x46, KEY_POWER2 }, /* TV On/Off button on remote */
> + { 0x0a, KEY_EPG }, /* Labeled Guide on remote */
> +
> + { 0x49, KEY_BACK },
> + { 0x59, KEY_INFO }, /* Labeled MORE on remote */
> + { 0x4d, KEY_MENU }, /* Labeled DVDMENU on remote */
> + { 0x55, KEY_CYCLEWINDOWS }, /* Labeled ALT-TAB on remote */
> +
> + { 0x0f, KEY_PREVIOUSSONG }, /* Labeled |<< REPLAY on remote */
> + { 0x12, KEY_NEXTSONG }, /* Labeled >>| SKIP on remote */
> + { 0x42, KEY_ENTER }, /* Labeled START with a green
> + MS windows logo on remote */
> +
> + { 0x15, KEY_VOLUMEUP },
> + { 0x05, KEY_VOLUMEDOWN },
> + { 0x11, KEY_CHANNELUP },
> + { 0x09, KEY_CHANNELDOWN },
> +
> + { 0x52, KEY_CAMERA },
> + { 0x5a, KEY_TUNER },
> + { 0x19, KEY_OPEN },
> +
> + { 0x13, KEY_MODE }, /* 4:3 16:9 select */
> + { 0x1f, KEY_ZOOM },
> +
> + { 0x43, KEY_REWIND },
> + { 0x47, KEY_PLAYPAUSE },
> + { 0x4f, KEY_FASTFORWARD },
> + { 0x57, KEY_MUTE },
> + { 0x0d, KEY_STOP },
> + { 0x01, KEY_RECORD },
> + { 0x4e, KEY_POWER },
> +};
> +
> +static struct rc_keymap fusionhdtv_mce_map = {
> + .map = {
> + .scan = fusionhdtv_mce,
> + .size = ARRAY_SIZE(fusionhdtv_mce),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_FUSIONHDTV_MCE,
> + }
> +};
> +
> +static int __init init_rc_map_fusionhdtv_mce(void)
> +{
> + return ir_register_map(&fusionhdtv_mce_map);
> +}
> +
> +static void __exit exit_rc_map_fusionhdtv_mce(void)
> +{
> + ir_unregister_map(&fusionhdtv_mce_map);
> +}
> +
> +module_init(init_rc_map_fusionhdtv_mce)
> +module_exit(exit_rc_map_fusionhdtv_mce)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-gadmei-rm008z.c b/drivers/media/IR/keymaps/rc-gadmei-rm008z.c
> new file mode 100644
> index 0000000..c16c0d1
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-gadmei-rm008z.c
> @@ -0,0 +1,81 @@
> +/* gadmei-rm008z.h - Keytable for gadmei_rm008z Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* GADMEI UTV330+ RM008Z remote
> + Shine Liu <shinel@foxmail.com>
> + */
> +
> +static struct ir_scancode gadmei_rm008z[] = {
> + { 0x14, KEY_POWER2}, /* POWER OFF */
> + { 0x0c, KEY_MUTE}, /* MUTE */
> +
> + { 0x18, KEY_TV}, /* TV */
> + { 0x0e, KEY_VIDEO}, /* AV */
> + { 0x0b, KEY_AUDIO}, /* SV */
> + { 0x0f, KEY_RADIO}, /* FM */
> +
> + { 0x00, KEY_1},
> + { 0x01, KEY_2},
> + { 0x02, KEY_3},
> + { 0x03, KEY_4},
> + { 0x04, KEY_5},
> + { 0x05, KEY_6},
> + { 0x06, KEY_7},
> + { 0x07, KEY_8},
> + { 0x08, KEY_9},
> + { 0x09, KEY_0},
> + { 0x0a, KEY_INFO}, /* OSD */
> + { 0x1c, KEY_BACKSPACE}, /* LAST */
> +
> + { 0x0d, KEY_PLAY}, /* PLAY */
> + { 0x1e, KEY_CAMERA}, /* SNAPSHOT */
> + { 0x1a, KEY_RECORD}, /* RECORD */
> + { 0x17, KEY_STOP}, /* STOP */
> +
> + { 0x1f, KEY_UP}, /* UP */
> + { 0x44, KEY_DOWN}, /* DOWN */
> + { 0x46, KEY_TAB}, /* BACK */
> + { 0x4a, KEY_ZOOM}, /* FULLSECREEN */
> +
> + { 0x10, KEY_VOLUMEUP}, /* VOLUMEUP */
> + { 0x11, KEY_VOLUMEDOWN}, /* VOLUMEDOWN */
> + { 0x12, KEY_CHANNELUP}, /* CHANNELUP */
> + { 0x13, KEY_CHANNELDOWN}, /* CHANNELDOWN */
> + { 0x15, KEY_ENTER}, /* OK */
> +};
> +
> +static struct rc_keymap gadmei_rm008z_map = {
> + .map = {
> + .scan = gadmei_rm008z,
> + .size = ARRAY_SIZE(gadmei_rm008z),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_GADMEI_RM008Z,
> + }
> +};
> +
> +static int __init init_rc_map_gadmei_rm008z(void)
> +{
> + return ir_register_map(&gadmei_rm008z_map);
> +}
> +
> +static void __exit exit_rc_map_gadmei_rm008z(void)
> +{
> + ir_unregister_map(&gadmei_rm008z_map);
> +}
> +
> +module_init(init_rc_map_gadmei_rm008z)
> +module_exit(exit_rc_map_gadmei_rm008z)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-genius-tvgo-a11mce.c b/drivers/media/IR/keymaps/rc-genius-tvgo-a11mce.c
> new file mode 100644
> index 0000000..89f8e38
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-genius-tvgo-a11mce.c
> @@ -0,0 +1,84 @@
> +/* genius-tvgo-a11mce.h - Keytable for genius_tvgo_a11mce Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/*
> + * Remote control for the Genius TVGO A11MCE
> + * Adrian Pardini <pardo.bsso@gmail.com>
> + */
> +
> +static struct ir_scancode genius_tvgo_a11mce[] = {
> + /* Keys 0 to 9 */
> + { 0x48, KEY_0 },
> + { 0x09, KEY_1 },
> + { 0x1d, KEY_2 },
> + { 0x1f, KEY_3 },
> + { 0x19, KEY_4 },
> + { 0x1b, KEY_5 },
> + { 0x11, KEY_6 },
> + { 0x17, KEY_7 },
> + { 0x12, KEY_8 },
> + { 0x16, KEY_9 },
> +
> + { 0x54, KEY_RECORD }, /* recording */
> + { 0x06, KEY_MUTE }, /* mute */
> + { 0x10, KEY_POWER },
> + { 0x40, KEY_LAST }, /* recall */
> + { 0x4c, KEY_CHANNELUP }, /* channel / program + */
> + { 0x00, KEY_CHANNELDOWN }, /* channel / program - */
> + { 0x0d, KEY_VOLUMEUP },
> + { 0x15, KEY_VOLUMEDOWN },
> + { 0x4d, KEY_OK }, /* also labeled as Pause */
> + { 0x1c, KEY_ZOOM }, /* full screen and Stop*/
> + { 0x02, KEY_MODE }, /* AV Source or Rewind*/
> + { 0x04, KEY_LIST }, /* -/-- */
> + /* small arrows above numbers */
> + { 0x1a, KEY_NEXT }, /* also Fast Forward */
> + { 0x0e, KEY_PREVIOUS }, /* also Rewind */
> + /* these are in a rather non standard layout and have
> + an alternate name written */
> + { 0x1e, KEY_UP }, /* Video Setting */
> + { 0x0a, KEY_DOWN }, /* Video Default */
> + { 0x05, KEY_CAMERA }, /* Snapshot */
> + { 0x0c, KEY_RIGHT }, /* Hide Panel */
> + /* Four buttons without label */
> + { 0x49, KEY_RED },
> + { 0x0b, KEY_GREEN },
> + { 0x13, KEY_YELLOW },
> + { 0x50, KEY_BLUE },
> +};
> +
> +static struct rc_keymap genius_tvgo_a11mce_map = {
> + .map = {
> + .scan = genius_tvgo_a11mce,
> + .size = ARRAY_SIZE(genius_tvgo_a11mce),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_GENIUS_TVGO_A11MCE,
> + }
> +};
> +
> +static int __init init_rc_map_genius_tvgo_a11mce(void)
> +{
> + return ir_register_map(&genius_tvgo_a11mce_map);
> +}
> +
> +static void __exit exit_rc_map_genius_tvgo_a11mce(void)
> +{
> + ir_unregister_map(&genius_tvgo_a11mce_map);
> +}
> +
> +module_init(init_rc_map_genius_tvgo_a11mce)
> +module_exit(exit_rc_map_genius_tvgo_a11mce)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-gotview7135.c b/drivers/media/IR/keymaps/rc-gotview7135.c
> new file mode 100644
> index 0000000..52f025b
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-gotview7135.c
> @@ -0,0 +1,79 @@
> +/* gotview7135.h - Keytable for gotview7135 Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Mike Baikov <mike@baikov.com> */
> +
> +static struct ir_scancode gotview7135[] = {
> +
> + { 0x11, KEY_POWER },
> + { 0x35, KEY_TV },
> + { 0x1b, KEY_0 },
> + { 0x29, KEY_1 },
> + { 0x19, KEY_2 },
> + { 0x39, KEY_3 },
> + { 0x1f, KEY_4 },
> + { 0x2c, KEY_5 },
> + { 0x21, KEY_6 },
> + { 0x24, KEY_7 },
> + { 0x18, KEY_8 },
> + { 0x2b, KEY_9 },
> + { 0x3b, KEY_AGAIN }, /* LOOP */
> + { 0x06, KEY_AUDIO },
> + { 0x31, KEY_PRINT }, /* PREVIEW */
> + { 0x3e, KEY_VIDEO },
> + { 0x10, KEY_CHANNELUP },
> + { 0x20, KEY_CHANNELDOWN },
> + { 0x0c, KEY_VOLUMEDOWN },
> + { 0x28, KEY_VOLUMEUP },
> + { 0x08, KEY_MUTE },
> + { 0x26, KEY_SEARCH }, /* SCAN */
> + { 0x3f, KEY_CAMERA }, /* SNAPSHOT */
> + { 0x12, KEY_RECORD },
> + { 0x32, KEY_STOP },
> + { 0x3c, KEY_PLAY },
> + { 0x1d, KEY_REWIND },
> + { 0x2d, KEY_PAUSE },
> + { 0x0d, KEY_FORWARD },
> + { 0x05, KEY_ZOOM }, /*FULL*/
> +
> + { 0x2a, KEY_F21 }, /* LIVE TIMESHIFT */
> + { 0x0e, KEY_F22 }, /* MIN TIMESHIFT */
> + { 0x1e, KEY_TIME }, /* TIMESHIFT */
> + { 0x38, KEY_F24 }, /* NORMAL TIMESHIFT */
> +};
> +
> +static struct rc_keymap gotview7135_map = {
> + .map = {
> + .scan = gotview7135,
> + .size = ARRAY_SIZE(gotview7135),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_GOTVIEW7135,
> + }
> +};
> +
> +static int __init init_rc_map_gotview7135(void)
> +{
> + return ir_register_map(&gotview7135_map);
> +}
> +
> +static void __exit exit_rc_map_gotview7135(void)
> +{
> + ir_unregister_map(&gotview7135_map);
> +}
> +
> +module_init(init_rc_map_gotview7135)
> +module_exit(exit_rc_map_gotview7135)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-hauppauge-new.c b/drivers/media/IR/keymaps/rc-hauppauge-new.c
> new file mode 100644
> index 0000000..c6f8cd7
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-hauppauge-new.c
> @@ -0,0 +1,100 @@
> +/* hauppauge-new.h - Keytable for hauppauge_new Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Hauppauge: the newer, gray remotes (seems there are multiple
> + * slightly different versions), shipped with cx88+ivtv cards.
> + * almost rc5 coding, but some non-standard keys */
> +
> +static struct ir_scancode hauppauge_new[] = {
> + /* Keys 0 to 9 */
> + { 0x00, KEY_0 },
> + { 0x01, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x03, KEY_3 },
> + { 0x04, KEY_4 },
> + { 0x05, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x09, KEY_9 },
> +
> + { 0x0a, KEY_TEXT }, /* keypad asterisk as well */
> + { 0x0b, KEY_RED }, /* red button */
> + { 0x0c, KEY_RADIO },
> + { 0x0d, KEY_MENU },
> + { 0x0e, KEY_SUBTITLE }, /* also the # key */
> + { 0x0f, KEY_MUTE },
> + { 0x10, KEY_VOLUMEUP },
> + { 0x11, KEY_VOLUMEDOWN },
> + { 0x12, KEY_PREVIOUS }, /* previous channel */
> + { 0x14, KEY_UP },
> + { 0x15, KEY_DOWN },
> + { 0x16, KEY_LEFT },
> + { 0x17, KEY_RIGHT },
> + { 0x18, KEY_VIDEO }, /* Videos */
> + { 0x19, KEY_AUDIO }, /* Music */
> + /* 0x1a: Pictures - presume this means
> + "Multimedia Home Platform" -
> + no "PICTURES" key in input.h
> + */
> + { 0x1a, KEY_MHP },
> +
> + { 0x1b, KEY_EPG }, /* Guide */
> + { 0x1c, KEY_TV },
> + { 0x1e, KEY_NEXTSONG }, /* skip >| */
> + { 0x1f, KEY_EXIT }, /* back/exit */
> + { 0x20, KEY_CHANNELUP }, /* channel / program + */
> + { 0x21, KEY_CHANNELDOWN }, /* channel / program - */
> + { 0x22, KEY_CHANNEL }, /* source (old black remote) */
> + { 0x24, KEY_PREVIOUSSONG }, /* replay |< */
> + { 0x25, KEY_ENTER }, /* OK */
> + { 0x26, KEY_SLEEP }, /* minimize (old black remote) */
> + { 0x29, KEY_BLUE }, /* blue key */
> + { 0x2e, KEY_GREEN }, /* green button */
> + { 0x30, KEY_PAUSE }, /* pause */
> + { 0x32, KEY_REWIND }, /* backward << */
> + { 0x34, KEY_FASTFORWARD }, /* forward >> */
> + { 0x35, KEY_PLAY },
> + { 0x36, KEY_STOP },
> + { 0x37, KEY_RECORD }, /* recording */
> + { 0x38, KEY_YELLOW }, /* yellow key */
> + { 0x3b, KEY_SELECT }, /* top right button */
> + { 0x3c, KEY_ZOOM }, /* full */
> + { 0x3d, KEY_POWER }, /* system power (green button) */
> +};
> +
> +static struct rc_keymap hauppauge_new_map = {
> + .map = {
> + .scan = hauppauge_new,
> + .size = ARRAY_SIZE(hauppauge_new),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_HAUPPAUGE_NEW,
> + }
> +};
> +
> +static int __init init_rc_map_hauppauge_new(void)
> +{
> + return ir_register_map(&hauppauge_new_map);
> +}
> +
> +static void __exit exit_rc_map_hauppauge_new(void)
> +{
> + ir_unregister_map(&hauppauge_new_map);
> +}
> +
> +module_init(init_rc_map_hauppauge_new)
> +module_exit(exit_rc_map_hauppauge_new)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-iodata-bctv7e.c b/drivers/media/IR/keymaps/rc-iodata-bctv7e.c
> new file mode 100644
> index 0000000..ef66002
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-iodata-bctv7e.c
> @@ -0,0 +1,88 @@
> +/* iodata-bctv7e.h - Keytable for iodata_bctv7e Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* IO-DATA BCTV7E Remote */
> +
> +static struct ir_scancode iodata_bctv7e[] = {
> + { 0x40, KEY_TV },
> + { 0x20, KEY_RADIO }, /* FM */
> + { 0x60, KEY_EPG },
> + { 0x00, KEY_POWER },
> +
> + /* Keys 0 to 9 */
> + { 0x44, KEY_0 }, /* 10 */
> + { 0x50, KEY_1 },
> + { 0x30, KEY_2 },
> + { 0x70, KEY_3 },
> + { 0x48, KEY_4 },
> + { 0x28, KEY_5 },
> + { 0x68, KEY_6 },
> + { 0x58, KEY_7 },
> + { 0x38, KEY_8 },
> + { 0x78, KEY_9 },
> +
> + { 0x10, KEY_L }, /* Live */
> + { 0x08, KEY_TIME }, /* Time Shift */
> +
> + { 0x18, KEY_PLAYPAUSE }, /* Play */
> +
> + { 0x24, KEY_ENTER }, /* 11 */
> + { 0x64, KEY_ESC }, /* 12 */
> + { 0x04, KEY_M }, /* Multi */
> +
> + { 0x54, KEY_VIDEO },
> + { 0x34, KEY_CHANNELUP },
> + { 0x74, KEY_VOLUMEUP },
> + { 0x14, KEY_MUTE },
> +
> + { 0x4c, KEY_VCR }, /* SVIDEO */
> + { 0x2c, KEY_CHANNELDOWN },
> + { 0x6c, KEY_VOLUMEDOWN },
> + { 0x0c, KEY_ZOOM },
> +
> + { 0x5c, KEY_PAUSE },
> + { 0x3c, KEY_RED }, /* || (red) */
> + { 0x7c, KEY_RECORD }, /* recording */
> + { 0x1c, KEY_STOP },
> +
> + { 0x41, KEY_REWIND }, /* backward << */
> + { 0x21, KEY_PLAY },
> + { 0x61, KEY_FASTFORWARD }, /* forward >> */
> + { 0x01, KEY_NEXT }, /* skip >| */
> +};
> +
> +static struct rc_keymap iodata_bctv7e_map = {
> + .map = {
> + .scan = iodata_bctv7e,
> + .size = ARRAY_SIZE(iodata_bctv7e),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_IODATA_BCTV7E,
> + }
> +};
> +
> +static int __init init_rc_map_iodata_bctv7e(void)
> +{
> + return ir_register_map(&iodata_bctv7e_map);
> +}
> +
> +static void __exit exit_rc_map_iodata_bctv7e(void)
> +{
> + ir_unregister_map(&iodata_bctv7e_map);
> +}
> +
> +module_init(init_rc_map_iodata_bctv7e)
> +module_exit(exit_rc_map_iodata_bctv7e)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-kaiomy.c b/drivers/media/IR/keymaps/rc-kaiomy.c
> new file mode 100644
> index 0000000..4c7883b
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-kaiomy.c
> @@ -0,0 +1,87 @@
> +/* kaiomy.h - Keytable for kaiomy Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Kaiomy TVnPC U2
> + Mauro Carvalho Chehab <mchehab@infradead.org>
> + */
> +
> +static struct ir_scancode kaiomy[] = {
> + { 0x43, KEY_POWER2},
> + { 0x01, KEY_LIST},
> + { 0x0b, KEY_ZOOM},
> + { 0x03, KEY_POWER},
> +
> + { 0x04, KEY_1},
> + { 0x08, KEY_2},
> + { 0x02, KEY_3},
> +
> + { 0x0f, KEY_4},
> + { 0x05, KEY_5},
> + { 0x06, KEY_6},
> +
> + { 0x0c, KEY_7},
> + { 0x0d, KEY_8},
> + { 0x0a, KEY_9},
> +
> + { 0x11, KEY_0},
> +
> + { 0x09, KEY_CHANNELUP},
> + { 0x07, KEY_CHANNELDOWN},
> +
> + { 0x0e, KEY_VOLUMEUP},
> + { 0x13, KEY_VOLUMEDOWN},
> +
> + { 0x10, KEY_HOME},
> + { 0x12, KEY_ENTER},
> +
> + { 0x14, KEY_RECORD},
> + { 0x15, KEY_STOP},
> + { 0x16, KEY_PLAY},
> + { 0x17, KEY_MUTE},
> +
> + { 0x18, KEY_UP},
> + { 0x19, KEY_DOWN},
> + { 0x1a, KEY_LEFT},
> + { 0x1b, KEY_RIGHT},
> +
> + { 0x1c, KEY_RED},
> + { 0x1d, KEY_GREEN},
> + { 0x1e, KEY_YELLOW},
> + { 0x1f, KEY_BLUE},
> +};
> +
> +static struct rc_keymap kaiomy_map = {
> + .map = {
> + .scan = kaiomy,
> + .size = ARRAY_SIZE(kaiomy),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_KAIOMY,
> + }
> +};
> +
> +static int __init init_rc_map_kaiomy(void)
> +{
> + return ir_register_map(&kaiomy_map);
> +}
> +
> +static void __exit exit_rc_map_kaiomy(void)
> +{
> + ir_unregister_map(&kaiomy_map);
> +}
> +
> +module_init(init_rc_map_kaiomy)
> +module_exit(exit_rc_map_kaiomy)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-kworld-315u.c b/drivers/media/IR/keymaps/rc-kworld-315u.c
> new file mode 100644
> index 0000000..618c817
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-kworld-315u.c
> @@ -0,0 +1,83 @@
> +/* kworld-315u.h - Keytable for kworld_315u Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Kworld 315U
> + */
> +
> +static struct ir_scancode kworld_315u[] = {
> + { 0x6143, KEY_POWER },
> + { 0x6101, KEY_TUNER }, /* source */
> + { 0x610b, KEY_ZOOM },
> + { 0x6103, KEY_POWER2 }, /* shutdown */
> +
> + { 0x6104, KEY_1 },
> + { 0x6108, KEY_2 },
> + { 0x6102, KEY_3 },
> + { 0x6109, KEY_CHANNELUP },
> +
> + { 0x610f, KEY_4 },
> + { 0x6105, KEY_5 },
> + { 0x6106, KEY_6 },
> + { 0x6107, KEY_CHANNELDOWN },
> +
> + { 0x610c, KEY_7 },
> + { 0x610d, KEY_8 },
> + { 0x610a, KEY_9 },
> + { 0x610e, KEY_VOLUMEUP },
> +
> + { 0x6110, KEY_LAST },
> + { 0x6111, KEY_0 },
> + { 0x6112, KEY_ENTER },
> + { 0x6113, KEY_VOLUMEDOWN },
> +
> + { 0x6114, KEY_RECORD },
> + { 0x6115, KEY_STOP },
> + { 0x6116, KEY_PLAY },
> + { 0x6117, KEY_MUTE },
> +
> + { 0x6118, KEY_UP },
> + { 0x6119, KEY_DOWN },
> + { 0x611a, KEY_LEFT },
> + { 0x611b, KEY_RIGHT },
> +
> + { 0x611c, KEY_RED },
> + { 0x611d, KEY_GREEN },
> + { 0x611e, KEY_YELLOW },
> + { 0x611f, KEY_BLUE },
> +};
> +
> +static struct rc_keymap kworld_315u_map = {
> + .map = {
> + .scan = kworld_315u,
> + .size = ARRAY_SIZE(kworld_315u),
> + .ir_type = IR_TYPE_NEC,
> + .name = RC_MAP_KWORLD_315U,
> + }
> +};
> +
> +static int __init init_rc_map_kworld_315u(void)
> +{
> + return ir_register_map(&kworld_315u_map);
> +}
> +
> +static void __exit exit_rc_map_kworld_315u(void)
> +{
> + ir_unregister_map(&kworld_315u_map);
> +}
> +
> +module_init(init_rc_map_kworld_315u)
> +module_exit(exit_rc_map_kworld_315u)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-kworld-plus-tv-analog.c b/drivers/media/IR/keymaps/rc-kworld-plus-tv-analog.c
> new file mode 100644
> index 0000000..366732f
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-kworld-plus-tv-analog.c
> @@ -0,0 +1,99 @@
> +/* kworld-plus-tv-analog.h - Keytable for kworld_plus_tv_analog Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Kworld Plus TV Analog Lite PCI IR
> + Mauro Carvalho Chehab <mchehab@infradead.org>
> + */
> +
> +static struct ir_scancode kworld_plus_tv_analog[] = {
> + { 0x0c, KEY_PROG1 }, /* Kworld key */
> + { 0x16, KEY_CLOSECD }, /* -> ) */
> + { 0x1d, KEY_POWER2 },
> +
> + { 0x00, KEY_1 },
> + { 0x01, KEY_2 },
> + { 0x02, KEY_3 }, /* Two keys have the same code: 3 and left */
> + { 0x03, KEY_4 }, /* Two keys have the same code: 3 and right */
> + { 0x04, KEY_5 },
> + { 0x05, KEY_6 },
> + { 0x06, KEY_7 },
> + { 0x07, KEY_8 },
> + { 0x08, KEY_9 },
> + { 0x0a, KEY_0 },
> +
> + { 0x09, KEY_AGAIN },
> + { 0x14, KEY_MUTE },
> +
> + { 0x20, KEY_UP },
> + { 0x21, KEY_DOWN },
> + { 0x0b, KEY_ENTER },
> +
> + { 0x10, KEY_CHANNELUP },
> + { 0x11, KEY_CHANNELDOWN },
> +
> + /* Couldn't map key left/key right since those
> + conflict with '3' and '4' scancodes
> + I dunno what the original driver does
> + */
> +
> + { 0x13, KEY_VOLUMEUP },
> + { 0x12, KEY_VOLUMEDOWN },
> +
> + /* The lower part of the IR
> + There are several duplicated keycodes there.
> + Most of them conflict with digits.
> + Add mappings just to the unused scancodes.
> + Somehow, the original driver has a way to know,
> + but this doesn't seem to be on some GPIO.
> + Also, it is not related to the time between keyup
> + and keydown.
> + */
> + { 0x19, KEY_TIME}, /* Timeshift */
> + { 0x1a, KEY_STOP},
> + { 0x1b, KEY_RECORD},
> +
> + { 0x22, KEY_TEXT},
> +
> + { 0x15, KEY_AUDIO}, /* ((*)) */
> + { 0x0f, KEY_ZOOM},
> + { 0x1c, KEY_CAMERA}, /* snapshot */
> +
> + { 0x18, KEY_RED}, /* B */
> + { 0x23, KEY_GREEN}, /* C */
> +};
> +
> +static struct rc_keymap kworld_plus_tv_analog_map = {
> + .map = {
> + .scan = kworld_plus_tv_analog,
> + .size = ARRAY_SIZE(kworld_plus_tv_analog),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_KWORLD_PLUS_TV_ANALOG,
> + }
> +};
> +
> +static int __init init_rc_map_kworld_plus_tv_analog(void)
> +{
> + return ir_register_map(&kworld_plus_tv_analog_map);
> +}
> +
> +static void __exit exit_rc_map_kworld_plus_tv_analog(void)
> +{
> + ir_unregister_map(&kworld_plus_tv_analog_map);
> +}
> +
> +module_init(init_rc_map_kworld_plus_tv_analog)
> +module_exit(exit_rc_map_kworld_plus_tv_analog)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-manli.c b/drivers/media/IR/keymaps/rc-manli.c
> new file mode 100644
> index 0000000..1e9fbfa
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-manli.c
> @@ -0,0 +1,135 @@
> +/* manli.h - Keytable for manli Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Michael Tokarev <mjt@tls.msk.ru>
> + http://www.corpit.ru/mjt/beholdTV/remote_control.jpg
> + keytable is used by MANLI MTV00[0x0c] and BeholdTV 40[13] at
> + least, and probably other cards too.
> + The "ascii-art picture" below (in comments, first row
> + is the keycode in hex, and subsequent row(s) shows
> + the button labels (several variants when appropriate)
> + helps to descide which keycodes to assign to the buttons.
> + */
> +
> +static struct ir_scancode manli[] = {
> +
> + /* 0x1c 0x12 *
> + * FUNCTION POWER *
> + * FM (|) *
> + * */
> + { 0x1c, KEY_RADIO }, /*XXX*/
> + { 0x12, KEY_POWER },
> +
> + /* 0x01 0x02 0x03 *
> + * 1 2 3 *
> + * *
> + * 0x04 0x05 0x06 *
> + * 4 5 6 *
> + * *
> + * 0x07 0x08 0x09 *
> + * 7 8 9 *
> + * */
> + { 0x01, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x03, KEY_3 },
> + { 0x04, KEY_4 },
> + { 0x05, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x09, KEY_9 },
> +
> + /* 0x0a 0x00 0x17 *
> + * RECALL 0 +100 *
> + * PLUS *
> + * */
> + { 0x0a, KEY_AGAIN }, /*XXX KEY_REWIND? */
> + { 0x00, KEY_0 },
> + { 0x17, KEY_DIGITS }, /*XXX*/
> +
> + /* 0x14 0x10 *
> + * MENU INFO *
> + * OSD */
> + { 0x14, KEY_MENU },
> + { 0x10, KEY_INFO },
> +
> + /* 0x0b *
> + * Up *
> + * *
> + * 0x18 0x16 0x0c *
> + * Left Ok Right *
> + * *
> + * 0x015 *
> + * Down *
> + * */
> + { 0x0b, KEY_UP },
> + { 0x18, KEY_LEFT },
> + { 0x16, KEY_OK }, /*XXX KEY_SELECT? KEY_ENTER? */
> + { 0x0c, KEY_RIGHT },
> + { 0x15, KEY_DOWN },
> +
> + /* 0x11 0x0d *
> + * TV/AV MODE *
> + * SOURCE STEREO *
> + * */
> + { 0x11, KEY_TV }, /*XXX*/
> + { 0x0d, KEY_MODE }, /*XXX there's no KEY_STEREO */
> +
> + /* 0x0f 0x1b 0x1a *
> + * AUDIO Vol+ Chan+ *
> + * TIMESHIFT??? *
> + * *
> + * 0x0e 0x1f 0x1e *
> + * SLEEP Vol- Chan- *
> + * */
> + { 0x0f, KEY_AUDIO },
> + { 0x1b, KEY_VOLUMEUP },
> + { 0x1a, KEY_CHANNELUP },
> + { 0x0e, KEY_TIME },
> + { 0x1f, KEY_VOLUMEDOWN },
> + { 0x1e, KEY_CHANNELDOWN },
> +
> + /* 0x13 0x19 *
> + * MUTE SNAPSHOT*
> + * */
> + { 0x13, KEY_MUTE },
> + { 0x19, KEY_CAMERA },
> +
> + /* 0x1d unused ? */
> +};
> +
> +static struct rc_keymap manli_map = {
> + .map = {
> + .scan = manli,
> + .size = ARRAY_SIZE(manli),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_MANLI,
> + }
> +};
> +
> +static int __init init_rc_map_manli(void)
> +{
> + return ir_register_map(&manli_map);
> +}
> +
> +static void __exit exit_rc_map_manli(void)
> +{
> + ir_unregister_map(&manli_map);
> +}
> +
> +module_init(init_rc_map_manli)
> +module_exit(exit_rc_map_manli)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-msi-tvanywhere-plus.c b/drivers/media/IR/keymaps/rc-msi-tvanywhere-plus.c
> new file mode 100644
> index 0000000..eb8e42c
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-msi-tvanywhere-plus.c
> @@ -0,0 +1,123 @@
> +/* msi-tvanywhere-plus.h - Keytable for msi_tvanywhere_plus Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/*
> + Keycodes for remote on the MSI TV@nywhere Plus. The controller IC on the card
> + is marked "KS003". The controller is I2C at address 0x30, but does not seem
> + to respond to probes until a read is performed from a valid device.
> + I don't know why...
> +
> + Note: This remote may be of similar or identical design to the
> + Pixelview remote (?). The raw codes and duplicate button codes
> + appear to be the same.
> +
> + Henry Wong <henry@stuffedcow.net>
> + Some changes to formatting and keycodes by Mark Schultz <n9xmj@yahoo.com>
> +*/
> +
> +static struct ir_scancode msi_tvanywhere_plus[] = {
> +
> +/* ---- Remote Button Layout ----
> +
> + POWER SOURCE SCAN MUTE
> + TV/FM 1 2 3
> + |> 4 5 6
> + <| 7 8 9
> + ^^UP 0 + RECALL
> + vvDN RECORD STOP PLAY
> +
> + MINIMIZE ZOOM
> +
> + CH+
> + VOL- VOL+
> + CH-
> +
> + SNAPSHOT MTS
> +
> + << FUNC >> RESET
> +*/
> +
> + { 0x01, KEY_1 }, /* 1 */
> + { 0x0b, KEY_2 }, /* 2 */
> + { 0x1b, KEY_3 }, /* 3 */
> + { 0x05, KEY_4 }, /* 4 */
> + { 0x09, KEY_5 }, /* 5 */
> + { 0x15, KEY_6 }, /* 6 */
> + { 0x06, KEY_7 }, /* 7 */
> + { 0x0a, KEY_8 }, /* 8 */
> + { 0x12, KEY_9 }, /* 9 */
> + { 0x02, KEY_0 }, /* 0 */
> + { 0x10, KEY_KPPLUS }, /* + */
> + { 0x13, KEY_AGAIN }, /* Recall */
> +
> + { 0x1e, KEY_POWER }, /* Power */
> + { 0x07, KEY_TUNER }, /* Source */
> + { 0x1c, KEY_SEARCH }, /* Scan */
> + { 0x18, KEY_MUTE }, /* Mute */
> +
> + { 0x03, KEY_RADIO }, /* TV/FM */
> + /* The next four keys are duplicates that appear to send the
> + same IR code as Ch+, Ch-, >>, and << . The raw code assigned
> + to them is the actual code + 0x20 - they will never be
> + detected as such unless some way is discovered to distinguish
> + these buttons from those that have the same code. */
> + { 0x3f, KEY_RIGHT }, /* |> and Ch+ */
> + { 0x37, KEY_LEFT }, /* <| and Ch- */
> + { 0x2c, KEY_UP }, /* ^^Up and >> */
> + { 0x24, KEY_DOWN }, /* vvDn and << */
> +
> + { 0x00, KEY_RECORD }, /* Record */
> + { 0x08, KEY_STOP }, /* Stop */
> + { 0x11, KEY_PLAY }, /* Play */
> +
> + { 0x0f, KEY_CLOSE }, /* Minimize */
> + { 0x19, KEY_ZOOM }, /* Zoom */
> + { 0x1a, KEY_CAMERA }, /* Snapshot */
> + { 0x0d, KEY_LANGUAGE }, /* MTS */
> +
> + { 0x14, KEY_VOLUMEDOWN }, /* Vol- */
> + { 0x16, KEY_VOLUMEUP }, /* Vol+ */
> + { 0x17, KEY_CHANNELDOWN }, /* Ch- */
> + { 0x1f, KEY_CHANNELUP }, /* Ch+ */
> +
> + { 0x04, KEY_REWIND }, /* << */
> + { 0x0e, KEY_MENU }, /* Function */
> + { 0x0c, KEY_FASTFORWARD }, /* >> */
> + { 0x1d, KEY_RESTART }, /* Reset */
> +};
> +
> +static struct rc_keymap msi_tvanywhere_plus_map = {
> + .map = {
> + .scan = msi_tvanywhere_plus,
> + .size = ARRAY_SIZE(msi_tvanywhere_plus),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_MSI_TVANYWHERE_PLUS,
> + }
> +};
> +
> +static int __init init_rc_map_msi_tvanywhere_plus(void)
> +{
> + return ir_register_map(&msi_tvanywhere_plus_map);
> +}
> +
> +static void __exit exit_rc_map_msi_tvanywhere_plus(void)
> +{
> + ir_unregister_map(&msi_tvanywhere_plus_map);
> +}
> +
> +module_init(init_rc_map_msi_tvanywhere_plus)
> +module_exit(exit_rc_map_msi_tvanywhere_plus)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-msi-tvanywhere.c b/drivers/media/IR/keymaps/rc-msi-tvanywhere.c
> new file mode 100644
> index 0000000..ef41185
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-msi-tvanywhere.c
> @@ -0,0 +1,69 @@
> +/* msi-tvanywhere.h - Keytable for msi_tvanywhere Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* MSI TV@nywhere MASTER remote */
> +
> +static struct ir_scancode msi_tvanywhere[] = {
> + /* Keys 0 to 9 */
> + { 0x00, KEY_0 },
> + { 0x01, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x03, KEY_3 },
> + { 0x04, KEY_4 },
> + { 0x05, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x09, KEY_9 },
> +
> + { 0x0c, KEY_MUTE },
> + { 0x0f, KEY_SCREEN }, /* Full Screen */
> + { 0x10, KEY_FN }, /* Funtion */
> + { 0x11, KEY_TIME }, /* Time shift */
> + { 0x12, KEY_POWER },
> + { 0x13, KEY_MEDIA }, /* MTS */
> + { 0x14, KEY_SLOW },
> + { 0x16, KEY_REWIND }, /* backward << */
> + { 0x17, KEY_ENTER }, /* Return */
> + { 0x18, KEY_FASTFORWARD }, /* forward >> */
> + { 0x1a, KEY_CHANNELUP },
> + { 0x1b, KEY_VOLUMEUP },
> + { 0x1e, KEY_CHANNELDOWN },
> + { 0x1f, KEY_VOLUMEDOWN },
> +};
> +
> +static struct rc_keymap msi_tvanywhere_map = {
> + .map = {
> + .scan = msi_tvanywhere,
> + .size = ARRAY_SIZE(msi_tvanywhere),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_MSI_TVANYWHERE,
> + }
> +};
> +
> +static int __init init_rc_map_msi_tvanywhere(void)
> +{
> + return ir_register_map(&msi_tvanywhere_map);
> +}
> +
> +static void __exit exit_rc_map_msi_tvanywhere(void)
> +{
> + ir_unregister_map(&msi_tvanywhere_map);
> +}
> +
> +module_init(init_rc_map_msi_tvanywhere)
> +module_exit(exit_rc_map_msi_tvanywhere)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-nebula.c b/drivers/media/IR/keymaps/rc-nebula.c
> new file mode 100644
> index 0000000..ccc50eb
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-nebula.c
> @@ -0,0 +1,96 @@
> +/* nebula.h - Keytable for nebula Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +static struct ir_scancode nebula[] = {
> + { 0x00, KEY_0 },
> + { 0x01, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x03, KEY_3 },
> + { 0x04, KEY_4 },
> + { 0x05, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x09, KEY_9 },
> + { 0x0a, KEY_TV },
> + { 0x0b, KEY_AUX },
> + { 0x0c, KEY_DVD },
> + { 0x0d, KEY_POWER },
> + { 0x0e, KEY_MHP }, /* labelled 'Picture' */
> + { 0x0f, KEY_AUDIO },
> + { 0x10, KEY_INFO },
> + { 0x11, KEY_F13 }, /* 16:9 */
> + { 0x12, KEY_F14 }, /* 14:9 */
> + { 0x13, KEY_EPG },
> + { 0x14, KEY_EXIT },
> + { 0x15, KEY_MENU },
> + { 0x16, KEY_UP },
> + { 0x17, KEY_DOWN },
> + { 0x18, KEY_LEFT },
> + { 0x19, KEY_RIGHT },
> + { 0x1a, KEY_ENTER },
> + { 0x1b, KEY_CHANNELUP },
> + { 0x1c, KEY_CHANNELDOWN },
> + { 0x1d, KEY_VOLUMEUP },
> + { 0x1e, KEY_VOLUMEDOWN },
> + { 0x1f, KEY_RED },
> + { 0x20, KEY_GREEN },
> + { 0x21, KEY_YELLOW },
> + { 0x22, KEY_BLUE },
> + { 0x23, KEY_SUBTITLE },
> + { 0x24, KEY_F15 }, /* AD */
> + { 0x25, KEY_TEXT },
> + { 0x26, KEY_MUTE },
> + { 0x27, KEY_REWIND },
> + { 0x28, KEY_STOP },
> + { 0x29, KEY_PLAY },
> + { 0x2a, KEY_FASTFORWARD },
> + { 0x2b, KEY_F16 }, /* chapter */
> + { 0x2c, KEY_PAUSE },
> + { 0x2d, KEY_PLAY },
> + { 0x2e, KEY_RECORD },
> + { 0x2f, KEY_F17 }, /* picture in picture */
> + { 0x30, KEY_KPPLUS }, /* zoom in */
> + { 0x31, KEY_KPMINUS }, /* zoom out */
> + { 0x32, KEY_F18 }, /* capture */
> + { 0x33, KEY_F19 }, /* web */
> + { 0x34, KEY_EMAIL },
> + { 0x35, KEY_PHONE },
> + { 0x36, KEY_PC },
> +};
> +
> +static struct rc_keymap nebula_map = {
> + .map = {
> + .scan = nebula,
> + .size = ARRAY_SIZE(nebula),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_NEBULA,
> + }
> +};
> +
> +static int __init init_rc_map_nebula(void)
> +{
> + return ir_register_map(&nebula_map);
> +}
> +
> +static void __exit exit_rc_map_nebula(void)
> +{
> + ir_unregister_map(&nebula_map);
> +}
> +
> +module_init(init_rc_map_nebula)
> +module_exit(exit_rc_map_nebula)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-nec-terratec-cinergy-xs.c b/drivers/media/IR/keymaps/rc-nec-terratec-cinergy-xs.c
> new file mode 100644
> index 0000000..e1b54d2
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-nec-terratec-cinergy-xs.c
> @@ -0,0 +1,105 @@
> +/* nec-terratec-cinergy-xs.h - Keytable for nec_terratec_cinergy_xs Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Terratec Cinergy Hybrid T USB XS FM
> + Mauro Carvalho Chehab <mchehab@redhat.com>
> + */
> +
> +static struct ir_scancode nec_terratec_cinergy_xs[] = {
> + { 0x1441, KEY_HOME},
> + { 0x1401, KEY_POWER2},
> +
> + { 0x1442, KEY_MENU}, /* DVD menu */
> + { 0x1443, KEY_SUBTITLE},
> + { 0x1444, KEY_TEXT}, /* Teletext */
> + { 0x1445, KEY_DELETE},
> +
> + { 0x1402, KEY_1},
> + { 0x1403, KEY_2},
> + { 0x1404, KEY_3},
> + { 0x1405, KEY_4},
> + { 0x1406, KEY_5},
> + { 0x1407, KEY_6},
> + { 0x1408, KEY_7},
> + { 0x1409, KEY_8},
> + { 0x140a, KEY_9},
> + { 0x140c, KEY_0},
> +
> + { 0x140b, KEY_TUNER}, /* AV */
> + { 0x140d, KEY_MODE}, /* A.B */
> +
> + { 0x1446, KEY_TV},
> + { 0x1447, KEY_DVD},
> + { 0x1449, KEY_VIDEO},
> + { 0x144a, KEY_RADIO}, /* Music */
> + { 0x144b, KEY_CAMERA}, /* PIC */
> +
> + { 0x1410, KEY_UP},
> + { 0x1411, KEY_LEFT},
> + { 0x1412, KEY_OK},
> + { 0x1413, KEY_RIGHT},
> + { 0x1414, KEY_DOWN},
> +
> + { 0x140f, KEY_EPG},
> + { 0x1416, KEY_INFO},
> + { 0x144d, KEY_BACKSPACE},
> +
> + { 0x141c, KEY_VOLUMEUP},
> + { 0x141e, KEY_VOLUMEDOWN},
> +
> + { 0x144c, KEY_PLAY},
> + { 0x141d, KEY_MUTE},
> +
> + { 0x141b, KEY_CHANNELUP},
> + { 0x141f, KEY_CHANNELDOWN},
> +
> + { 0x1417, KEY_RED},
> + { 0x1418, KEY_GREEN},
> + { 0x1419, KEY_YELLOW},
> + { 0x141a, KEY_BLUE},
> +
> + { 0x1458, KEY_RECORD},
> + { 0x1448, KEY_STOP},
> + { 0x1440, KEY_PAUSE},
> +
> + { 0x1454, KEY_LAST},
> + { 0x144e, KEY_REWIND},
> + { 0x144f, KEY_FASTFORWARD},
> + { 0x145c, KEY_NEXT},
> +};
> +
> +static struct rc_keymap nec_terratec_cinergy_xs_map = {
> + .map = {
> + .scan = nec_terratec_cinergy_xs,
> + .size = ARRAY_SIZE(nec_terratec_cinergy_xs),
> + .ir_type = IR_TYPE_NEC,
> + .name = RC_MAP_NEC_TERRATEC_CINERGY_XS,
> + }
> +};
> +
> +static int __init init_rc_map_nec_terratec_cinergy_xs(void)
> +{
> + return ir_register_map(&nec_terratec_cinergy_xs_map);
> +}
> +
> +static void __exit exit_rc_map_nec_terratec_cinergy_xs(void)
> +{
> + ir_unregister_map(&nec_terratec_cinergy_xs_map);
> +}
> +
> +module_init(init_rc_map_nec_terratec_cinergy_xs)
> +module_exit(exit_rc_map_nec_terratec_cinergy_xs)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-norwood.c b/drivers/media/IR/keymaps/rc-norwood.c
> new file mode 100644
> index 0000000..e5849a6
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-norwood.c
> @@ -0,0 +1,85 @@
> +/* norwood.h - Keytable for norwood Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Norwood Micro (non-Pro) TV Tuner
> + By Peter Naulls <peter@chocky.org>
> + Key comments are the functions given in the manual */
> +
> +static struct ir_scancode norwood[] = {
> + /* Keys 0 to 9 */
> + { 0x20, KEY_0 },
> + { 0x21, KEY_1 },
> + { 0x22, KEY_2 },
> + { 0x23, KEY_3 },
> + { 0x24, KEY_4 },
> + { 0x25, KEY_5 },
> + { 0x26, KEY_6 },
> + { 0x27, KEY_7 },
> + { 0x28, KEY_8 },
> + { 0x29, KEY_9 },
> +
> + { 0x78, KEY_TUNER }, /* Video Source */
> + { 0x2c, KEY_EXIT }, /* Open/Close software */
> + { 0x2a, KEY_SELECT }, /* 2 Digit Select */
> + { 0x69, KEY_AGAIN }, /* Recall */
> +
> + { 0x32, KEY_BRIGHTNESSUP }, /* Brightness increase */
> + { 0x33, KEY_BRIGHTNESSDOWN }, /* Brightness decrease */
> + { 0x6b, KEY_KPPLUS }, /* (not named >>>>>) */
> + { 0x6c, KEY_KPMINUS }, /* (not named <<<<<) */
> +
> + { 0x2d, KEY_MUTE }, /* Mute */
> + { 0x30, KEY_VOLUMEUP }, /* Volume up */
> + { 0x31, KEY_VOLUMEDOWN }, /* Volume down */
> + { 0x60, KEY_CHANNELUP }, /* Channel up */
> + { 0x61, KEY_CHANNELDOWN }, /* Channel down */
> +
> + { 0x3f, KEY_RECORD }, /* Record */
> + { 0x37, KEY_PLAY }, /* Play */
> + { 0x36, KEY_PAUSE }, /* Pause */
> + { 0x2b, KEY_STOP }, /* Stop */
> + { 0x67, KEY_FASTFORWARD }, /* Foward */
> + { 0x66, KEY_REWIND }, /* Rewind */
> + { 0x3e, KEY_SEARCH }, /* Auto Scan */
> + { 0x2e, KEY_CAMERA }, /* Capture Video */
> + { 0x6d, KEY_MENU }, /* Show/Hide Control */
> + { 0x2f, KEY_ZOOM }, /* Full Screen */
> + { 0x34, KEY_RADIO }, /* FM */
> + { 0x65, KEY_POWER }, /* Computer power */
> +};
> +
> +static struct rc_keymap norwood_map = {
> + .map = {
> + .scan = norwood,
> + .size = ARRAY_SIZE(norwood),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_NORWOOD,
> + }
> +};
> +
> +static int __init init_rc_map_norwood(void)
> +{
> + return ir_register_map(&norwood_map);
> +}
> +
> +static void __exit exit_rc_map_norwood(void)
> +{
> + ir_unregister_map(&norwood_map);
> +}
> +
> +module_init(init_rc_map_norwood)
> +module_exit(exit_rc_map_norwood)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-npgtech.c b/drivers/media/IR/keymaps/rc-npgtech.c
> new file mode 100644
> index 0000000..b9ece1e
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-npgtech.c
> @@ -0,0 +1,80 @@
> +/* npgtech.h - Keytable for npgtech Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +static struct ir_scancode npgtech[] = {
> + { 0x1d, KEY_SWITCHVIDEOMODE }, /* switch inputs */
> + { 0x2a, KEY_FRONT },
> +
> + { 0x3e, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x06, KEY_3 },
> + { 0x0a, KEY_4 },
> + { 0x0e, KEY_5 },
> + { 0x12, KEY_6 },
> + { 0x16, KEY_7 },
> + { 0x1a, KEY_8 },
> + { 0x1e, KEY_9 },
> + { 0x3a, KEY_0 },
> + { 0x22, KEY_NUMLOCK }, /* -/-- */
> + { 0x20, KEY_REFRESH },
> +
> + { 0x03, KEY_BRIGHTNESSDOWN },
> + { 0x28, KEY_AUDIO },
> + { 0x3c, KEY_CHANNELUP },
> + { 0x3f, KEY_VOLUMEDOWN },
> + { 0x2e, KEY_MUTE },
> + { 0x3b, KEY_VOLUMEUP },
> + { 0x00, KEY_CHANNELDOWN },
> + { 0x07, KEY_BRIGHTNESSUP },
> + { 0x2c, KEY_TEXT },
> +
> + { 0x37, KEY_RECORD },
> + { 0x17, KEY_PLAY },
> + { 0x13, KEY_PAUSE },
> + { 0x26, KEY_STOP },
> + { 0x18, KEY_FASTFORWARD },
> + { 0x14, KEY_REWIND },
> + { 0x33, KEY_ZOOM },
> + { 0x32, KEY_KEYBOARD },
> + { 0x30, KEY_GOTO }, /* Pointing arrow */
> + { 0x36, KEY_MACRO }, /* Maximize/Minimize (yellow) */
> + { 0x0b, KEY_RADIO },
> + { 0x10, KEY_POWER },
> +
> +};
> +
> +static struct rc_keymap npgtech_map = {
> + .map = {
> + .scan = npgtech,
> + .size = ARRAY_SIZE(npgtech),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_NPGTECH,
> + }
> +};
> +
> +static int __init init_rc_map_npgtech(void)
> +{
> + return ir_register_map(&npgtech_map);
> +}
> +
> +static void __exit exit_rc_map_npgtech(void)
> +{
> + ir_unregister_map(&npgtech_map);
> +}
> +
> +module_init(init_rc_map_npgtech)
> +module_exit(exit_rc_map_npgtech)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-pctv-sedna.c b/drivers/media/IR/keymaps/rc-pctv-sedna.c
> new file mode 100644
> index 0000000..4129bb4
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-pctv-sedna.c
> @@ -0,0 +1,80 @@
> +/* pctv-sedna.h - Keytable for pctv_sedna Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Mapping for the 28 key remote control as seen at
> + http://www.sednacomputer.com/photo/cardbus-tv.jpg
> + Pavel Mihaylov <bin@bash.info>
> + Also for the remote bundled with Kozumi KTV-01C card */
> +
> +static struct ir_scancode pctv_sedna[] = {
> + { 0x00, KEY_0 },
> + { 0x01, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x03, KEY_3 },
> + { 0x04, KEY_4 },
> + { 0x05, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x09, KEY_9 },
> +
> + { 0x0a, KEY_AGAIN }, /* Recall */
> + { 0x0b, KEY_CHANNELUP },
> + { 0x0c, KEY_VOLUMEUP },
> + { 0x0d, KEY_MODE }, /* Stereo */
> + { 0x0e, KEY_STOP },
> + { 0x0f, KEY_PREVIOUSSONG },
> + { 0x10, KEY_ZOOM },
> + { 0x11, KEY_TUNER }, /* Source */
> + { 0x12, KEY_POWER },
> + { 0x13, KEY_MUTE },
> + { 0x15, KEY_CHANNELDOWN },
> + { 0x18, KEY_VOLUMEDOWN },
> + { 0x19, KEY_CAMERA }, /* Snapshot */
> + { 0x1a, KEY_NEXTSONG },
> + { 0x1b, KEY_TIME }, /* Time Shift */
> + { 0x1c, KEY_RADIO }, /* FM Radio */
> + { 0x1d, KEY_RECORD },
> + { 0x1e, KEY_PAUSE },
> + /* additional codes for Kozumi's remote */
> + { 0x14, KEY_INFO }, /* OSD */
> + { 0x16, KEY_OK }, /* OK */
> + { 0x17, KEY_DIGITS }, /* Plus */
> + { 0x1f, KEY_PLAY }, /* Play */
> +};
> +
> +static struct rc_keymap pctv_sedna_map = {
> + .map = {
> + .scan = pctv_sedna,
> + .size = ARRAY_SIZE(pctv_sedna),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_PCTV_SEDNA,
> + }
> +};
> +
> +static int __init init_rc_map_pctv_sedna(void)
> +{
> + return ir_register_map(&pctv_sedna_map);
> +}
> +
> +static void __exit exit_rc_map_pctv_sedna(void)
> +{
> + ir_unregister_map(&pctv_sedna_map);
> +}
> +
> +module_init(init_rc_map_pctv_sedna)
> +module_exit(exit_rc_map_pctv_sedna)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-pinnacle-color.c b/drivers/media/IR/keymaps/rc-pinnacle-color.c
> new file mode 100644
> index 0000000..326e023
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-pinnacle-color.c
> @@ -0,0 +1,94 @@
> +/* pinnacle-color.h - Keytable for pinnacle_color Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +static struct ir_scancode pinnacle_color[] = {
> + { 0x59, KEY_MUTE },
> + { 0x4a, KEY_POWER },
> +
> + { 0x18, KEY_TEXT },
> + { 0x26, KEY_TV },
> + { 0x3d, KEY_PRINT },
> +
> + { 0x48, KEY_RED },
> + { 0x04, KEY_GREEN },
> + { 0x11, KEY_YELLOW },
> + { 0x00, KEY_BLUE },
> +
> + { 0x2d, KEY_VOLUMEUP },
> + { 0x1e, KEY_VOLUMEDOWN },
> +
> + { 0x49, KEY_MENU },
> +
> + { 0x16, KEY_CHANNELUP },
> + { 0x17, KEY_CHANNELDOWN },
> +
> + { 0x20, KEY_UP },
> + { 0x21, KEY_DOWN },
> + { 0x22, KEY_LEFT },
> + { 0x23, KEY_RIGHT },
> + { 0x0d, KEY_SELECT },
> +
> + { 0x08, KEY_BACK },
> + { 0x07, KEY_REFRESH },
> +
> + { 0x2f, KEY_ZOOM },
> + { 0x29, KEY_RECORD },
> +
> + { 0x4b, KEY_PAUSE },
> + { 0x4d, KEY_REWIND },
> + { 0x2e, KEY_PLAY },
> + { 0x4e, KEY_FORWARD },
> + { 0x53, KEY_PREVIOUS },
> + { 0x4c, KEY_STOP },
> + { 0x54, KEY_NEXT },
> +
> + { 0x69, KEY_0 },
> + { 0x6a, KEY_1 },
> + { 0x6b, KEY_2 },
> + { 0x6c, KEY_3 },
> + { 0x6d, KEY_4 },
> + { 0x6e, KEY_5 },
> + { 0x6f, KEY_6 },
> + { 0x70, KEY_7 },
> + { 0x71, KEY_8 },
> + { 0x72, KEY_9 },
> +
> + { 0x74, KEY_CHANNEL },
> + { 0x0a, KEY_BACKSPACE },
> +};
> +
> +static struct rc_keymap pinnacle_color_map = {
> + .map = {
> + .scan = pinnacle_color,
> + .size = ARRAY_SIZE(pinnacle_color),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_PINNACLE_COLOR,
> + }
> +};
> +
> +static int __init init_rc_map_pinnacle_color(void)
> +{
> + return ir_register_map(&pinnacle_color_map);
> +}
> +
> +static void __exit exit_rc_map_pinnacle_color(void)
> +{
> + ir_unregister_map(&pinnacle_color_map);
> +}
> +
> +module_init(init_rc_map_pinnacle_color)
> +module_exit(exit_rc_map_pinnacle_color)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-pinnacle-grey.c b/drivers/media/IR/keymaps/rc-pinnacle-grey.c
> new file mode 100644
> index 0000000..14cb772
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-pinnacle-grey.c
> @@ -0,0 +1,89 @@
> +/* pinnacle-grey.h - Keytable for pinnacle_grey Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +static struct ir_scancode pinnacle_grey[] = {
> + { 0x3a, KEY_0 },
> + { 0x31, KEY_1 },
> + { 0x32, KEY_2 },
> + { 0x33, KEY_3 },
> + { 0x34, KEY_4 },
> + { 0x35, KEY_5 },
> + { 0x36, KEY_6 },
> + { 0x37, KEY_7 },
> + { 0x38, KEY_8 },
> + { 0x39, KEY_9 },
> +
> + { 0x2f, KEY_POWER },
> +
> + { 0x2e, KEY_P },
> + { 0x1f, KEY_L },
> + { 0x2b, KEY_I },
> +
> + { 0x2d, KEY_SCREEN },
> + { 0x1e, KEY_ZOOM },
> + { 0x1b, KEY_VOLUMEUP },
> + { 0x0f, KEY_VOLUMEDOWN },
> + { 0x17, KEY_CHANNELUP },
> + { 0x1c, KEY_CHANNELDOWN },
> + { 0x25, KEY_INFO },
> +
> + { 0x3c, KEY_MUTE },
> +
> + { 0x3d, KEY_LEFT },
> + { 0x3b, KEY_RIGHT },
> +
> + { 0x3f, KEY_UP },
> + { 0x3e, KEY_DOWN },
> + { 0x1a, KEY_ENTER },
> +
> + { 0x1d, KEY_MENU },
> + { 0x19, KEY_AGAIN },
> + { 0x16, KEY_PREVIOUSSONG },
> + { 0x13, KEY_NEXTSONG },
> + { 0x15, KEY_PAUSE },
> + { 0x0e, KEY_REWIND },
> + { 0x0d, KEY_PLAY },
> + { 0x0b, KEY_STOP },
> + { 0x07, KEY_FORWARD },
> + { 0x27, KEY_RECORD },
> + { 0x26, KEY_TUNER },
> + { 0x29, KEY_TEXT },
> + { 0x2a, KEY_MEDIA },
> + { 0x18, KEY_EPG },
> +};
> +
> +static struct rc_keymap pinnacle_grey_map = {
> + .map = {
> + .scan = pinnacle_grey,
> + .size = ARRAY_SIZE(pinnacle_grey),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_PINNACLE_GREY,
> + }
> +};
> +
> +static int __init init_rc_map_pinnacle_grey(void)
> +{
> + return ir_register_map(&pinnacle_grey_map);
> +}
> +
> +static void __exit exit_rc_map_pinnacle_grey(void)
> +{
> + ir_unregister_map(&pinnacle_grey_map);
> +}
> +
> +module_init(init_rc_map_pinnacle_grey)
> +module_exit(exit_rc_map_pinnacle_grey)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-pinnacle-pctv-hd.c b/drivers/media/IR/keymaps/rc-pinnacle-pctv-hd.c
> new file mode 100644
> index 0000000..835bf4e
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-pinnacle-pctv-hd.c
> @@ -0,0 +1,73 @@
> +/* pinnacle-pctv-hd.h - Keytable for pinnacle_pctv_hd Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Pinnacle PCTV HD 800i mini remote */
> +
> +static struct ir_scancode pinnacle_pctv_hd[] = {
> +
> + { 0x0f, KEY_1 },
> + { 0x15, KEY_2 },
> + { 0x10, KEY_3 },
> + { 0x18, KEY_4 },
> + { 0x1b, KEY_5 },
> + { 0x1e, KEY_6 },
> + { 0x11, KEY_7 },
> + { 0x21, KEY_8 },
> + { 0x12, KEY_9 },
> + { 0x27, KEY_0 },
> +
> + { 0x24, KEY_ZOOM },
> + { 0x2a, KEY_SUBTITLE },
> +
> + { 0x00, KEY_MUTE },
> + { 0x01, KEY_ENTER }, /* Pinnacle Logo */
> + { 0x39, KEY_POWER },
> +
> + { 0x03, KEY_VOLUMEUP },
> + { 0x09, KEY_VOLUMEDOWN },
> + { 0x06, KEY_CHANNELUP },
> + { 0x0c, KEY_CHANNELDOWN },
> +
> + { 0x2d, KEY_REWIND },
> + { 0x30, KEY_PLAYPAUSE },
> + { 0x33, KEY_FASTFORWARD },
> + { 0x3c, KEY_STOP },
> + { 0x36, KEY_RECORD },
> + { 0x3f, KEY_EPG }, /* Labeled "?" */
> +};
> +
> +static struct rc_keymap pinnacle_pctv_hd_map = {
> + .map = {
> + .scan = pinnacle_pctv_hd,
> + .size = ARRAY_SIZE(pinnacle_pctv_hd),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_PINNACLE_PCTV_HD,
> + }
> +};
> +
> +static int __init init_rc_map_pinnacle_pctv_hd(void)
> +{
> + return ir_register_map(&pinnacle_pctv_hd_map);
> +}
> +
> +static void __exit exit_rc_map_pinnacle_pctv_hd(void)
> +{
> + ir_unregister_map(&pinnacle_pctv_hd_map);
> +}
> +
> +module_init(init_rc_map_pinnacle_pctv_hd)
> +module_exit(exit_rc_map_pinnacle_pctv_hd)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-pixelview-new.c b/drivers/media/IR/keymaps/rc-pixelview-new.c
> new file mode 100644
> index 0000000..7bbbbf5
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-pixelview-new.c
> @@ -0,0 +1,83 @@
> +/* pixelview-new.h - Keytable for pixelview_new Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/*
> + Mauro Carvalho Chehab <mchehab@infradead.org>
> + present on PV MPEG 8000GT
> + */
> +
> +static struct ir_scancode pixelview_new[] = {
> + { 0x3c, KEY_TIME }, /* Timeshift */
> + { 0x12, KEY_POWER },
> +
> + { 0x3d, KEY_1 },
> + { 0x38, KEY_2 },
> + { 0x18, KEY_3 },
> + { 0x35, KEY_4 },
> + { 0x39, KEY_5 },
> + { 0x15, KEY_6 },
> + { 0x36, KEY_7 },
> + { 0x3a, KEY_8 },
> + { 0x1e, KEY_9 },
> + { 0x3e, KEY_0 },
> +
> + { 0x1c, KEY_AGAIN }, /* LOOP */
> + { 0x3f, KEY_MEDIA }, /* Source */
> + { 0x1f, KEY_LAST }, /* +100 */
> + { 0x1b, KEY_MUTE },
> +
> + { 0x17, KEY_CHANNELDOWN },
> + { 0x16, KEY_CHANNELUP },
> + { 0x10, KEY_VOLUMEUP },
> + { 0x14, KEY_VOLUMEDOWN },
> + { 0x13, KEY_ZOOM },
> +
> + { 0x19, KEY_CAMERA }, /* SNAPSHOT */
> + { 0x1a, KEY_SEARCH }, /* scan */
> +
> + { 0x37, KEY_REWIND }, /* << */
> + { 0x32, KEY_RECORD }, /* o (red) */
> + { 0x33, KEY_FORWARD }, /* >> */
> + { 0x11, KEY_STOP }, /* square */
> + { 0x3b, KEY_PLAY }, /* > */
> + { 0x30, KEY_PLAYPAUSE }, /* || */
> +
> + { 0x31, KEY_TV },
> + { 0x34, KEY_RADIO },
> +};
> +
> +static struct rc_keymap pixelview_new_map = {
> + .map = {
> + .scan = pixelview_new,
> + .size = ARRAY_SIZE(pixelview_new),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_PIXELVIEW_NEW,
> + }
> +};
> +
> +static int __init init_rc_map_pixelview_new(void)
> +{
> + return ir_register_map(&pixelview_new_map);
> +}
> +
> +static void __exit exit_rc_map_pixelview_new(void)
> +{
> + ir_unregister_map(&pixelview_new_map);
> +}
> +
> +module_init(init_rc_map_pixelview_new)
> +module_exit(exit_rc_map_pixelview_new)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-pixelview.c b/drivers/media/IR/keymaps/rc-pixelview.c
> new file mode 100644
> index 0000000..82ff12e
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-pixelview.c
> @@ -0,0 +1,82 @@
> +/* pixelview.h - Keytable for pixelview Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +static struct ir_scancode pixelview[] = {
> +
> + { 0x1e, KEY_POWER }, /* power */
> + { 0x07, KEY_MEDIA }, /* source */
> + { 0x1c, KEY_SEARCH }, /* scan */
> +
> +
> + { 0x03, KEY_TUNER }, /* TV/FM */
> +
> + { 0x00, KEY_RECORD },
> + { 0x08, KEY_STOP },
> + { 0x11, KEY_PLAY },
> +
> + { 0x1a, KEY_PLAYPAUSE }, /* freeze */
> + { 0x19, KEY_ZOOM }, /* zoom */
> + { 0x0f, KEY_TEXT }, /* min */
> +
> + { 0x01, KEY_1 },
> + { 0x0b, KEY_2 },
> + { 0x1b, KEY_3 },
> + { 0x05, KEY_4 },
> + { 0x09, KEY_5 },
> + { 0x15, KEY_6 },
> + { 0x06, KEY_7 },
> + { 0x0a, KEY_8 },
> + { 0x12, KEY_9 },
> + { 0x02, KEY_0 },
> + { 0x10, KEY_LAST }, /* +100 */
> + { 0x13, KEY_LIST }, /* recall */
> +
> + { 0x1f, KEY_CHANNELUP }, /* chn down */
> + { 0x17, KEY_CHANNELDOWN }, /* chn up */
> + { 0x16, KEY_VOLUMEUP }, /* vol down */
> + { 0x14, KEY_VOLUMEDOWN }, /* vol up */
> +
> + { 0x04, KEY_KPMINUS }, /* <<< */
> + { 0x0e, KEY_SETUP }, /* function */
> + { 0x0c, KEY_KPPLUS }, /* >>> */
> +
> + { 0x0d, KEY_GOTO }, /* mts */
> + { 0x1d, KEY_REFRESH }, /* reset */
> + { 0x18, KEY_MUTE }, /* mute/unmute */
> +};
> +
> +static struct rc_keymap pixelview_map = {
> + .map = {
> + .scan = pixelview,
> + .size = ARRAY_SIZE(pixelview),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_PIXELVIEW,
> + }
> +};
> +
> +static int __init init_rc_map_pixelview(void)
> +{
> + return ir_register_map(&pixelview_map);
> +}
> +
> +static void __exit exit_rc_map_pixelview(void)
> +{
> + ir_unregister_map(&pixelview_map);
> +}
> +
> +module_init(init_rc_map_pixelview)
> +module_exit(exit_rc_map_pixelview)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-powercolor-real-angel.c b/drivers/media/IR/keymaps/rc-powercolor-real-angel.c
> new file mode 100644
> index 0000000..7cef819
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-powercolor-real-angel.c
> @@ -0,0 +1,81 @@
> +/* powercolor-real-angel.h - Keytable for powercolor_real_angel Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/*
> + * Remote control for Powercolor Real Angel 330
> + * Daniel Fraga <fragabr@gmail.com>
> + */
> +
> +static struct ir_scancode powercolor_real_angel[] = {
> + { 0x38, KEY_SWITCHVIDEOMODE }, /* switch inputs */
> + { 0x0c, KEY_MEDIA }, /* Turn ON/OFF App */
> + { 0x00, KEY_0 },
> + { 0x01, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x03, KEY_3 },
> + { 0x04, KEY_4 },
> + { 0x05, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x09, KEY_9 },
> + { 0x0a, KEY_DIGITS }, /* single, double, tripple digit */
> + { 0x29, KEY_PREVIOUS }, /* previous channel */
> + { 0x12, KEY_BRIGHTNESSUP },
> + { 0x13, KEY_BRIGHTNESSDOWN },
> + { 0x2b, KEY_MODE }, /* stereo/mono */
> + { 0x2c, KEY_TEXT }, /* teletext */
> + { 0x20, KEY_CHANNELUP }, /* channel up */
> + { 0x21, KEY_CHANNELDOWN }, /* channel down */
> + { 0x10, KEY_VOLUMEUP }, /* volume up */
> + { 0x11, KEY_VOLUMEDOWN }, /* volume down */
> + { 0x0d, KEY_MUTE },
> + { 0x1f, KEY_RECORD },
> + { 0x17, KEY_PLAY },
> + { 0x16, KEY_PAUSE },
> + { 0x0b, KEY_STOP },
> + { 0x27, KEY_FASTFORWARD },
> + { 0x26, KEY_REWIND },
> + { 0x1e, KEY_SEARCH }, /* autoscan */
> + { 0x0e, KEY_CAMERA }, /* snapshot */
> + { 0x2d, KEY_SETUP },
> + { 0x0f, KEY_SCREEN }, /* full screen */
> + { 0x14, KEY_RADIO }, /* FM radio */
> + { 0x25, KEY_POWER }, /* power */
> +};
> +
> +static struct rc_keymap powercolor_real_angel_map = {
> + .map = {
> + .scan = powercolor_real_angel,
> + .size = ARRAY_SIZE(powercolor_real_angel),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_POWERCOLOR_REAL_ANGEL,
> + }
> +};
> +
> +static int __init init_rc_map_powercolor_real_angel(void)
> +{
> + return ir_register_map(&powercolor_real_angel_map);
> +}
> +
> +static void __exit exit_rc_map_powercolor_real_angel(void)
> +{
> + ir_unregister_map(&powercolor_real_angel_map);
> +}
> +
> +module_init(init_rc_map_powercolor_real_angel)
> +module_exit(exit_rc_map_powercolor_real_angel)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-proteus-2309.c b/drivers/media/IR/keymaps/rc-proteus-2309.c
> new file mode 100644
> index 0000000..22e92d3
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-proteus-2309.c
> @@ -0,0 +1,69 @@
> +/* proteus-2309.h - Keytable for proteus_2309 Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Michal Majchrowicz <mmajchrowicz@gmail.com> */
> +
> +static struct ir_scancode proteus_2309[] = {
> + /* numeric */
> + { 0x00, KEY_0 },
> + { 0x01, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x03, KEY_3 },
> + { 0x04, KEY_4 },
> + { 0x05, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x09, KEY_9 },
> +
> + { 0x5c, KEY_POWER }, /* power */
> + { 0x20, KEY_ZOOM }, /* full screen */
> + { 0x0f, KEY_BACKSPACE }, /* recall */
> + { 0x1b, KEY_ENTER }, /* mute */
> + { 0x41, KEY_RECORD }, /* record */
> + { 0x43, KEY_STOP }, /* stop */
> + { 0x16, KEY_S },
> + { 0x1a, KEY_POWER2 }, /* off */
> + { 0x2e, KEY_RED },
> + { 0x1f, KEY_CHANNELDOWN }, /* channel - */
> + { 0x1c, KEY_CHANNELUP }, /* channel + */
> + { 0x10, KEY_VOLUMEDOWN }, /* volume - */
> + { 0x1e, KEY_VOLUMEUP }, /* volume + */
> + { 0x14, KEY_F1 },
> +};
> +
> +static struct rc_keymap proteus_2309_map = {
> + .map = {
> + .scan = proteus_2309,
> + .size = ARRAY_SIZE(proteus_2309),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_PROTEUS_2309,
> + }
> +};
> +
> +static int __init init_rc_map_proteus_2309(void)
> +{
> + return ir_register_map(&proteus_2309_map);
> +}
> +
> +static void __exit exit_rc_map_proteus_2309(void)
> +{
> + ir_unregister_map(&proteus_2309_map);
> +}
> +
> +module_init(init_rc_map_proteus_2309)
> +module_exit(exit_rc_map_proteus_2309)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-purpletv.c b/drivers/media/IR/keymaps/rc-purpletv.c
> new file mode 100644
> index 0000000..4e20fc2
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-purpletv.c
> @@ -0,0 +1,81 @@
> +/* purpletv.h - Keytable for purpletv Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +static struct ir_scancode purpletv[] = {
> + { 0x03, KEY_POWER },
> + { 0x6f, KEY_MUTE },
> + { 0x10, KEY_BACKSPACE }, /* Recall */
> +
> + { 0x11, KEY_0 },
> + { 0x04, KEY_1 },
> + { 0x05, KEY_2 },
> + { 0x06, KEY_3 },
> + { 0x08, KEY_4 },
> + { 0x09, KEY_5 },
> + { 0x0a, KEY_6 },
> + { 0x0c, KEY_7 },
> + { 0x0d, KEY_8 },
> + { 0x0e, KEY_9 },
> + { 0x12, KEY_DOT }, /* 100+ */
> +
> + { 0x07, KEY_VOLUMEUP },
> + { 0x0b, KEY_VOLUMEDOWN },
> + { 0x1a, KEY_KPPLUS },
> + { 0x18, KEY_KPMINUS },
> + { 0x15, KEY_UP },
> + { 0x1d, KEY_DOWN },
> + { 0x0f, KEY_CHANNELUP },
> + { 0x13, KEY_CHANNELDOWN },
> + { 0x48, KEY_ZOOM },
> +
> + { 0x1b, KEY_VIDEO }, /* Video source */
> + { 0x1f, KEY_CAMERA }, /* Snapshot */
> + { 0x49, KEY_LANGUAGE }, /* MTS Select */
> + { 0x19, KEY_SEARCH }, /* Auto Scan */
> +
> + { 0x4b, KEY_RECORD },
> + { 0x46, KEY_PLAY },
> + { 0x45, KEY_PAUSE }, /* Pause */
> + { 0x44, KEY_STOP },
> + { 0x43, KEY_TIME }, /* Time Shift */
> + { 0x17, KEY_CHANNEL }, /* SURF CH */
> + { 0x40, KEY_FORWARD }, /* Forward ? */
> + { 0x42, KEY_REWIND }, /* Backward ? */
> +
> +};
> +
> +static struct rc_keymap purpletv_map = {
> + .map = {
> + .scan = purpletv,
> + .size = ARRAY_SIZE(purpletv),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_PURPLETV,
> + }
> +};
> +
> +static int __init init_rc_map_purpletv(void)
> +{
> + return ir_register_map(&purpletv_map);
> +}
> +
> +static void __exit exit_rc_map_purpletv(void)
> +{
> + ir_unregister_map(&purpletv_map);
> +}
> +
> +module_init(init_rc_map_purpletv)
> +module_exit(exit_rc_map_purpletv)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-pv951.c b/drivers/media/IR/keymaps/rc-pv951.c
> new file mode 100644
> index 0000000..36679e7
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-pv951.c
> @@ -0,0 +1,78 @@
> +/* pv951.h - Keytable for pv951 Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Mark Phalan <phalanm@o2.ie> */
> +
> +static struct ir_scancode pv951[] = {
> + { 0x00, KEY_0 },
> + { 0x01, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x03, KEY_3 },
> + { 0x04, KEY_4 },
> + { 0x05, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x09, KEY_9 },
> +
> + { 0x12, KEY_POWER },
> + { 0x10, KEY_MUTE },
> + { 0x1f, KEY_VOLUMEDOWN },
> + { 0x1b, KEY_VOLUMEUP },
> + { 0x1a, KEY_CHANNELUP },
> + { 0x1e, KEY_CHANNELDOWN },
> + { 0x0e, KEY_PAGEUP },
> + { 0x1d, KEY_PAGEDOWN },
> + { 0x13, KEY_SOUND },
> +
> + { 0x18, KEY_KPPLUSMINUS }, /* CH +/- */
> + { 0x16, KEY_SUBTITLE }, /* CC */
> + { 0x0d, KEY_TEXT }, /* TTX */
> + { 0x0b, KEY_TV }, /* AIR/CBL */
> + { 0x11, KEY_PC }, /* PC/TV */
> + { 0x17, KEY_OK }, /* CH RTN */
> + { 0x19, KEY_MODE }, /* FUNC */
> + { 0x0c, KEY_SEARCH }, /* AUTOSCAN */
> +
> + /* Not sure what to do with these ones! */
> + { 0x0f, KEY_SELECT }, /* SOURCE */
> + { 0x0a, KEY_KPPLUS }, /* +100 */
> + { 0x14, KEY_EQUAL }, /* SYNC */
> + { 0x1c, KEY_MEDIA }, /* PC/TV */
> +};
> +
> +static struct rc_keymap pv951_map = {
> + .map = {
> + .scan = pv951,
> + .size = ARRAY_SIZE(pv951),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_PV951,
> + }
> +};
> +
> +static int __init init_rc_map_pv951(void)
> +{
> + return ir_register_map(&pv951_map);
> +}
> +
> +static void __exit exit_rc_map_pv951(void)
> +{
> + ir_unregister_map(&pv951_map);
> +}
> +
> +module_init(init_rc_map_pv951)
> +module_exit(exit_rc_map_pv951)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-rc5-hauppauge-new.c b/drivers/media/IR/keymaps/rc-rc5-hauppauge-new.c
> new file mode 100644
> index 0000000..cc6b8f5
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-rc5-hauppauge-new.c
> @@ -0,0 +1,103 @@
> +/* rc5-hauppauge-new.h - Keytable for rc5_hauppauge_new Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/*
> + * Hauppauge:the newer, gray remotes (seems there are multiple
> + * slightly different versions), shipped with cx88+ivtv cards.
> + *
> + * This table contains the complete RC5 code, instead of just the data part
> + */
> +
> +static struct ir_scancode rc5_hauppauge_new[] = {
> + /* Keys 0 to 9 */
> + { 0x1e00, KEY_0 },
> + { 0x1e01, KEY_1 },
> + { 0x1e02, KEY_2 },
> + { 0x1e03, KEY_3 },
> + { 0x1e04, KEY_4 },
> + { 0x1e05, KEY_5 },
> + { 0x1e06, KEY_6 },
> + { 0x1e07, KEY_7 },
> + { 0x1e08, KEY_8 },
> + { 0x1e09, KEY_9 },
> +
> + { 0x1e0a, KEY_TEXT }, /* keypad asterisk as well */
> + { 0x1e0b, KEY_RED }, /* red button */
> + { 0x1e0c, KEY_RADIO },
> + { 0x1e0d, KEY_MENU },
> + { 0x1e0e, KEY_SUBTITLE }, /* also the # key */
> + { 0x1e0f, KEY_MUTE },
> + { 0x1e10, KEY_VOLUMEUP },
> + { 0x1e11, KEY_VOLUMEDOWN },
> + { 0x1e12, KEY_PREVIOUS }, /* previous channel */
> + { 0x1e14, KEY_UP },
> + { 0x1e15, KEY_DOWN },
> + { 0x1e16, KEY_LEFT },
> + { 0x1e17, KEY_RIGHT },
> + { 0x1e18, KEY_VIDEO }, /* Videos */
> + { 0x1e19, KEY_AUDIO }, /* Music */
> + /* 0x1e1a: Pictures - presume this means
> + "Multimedia Home Platform" -
> + no "PICTURES" key in input.h
> + */
> + { 0x1e1a, KEY_MHP },
> +
> + { 0x1e1b, KEY_EPG }, /* Guide */
> + { 0x1e1c, KEY_TV },
> + { 0x1e1e, KEY_NEXTSONG }, /* skip >| */
> + { 0x1e1f, KEY_EXIT }, /* back/exit */
> + { 0x1e20, KEY_CHANNELUP }, /* channel / program + */
> + { 0x1e21, KEY_CHANNELDOWN }, /* channel / program - */
> + { 0x1e22, KEY_CHANNEL }, /* source (old black remote) */
> + { 0x1e24, KEY_PREVIOUSSONG }, /* replay |< */
> + { 0x1e25, KEY_ENTER }, /* OK */
> + { 0x1e26, KEY_SLEEP }, /* minimize (old black remote) */
> + { 0x1e29, KEY_BLUE }, /* blue key */
> + { 0x1e2e, KEY_GREEN }, /* green button */
> + { 0x1e30, KEY_PAUSE }, /* pause */
> + { 0x1e32, KEY_REWIND }, /* backward << */
> + { 0x1e34, KEY_FASTFORWARD }, /* forward >> */
> + { 0x1e35, KEY_PLAY },
> + { 0x1e36, KEY_STOP },
> + { 0x1e37, KEY_RECORD }, /* recording */
> + { 0x1e38, KEY_YELLOW }, /* yellow key */
> + { 0x1e3b, KEY_SELECT }, /* top right button */
> + { 0x1e3c, KEY_ZOOM }, /* full */
> + { 0x1e3d, KEY_POWER }, /* system power (green button) */
> +};
> +
> +static struct rc_keymap rc5_hauppauge_new_map = {
> + .map = {
> + .scan = rc5_hauppauge_new,
> + .size = ARRAY_SIZE(rc5_hauppauge_new),
> + .ir_type = IR_TYPE_RC5,
> + .name = RC_MAP_RC5_HAUPPAUGE_NEW,
> + }
> +};
> +
> +static int __init init_rc_map_rc5_hauppauge_new(void)
> +{
> + return ir_register_map(&rc5_hauppauge_new_map);
> +}
> +
> +static void __exit exit_rc_map_rc5_hauppauge_new(void)
> +{
> + ir_unregister_map(&rc5_hauppauge_new_map);
> +}
> +
> +module_init(init_rc_map_rc5_hauppauge_new)
> +module_exit(exit_rc_map_rc5_hauppauge_new)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-rc5-tv.c b/drivers/media/IR/keymaps/rc-rc5-tv.c
> new file mode 100644
> index 0000000..73cce2f
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-rc5-tv.c
> @@ -0,0 +1,81 @@
> +/* rc5-tv.h - Keytable for rc5_tv Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* generic RC5 keytable */
> +/* see http://users.pandora.be/nenya/electronics/rc5/codes00.htm */
> +/* used by old (black) Hauppauge remotes */
> +
> +static struct ir_scancode rc5_tv[] = {
> + /* Keys 0 to 9 */
> + { 0x00, KEY_0 },
> + { 0x01, KEY_1 },
> + { 0x02, KEY_2 },
> + { 0x03, KEY_3 },
> + { 0x04, KEY_4 },
> + { 0x05, KEY_5 },
> + { 0x06, KEY_6 },
> + { 0x07, KEY_7 },
> + { 0x08, KEY_8 },
> + { 0x09, KEY_9 },
> +
> + { 0x0b, KEY_CHANNEL }, /* channel / program (japan: 11) */
> + { 0x0c, KEY_POWER }, /* standby */
> + { 0x0d, KEY_MUTE }, /* mute / demute */
> + { 0x0f, KEY_TV }, /* display */
> + { 0x10, KEY_VOLUMEUP },
> + { 0x11, KEY_VOLUMEDOWN },
> + { 0x12, KEY_BRIGHTNESSUP },
> + { 0x13, KEY_BRIGHTNESSDOWN },
> + { 0x1e, KEY_SEARCH }, /* search + */
> + { 0x20, KEY_CHANNELUP }, /* channel / program + */
> + { 0x21, KEY_CHANNELDOWN }, /* channel / program - */
> + { 0x22, KEY_CHANNEL }, /* alt / channel */
> + { 0x23, KEY_LANGUAGE }, /* 1st / 2nd language */
> + { 0x26, KEY_SLEEP }, /* sleeptimer */
> + { 0x2e, KEY_MENU }, /* 2nd controls (USA: menu) */
> + { 0x30, KEY_PAUSE },
> + { 0x32, KEY_REWIND },
> + { 0x33, KEY_GOTO },
> + { 0x35, KEY_PLAY },
> + { 0x36, KEY_STOP },
> + { 0x37, KEY_RECORD }, /* recording */
> + { 0x3c, KEY_TEXT }, /* teletext submode (Japan: 12) */
> + { 0x3d, KEY_SUSPEND }, /* system standby */
> +
> +};
> +
> +static struct rc_keymap rc5_tv_map = {
> + .map = {
> + .scan = rc5_tv,
> + .size = ARRAY_SIZE(rc5_tv),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_RC5_TV,
> + }
> +};
> +
> +static int __init init_rc_map_rc5_tv(void)
> +{
> + return ir_register_map(&rc5_tv_map);
> +}
> +
> +static void __exit exit_rc_map_rc5_tv(void)
> +{
> + ir_unregister_map(&rc5_tv_map);
> +}
> +
> +module_init(init_rc_map_rc5_tv)
> +module_exit(exit_rc_map_rc5_tv)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-real-audio-220-32-keys.c b/drivers/media/IR/keymaps/rc-real-audio-220-32-keys.c
> new file mode 100644
> index 0000000..ab1a6d2
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-real-audio-220-32-keys.c
> @@ -0,0 +1,78 @@
> +/* real-audio-220-32-keys.h - Keytable for real_audio_220_32_keys Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Zogis Real Audio 220 - 32 keys IR */
> +
> +static struct ir_scancode real_audio_220_32_keys[] = {
> + { 0x1c, KEY_RADIO},
> + { 0x12, KEY_POWER2},
> +
> + { 0x01, KEY_1},
> + { 0x02, KEY_2},
> + { 0x03, KEY_3},
> + { 0x04, KEY_4},
> + { 0x05, KEY_5},
> + { 0x06, KEY_6},
> + { 0x07, KEY_7},
> + { 0x08, KEY_8},
> + { 0x09, KEY_9},
> + { 0x00, KEY_0},
> +
> + { 0x0c, KEY_VOLUMEUP},
> + { 0x18, KEY_VOLUMEDOWN},
> + { 0x0b, KEY_CHANNELUP},
> + { 0x15, KEY_CHANNELDOWN},
> + { 0x16, KEY_ENTER},
> +
> + { 0x11, KEY_LIST}, /* Source */
> + { 0x0d, KEY_AUDIO}, /* stereo */
> +
> + { 0x0f, KEY_PREVIOUS}, /* Prev */
> + { 0x1b, KEY_TIME}, /* Timeshift */
> + { 0x1a, KEY_NEXT}, /* Next */
> +
> + { 0x0e, KEY_STOP},
> + { 0x1f, KEY_PLAY},
> + { 0x1e, KEY_PLAYPAUSE}, /* Pause */
> +
> + { 0x1d, KEY_RECORD},
> + { 0x13, KEY_MUTE},
> + { 0x19, KEY_CAMERA}, /* Snapshot */
> +
> +};
> +
> +static struct rc_keymap real_audio_220_32_keys_map = {
> + .map = {
> + .scan = real_audio_220_32_keys,
> + .size = ARRAY_SIZE(real_audio_220_32_keys),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_REAL_AUDIO_220_32_KEYS,
> + }
> +};
> +
> +static int __init init_rc_map_real_audio_220_32_keys(void)
> +{
> + return ir_register_map(&real_audio_220_32_keys_map);
> +}
> +
> +static void __exit exit_rc_map_real_audio_220_32_keys(void)
> +{
> + ir_unregister_map(&real_audio_220_32_keys_map);
> +}
> +
> +module_init(init_rc_map_real_audio_220_32_keys)
> +module_exit(exit_rc_map_real_audio_220_32_keys)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-tbs-nec.c b/drivers/media/IR/keymaps/rc-tbs-nec.c
> new file mode 100644
> index 0000000..3309631
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-tbs-nec.c
> @@ -0,0 +1,73 @@
> +/* tbs-nec.h - Keytable for tbs_nec Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +static struct ir_scancode tbs_nec[] = {
> + { 0x04, KEY_POWER2}, /*power*/
> + { 0x14, KEY_MUTE}, /*mute*/
> + { 0x07, KEY_1},
> + { 0x06, KEY_2},
> + { 0x05, KEY_3},
> + { 0x0b, KEY_4},
> + { 0x0a, KEY_5},
> + { 0x09, KEY_6},
> + { 0x0f, KEY_7},
> + { 0x0e, KEY_8},
> + { 0x0d, KEY_9},
> + { 0x12, KEY_0},
> + { 0x16, KEY_CHANNELUP}, /*ch+*/
> + { 0x11, KEY_CHANNELDOWN},/*ch-*/
> + { 0x13, KEY_VOLUMEUP}, /*vol+*/
> + { 0x0c, KEY_VOLUMEDOWN},/*vol-*/
> + { 0x03, KEY_RECORD}, /*rec*/
> + { 0x18, KEY_PAUSE}, /*pause*/
> + { 0x19, KEY_OK}, /*ok*/
> + { 0x1a, KEY_CAMERA}, /* snapshot */
> + { 0x01, KEY_UP},
> + { 0x10, KEY_LEFT},
> + { 0x02, KEY_RIGHT},
> + { 0x08, KEY_DOWN},
> + { 0x15, KEY_FAVORITES},
> + { 0x17, KEY_SUBTITLE},
> + { 0x1d, KEY_ZOOM},
> + { 0x1f, KEY_EXIT},
> + { 0x1e, KEY_MENU},
> + { 0x1c, KEY_EPG},
> + { 0x00, KEY_PREVIOUS},
> + { 0x1b, KEY_MODE},
> +};
> +
> +static struct rc_keymap tbs_nec_map = {
> + .map = {
> + .scan = tbs_nec,
> + .size = ARRAY_SIZE(tbs_nec),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_TBS_NEC,
> + }
> +};
> +
> +static int __init init_rc_map_tbs_nec(void)
> +{
> + return ir_register_map(&tbs_nec_map);
> +}
> +
> +static void __exit exit_rc_map_tbs_nec(void)
> +{
> + ir_unregister_map(&tbs_nec_map);
> +}
> +
> +module_init(init_rc_map_tbs_nec)
> +module_exit(exit_rc_map_tbs_nec)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-terratec-cinergy-xs.c b/drivers/media/IR/keymaps/rc-terratec-cinergy-xs.c
> new file mode 100644
> index 0000000..5326a0b
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-terratec-cinergy-xs.c
> @@ -0,0 +1,92 @@
> +/* terratec-cinergy-xs.h - Keytable for terratec_cinergy_xs Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Terratec Cinergy Hybrid T USB XS
> + Devin Heitmueller <dheitmueller@linuxtv.org>
> + */
> +
> +static struct ir_scancode terratec_cinergy_xs[] = {
> + { 0x41, KEY_HOME},
> + { 0x01, KEY_POWER},
> + { 0x42, KEY_MENU},
> + { 0x02, KEY_1},
> + { 0x03, KEY_2},
> + { 0x04, KEY_3},
> + { 0x43, KEY_SUBTITLE},
> + { 0x05, KEY_4},
> + { 0x06, KEY_5},
> + { 0x07, KEY_6},
> + { 0x44, KEY_TEXT},
> + { 0x08, KEY_7},
> + { 0x09, KEY_8},
> + { 0x0a, KEY_9},
> + { 0x45, KEY_DELETE},
> + { 0x0b, KEY_TUNER},
> + { 0x0c, KEY_0},
> + { 0x0d, KEY_MODE},
> + { 0x46, KEY_TV},
> + { 0x47, KEY_DVD},
> + { 0x49, KEY_VIDEO},
> + { 0x4b, KEY_AUX},
> + { 0x10, KEY_UP},
> + { 0x11, KEY_LEFT},
> + { 0x12, KEY_OK},
> + { 0x13, KEY_RIGHT},
> + { 0x14, KEY_DOWN},
> + { 0x0f, KEY_EPG},
> + { 0x16, KEY_INFO},
> + { 0x4d, KEY_BACKSPACE},
> + { 0x1c, KEY_VOLUMEUP},
> + { 0x4c, KEY_PLAY},
> + { 0x1b, KEY_CHANNELUP},
> + { 0x1e, KEY_VOLUMEDOWN},
> + { 0x1d, KEY_MUTE},
> + { 0x1f, KEY_CHANNELDOWN},
> + { 0x17, KEY_RED},
> + { 0x18, KEY_GREEN},
> + { 0x19, KEY_YELLOW},
> + { 0x1a, KEY_BLUE},
> + { 0x58, KEY_RECORD},
> + { 0x48, KEY_STOP},
> + { 0x40, KEY_PAUSE},
> + { 0x54, KEY_LAST},
> + { 0x4e, KEY_REWIND},
> + { 0x4f, KEY_FASTFORWARD},
> + { 0x5c, KEY_NEXT},
> +};
> +
> +static struct rc_keymap terratec_cinergy_xs_map = {
> + .map = {
> + .scan = terratec_cinergy_xs,
> + .size = ARRAY_SIZE(terratec_cinergy_xs),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_TERRATEC_CINERGY_XS,
> + }
> +};
> +
> +static int __init init_rc_map_terratec_cinergy_xs(void)
> +{
> + return ir_register_map(&terratec_cinergy_xs_map);
> +}
> +
> +static void __exit exit_rc_map_terratec_cinergy_xs(void)
> +{
> + ir_unregister_map(&terratec_cinergy_xs_map);
> +}
> +
> +module_init(init_rc_map_terratec_cinergy_xs)
> +module_exit(exit_rc_map_terratec_cinergy_xs)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-tevii-nec.c b/drivers/media/IR/keymaps/rc-tevii-nec.c
> new file mode 100644
> index 0000000..e30d411
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-tevii-nec.c
> @@ -0,0 +1,88 @@
> +/* tevii-nec.h - Keytable for tevii_nec Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +static struct ir_scancode tevii_nec[] = {
> + { 0x0a, KEY_POWER2},
> + { 0x0c, KEY_MUTE},
> + { 0x11, KEY_1},
> + { 0x12, KEY_2},
> + { 0x13, KEY_3},
> + { 0x14, KEY_4},
> + { 0x15, KEY_5},
> + { 0x16, KEY_6},
> + { 0x17, KEY_7},
> + { 0x18, KEY_8},
> + { 0x19, KEY_9},
> + { 0x10, KEY_0},
> + { 0x1c, KEY_MENU},
> + { 0x0f, KEY_VOLUMEDOWN},
> + { 0x1a, KEY_LAST},
> + { 0x0e, KEY_OPEN},
> + { 0x04, KEY_RECORD},
> + { 0x09, KEY_VOLUMEUP},
> + { 0x08, KEY_CHANNELUP},
> + { 0x07, KEY_PVR},
> + { 0x0b, KEY_TIME},
> + { 0x02, KEY_RIGHT},
> + { 0x03, KEY_LEFT},
> + { 0x00, KEY_UP},
> + { 0x1f, KEY_OK},
> + { 0x01, KEY_DOWN},
> + { 0x05, KEY_TUNER},
> + { 0x06, KEY_CHANNELDOWN},
> + { 0x40, KEY_PLAYPAUSE},
> + { 0x1e, KEY_REWIND},
> + { 0x1b, KEY_FAVORITES},
> + { 0x1d, KEY_BACK},
> + { 0x4d, KEY_FASTFORWARD},
> + { 0x44, KEY_EPG},
> + { 0x4c, KEY_INFO},
> + { 0x41, KEY_AB},
> + { 0x43, KEY_AUDIO},
> + { 0x45, KEY_SUBTITLE},
> + { 0x4a, KEY_LIST},
> + { 0x46, KEY_F1},
> + { 0x47, KEY_F2},
> + { 0x5e, KEY_F3},
> + { 0x5c, KEY_F4},
> + { 0x52, KEY_F5},
> + { 0x5a, KEY_F6},
> + { 0x56, KEY_MODE},
> + { 0x58, KEY_SWITCHVIDEOMODE},
> +};
> +
> +static struct rc_keymap tevii_nec_map = {
> + .map = {
> + .scan = tevii_nec,
> + .size = ARRAY_SIZE(tevii_nec),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_TEVII_NEC,
> + }
> +};
> +
> +static int __init init_rc_map_tevii_nec(void)
> +{
> + return ir_register_map(&tevii_nec_map);
> +}
> +
> +static void __exit exit_rc_map_tevii_nec(void)
> +{
> + ir_unregister_map(&tevii_nec_map);
> +}
> +
> +module_init(init_rc_map_tevii_nec)
> +module_exit(exit_rc_map_tevii_nec)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-tt-1500.c b/drivers/media/IR/keymaps/rc-tt-1500.c
> new file mode 100644
> index 0000000..bc88de0
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-tt-1500.c
> @@ -0,0 +1,82 @@
> +/* tt-1500.h - Keytable for tt_1500 Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* for the Technotrend 1500 bundled remotes (grey and black): */
> +
> +static struct ir_scancode tt_1500[] = {
> + { 0x01, KEY_POWER },
> + { 0x02, KEY_SHUFFLE }, /* ? double-arrow key */
> + { 0x03, KEY_1 },
> + { 0x04, KEY_2 },
> + { 0x05, KEY_3 },
> + { 0x06, KEY_4 },
> + { 0x07, KEY_5 },
> + { 0x08, KEY_6 },
> + { 0x09, KEY_7 },
> + { 0x0a, KEY_8 },
> + { 0x0b, KEY_9 },
> + { 0x0c, KEY_0 },
> + { 0x0d, KEY_UP },
> + { 0x0e, KEY_LEFT },
> + { 0x0f, KEY_OK },
> + { 0x10, KEY_RIGHT },
> + { 0x11, KEY_DOWN },
> + { 0x12, KEY_INFO },
> + { 0x13, KEY_EXIT },
> + { 0x14, KEY_RED },
> + { 0x15, KEY_GREEN },
> + { 0x16, KEY_YELLOW },
> + { 0x17, KEY_BLUE },
> + { 0x18, KEY_MUTE },
> + { 0x19, KEY_TEXT },
> + { 0x1a, KEY_MODE }, /* ? TV/Radio */
> + { 0x21, KEY_OPTION },
> + { 0x22, KEY_EPG },
> + { 0x23, KEY_CHANNELUP },
> + { 0x24, KEY_CHANNELDOWN },
> + { 0x25, KEY_VOLUMEUP },
> + { 0x26, KEY_VOLUMEDOWN },
> + { 0x27, KEY_SETUP },
> + { 0x3a, KEY_RECORD }, /* these keys are only in the black remote */
> + { 0x3b, KEY_PLAY },
> + { 0x3c, KEY_STOP },
> + { 0x3d, KEY_REWIND },
> + { 0x3e, KEY_PAUSE },
> + { 0x3f, KEY_FORWARD },
> +};
> +
> +static struct rc_keymap tt_1500_map = {
> + .map = {
> + .scan = tt_1500,
> + .size = ARRAY_SIZE(tt_1500),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_TT_1500,
> + }
> +};
> +
> +static int __init init_rc_map_tt_1500(void)
> +{
> + return ir_register_map(&tt_1500_map);
> +}
> +
> +static void __exit exit_rc_map_tt_1500(void)
> +{
> + ir_unregister_map(&tt_1500_map);
> +}
> +
> +module_init(init_rc_map_tt_1500)
> +module_exit(exit_rc_map_tt_1500)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-videomate-s350.c b/drivers/media/IR/keymaps/rc-videomate-s350.c
> new file mode 100644
> index 0000000..4df7fcd
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-videomate-s350.c
> @@ -0,0 +1,85 @@
> +/* videomate-s350.h - Keytable for videomate_s350 Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +static struct ir_scancode videomate_s350[] = {
> + { 0x00, KEY_TV},
> + { 0x01, KEY_DVD},
> + { 0x04, KEY_RECORD},
> + { 0x05, KEY_VIDEO}, /* TV/Video */
> + { 0x07, KEY_STOP},
> + { 0x08, KEY_PLAYPAUSE},
> + { 0x0a, KEY_REWIND},
> + { 0x0f, KEY_FASTFORWARD},
> + { 0x10, KEY_CHANNELUP},
> + { 0x12, KEY_VOLUMEUP},
> + { 0x13, KEY_CHANNELDOWN},
> + { 0x14, KEY_MUTE},
> + { 0x15, KEY_VOLUMEDOWN},
> + { 0x16, KEY_1},
> + { 0x17, KEY_2},
> + { 0x18, KEY_3},
> + { 0x19, KEY_4},
> + { 0x1a, KEY_5},
> + { 0x1b, KEY_6},
> + { 0x1c, KEY_7},
> + { 0x1d, KEY_8},
> + { 0x1e, KEY_9},
> + { 0x1f, KEY_0},
> + { 0x21, KEY_SLEEP},
> + { 0x24, KEY_ZOOM},
> + { 0x25, KEY_LAST}, /* Recall */
> + { 0x26, KEY_SUBTITLE}, /* CC */
> + { 0x27, KEY_LANGUAGE}, /* MTS */
> + { 0x29, KEY_CHANNEL}, /* SURF */
> + { 0x2b, KEY_A},
> + { 0x2c, KEY_B},
> + { 0x2f, KEY_CAMERA}, /* Snapshot */
> + { 0x23, KEY_RADIO},
> + { 0x02, KEY_PREVIOUSSONG},
> + { 0x06, KEY_NEXTSONG},
> + { 0x03, KEY_EPG},
> + { 0x09, KEY_SETUP},
> + { 0x22, KEY_BACKSPACE},
> + { 0x0c, KEY_UP},
> + { 0x0e, KEY_DOWN},
> + { 0x0b, KEY_LEFT},
> + { 0x0d, KEY_RIGHT},
> + { 0x11, KEY_ENTER},
> + { 0x20, KEY_TEXT},
> +};
> +
> +static struct rc_keymap videomate_s350_map = {
> + .map = {
> + .scan = videomate_s350,
> + .size = ARRAY_SIZE(videomate_s350),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_VIDEOMATE_S350,
> + }
> +};
> +
> +static int __init init_rc_map_videomate_s350(void)
> +{
> + return ir_register_map(&videomate_s350_map);
> +}
> +
> +static void __exit exit_rc_map_videomate_s350(void)
> +{
> + ir_unregister_map(&videomate_s350_map);
> +}
> +
> +module_init(init_rc_map_videomate_s350)
> +module_exit(exit_rc_map_videomate_s350)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-videomate-tv-pvr.c b/drivers/media/IR/keymaps/rc-videomate-tv-pvr.c
> new file mode 100644
> index 0000000..776b0a6
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-videomate-tv-pvr.c
> @@ -0,0 +1,87 @@
> +/* videomate-tv-pvr.h - Keytable for videomate_tv_pvr Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +static struct ir_scancode videomate_tv_pvr[] = {
> + { 0x14, KEY_MUTE },
> + { 0x24, KEY_ZOOM },
> +
> + { 0x01, KEY_DVD },
> + { 0x23, KEY_RADIO },
> + { 0x00, KEY_TV },
> +
> + { 0x0a, KEY_REWIND },
> + { 0x08, KEY_PLAYPAUSE },
> + { 0x0f, KEY_FORWARD },
> +
> + { 0x02, KEY_PREVIOUS },
> + { 0x07, KEY_STOP },
> + { 0x06, KEY_NEXT },
> +
> + { 0x0c, KEY_UP },
> + { 0x0e, KEY_DOWN },
> + { 0x0b, KEY_LEFT },
> + { 0x0d, KEY_RIGHT },
> + { 0x11, KEY_OK },
> +
> + { 0x03, KEY_MENU },
> + { 0x09, KEY_SETUP },
> + { 0x05, KEY_VIDEO },
> + { 0x22, KEY_CHANNEL },
> +
> + { 0x12, KEY_VOLUMEUP },
> + { 0x15, KEY_VOLUMEDOWN },
> + { 0x10, KEY_CHANNELUP },
> + { 0x13, KEY_CHANNELDOWN },
> +
> + { 0x04, KEY_RECORD },
> +
> + { 0x16, KEY_1 },
> + { 0x17, KEY_2 },
> + { 0x18, KEY_3 },
> + { 0x19, KEY_4 },
> + { 0x1a, KEY_5 },
> + { 0x1b, KEY_6 },
> + { 0x1c, KEY_7 },
> + { 0x1d, KEY_8 },
> + { 0x1e, KEY_9 },
> + { 0x1f, KEY_0 },
> +
> + { 0x20, KEY_LANGUAGE },
> + { 0x21, KEY_SLEEP },
> +};
> +
> +static struct rc_keymap videomate_tv_pvr_map = {
> + .map = {
> + .scan = videomate_tv_pvr,
> + .size = ARRAY_SIZE(videomate_tv_pvr),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_VIDEOMATE_TV_PVR,
> + }
> +};
> +
> +static int __init init_rc_map_videomate_tv_pvr(void)
> +{
> + return ir_register_map(&videomate_tv_pvr_map);
> +}
> +
> +static void __exit exit_rc_map_videomate_tv_pvr(void)
> +{
> + ir_unregister_map(&videomate_tv_pvr_map);
> +}
> +
> +module_init(init_rc_map_videomate_tv_pvr)
> +module_exit(exit_rc_map_videomate_tv_pvr)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-winfast-usbii-deluxe.c b/drivers/media/IR/keymaps/rc-winfast-usbii-deluxe.c
> new file mode 100644
> index 0000000..9d2d550
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-winfast-usbii-deluxe.c
> @@ -0,0 +1,82 @@
> +/* winfast-usbii-deluxe.h - Keytable for winfast_usbii_deluxe Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Leadtek Winfast TV USB II Deluxe remote
> + Magnus Alm <magnus.alm@gmail.com>
> + */
> +
> +static struct ir_scancode winfast_usbii_deluxe[] = {
> + { 0x62, KEY_0},
> + { 0x75, KEY_1},
> + { 0x76, KEY_2},
> + { 0x77, KEY_3},
> + { 0x79, KEY_4},
> + { 0x7a, KEY_5},
> + { 0x7b, KEY_6},
> + { 0x7d, KEY_7},
> + { 0x7e, KEY_8},
> + { 0x7f, KEY_9},
> +
> + { 0x38, KEY_CAMERA}, /* SNAPSHOT */
> + { 0x37, KEY_RECORD}, /* RECORD */
> + { 0x35, KEY_TIME}, /* TIMESHIFT */
> +
> + { 0x74, KEY_VOLUMEUP}, /* VOLUMEUP */
> + { 0x78, KEY_VOLUMEDOWN}, /* VOLUMEDOWN */
> + { 0x64, KEY_MUTE}, /* MUTE */
> +
> + { 0x21, KEY_CHANNEL}, /* SURF */
> + { 0x7c, KEY_CHANNELUP}, /* CHANNELUP */
> + { 0x60, KEY_CHANNELDOWN}, /* CHANNELDOWN */
> + { 0x61, KEY_LAST}, /* LAST CHANNEL (RECALL) */
> +
> + { 0x72, KEY_VIDEO}, /* INPUT MODES (TV/FM) */
> +
> + { 0x70, KEY_POWER2}, /* TV ON/OFF */
> +
> + { 0x39, KEY_CYCLEWINDOWS}, /* MINIMIZE (BOSS) */
> + { 0x3a, KEY_NEW}, /* PIP */
> + { 0x73, KEY_ZOOM}, /* FULLSECREEN */
> +
> + { 0x66, KEY_INFO}, /* OSD (DISPLAY) */
> +
> + { 0x31, KEY_DOT}, /* '.' */
> + { 0x63, KEY_ENTER}, /* ENTER */
> +
> +};
> +
> +static struct rc_keymap winfast_usbii_deluxe_map = {
> + .map = {
> + .scan = winfast_usbii_deluxe,
> + .size = ARRAY_SIZE(winfast_usbii_deluxe),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_WINFAST_USBII_DELUXE,
> + }
> +};
> +
> +static int __init init_rc_map_winfast_usbii_deluxe(void)
> +{
> + return ir_register_map(&winfast_usbii_deluxe_map);
> +}
> +
> +static void __exit exit_rc_map_winfast_usbii_deluxe(void)
> +{
> + ir_unregister_map(&winfast_usbii_deluxe_map);
> +}
> +
> +module_init(init_rc_map_winfast_usbii_deluxe)
> +module_exit(exit_rc_map_winfast_usbii_deluxe)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/keymaps/rc-winfast.c b/drivers/media/IR/keymaps/rc-winfast.c
> new file mode 100644
> index 0000000..0e90a3b
> --- /dev/null
> +++ b/drivers/media/IR/keymaps/rc-winfast.c
> @@ -0,0 +1,102 @@
> +/* winfast.h - Keytable for winfast Remote Controller
> + *
> + * keymap imported from ir-keymaps.c
> + *
> + * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + */
> +
> +#include <media/rc-map.h>
> +
> +/* Table for Leadtek Winfast Remote Controls - used by both bttv and cx88 */
> +
> +static struct ir_scancode winfast[] = {
> + /* Keys 0 to 9 */
> + { 0x12, KEY_0 },
> + { 0x05, KEY_1 },
> + { 0x06, KEY_2 },
> + { 0x07, KEY_3 },
> + { 0x09, KEY_4 },
> + { 0x0a, KEY_5 },
> + { 0x0b, KEY_6 },
> + { 0x0d, KEY_7 },
> + { 0x0e, KEY_8 },
> + { 0x0f, KEY_9 },
> +
> + { 0x00, KEY_POWER },
> + { 0x1b, KEY_AUDIO }, /* Audio Source */
> + { 0x02, KEY_TUNER }, /* TV/FM, not on Y0400052 */
> + { 0x1e, KEY_VIDEO }, /* Video Source */
> + { 0x16, KEY_INFO }, /* Display information */
> + { 0x04, KEY_VOLUMEUP },
> + { 0x08, KEY_VOLUMEDOWN },
> + { 0x0c, KEY_CHANNELUP },
> + { 0x10, KEY_CHANNELDOWN },
> + { 0x03, KEY_ZOOM }, /* fullscreen */
> + { 0x1f, KEY_TEXT }, /* closed caption/teletext */
> + { 0x20, KEY_SLEEP },
> + { 0x29, KEY_CLEAR }, /* boss key */
> + { 0x14, KEY_MUTE },
> + { 0x2b, KEY_RED },
> + { 0x2c, KEY_GREEN },
> + { 0x2d, KEY_YELLOW },
> + { 0x2e, KEY_BLUE },
> + { 0x18, KEY_KPPLUS }, /* fine tune + , not on Y040052 */
> + { 0x19, KEY_KPMINUS }, /* fine tune - , not on Y040052 */
> + { 0x2a, KEY_MEDIA }, /* PIP (Picture in picture */
> + { 0x21, KEY_DOT },
> + { 0x13, KEY_ENTER },
> + { 0x11, KEY_LAST }, /* Recall (last channel */
> + { 0x22, KEY_PREVIOUS },
> + { 0x23, KEY_PLAYPAUSE },
> + { 0x24, KEY_NEXT },
> + { 0x25, KEY_TIME }, /* Time Shifting */
> + { 0x26, KEY_STOP },
> + { 0x27, KEY_RECORD },
> + { 0x28, KEY_SAVE }, /* Screenshot */
> + { 0x2f, KEY_MENU },
> + { 0x30, KEY_CANCEL },
> + { 0x31, KEY_CHANNEL }, /* Channel Surf */
> + { 0x32, KEY_SUBTITLE },
> + { 0x33, KEY_LANGUAGE },
> + { 0x34, KEY_REWIND },
> + { 0x35, KEY_FASTFORWARD },
> + { 0x36, KEY_TV },
> + { 0x37, KEY_RADIO }, /* FM */
> + { 0x38, KEY_DVD },
> +
> + { 0x1a, KEY_MODE}, /* change to MCE mode on Y04G0051 */
> + { 0x3e, KEY_F21 }, /* MCE +VOL, on Y04G0033 */
> + { 0x3a, KEY_F22 }, /* MCE -VOL, on Y04G0033 */
> + { 0x3b, KEY_F23 }, /* MCE +CH, on Y04G0033 */
> + { 0x3f, KEY_F24 } /* MCE -CH, on Y04G0033 */
> +};
> +
> +static struct rc_keymap winfast_map = {
> + .map = {
> + .scan = winfast,
> + .size = ARRAY_SIZE(winfast),
> + .ir_type = IR_TYPE_UNKNOWN, /* Legacy IR type */
> + .name = RC_MAP_WINFAST,
> + }
> +};
> +
> +static int __init init_rc_map_winfast(void)
> +{
> + return ir_register_map(&winfast_map);
> +}
> +
> +static void __exit exit_rc_map_winfast(void)
> +{
> + ir_unregister_map(&winfast_map);
> +}
> +
> +module_init(init_rc_map_winfast)
> +module_exit(exit_rc_map_winfast)
> +
> +MODULE_LICENSE("GPL");
> +MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
> diff --git a/drivers/media/IR/rc-map.c b/drivers/media/IR/rc-map.c
> index aa269f5..02c72f0 100644
> --- a/drivers/media/IR/rc-map.c
> +++ b/drivers/media/IR/rc-map.c
> @@ -64,7 +64,7 @@ int ir_register_map(struct rc_keymap *map)
> spin_unlock(&rc_map_lock);
> return 0;
> }
> -EXPORT_SYMBOL_GPL(ir_raw_handler_register);
> +EXPORT_SYMBOL_GPL(ir_register_map);
>
> void ir_unregister_map(struct rc_keymap *map)
> {
> @@ -72,4 +72,4 @@ void ir_unregister_map(struct rc_keymap *map)
> list_del(&map->list);
> spin_unlock(&rc_map_lock);
> }
> -EXPORT_SYMBOL_GPL(ir_raw_handler_unregister);
> +EXPORT_SYMBOL_GPL(ir_unregister_map);
^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [PATCH 08/26] V4L/DVB: Break Remote Controller keymaps into modules
2010-04-10 12:27 ` Andy Walls
@ 2010-04-10 16:06 ` Mauro Carvalho Chehab
2010-04-10 17:26 ` Andy Walls
0 siblings, 1 reply; 29+ messages in thread
From: Mauro Carvalho Chehab @ 2010-04-10 16:06 UTC (permalink / raw)
To: Andy Walls; +Cc: linux-media
Andy Walls wrote:
> On Tue, 2010-04-06 at 15:18 -0300, Mauro Carvalho Chehab wrote:
>> The original Remote Controller approach were very messy: a big file,
>> that were part of ir-common kernel module, containing 64 different
>> RC keymap tables, used by the V4L/DVB drivers.
>>
>> Better to break each RC keymap table into a separate module,
>> registering them into rc core on a process similar to the fs/nls tables.
>>
>> As an userspace program is now in charge of loading those tables,
>> adds an option to allow the complete removal of those tables from
>> kernelspace.
>>
>> Yet, on embedded devices like Set Top Boxes and TV sets, maybe the
>> only available input device is the IR. So, we should keep allowing
>> the usage of in-kernel tables, but a latter patch should change
>> the default to 'n', after giving some time for distros to add
>> the v4l-utils with the ir-keytable program, to allow the table
>> load via userspace.
>
> I know I'm probably late on commenting on this.
>
> Although this is interesting, it seems like overkill.
>
>
> 1. How will this help move us to the "just works" case, if now userspace
> has to help the kernel. Every distro is likely just going to bundle a
> script which loads them all into the kernel and forgets about them.
No. They will either use userspace or kernelspace keymaps. For in-kernel
keymaps, there's nothing needed on userspace.
> 2. How is a driver, which knows the bundled remote, supposed to convey
> to userspace "load this map by default for my IR receiver"? Is that
> covered in another portion of the patch?
It is on a separate patch. Basically, by the name. The table name is stored
on each IR map entry on kernel. If the table is in kernel, the table will
be dynamically loaded, when needed.
Userspace can always replace it by another one.
For example, this is my current test setup:
$ ./ir-keytable
Found /sys/class/rc/rc0/ (/dev/input/event8) with:
Driver "saa7134", raw software decoder, table "rc-avermedia-m135a-rm-jx"
Supported protocols: NEC RC-5 RC-6
Found /sys/class/rc/rc1/ (/dev/input/event9) with:
Driver "cx88xx", hardware decoder, table "rc-pixelview-mk12"
Supported protocols: other
Current protocols: NEC
Found /sys/class/rc/rc2/ (/dev/input/event10) with:
Driver "em28xx", hardware decoder, table "rc-rc5-hauppauge-new"
Supported protocols: NEC RC-5
Current protocols: RC-5
When ready, ir-keytable udev option will get driver and table info and
seek on some files for the proper keymap, if the user wants to replace it
by a customized one, or if the kernel keymap is disabled.
>
> 3. If you're going to be so remote specific, why not add protocol
> information in these regarding the remotes? You can tell the core
> everything to expect from this remote: raw vs. hardware decoder and the
> RC-5/NEC/RC-6/JVC/whatever raw protocol decoder to use. That gets us
> closer to "just works" and avoids false input events from two of the raw
> deoders both thinking they got a valid code.
The table contains the info.
> 4. /sbin/lsmod is now going to give a very long listing with lots of
> noise. When these things are registered with the core, is the module's
> use count incremented when the core knows a driver is using one of them?
No. It will just show the used modules, as they're dynamically loaded.
For example, with my 3 test device driver loaded, it shows:
rc_rc5_hauppauge_new 1100 0
rc_pixelview_mk12 953 0
rc_avermedia_m135a_rm_jx 1016 0
>
> 5. Each module is going to consume a page of vmalloc address space and
> ram, and an addtional page of vmalloc address as a gap behind it. These
> maps are rather small in comparison. Is it really worth all the page
> table entries to load all these as individual modules? Memory is cheap,
> and small allocations can fill in fragmentation gaps in the vmalloc
> address space, but page table entries are spent on better things.
My plan is to merge several keymaps. I'm currently trying to obtain some
RC's to write the correct keymaps and try to merge them.
> I guess I'm not aware of what the return is here for the costs.
--
Cheers,
Mauro
^ permalink raw reply [flat|nested] 29+ messages in thread
* Re: [PATCH 08/26] V4L/DVB: Break Remote Controller keymaps into modules
2010-04-10 16:06 ` Mauro Carvalho Chehab
@ 2010-04-10 17:26 ` Andy Walls
0 siblings, 0 replies; 29+ messages in thread
From: Andy Walls @ 2010-04-10 17:26 UTC (permalink / raw)
To: Mauro Carvalho Chehab; +Cc: linux-media
On Sat, 2010-04-10 at 13:06 -0300, Mauro Carvalho Chehab wrote:
> Andy Walls wrote:
> > On Tue, 2010-04-06 at 15:18 -0300, Mauro Carvalho Chehab wrote:
> >> The original Remote Controller approach were very messy: a big file,
> >> that were part of ir-common kernel module, containing 64 different
> >> RC keymap tables, used by the V4L/DVB drivers.
> >>
> >> Better to break each RC keymap table into a separate module,
> >> registering them into rc core on a process similar to the fs/nls tables.
> >>
> >> As an userspace program is now in charge of loading those tables,
> >> adds an option to allow the complete removal of those tables from
> >> kernelspace.
> >>
> >> Yet, on embedded devices like Set Top Boxes and TV sets, maybe the
> >> only available input device is the IR. So, we should keep allowing
> >> the usage of in-kernel tables, but a latter patch should change
> >> the default to 'n', after giving some time for distros to add
> >> the v4l-utils with the ir-keytable program, to allow the table
> >> load via userspace.
> >
> > I know I'm probably late on commenting on this.
> >
> > Although this is interesting, it seems like overkill.
> >
> >
> > 1. How will this help move us to the "just works" case, if now userspace
> > has to help the kernel. Every distro is likely just going to bundle a
> > script which loads them all into the kernel and forgets about them.
>
> No. They will either use userspace or kernelspace keymaps. For in-kernel
> keymaps, there's nothing needed on userspace.
>
> > 2. How is a driver, which knows the bundled remote, supposed to convey
> > to userspace "load this map by default for my IR receiver"? Is that
> > covered in another portion of the patch?
>
> It is on a separate patch. Basically, by the name. The table name is stored
> on each IR map entry on kernel. If the table is in kernel, the table will
> be dynamically loaded, when needed.
>
> Userspace can always replace it by another one.
>
> For example, this is my current test setup:
>
> $ ./ir-keytable
> Found /sys/class/rc/rc0/ (/dev/input/event8) with:
> Driver "saa7134", raw software decoder, table "rc-avermedia-m135a-rm-jx"
> Supported protocols: NEC RC-5 RC-6
> Found /sys/class/rc/rc1/ (/dev/input/event9) with:
> Driver "cx88xx", hardware decoder, table "rc-pixelview-mk12"
> Supported protocols: other
> Current protocols: NEC
> Found /sys/class/rc/rc2/ (/dev/input/event10) with:
> Driver "em28xx", hardware decoder, table "rc-rc5-hauppauge-new"
> Supported protocols: NEC RC-5
> Current protocols: RC-5
>
> When ready, ir-keytable udev option will get driver and table info and
> seek on some files for the proper keymap, if the user wants to replace it
> by a customized one, or if the kernel keymap is disabled.
>
> >
> > 3. If you're going to be so remote specific, why not add protocol
> > information in these regarding the remotes? You can tell the core
> > everything to expect from this remote: raw vs. hardware decoder and the
> > RC-5/NEC/RC-6/JVC/whatever raw protocol decoder to use. That gets us
> > closer to "just works" and avoids false input events from two of the raw
> > deoders both thinking they got a valid code.
>
> The table contains the info.
> > 4. /sbin/lsmod is now going to give a very long listing with lots of
> > noise. When these things are registered with the core, is the module's
> > use count incremented when the core knows a driver is using one of them?
>
> No. It will just show the used modules, as they're dynamically loaded.
> For example, with my 3 test device driver loaded, it shows:
>
> rc_rc5_hauppauge_new 1100 0
> rc_pixelview_mk12 953 0
> rc_avermedia_m135a_rm_jx 1016 0
>
Ah OK. Thanks for all your replies. Shame on me for not reading all
the patch series. I'll try to do my homework better next time.
Regards,
Andy
> > 5. Each module is going to consume a page of vmalloc address space and
> > ram, and an addtional page of vmalloc address as a gap behind it. These
> > maps are rather small in comparison. Is it really worth all the page
> > table entries to load all these as individual modules? Memory is cheap,
> > and small allocations can fill in fragmentation gaps in the vmalloc
> > address space, but page table entries are spent on better things.
>
> My plan is to merge several keymaps. I'm currently trying to obtain some
> RC's to write the correct keymaps and try to merge them.
>
> > I guess I'm not aware of what the return is here for the costs.
^ permalink raw reply [flat|nested] 29+ messages in thread
end of thread, other threads:[~2010-04-10 17:26 UTC | newest]
Thread overview: 29+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <cover.1270577768.git.mchehab@redhat.com>
2010-04-06 18:18 ` [PATCH 22/26] V4L-DVB: ir-core: remove the ancillary buffer Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 24/26] V4L/DVB: ir-core: Add support for badly-implemented hardware decoders Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 23/26] V4L/DVB: ir-core: move rc map code to rc-map.h Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 26/26] V4L/DVB: ir-rc5-decoder: fix state machine Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 25/26] V4L/DVB: re-add enable/disable check to the IR decoders Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 21/26] V4L/DVB: cx88: don't handle IR on Pixelview too fast Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 13/26] V4L/DVB: saa7134: Add support for both positive and negative edge IRQ Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 20/26] V4L-DVB: ir-rc5-decoder: Add a decoder for RC-5 IR protocol Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 19/26] ir-nec-decoder: Cleanups Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 18/26] V4L/DVB: ir-nec-decoder: Reimplement the entire decoder Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 15/26] V4L/DVB: ir-core: re-add some debug functions for keytable changes Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 17/26] V4L/DVB: Convert drivers/media/dvb/ttpci/budget-ci.c to use ir-core Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 14/26] V4L/DVB: drivers/media/IR - improve keytable code Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 10/26] V4L/DVB: ir-core: Make use of the new IR keymap modules Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 11/26] V4L/DVB: ir-common: remove keymap tables from the module Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 12/26] V4L/DVB: saa7134: Fix IRQ2 bit names for the register map Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 08/26] V4L/DVB: Break Remote Controller keymaps into modules Mauro Carvalho Chehab
2010-04-10 12:27 ` Andy Walls
2010-04-10 16:06 ` Mauro Carvalho Chehab
2010-04-10 17:26 ` Andy Walls
2010-04-06 18:18 ` [PATCH 07/26] V4L/DVB: ir-core: Add support for RC map code register Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 05/26] V4L/DVB: ir-common: Use macros to define the keytables Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 09/26] V4L/DVB: ir: prepare IR code for a parameter change at register function Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 04/26] V4L/DVB: rename all *_rc_keys to ir_codes_*_nec_table Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 06/26] V4L/DVB: ir-common: move IR tables from ir-keymaps.c to a separate file Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 01/26] V4L/DVB: ir-common: Use a function to declare an IR table Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 03/26] V4L/DVB: IR: use IR_KEYTABLE where an IR table is needed Mauro Carvalho Chehab
2010-04-06 18:18 ` [PATCH 02/26] V4L/DVB: ir-common: re-order keytables by name and remove duplicates Mauro Carvalho Chehab
2010-04-06 19:13 ` [PATCH 16/26] V4L/DVB: ir-core: improve keyup/keydown logic Mauro Carvalho Chehab
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox