aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSridharan S N <[email protected]>2023-06-16 14:02:37 +0530
committerBjorn Andersson <[email protected]>2023-08-13 19:48:36 -0700
commit0354e2d4d203bcffb61d671265f9f0bc52b244ff (patch)
treee3a10a4e228bb383ad0a2680efbf537e5f81f833
parent76a6dd7bfcbb91217e4429d73c14ee67b441137d (diff)
arm64: dts: qcom: ipq5332: enable GPIO based LEDs and Buttons
Add support for wlan-2g LED on GPIO 36 and wps buttons on GPIO 35. Signed-off-by: Sridharan S N <[email protected]> Reviewed-by: Konrad Dybcio <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Bjorn Andersson <[email protected]>
-rw-r--r--arch/arm64/boot/dts/qcom/ipq5332-rdp-common.dtsi42
1 files changed, 42 insertions, 0 deletions
diff --git a/arch/arm64/boot/dts/qcom/ipq5332-rdp-common.dtsi b/arch/arm64/boot/dts/qcom/ipq5332-rdp-common.dtsi
index f13dea7d67fe..4870cdb764d0 100644
--- a/arch/arm64/boot/dts/qcom/ipq5332-rdp-common.dtsi
+++ b/arch/arm64/boot/dts/qcom/ipq5332-rdp-common.dtsi
@@ -19,6 +19,31 @@
chosen {
stdout-path = "serial0";
};
+
+ gpio-keys {
+ compatible = "gpio-keys";
+ pinctrl-0 = <&gpio_keys_default>;
+ pinctrl-names = "default";
+
+ button-wps {
+ label = "wps";
+ linux,code = <KEY_WPS_BUTTON>;
+ gpios = <&tlmm 35 GPIO_ACTIVE_LOW>;
+ debounce-interval = <60>;
+ };
+ };
+
+ leds {
+ compatible = "gpio-leds";
+ pinctrl-0 = <&gpio_leds_default>;
+ pinctrl-names = "default";
+
+ led-0 {
+ gpios = <&tlmm 36 GPIO_ACTIVE_HIGH>;
+ linux,default-trigger = "phy0tx";
+ default-state = "off";
+ };
+ };
};
&blsp1_uart0 {
@@ -34,3 +59,20 @@
&xo_board {
clock-frequency = <24000000>;
};
+
+/* PINCTRL */
+&tlmm {
+ gpio_keys_default: gpio-keys-default-state {
+ pins = "gpio35";
+ function = "gpio";
+ drive-strength = <8>;
+ bias-pull-up;
+ };
+
+ gpio_leds_default: gpio-leds-default-state {
+ pins = "gpio36";
+ function = "gpio";
+ drive-strength = <8>;
+ bias-pull-down;
+ };
+};