Commit 8cb53a8d authored by Chen Jun's avatar Chen Jun Committed by Wei Xu

arm64: dts: hi3660: add power key dts node

We use gpio_034 as power key on hikey960, and set gpio with pull-up
state, when key press the voltage on the gpio will come to lower, and
power key event will be reported.
Signed-off-by: default avatarChen Jun <chenjun14@huawei.com>
Signed-off-by: default avatarJohn Stultz <john.stultz@linaro.org>
Signed-off-by: default avatarGuodong Xu <guodong.xu@linaro.org>
Signed-off-by: default avatarWei Xu <xuwei5@hisilicon.com>
parent 0a0698f6
......@@ -10,6 +10,8 @@
#include "hi3660.dtsi"
#include "hikey960-pinctrl.dtsi"
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
#include <dt-bindings/interrupt-controller/irq.h>
/ {
model = "HiKey960";
......@@ -34,6 +36,19 @@ memory@0 {
/* rewrite this at bootloader */
reg = <0x0 0x0 0x0 0x0>;
};
keys {
compatible = "gpio-keys";
pinctrl-names = "default";
pinctrl-0 = <&pwr_key_pmx_func &pwr_key_cfg_func>;
power {
wakeup-source;
gpios = <&gpio4 2 GPIO_ACTIVE_LOW>;
label = "GPIO Power";
linux,code = <KEY_POWER>;
};
};
};
&i2c0 {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment