Debian Codegraph @

Documentation/devicetree/bindings/extcon/linux,extcon-usb-gpio.yaml

raw
1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2 %YAML 1.2
3 ---
4 $id: http://devicetree.org/schemas/extcon/linux,extcon-usb-gpio.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
6
7 title: USB GPIO Extcon device
8
9 maintainers:
10 - Frank Li <[email protected]>
11
12 description:
13 This is a virtual device used to generate USB cable states from the USB ID pin
14 connected to a GPIO pin.
15
16 properties:
17 compatible:
18 const: linux,extcon-usb-gpio
19
20 id-gpios:
21 description: gpio for USB ID pin. See gpio binding.
22 vbus-gpios:
23 description: gpio for USB VBUS pin.
24
25 required:
26 - compatible
27
28 anyOf:
29 - required:
30 - id-gpios
31 - required:
32 - vbus-gpios
33
34 additionalProperties: false
35
36 examples:
37 - |
38 #include <dt-bindings/gpio/gpio.h>
39
40 extcon_usb1 {
41 compatible = "linux,extcon-usb-gpio";
42 id-gpios = <&gpio6 1 GPIO_ACTIVE_HIGH>;
43 };