[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20250208102009.514525-2-amadeus@jmu.edu.cn>
Date: Sat, 8 Feb 2025 18:20:09 +0800
From: Chukun Pan <amadeus@....edu.cn>
To: Krzysztof Kozlowski <krzk+dt@...nel.org>
Cc: Conor Dooley <conor+dt@...nel.org>,
Johannes Berg <johannes@...solutions.net>,
Philipp Zabel <p.zabel@...gutronix.de>,
Rob Herring <robh@...nel.org>,
linux-kernel@...r.kernel.org,
devicetree@...r.kernel.org,
Chukun Pan <amadeus@....edu.cn>,
Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
Subject: [PATCH v3 1/1] dt-bindings: net: rfkill-gpio: document reset-gpios
Some 5G WWAN modems have multiple gpio controls. When using rfkill command
to manage it, we need to at least change the status of reset and shutdown
gpios at the same time. Also, it might be incorrect to put the reset gpio
at usb when the module is connected via USB M2 slot, there may be other
devices connected under some USB node, but the reset gpio is only used for
the WWAN module. So document the reset-gpios to rfkill-gpio as an optional
property and add it to a new example.
For example:
- reset: modem Reset#
- shutdown: modem WWAN_DISABLE# or FULL_CARD_POWER_OFF#
rfkill unblock wwan:
[ 109.582080] usb 2-1: new SuperSpeed USB device number 2 using xhci-mtk
rfkill block wwan:
[ 126.611963] usb 2-1: USB disconnect, device number 2
Signed-off-by: Chukun Pan <amadeus@....edu.cn>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
---
.../devicetree/bindings/net/rfkill-gpio.yaml | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/Documentation/devicetree/bindings/net/rfkill-gpio.yaml b/Documentation/devicetree/bindings/net/rfkill-gpio.yaml
index 9630c8466fac..7f297efdc976 100644
--- a/Documentation/devicetree/bindings/net/rfkill-gpio.yaml
+++ b/Documentation/devicetree/bindings/net/rfkill-gpio.yaml
@@ -29,6 +29,9 @@ properties:
- wlan
- wwan
+ reset-gpios:
+ maxItems: 1
+
shutdown-gpios:
maxItems: 1
@@ -49,3 +52,14 @@ examples:
radio-type = "wlan";
shutdown-gpios = <&gpio2 25 GPIO_ACTIVE_HIGH>;
};
+
+ - | # 5G WWAN modem
+ #include <dt-bindings/gpio/gpio.h>
+
+ rfkill {
+ compatible = "rfkill-gpio";
+ label = "rfkill-modem";
+ radio-type = "wwan";
+ reset-gpios = <&gpio0 5 GPIO_ACTIVE_HIGH>;
+ shutdown-gpios = <&gpio0 6 GPIO_ACTIVE_HIGH>;
+ };
--
2.25.1
Powered by blists - more mailing lists