162306a36Sopenharmony_ci// SPDX-License-Identifier: GPL-2.0-or-later
262306a36Sopenharmony_ci/*
362306a36Sopenharmony_ci * LeadTek Y04G0051 remote controller keytable
462306a36Sopenharmony_ci *
562306a36Sopenharmony_ci * Copyright (C) 2010 Antti Palosaari <crope@iki.fi>
662306a36Sopenharmony_ci */
762306a36Sopenharmony_ci
862306a36Sopenharmony_ci#include <media/rc-map.h>
962306a36Sopenharmony_ci#include <linux/module.h>
1062306a36Sopenharmony_ci
1162306a36Sopenharmony_cistatic struct rc_map_table leadtek_y04g0051[] = {
1262306a36Sopenharmony_ci	{ 0x0300, KEY_POWER2 },
1362306a36Sopenharmony_ci	{ 0x0303, KEY_SCREEN },
1462306a36Sopenharmony_ci	{ 0x0304, KEY_RIGHT },
1562306a36Sopenharmony_ci	{ 0x0305, KEY_NUMERIC_1 },
1662306a36Sopenharmony_ci	{ 0x0306, KEY_NUMERIC_2 },
1762306a36Sopenharmony_ci	{ 0x0307, KEY_NUMERIC_3 },
1862306a36Sopenharmony_ci	{ 0x0308, KEY_LEFT },
1962306a36Sopenharmony_ci	{ 0x0309, KEY_NUMERIC_4 },
2062306a36Sopenharmony_ci	{ 0x030a, KEY_NUMERIC_5 },
2162306a36Sopenharmony_ci	{ 0x030b, KEY_NUMERIC_6 },
2262306a36Sopenharmony_ci	{ 0x030c, KEY_UP },
2362306a36Sopenharmony_ci	{ 0x030d, KEY_NUMERIC_7 },
2462306a36Sopenharmony_ci	{ 0x030e, KEY_NUMERIC_8 },
2562306a36Sopenharmony_ci	{ 0x030f, KEY_NUMERIC_9 },
2662306a36Sopenharmony_ci	{ 0x0310, KEY_DOWN },
2762306a36Sopenharmony_ci	{ 0x0311, KEY_AGAIN },
2862306a36Sopenharmony_ci	{ 0x0312, KEY_NUMERIC_0 },
2962306a36Sopenharmony_ci	{ 0x0313, KEY_OK },              /* 1st ok */
3062306a36Sopenharmony_ci	{ 0x0314, KEY_MUTE },
3162306a36Sopenharmony_ci	{ 0x0316, KEY_OK },              /* 2nd ok */
3262306a36Sopenharmony_ci	{ 0x031e, KEY_VIDEO },           /* 2nd video */
3362306a36Sopenharmony_ci	{ 0x031b, KEY_AUDIO },
3462306a36Sopenharmony_ci	{ 0x031f, KEY_TEXT },
3562306a36Sopenharmony_ci	{ 0x0340, KEY_SLEEP },
3662306a36Sopenharmony_ci	{ 0x0341, KEY_DOT },
3762306a36Sopenharmony_ci	{ 0x0342, KEY_REWIND },
3862306a36Sopenharmony_ci	{ 0x0343, KEY_PLAY },
3962306a36Sopenharmony_ci	{ 0x0344, KEY_FASTFORWARD },
4062306a36Sopenharmony_ci	{ 0x0345, KEY_TIME },
4162306a36Sopenharmony_ci	{ 0x0346, KEY_STOP },            /* 2nd stop */
4262306a36Sopenharmony_ci	{ 0x0347, KEY_RECORD },
4362306a36Sopenharmony_ci	{ 0x0348, KEY_CAMERA },
4462306a36Sopenharmony_ci	{ 0x0349, KEY_ESC },
4562306a36Sopenharmony_ci	{ 0x034a, KEY_NEW },
4662306a36Sopenharmony_ci	{ 0x034b, KEY_RED },
4762306a36Sopenharmony_ci	{ 0x034c, KEY_GREEN },
4862306a36Sopenharmony_ci	{ 0x034d, KEY_YELLOW },
4962306a36Sopenharmony_ci	{ 0x034e, KEY_BLUE },
5062306a36Sopenharmony_ci	{ 0x034f, KEY_MENU },
5162306a36Sopenharmony_ci	{ 0x0350, KEY_STOP },            /* 1st stop */
5262306a36Sopenharmony_ci	{ 0x0351, KEY_CHANNEL },
5362306a36Sopenharmony_ci	{ 0x0352, KEY_VIDEO },           /* 1st video */
5462306a36Sopenharmony_ci	{ 0x0353, KEY_EPG },
5562306a36Sopenharmony_ci	{ 0x0354, KEY_PREVIOUS },
5662306a36Sopenharmony_ci	{ 0x0355, KEY_NEXT },
5762306a36Sopenharmony_ci	{ 0x0356, KEY_TV },
5862306a36Sopenharmony_ci	{ 0x035a, KEY_VOLUMEDOWN },
5962306a36Sopenharmony_ci	{ 0x035b, KEY_CHANNELUP },
6062306a36Sopenharmony_ci	{ 0x035e, KEY_VOLUMEUP },
6162306a36Sopenharmony_ci	{ 0x035f, KEY_CHANNELDOWN },
6262306a36Sopenharmony_ci};
6362306a36Sopenharmony_ci
6462306a36Sopenharmony_cistatic struct rc_map_list leadtek_y04g0051_map = {
6562306a36Sopenharmony_ci	.map = {
6662306a36Sopenharmony_ci		.scan     = leadtek_y04g0051,
6762306a36Sopenharmony_ci		.size     = ARRAY_SIZE(leadtek_y04g0051),
6862306a36Sopenharmony_ci		.rc_proto = RC_PROTO_NEC,
6962306a36Sopenharmony_ci		.name     = RC_MAP_LEADTEK_Y04G0051,
7062306a36Sopenharmony_ci	}
7162306a36Sopenharmony_ci};
7262306a36Sopenharmony_ci
7362306a36Sopenharmony_cistatic int __init init_rc_map_leadtek_y04g0051(void)
7462306a36Sopenharmony_ci{
7562306a36Sopenharmony_ci	return rc_map_register(&leadtek_y04g0051_map);
7662306a36Sopenharmony_ci}
7762306a36Sopenharmony_ci
7862306a36Sopenharmony_cistatic void __exit exit_rc_map_leadtek_y04g0051(void)
7962306a36Sopenharmony_ci{
8062306a36Sopenharmony_ci	rc_map_unregister(&leadtek_y04g0051_map);
8162306a36Sopenharmony_ci}
8262306a36Sopenharmony_ci
8362306a36Sopenharmony_cimodule_init(init_rc_map_leadtek_y04g0051)
8462306a36Sopenharmony_cimodule_exit(exit_rc_map_leadtek_y04g0051)
8562306a36Sopenharmony_ci
8662306a36Sopenharmony_ciMODULE_LICENSE("GPL");
8762306a36Sopenharmony_ciMODULE_AUTHOR("Antti Palosaari <crope@iki.fi>");
88