Duy Truong | 790f06d | 2013-02-13 16:38:12 -0800 | [diff] [blame] | 1 | /* Copyright (c) 2012, The Linux Foundation. All rights reserved. |
Ravi Kumar V | 77ffaef | 2012-04-10 16:33:46 +0530 | [diff] [blame] | 2 | * |
| 3 | * This program is free software; you can redistribute it and/or modify |
| 4 | * it under the terms of the GNU General Public License version 2 and |
| 5 | * only version 2 as published by the Free Software Foundation. |
| 6 | * |
| 7 | * This program is distributed in the hope that it will be useful, |
| 8 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 9 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 10 | * GNU General Public License for more details. |
| 11 | */ |
| 12 | |
Steve Muckle | f132c6c | 2012-06-06 18:30:57 -0700 | [diff] [blame] | 13 | #include <linux/module.h> |
Ravi Kumar V | 77ffaef | 2012-04-10 16:33:46 +0530 | [diff] [blame] | 14 | #include <media/rc-map.h> |
| 15 | |
| 16 | static struct rc_map_table philips[] = { |
| 17 | |
| 18 | { 0x00, KEY_NUMERIC_0 }, |
| 19 | { 0x01, KEY_NUMERIC_1 }, |
| 20 | { 0x02, KEY_NUMERIC_2 }, |
| 21 | { 0x03, KEY_NUMERIC_3 }, |
| 22 | { 0x04, KEY_NUMERIC_4 }, |
| 23 | { 0x05, KEY_NUMERIC_5 }, |
| 24 | { 0x06, KEY_NUMERIC_6 }, |
| 25 | { 0x07, KEY_NUMERIC_7 }, |
| 26 | { 0x08, KEY_NUMERIC_8 }, |
| 27 | { 0x09, KEY_NUMERIC_9 }, |
| 28 | { 0xF4, KEY_SOUND }, |
| 29 | { 0xF3, KEY_SCREEN }, /* Picture */ |
| 30 | |
| 31 | { 0x10, KEY_VOLUMEUP }, |
| 32 | { 0x11, KEY_VOLUMEDOWN }, |
| 33 | { 0x0d, KEY_MUTE }, |
| 34 | { 0x20, KEY_CHANNELUP }, |
| 35 | { 0x21, KEY_CHANNELDOWN }, |
| 36 | { 0x0A, KEY_BACK }, |
| 37 | { 0x0f, KEY_INFO }, |
| 38 | { 0x5c, KEY_OK }, |
| 39 | { 0x58, KEY_UP }, |
| 40 | { 0x59, KEY_DOWN }, |
| 41 | { 0x5a, KEY_LEFT }, |
| 42 | { 0x5b, KEY_RIGHT }, |
| 43 | { 0xcc, KEY_PAUSE }, |
| 44 | { 0x6d, KEY_PVR }, /* Demo */ |
| 45 | { 0x40, KEY_EXIT }, |
| 46 | { 0x6e, KEY_PROG1 }, /* Scenea */ |
| 47 | { 0x6f, KEY_MODE }, /* Dual */ |
| 48 | { 0x70, KEY_SLEEP }, |
| 49 | { 0xf5, KEY_TUNER }, /* Format */ |
| 50 | |
| 51 | { 0x4f, KEY_TV }, |
| 52 | { 0x3c, KEY_NEW }, /* USB */ |
| 53 | { 0x38, KEY_COMPOSE }, /* Source */ |
| 54 | { 0x54, KEY_MENU }, |
| 55 | |
| 56 | { 0x0C, KEY_POWER }, |
| 57 | }; |
| 58 | |
| 59 | static struct rc_map_list rc6_philips_map = { |
| 60 | .map = { |
| 61 | .scan = philips, |
| 62 | .size = ARRAY_SIZE(philips), |
| 63 | .rc_type = RC_TYPE_RC6, |
| 64 | .name = RC_MAP_RC6_PHILIPS, |
| 65 | } |
| 66 | }; |
| 67 | |
| 68 | static int __init init_rc_map_rc6_philips(void) |
| 69 | { |
| 70 | return rc_map_register(&rc6_philips_map); |
| 71 | } |
| 72 | |
| 73 | static void __exit exit_rc_map_rc6_philips(void) |
| 74 | { |
| 75 | rc_map_unregister(&rc6_philips_map); |
| 76 | } |
| 77 | |
| 78 | module_init(init_rc_map_rc6_philips) |
| 79 | module_exit(exit_rc_map_rc6_philips) |
| 80 | |
| 81 | MODULE_DESCRIPTION("Philips Remote Keymap "); |
| 82 | MODULE_LICENSE("GPL v2"); |