[PATCH 13/15] MIPS: black-swift: enable GPIO key
Antony Pavlov
antonynpavlov at gmail.com
Mon Mar 7 05:30:24 PST 2016
Signed-off-by: Antony Pavlov <antonynpavlov at gmail.com>
---
arch/mips/dts/black-swift.dts | 11 +++++++++++
arch/mips/mach-ath79/Kconfig | 1 +
2 files changed, 12 insertions(+)
diff --git a/arch/mips/dts/black-swift.dts b/arch/mips/dts/black-swift.dts
index b0fa3b0..d19c381 100644
--- a/arch/mips/dts/black-swift.dts
+++ b/arch/mips/dts/black-swift.dts
@@ -2,6 +2,7 @@
#include "ar9331.dtsi"
#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
/ {
model = "Black Swift";
@@ -15,6 +16,16 @@
spiflash = &spiflash;
};
+ buttons {
+ compatible = "gpio-keys";
+
+ s1 {
+ label = "S1";
+ gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+ };
+
leds {
compatible = "gpio-leds";
diff --git a/arch/mips/mach-ath79/Kconfig b/arch/mips/mach-ath79/Kconfig
index 9b8e394..374d722 100644
--- a/arch/mips/mach-ath79/Kconfig
+++ b/arch/mips/mach-ath79/Kconfig
@@ -18,6 +18,7 @@ config BOARD_BLACK_SWIFT
select HAVE_PBL_IMAGE
select HAVE_IMAGE_COMPRESSION
select HAS_NMON
+ select INPUT
endchoice
--
2.7.0
More information about the barebox
mailing list