diff options
author | Alan Luck <luckyhome2008@gmail.com> | 2023-02-25 22:17:37 -0800 |
---|---|---|
committer | Hauke Mehrtens <hauke@hauke-m.de> | 2023-03-05 17:24:46 +0100 |
commit | 4c1d7787d460cd0798eb01a42c6a8a7fc96e2999 (patch) | |
tree | ecab279e7b5d633b63921ef8861105473d171d23 /target/linux/ipq806x/files-5.15/arch | |
parent | 8298270b6003ba852d15dc35e3abe9ed46d6879f (diff) | |
download | upstream-4c1d7787d460cd0798eb01a42c6a8a7fc96e2999.tar.gz upstream-4c1d7787d460cd0798eb01a42c6a8a7fc96e2999.tar.bz2 upstream-4c1d7787d460cd0798eb01a42c6a8a7fc96e2999.zip |
ipq806x: Add buttons to OnHub
These are the factory reset button (external) and "developer mode"
button (hidden inside the case (ASUS) or under a screw in the base
(TP-Link)) found on the TP-Link and ASUS OnHub devices.
Signed-off-by: Alan Luck <luckyhome2008@gmail.com>
[Brian: add description; factor out for both ASUS and TP-Link; use
existing pinmux definitions; add keycode for dev button]
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Diffstat (limited to 'target/linux/ipq806x/files-5.15/arch')
-rw-r--r-- | target/linux/ipq806x/files-5.15/arch/arm/boot/dts/qcom-ipq8064-onhub.dtsi | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/target/linux/ipq806x/files-5.15/arch/arm/boot/dts/qcom-ipq8064-onhub.dtsi b/target/linux/ipq806x/files-5.15/arch/arm/boot/dts/qcom-ipq8064-onhub.dtsi index 25ba71da00..549c462026 100644 --- a/target/linux/ipq806x/files-5.15/arch/arm/boot/dts/qcom-ipq8064-onhub.dtsi +++ b/target/linux/ipq806x/files-5.15/arch/arm/boot/dts/qcom-ipq8064-onhub.dtsi @@ -5,6 +5,7 @@ #include "qcom-ipq8064-smb208.dtsi" #include <dt-bindings/gpio/gpio.h> +#include <dt-bindings/input/input.h> #include <dt-bindings/soc/qcom,tcsr.h> / { @@ -30,6 +31,28 @@ }; }; + keys { + compatible = "gpio-keys"; + pinctrl-0 = <&button_pins>; + pinctrl-names = "default"; + + reset { + label = "reset"; + gpios = <&qcom_pinmux 16 GPIO_ACTIVE_LOW>; + linux,code = <KEY_RESTART>; + debounce-interval = <60>; + wakeup-source; + }; + + dev { + label = "dev"; + gpios = <&qcom_pinmux 15 GPIO_ACTIVE_LOW>; + linux,code = <KEY_CONFIG>; + debounce-interval = <60>; + wakeup-source; + }; + }; + mdio: mdio { compatible = "virtual,mdio-gpio"; #address-cells = <1>; @@ -227,12 +250,17 @@ pins = "gpio17"; output-low; }; + }; + + button_pins: button_pins { recovery { pins = "gpio16"; + function = "gpio"; bias-none; }; developer { pins = "gpio15"; + function = "gpio"; bias-none; }; }; |