67 lines
1.9 KiB
Diff
67 lines
1.9 KiB
Diff
|
From d645bba65699ab3452fef8129b9daddcb53443cc Mon Sep 17 00:00:00 2001
|
||
|
From: =?UTF-8?q?Ond=C5=99ej=20Jirman?= <megi@xff.cz>
|
||
|
Date: Fri, 18 Aug 2017 13:56:06 +0200
|
||
|
Subject: [PATCH 273/464] Add support for my private Sapomat device
|
||
|
|
||
|
---
|
||
|
arch/arm/boot/dts/allwinner/Makefile | 1 +
|
||
|
.../sun8i-h3-orangepi-pc-sapomat.dts | 34 +++++++++++++++++++
|
||
|
2 files changed, 35 insertions(+)
|
||
|
create mode 100644 arch/arm/boot/dts/allwinner/sun8i-h3-orangepi-pc-sapomat.dts
|
||
|
|
||
|
diff --git a/arch/arm/boot/dts/allwinner/Makefile b/arch/arm/boot/dts/allwinner/Makefile
|
||
|
index 589a1ce1120a..f850ef8cc058 100644
|
||
|
--- a/arch/arm/boot/dts/allwinner/Makefile
|
||
|
+++ b/arch/arm/boot/dts/allwinner/Makefile
|
||
|
@@ -218,6 +218,7 @@ dtb-$(CONFIG_MACH_SUN8I) += \
|
||
|
sun8i-h3-orangepi-lite.dtb \
|
||
|
sun8i-h3-orangepi-one.dtb \
|
||
|
sun8i-h3-orangepi-pc.dtb \
|
||
|
+ sun8i-h3-orangepi-pc-sapomat.dtb \
|
||
|
sun8i-h3-orangepi-pc-plus.dtb \
|
||
|
sun8i-h3-orangepi-plus.dtb \
|
||
|
sun8i-h3-orangepi-plus2e.dtb \
|
||
|
diff --git a/arch/arm/boot/dts/allwinner/sun8i-h3-orangepi-pc-sapomat.dts b/arch/arm/boot/dts/allwinner/sun8i-h3-orangepi-pc-sapomat.dts
|
||
|
new file mode 100644
|
||
|
index 000000000000..55c82d5fb63f
|
||
|
--- /dev/null
|
||
|
+++ b/arch/arm/boot/dts/allwinner/sun8i-h3-orangepi-pc-sapomat.dts
|
||
|
@@ -0,0 +1,34 @@
|
||
|
+#include <dt-bindings/gpio/gpio.h>
|
||
|
+#include <dt-bindings/input/input.h>
|
||
|
+#include "sun8i-h3-orangepi-pc.dts"
|
||
|
+
|
||
|
+/ {
|
||
|
+ model = "Xunlong Orange Pi PC Sapomat";
|
||
|
+
|
||
|
+ sapomat_gpio_keys {
|
||
|
+ compatible = "gpio-keys-polled";
|
||
|
+ poll-interval = <50>;
|
||
|
+ pinctrl-names = "default";
|
||
|
+ pinctrl-0 = <&sapomat_btn_pins>;
|
||
|
+
|
||
|
+ red_btn {
|
||
|
+ label = "Red Button";
|
||
|
+ linux,code = <BTN_4>;
|
||
|
+ gpios = <&pio 2 4 GPIO_ACTIVE_LOW>; /* PC4 */
|
||
|
+ };
|
||
|
+
|
||
|
+ green_btn {
|
||
|
+ label = "Green Button";
|
||
|
+ linux,code = <BTN_5>;
|
||
|
+ gpios = <&pio 2 7 GPIO_ACTIVE_LOW>; /* PC7 */
|
||
|
+ };
|
||
|
+ };
|
||
|
+};
|
||
|
+
|
||
|
+&pio {
|
||
|
+ sapomat_btn_pins: btn_pins@0 {
|
||
|
+ pins = "PC4", "PC7";
|
||
|
+ function = "gpio_in";
|
||
|
+ bias-pull-up;
|
||
|
+ };
|
||
|
+};
|
||
|
--
|
||
|
2.34.1
|
||
|
|