mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-28 21:26:49 +00:00
Merge pull request #5903 from jernejsk/aw-keys
Allwinner: small cleanup
This commit is contained in:
commit
75b30b2d2b
@ -0,0 +1,107 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Jernej Skrabec <jernej.skrabec@gmail.com>
|
||||
Date: Sat, 30 Jan 2021 18:12:26 +0100
|
||||
Subject: [PATCH] ARM: dts: sun8i: Adjust power key nodes
|
||||
|
||||
Several H3 and one H2+ board have power key nodes, which are slightly
|
||||
off. Some are missing wakeup-source property and some have BTN_0 code
|
||||
assigned instead of KEY_POWER.
|
||||
|
||||
Adjust them, so they can function as intended by designer.
|
||||
|
||||
Signed-off-by: Jernej Skrabec <jernej.skrabec@gmail.com>
|
||||
[BananaPi M2 Zero changes]
|
||||
Signed-off-by: Michael Klein <michael@fossekall.de>
|
||||
---
|
||||
arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts | 3 ++-
|
||||
arch/arm/boot/dts/sun8i-h3-nanopi.dtsi | 1 +
|
||||
arch/arm/boot/dts/sun8i-h3-orangepi-2.dts | 3 ++-
|
||||
arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts | 3 ++-
|
||||
arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi | 3 ++-
|
||||
arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi | 1 +
|
||||
6 files changed, 10 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts b/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts
|
||||
index 8e8634ff2f9d..d5c7b7984d85 100644
|
||||
--- a/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts
|
||||
+++ b/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts
|
||||
@@ -52,8 +52,9 @@ gpio_keys {
|
||||
|
||||
sw4 {
|
||||
label = "power";
|
||||
- linux,code = <BTN_0>;
|
||||
+ linux,code = <KEY_POWER>;
|
||||
gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>;
|
||||
+ wakeup-source;
|
||||
};
|
||||
};
|
||||
|
||||
diff --git a/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi b/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
index c7c3e7d8b3c8..fc45d5aaa67f 100644
|
||||
--- a/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
+++ b/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
@@ -81,6 +81,7 @@ k1 {
|
||||
label = "k1";
|
||||
linux,code = <KEY_POWER>;
|
||||
gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>;
|
||||
+ wakeup-source;
|
||||
};
|
||||
};
|
||||
};
|
||||
diff --git a/arch/arm/boot/dts/sun8i-h3-orangepi-2.dts b/arch/arm/boot/dts/sun8i-h3-orangepi-2.dts
|
||||
index 597c425d08ec..9daffd90c12f 100644
|
||||
--- a/arch/arm/boot/dts/sun8i-h3-orangepi-2.dts
|
||||
+++ b/arch/arm/boot/dts/sun8i-h3-orangepi-2.dts
|
||||
@@ -99,8 +99,9 @@ sw2 {
|
||||
|
||||
sw4 {
|
||||
label = "sw4";
|
||||
- linux,code = <BTN_0>;
|
||||
+ linux,code = <KEY_POWER>;
|
||||
gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>;
|
||||
+ wakeup-source;
|
||||
};
|
||||
};
|
||||
|
||||
diff --git a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
|
||||
index 5aff8ecc66cb..90f75fa85e68 100644
|
||||
--- a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
|
||||
+++ b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
|
||||
@@ -91,8 +91,9 @@ r_gpio_keys {
|
||||
|
||||
sw4 {
|
||||
label = "sw4";
|
||||
- linux,code = <BTN_0>;
|
||||
+ linux,code = <KEY_POWER>;
|
||||
gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>;
|
||||
+ wakeup-source;
|
||||
};
|
||||
};
|
||||
};
|
||||
diff --git a/arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi b/arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi
|
||||
index 7a6af54dd342..d03f5853ef7b 100644
|
||||
--- a/arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi
|
||||
+++ b/arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi
|
||||
@@ -82,8 +82,9 @@ gpio_keys {
|
||||
|
||||
sw4 {
|
||||
label = "power";
|
||||
- linux,code = <BTN_0>;
|
||||
+ linux,code = <KEY_POWER>;
|
||||
gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>;
|
||||
+ wakeup-source;
|
||||
};
|
||||
};
|
||||
|
||||
diff --git a/arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi b/arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi
|
||||
index c44fd726945a..9e14fe5fdcde 100644
|
||||
--- a/arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi
|
||||
+++ b/arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi
|
||||
@@ -49,6 +49,7 @@ power {
|
||||
label = "power";
|
||||
linux,code = <KEY_POWER>;
|
||||
gpios = <&r_pio 0 2 GPIO_ACTIVE_LOW>; /* PL2 */
|
||||
+ wakeup-source;
|
||||
};
|
||||
};
|
||||
|
@ -1,72 +0,0 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Jernej Skrabec <jernej.skrabec@siol.net>
|
||||
Date: Sat, 30 Jan 2021 18:12:26 +0100
|
||||
Subject: [PATCH] h3/h5: power key wake up source
|
||||
|
||||
---
|
||||
arch/arm/boot/dts/sun8i-h3-nanopi.dtsi | 1 +
|
||||
arch/arm/boot/dts/sun8i-h3-orangepi-2.dts | 3 ++-
|
||||
arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts | 3 ++-
|
||||
arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi | 3 ++-
|
||||
arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi | 1 +
|
||||
6 files changed, 19 insertions(+), 3 deletions(-)
|
||||
|
||||
--- a/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
+++ b/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
@@ -81,6 +81,7 @@
|
||||
label = "k1";
|
||||
linux,code = <KEY_POWER>;
|
||||
gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>;
|
||||
+ wakeup-source;
|
||||
};
|
||||
};
|
||||
};
|
||||
--- a/arch/arm/boot/dts/sun8i-h3-orangepi-2.dts
|
||||
+++ b/arch/arm/boot/dts/sun8i-h3-orangepi-2.dts
|
||||
@@ -99,8 +99,9 @@
|
||||
|
||||
sw4 {
|
||||
label = "sw4";
|
||||
- linux,code = <BTN_0>;
|
||||
+ linux,code = <KEY_POWER>;
|
||||
gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>;
|
||||
+ wakeup-source;
|
||||
};
|
||||
};
|
||||
|
||||
--- a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
|
||||
+++ b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
|
||||
@@ -91,8 +91,9 @@
|
||||
|
||||
sw4 {
|
||||
label = "sw4";
|
||||
- linux,code = <BTN_0>;
|
||||
+ linux,code = <KEY_POWER>;
|
||||
gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>;
|
||||
+ wakeup-source;
|
||||
};
|
||||
};
|
||||
};
|
||||
--- a/arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi
|
||||
+++ b/arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi
|
||||
@@ -82,8 +82,9 @@
|
||||
|
||||
sw4 {
|
||||
label = "power";
|
||||
- linux,code = <BTN_0>;
|
||||
+ linux,code = <KEY_POWER>;
|
||||
gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>;
|
||||
+ wakeup-source;
|
||||
};
|
||||
};
|
||||
|
||||
--- a/arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi
|
||||
+++ b/arch/arm/boot/dts/sunxi-libretech-all-h3-cc.dtsi
|
||||
@@ -49,6 +49,7 @@
|
||||
label = "power";
|
||||
linux,code = <KEY_POWER>;
|
||||
gpios = <&r_pio 0 2 GPIO_ACTIVE_LOW>; /* PL2 */
|
||||
+ wakeup-source;
|
||||
};
|
||||
};
|
||||
|
@ -1,20 +0,0 @@
|
||||
commit 2bfc2341d47781d56d019b5bbdfc5a9c59422ed2
|
||||
Author: Michael Klein <michael@fossekall.de>
|
||||
Date: Sun Nov 8 18:59:52 2020 +0100
|
||||
|
||||
KEY_POWER
|
||||
|
||||
diff --git a/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts b/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts
|
||||
index ccf6e6c83fb1..158331f9c7e8 100644
|
||||
--- a/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts
|
||||
+++ b/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts
|
||||
@@ -56,7 +56,8 @@ gpio_keys {
|
||||
|
||||
sw4 {
|
||||
label = "power";
|
||||
- linux,code = <BTN_0>;
|
||||
+ linux,code = <KEY_POWER>;
|
||||
gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>;
|
||||
+ wakeup-source;
|
||||
};
|
||||
};
|
Loading…
x
Reference in New Issue
Block a user