Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dt-bindings: net: Add rfkill-gpio binding

Add a device tree binding document for GPIO controlled rfkill switches.
The label and radio-type properties correspond to the name and type
properties used for ACPI, respectively. The shutdown-gpios property
is the same as defined for ACPI.

Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Reviewed-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20230102-rfkill-gpio-dt-v2-1-d1b83758c16d@pengutronix.de
Signed-off-by: Johannes Berg <johannes.berg@intel.com>

authored by

Philipp Zabel and committed by
Johannes Berg
50071fdf 71a659bf

+51
+51
Documentation/devicetree/bindings/net/rfkill-gpio.yaml
··· 1 + # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2 + %YAML 1.2 3 + --- 4 + $id: http://devicetree.org/schemas/net/rfkill-gpio.yaml# 5 + $schema: http://devicetree.org/meta-schemas/core.yaml# 6 + 7 + title: GPIO controlled rfkill switch 8 + 9 + maintainers: 10 + - Johannes Berg <johannes@sipsolutions.net> 11 + - Philipp Zabel <p.zabel@pengutronix.de> 12 + 13 + properties: 14 + compatible: 15 + const: rfkill-gpio 16 + 17 + label: 18 + description: rfkill switch name, defaults to node name 19 + 20 + radio-type: 21 + description: rfkill radio type 22 + enum: 23 + - bluetooth 24 + - fm 25 + - gps 26 + - nfc 27 + - ultrawideband 28 + - wimax 29 + - wlan 30 + - wwan 31 + 32 + shutdown-gpios: 33 + maxItems: 1 34 + 35 + required: 36 + - compatible 37 + - radio-type 38 + - shutdown-gpios 39 + 40 + additionalProperties: false 41 + 42 + examples: 43 + - | 44 + #include <dt-bindings/gpio/gpio.h> 45 + 46 + rfkill { 47 + compatible = "rfkill-gpio"; 48 + label = "rfkill-pcie-wlan"; 49 + radio-type = "wlan"; 50 + shutdown-gpios = <&gpio2 25 GPIO_ACTIVE_HIGH>; 51 + };