xref: /freebsd/sys/contrib/device-tree/Bindings/phy/motorola,cpcap-usb-phy.yaml (revision 833e5d42ab135b0238e61c5b3c19b8619677cbfa)
1*833e5d42SEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2*833e5d42SEmmanuel Vadot%YAML 1.2
3*833e5d42SEmmanuel Vadot---
4*833e5d42SEmmanuel Vadot$id: http://devicetree.org/schemas/phy/motorola,cpcap-usb-phy.yaml#
5*833e5d42SEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6*833e5d42SEmmanuel Vadot
7*833e5d42SEmmanuel Vadottitle: Motorola CPCAP PMIC USB PHY
8*833e5d42SEmmanuel Vadot
9*833e5d42SEmmanuel Vadotmaintainers:
10*833e5d42SEmmanuel Vadot  - Tony Lindgren <tony@atomide.com>
11*833e5d42SEmmanuel Vadot
12*833e5d42SEmmanuel Vadotproperties:
13*833e5d42SEmmanuel Vadot  compatible:
14*833e5d42SEmmanuel Vadot    enum:
15*833e5d42SEmmanuel Vadot      - motorola,cpcap-usb-phy
16*833e5d42SEmmanuel Vadot      - motorola,mapphone-cpcap-usb-phy
17*833e5d42SEmmanuel Vadot
18*833e5d42SEmmanuel Vadot  '#phy-cells':
19*833e5d42SEmmanuel Vadot    const: 0
20*833e5d42SEmmanuel Vadot
21*833e5d42SEmmanuel Vadot  interrupts:
22*833e5d42SEmmanuel Vadot    description: CPCAP PMIC interrupts used by the USB PHY
23*833e5d42SEmmanuel Vadot    items:
24*833e5d42SEmmanuel Vadot      - description: id_ground interrupt
25*833e5d42SEmmanuel Vadot      - description: id_float interrupt
26*833e5d42SEmmanuel Vadot      - description: se0conn interrupt
27*833e5d42SEmmanuel Vadot      - description: vbusvld interrupt
28*833e5d42SEmmanuel Vadot      - description: sessvld interrupt
29*833e5d42SEmmanuel Vadot      - description: sessend interrupt
30*833e5d42SEmmanuel Vadot      - description: se1 interrupt
31*833e5d42SEmmanuel Vadot      - description: dm interrupt
32*833e5d42SEmmanuel Vadot      - description: dp interrupt
33*833e5d42SEmmanuel Vadot
34*833e5d42SEmmanuel Vadot  interrupt-names:
35*833e5d42SEmmanuel Vadot    description: Interrupt names
36*833e5d42SEmmanuel Vadot    items:
37*833e5d42SEmmanuel Vadot      - const: id_ground
38*833e5d42SEmmanuel Vadot      - const: id_float
39*833e5d42SEmmanuel Vadot      - const: se0conn
40*833e5d42SEmmanuel Vadot      - const: vbusvld
41*833e5d42SEmmanuel Vadot      - const: sessvld
42*833e5d42SEmmanuel Vadot      - const: sessend
43*833e5d42SEmmanuel Vadot      - const: se1
44*833e5d42SEmmanuel Vadot      - const: dm
45*833e5d42SEmmanuel Vadot      - const: dp
46*833e5d42SEmmanuel Vadot
47*833e5d42SEmmanuel Vadot  io-channels:
48*833e5d42SEmmanuel Vadot    description: IIO ADC channels used by the USB PHY
49*833e5d42SEmmanuel Vadot    items:
50*833e5d42SEmmanuel Vadot      - description: vbus channel
51*833e5d42SEmmanuel Vadot      - description: id channel
52*833e5d42SEmmanuel Vadot
53*833e5d42SEmmanuel Vadot  io-channel-names:
54*833e5d42SEmmanuel Vadot    items:
55*833e5d42SEmmanuel Vadot      - const: vbus
56*833e5d42SEmmanuel Vadot      - const: id
57*833e5d42SEmmanuel Vadot
58*833e5d42SEmmanuel Vadot  vusb-supply: true
59*833e5d42SEmmanuel Vadot
60*833e5d42SEmmanuel Vadot  pinctrl-names:
61*833e5d42SEmmanuel Vadot    items:
62*833e5d42SEmmanuel Vadot      - const: default
63*833e5d42SEmmanuel Vadot      - const: ulpi
64*833e5d42SEmmanuel Vadot      - const: utmi
65*833e5d42SEmmanuel Vadot      - const: uart
66*833e5d42SEmmanuel Vadot
67*833e5d42SEmmanuel Vadot  mode-gpios:
68*833e5d42SEmmanuel Vadot    description: Optional GPIOs for configuring alternate modes
69*833e5d42SEmmanuel Vadot    items:
70*833e5d42SEmmanuel Vadot      - description: "mode selection GPIO #0"
71*833e5d42SEmmanuel Vadot      - description: "mode selection GPIO #1"
72*833e5d42SEmmanuel Vadot
73*833e5d42SEmmanuel Vadotrequired:
74*833e5d42SEmmanuel Vadot  - compatible
75*833e5d42SEmmanuel Vadot  - '#phy-cells'
76*833e5d42SEmmanuel Vadot  - interrupts-extended
77*833e5d42SEmmanuel Vadot  - interrupt-names
78*833e5d42SEmmanuel Vadot  - io-channels
79*833e5d42SEmmanuel Vadot  - io-channel-names
80*833e5d42SEmmanuel Vadot  - vusb-supply
81*833e5d42SEmmanuel Vadot
82*833e5d42SEmmanuel VadotadditionalProperties: false
83*833e5d42SEmmanuel Vadot
84*833e5d42SEmmanuel Vadotexamples:
85*833e5d42SEmmanuel Vadot  - |
86*833e5d42SEmmanuel Vadot    #include <dt-bindings/gpio/gpio.h>
87*833e5d42SEmmanuel Vadot
88*833e5d42SEmmanuel Vadot    phy {
89*833e5d42SEmmanuel Vadot        compatible = "motorola,mapphone-cpcap-usb-phy";
90*833e5d42SEmmanuel Vadot        #phy-cells = <0>;
91*833e5d42SEmmanuel Vadot        interrupts-extended = <
92*833e5d42SEmmanuel Vadot            &cpcap 15 0 &cpcap 14 0 &cpcap 28 0 &cpcap 19 0
93*833e5d42SEmmanuel Vadot            &cpcap 18 0 &cpcap 17 0 &cpcap 16 0 &cpcap 49 0
94*833e5d42SEmmanuel Vadot            &cpcap 48 1
95*833e5d42SEmmanuel Vadot        >;
96*833e5d42SEmmanuel Vadot        interrupt-names = "id_ground", "id_float", "se0conn", "vbusvld",
97*833e5d42SEmmanuel Vadot                          "sessvld", "sessend", "se1", "dm", "dp";
98*833e5d42SEmmanuel Vadot        io-channels = <&cpcap_adc 2>, <&cpcap_adc 7>;
99*833e5d42SEmmanuel Vadot        io-channel-names = "vbus", "id";
100*833e5d42SEmmanuel Vadot        vusb-supply = <&vusb>;
101*833e5d42SEmmanuel Vadot        pinctrl-0 = <&usb_gpio_mux_sel1 &usb_gpio_mux_sel2>;
102*833e5d42SEmmanuel Vadot        pinctrl-1 = <&usb_ulpi_pins>;
103*833e5d42SEmmanuel Vadot        pinctrl-2 = <&usb_utmi_pins>;
104*833e5d42SEmmanuel Vadot        pinctrl-3 = <&uart3_pins>;
105*833e5d42SEmmanuel Vadot        pinctrl-names = "default", "ulpi", "utmi", "uart";
106*833e5d42SEmmanuel Vadot        mode-gpios = <&gpio2 28 GPIO_ACTIVE_HIGH>, <&gpio1 0 GPIO_ACTIVE_HIGH>;
107*833e5d42SEmmanuel Vadot    };
108