WIP FPC-III support
[linux/fpc-iii.git] / drivers / media / rc / keymaps / rc-pine64.c
blob9b2bdbbce04e9a4d94ed21a3099d654b4645a61e
1 // SPDX-License-Identifier: GPL-2.0+
3 // Keytable for the Pine64 IR Remote Controller
4 // Copyright (c) 2017 Jonas Karlman
6 #include <media/rc-map.h>
7 #include <linux/module.h>
9 static struct rc_map_table pine64[] = {
10 { 0x40404d, KEY_POWER },
11 { 0x40401f, KEY_WWW },
12 { 0x40400a, KEY_MUTE },
14 { 0x404017, KEY_VOLUMEDOWN },
15 { 0x404018, KEY_VOLUMEUP },
17 { 0x404010, KEY_LEFT },
18 { 0x404011, KEY_RIGHT },
19 { 0x40400b, KEY_UP },
20 { 0x40400e, KEY_DOWN },
21 { 0x40400d, KEY_OK },
23 { 0x40401d, KEY_MENU },
24 { 0x40401a, KEY_HOME },
26 { 0x404045, KEY_BACK },
28 { 0x404001, KEY_NUMERIC_1 },
29 { 0x404002, KEY_NUMERIC_2 },
30 { 0x404003, KEY_NUMERIC_3 },
31 { 0x404004, KEY_NUMERIC_4 },
32 { 0x404005, KEY_NUMERIC_5 },
33 { 0x404006, KEY_NUMERIC_6 },
34 { 0x404007, KEY_NUMERIC_7 },
35 { 0x404008, KEY_NUMERIC_8 },
36 { 0x404009, KEY_NUMERIC_9 },
37 { 0x40400c, KEY_BACKSPACE },
38 { 0x404000, KEY_NUMERIC_0 },
39 { 0x404047, KEY_EPG }, // mouse
42 static struct rc_map_list pine64_map = {
43 .map = {
44 .scan = pine64,
45 .size = ARRAY_SIZE(pine64),
46 .rc_proto = RC_PROTO_NECX,
47 .name = RC_MAP_PINE64,
51 static int __init init_rc_map_pine64(void)
53 return rc_map_register(&pine64_map);
56 static void __exit exit_rc_map_pine64(void)
58 rc_map_unregister(&pine64_map);
61 module_init(init_rc_map_pine64)
62 module_exit(exit_rc_map_pine64)
64 MODULE_LICENSE("GPL");
65 MODULE_AUTHOR("Jonas Karlman");