cachepc-linux

Fork of AMDESE/linux with modifications for CachePC side-channel attack
git clone https://git.sinitax.com/sinitax/cachepc-linux
Log | Files | Refs | README | LICENSE | sfeed.txt

rc-pine64.c (1380B)


      1// SPDX-License-Identifier: GPL-2.0+
      2
      3// Keytable for the Pine64 IR Remote Controller
      4// Copyright (c) 2017 Jonas Karlman
      5
      6#include <media/rc-map.h>
      7#include <linux/module.h>
      8
      9static struct rc_map_table pine64[] = {
     10	{ 0x40404d, KEY_POWER },
     11	{ 0x40401f, KEY_WWW },
     12	{ 0x40400a, KEY_MUTE },
     13
     14	{ 0x404017, KEY_VOLUMEDOWN },
     15	{ 0x404018, KEY_VOLUMEUP },
     16
     17	{ 0x404010, KEY_LEFT },
     18	{ 0x404011, KEY_RIGHT },
     19	{ 0x40400b, KEY_UP },
     20	{ 0x40400e, KEY_DOWN },
     21	{ 0x40400d, KEY_OK },
     22
     23	{ 0x40401d, KEY_MENU },
     24	{ 0x40401a, KEY_HOME },
     25
     26	{ 0x404045, KEY_BACK },
     27
     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
     40};
     41
     42static 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,
     48	}
     49};
     50
     51static int __init init_rc_map_pine64(void)
     52{
     53	return rc_map_register(&pine64_map);
     54}
     55
     56static void __exit exit_rc_map_pine64(void)
     57{
     58	rc_map_unregister(&pine64_map);
     59}
     60
     61module_init(init_rc_map_pine64)
     62module_exit(exit_rc_map_pine64)
     63
     64MODULE_LICENSE("GPL");
     65MODULE_AUTHOR("Jonas Karlman");