From 30a7fa058e56763c746dd15aa4a810a709a5869d Mon Sep 17 00:00:00 2001 From: Prateek Patil Date: Fri, 21 Mar 2025 16:35:50 +0530 Subject: [PATCH] ARM: dts: msm: Add WLAN_EN GPIO Support through Linux pinctrl framework Add WLAN_EN GPIO definition to be supported through Linux pinctrl framework. Using Linux pinctrl framework API add support to control WLAN_EN GPIO: 1. Read WLAN_EN GPIO value 2. Change WLAN_EN GPIO value Change-Id: Ic205814b6b38d515b23879673afe76882ad0098b CRs-Fixed: 4093812 --- kera-wcn7750.dtsi | 33 ++++++++++++++++++++++++++++++++- tuna-wcn7750.dtsi | 33 ++++++++++++++++++++++++++++++++- 2 files changed, 64 insertions(+), 2 deletions(-) diff --git a/kera-wcn7750.dtsi b/kera-wcn7750.dtsi index c83a831f..7bde4c31 100644 --- a/kera-wcn7750.dtsi +++ b/kera-wcn7750.dtsi @@ -14,6 +14,34 @@ function = "wcn_sw_ctrl"; }; }; + + icnss_wlan_en_active: icnss_wlan_en_active { + mux { + pins = "gpio35"; + function = "gpio"; + }; + + config { + pins = "gpio35"; + drive-strength = <16>; + output-high; + bias-pull-up; + }; + }; + + icnss_wlan_en_sleep: icnss_wlan_en_sleep { + mux { + pins = "gpio35"; + function = "gpio"; + }; + + config { + pins = "gpio35"; + drive-strength = <2>; + output-low; + bias-pull-down; + }; + }; }; &soc { @@ -70,9 +98,12 @@ sw-ctrl-gpio = <81>; /* List of GPIOs to be setup for interrupt wakeup capable */ mpm_wake_set_gpios = <81>; + pin_wlan-en-gpio = <&tlmm 35 0>; pin_sw-ctrl-gpio = <&tlmm 81 0>; - pinctrl-names = "sw_ctrl"; + pinctrl-names = "sw_ctrl", "wlan_en_active", "wlan_en_sleep"; pinctrl-0 = <&icnss_sw_ctrl>; + pinctrl-1 = <&icnss_wlan_en_active>; + pinctrl-2 = <&icnss_wlan_en_sleep>; interrupts = , , diff --git a/tuna-wcn7750.dtsi b/tuna-wcn7750.dtsi index e4ffa766..b2f61c14 100644 --- a/tuna-wcn7750.dtsi +++ b/tuna-wcn7750.dtsi @@ -14,6 +14,34 @@ function = "wcn_sw_ctrl"; }; }; + + icnss_wlan_en_active: icnss_wlan_en_active { + mux { + pins = "gpio35"; + function = "gpio"; + }; + + config { + pins = "gpio35"; + drive-strength = <16>; + output-high; + bias-pull-up; + }; + }; + + icnss_wlan_en_sleep: icnss_wlan_en_sleep { + mux { + pins = "gpio35"; + function = "gpio"; + }; + + config { + pins = "gpio35"; + drive-strength = <2>; + output-low; + bias-pull-down; + }; + }; }; &soc { @@ -66,9 +94,12 @@ sw-ctrl-gpio =<80>; /* List of GPIOs to be setup for interrupt wakeup capable */ mpm_wake_set_gpios = <80>; + pin_wlan-en-gpio = <&tlmm 35 0>; pin_sw-ctrl-gpio = <&tlmm 80 0>; - pinctrl-names = "sw_ctrl"; + pinctrl-names = "sw_ctrl", "wlan_en_active", "wlan_en_sleep"; pinctrl-0 = <&icnss_sw_ctrl>; + pinctrl-1 = <&icnss_wlan_en_active>; + pinctrl-2 = <&icnss_wlan_en_sleep>; interrupts = , ,