Support the user LED available on the latest revision of the PCB. Also rebase the patchset ontop of the Raspberry Pi kernel 1.20210928.
72 lines
1.9 KiB
Diff
72 lines
1.9 KiB
Diff
From 7e2f95935408ec5b1d7a2b63daaef7fdb01d642c Mon Sep 17 00:00:00 2001
|
|
Message-Id: <7e2f95935408ec5b1d7a2b63daaef7fdb01d642c.1635895105.git.stefan@agner.ch>
|
|
In-Reply-To: <fa42d0ece205b3c2a8a06dac3e4436400cf59978.1635895105.git.stefan@agner.ch>
|
|
References: <fa42d0ece205b3c2a8a06dac3e4436400cf59978.1635895105.git.stefan@agner.ch>
|
|
From: Stefan Agner <stefan@agner.ch>
|
|
Date: Tue, 9 Mar 2021 15:02:53 +0100
|
|
Subject: [PATCH 6/7] ARM: dts: bcm2711: amber: enable GPIO keys
|
|
|
|
Signed-off-by: Stefan Agner <stefan@agner.ch>
|
|
---
|
|
.../arm/boot/dts/bcm2711-rpi-cm4-ha-amber.dts | 30 +++++++++++++++++++
|
|
1 file changed, 30 insertions(+)
|
|
|
|
diff --git a/arch/arm/boot/dts/bcm2711-rpi-cm4-ha-amber.dts b/arch/arm/boot/dts/bcm2711-rpi-cm4-ha-amber.dts
|
|
index 637ce01618d8..a2cbb8510491 100644
|
|
--- a/arch/arm/boot/dts/bcm2711-rpi-cm4-ha-amber.dts
|
|
+++ b/arch/arm/boot/dts/bcm2711-rpi-cm4-ha-amber.dts
|
|
@@ -2,6 +2,7 @@
|
|
/dts-v1/;
|
|
#include "bcm2711.dtsi"
|
|
#include "bcm2835-rpi.dtsi"
|
|
+#include <dt-bindings/input/input.h>
|
|
|
|
#include <dt-bindings/reset/raspberrypi,firmware-reset.h>
|
|
|
|
@@ -29,6 +30,29 @@ aliases {
|
|
blconfig = &blconfig;
|
|
};
|
|
|
|
+ keys: gpio-keys {
|
|
+ compatible = "gpio-keys";
|
|
+
|
|
+ pinctrl-names = "default";
|
|
+ pinctrl-0 = <&gpio_button_pins>;
|
|
+
|
|
+ status = "okay";
|
|
+
|
|
+ power {
|
|
+ label = "Power Button";
|
|
+ linux,code = <KEY_POWER>;
|
|
+ gpios = <&gpio 26 GPIO_ACTIVE_LOW>;
|
|
+ debounce-interval = <100>; // ms
|
|
+ };
|
|
+
|
|
+ user {
|
|
+ label = "User Button";
|
|
+ linux,code = <KEY_MACRO>;
|
|
+ gpios = <&gpio 27 GPIO_ACTIVE_LOW>;
|
|
+ debounce-interval = <100>; // ms
|
|
+ };
|
|
+ };
|
|
+
|
|
leds {
|
|
led-act {
|
|
gpios = <&gpio 42 GPIO_ACTIVE_HIGH>;
|
|
@@ -438,6 +462,12 @@ spidev1: spidev@1{
|
|
};
|
|
|
|
&gpio {
|
|
+ gpio_button_pins: gpio_button_pins {
|
|
+ brcm,pins = <26 27>;
|
|
+ brcm,function = <BCM2835_FSEL_GPIO_IN>;
|
|
+ brcm,pull = <BCM2835_PUD_UP>;
|
|
+ };
|
|
+
|
|
spi0_pins: spi0_pins {
|
|
brcm,pins = <9 10 11>;
|
|
brcm,function = <BCM2835_FSEL_ALT0>;
|
|
--
|
|
2.33.1
|
|
|