linux 2.6.16.38 w/ vs2.0.3-rc1
[linux-2.6.git] / drivers / media / video / ir-kbd-i2c.c
index 7e66d83..58b0e69 100644 (file)
 #include <media/ir-common.h>
 #include <media/ir-kbd-i2c.h>
 
+/* Mark Phalan <phalanm@o2.ie> */
+static IR_KEYTAB_TYPE ir_codes_pv951[IR_KEYTAB_SIZE] = {
+       [  0 ] = KEY_KP0,
+       [  1 ] = KEY_KP1,
+       [  2 ] = KEY_KP2,
+       [  3 ] = KEY_KP3,
+       [  4 ] = KEY_KP4,
+       [  5 ] = KEY_KP5,
+       [  6 ] = KEY_KP6,
+       [  7 ] = KEY_KP7,
+       [  8 ] = KEY_KP8,
+       [  9 ] = KEY_KP9,
+
+       [ 18 ] = KEY_POWER,
+       [ 16 ] = KEY_MUTE,
+       [ 31 ] = KEY_VOLUMEDOWN,
+       [ 27 ] = KEY_VOLUMEUP,
+       [ 26 ] = KEY_CHANNELUP,
+       [ 30 ] = KEY_CHANNELDOWN,
+       [ 14 ] = KEY_PAGEUP,
+       [ 29 ] = KEY_PAGEDOWN,
+       [ 19 ] = KEY_SOUND,
+
+       [ 24 ] = KEY_KPPLUSMINUS,       /* CH +/- */
+       [ 22 ] = KEY_SUBTITLE,          /* CC */
+       [ 13 ] = KEY_TEXT,              /* TTX */
+       [ 11 ] = KEY_TV,                /* AIR/CBL */
+       [ 17 ] = KEY_PC,                /* PC/TV */
+       [ 23 ] = KEY_OK,                /* CH RTN */
+       [ 25 ] = KEY_MODE,              /* FUNC */
+       [ 12 ] = KEY_SEARCH,            /* AUTOSCAN */
+
+       /* Not sure what to do with these ones! */
+       [ 15 ] = KEY_SELECT,            /* SOURCE */
+       [ 10 ] = KEY_KPPLUS,            /* +100 */
+       [ 20 ] = KEY_KPEQUAL,           /* SYNC */
+       [ 28 ] = KEY_MEDIA,             /* PC/TV */
+};
+
 /* ----------------------------------------------------------------------- */
 /* insmod parameters                                                       */
 
 static int debug;
 module_param(debug, int, 0644);    /* debug level (0,1,2) */
 
-static int hauppauge = 0;
-module_param(hauppauge, int, 0644);    /* Choose Hauppauge remote */
-MODULE_PARM_DESC(hauppauge, "Specify Hauppauge remote: 0=black, 1=grey (defaults to 0)");
-
-
 #define DEVNAME "ir-kbd-i2c"
 #define dprintk(level, fmt, arg...)    if (debug >= level) \
        printk(KERN_DEBUG DEVNAME ": " fmt , ## arg)
@@ -302,11 +336,7 @@ static int ir_attach(struct i2c_adapter *adap, int addr,
                name        = "Hauppauge";
                ir->get_key = get_key_haup;
                ir_type     = IR_TYPE_RC5;
-               if (hauppauge == 1) {
-                       ir_codes    = ir_codes_hauppauge_new;
-               } else {
-                       ir_codes    = ir_codes_rc5_tv;
-               }
+               ir_codes    = ir_codes_rc5_tv;
                break;
        case 0x30:
                name        = "KNC One";
@@ -411,9 +441,6 @@ static int ir_probe(struct i2c_adapter *adap)
        case I2C_HW_B_BT848:
                probe = probe_bttv;
                break;
-       case I2C_HW_B_CX2341X:
-               probe = probe_bttv;
-               break;
        case I2C_HW_SAA7134:
                probe = probe_saa7134;
                break;