mirror of
https://github.com/FUjr/gl-infra-builder.git
synced 2025-12-16 09:10:02 +00:00
siflower: fix switch button hotplug
This commit is contained in:
parent
15185686e0
commit
fc2f2fd28c
@ -1,21 +1,21 @@
|
||||
From 0ce1fdf1cb217327aace4bcc090a81248ed19940 Mon Sep 17 00:00:00 2001
|
||||
From 09c603fb217deada0bf50b1e08d3bc88860645c1 Mon Sep 17 00:00:00 2001
|
||||
From: gl-dengxinfa <xinfa.deng@gl-inet.com>
|
||||
Date: Mon, 14 Nov 2022 15:31:45 +0800
|
||||
Date: Mon, 14 Nov 2022 19:48:28 +0800
|
||||
Subject: [PATCH] fix: switch button execute etc rc.button switch
|
||||
|
||||
---
|
||||
.../package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c | 1 +
|
||||
openwrt-18.06/package/kernel/button-hotplug/src/button-hotplug.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/openwrt-18.06/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c b/openwrt-18.06/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c
|
||||
index 1aef23e87..52c280755 100644
|
||||
--- a/openwrt-18.06/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c
|
||||
+++ b/openwrt-18.06/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c
|
||||
@@ -106,6 +106,7 @@ static struct bh_map button_map[] = {
|
||||
BH_MAP(KEY_WIMAX, "wwan"),
|
||||
BH_MAP(KEY_WLAN, "wlan"),
|
||||
BH_MAP(KEY_WPS_BUTTON, "wps"),
|
||||
+ BH_MAP(KEY_SETUP, "switch"),
|
||||
diff --git a/openwrt-18.06/package/kernel/button-hotplug/src/button-hotplug.c b/openwrt-18.06/package/kernel/button-hotplug/src/button-hotplug.c
|
||||
index 5294a9700..e038702cc 100644
|
||||
--- a/openwrt-18.06/package/kernel/button-hotplug/src/button-hotplug.c
|
||||
+++ b/openwrt-18.06/package/kernel/button-hotplug/src/button-hotplug.c
|
||||
@@ -88,6 +88,7 @@ static struct bh_map button_map[] = {
|
||||
BH_MAP(KEY_RFKILL, "rfkill"),
|
||||
BH_MAP(KEY_WPS_BUTTON, "wps"),
|
||||
BH_MAP(KEY_WIMAX, "wwan"),
|
||||
+ BH_MAP(KEY_SETUP, "switch"),
|
||||
};
|
||||
|
||||
/* -------------------------------------------------------------------------*/
|
||||
|
||||
@ -61,7 +61,7 @@ index 0eaa1ce37..9608336c4 100644
|
||||
- label = "BTN_0";
|
||||
- linux,code = <0x100>; //BTN_0
|
||||
+ label = "switch";
|
||||
+ linux,code = <KEY_SETUP>;
|
||||
+ linux,code = <141>;
|
||||
gpios = <&gpio 1 1>;
|
||||
poll-interval = <10>;
|
||||
debounce-interval = <20>;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user