← Documents Documentation/devicetree/bindings/usb/chipidea,usb2-imx.yaml GitHub 원문 ↗

Linux 6.18.37 · Devicetree Bindings / USB

NXP USB2 ChipIdea USB Controller

NXP i.MX·Vybrid ChipIdea USB2의 compatible fallback, picoPHY tuning, SoC별 clock·interrupt와 HSIC 예제를 설명합니다.

Source pathDocumentation/devicetree/bindings/usb/chipidea,usb2-imx.yaml
Source versionLinux v6.18.37
TranslationDUJINLABS 전문 번역 + 해설

요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.

1. 요약·해설

원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.

요약과 해설

chipidea,usb2-imx.yaml:1-309

NXP i.MX·Vybrid ChipIdea USB2의 compatible fallback, picoPHY tuning, SoC별 clock·interrupt와 HSIC 예제를 설명합니다. 접을 수 있는 영어 원문 전체와 한국어 전문 번역을 함께 제공하며, compatible, register, clock, interrupt, PHY, mux, pinctrl, endpoint, source path와 원문 줄 좌표를 원형대로 보존합니다.

2. 영어 원문 전체

번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.

원문 전체 펼치기
1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2 %YAML 1.2
3 ---
4 $id: http://devicetree.org/schemas/usb/chipidea,usb2-imx.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
6
7 title: NXP USB2 ChipIdea USB controller
8
9 maintainers:
10 - Xu Yang <[email protected]>
11
12 properties:
13 compatible:
14 oneOf:
15 - enum:
16 - fsl,imx27-usb
17 - items:
18 - enum:
19 - fsl,imx23-usb
20 - fsl,imx25-usb
21 - fsl,imx28-usb
22 - fsl,imx35-usb
23 - fsl,imx50-usb
24 - fsl,imx51-usb
25 - fsl,imx53-usb
26 - fsl,imx6q-usb
27 - fsl,imx6sl-usb
28 - fsl,imx6sx-usb
29 - fsl,imx6ul-usb
30 - fsl,imx7d-usb
31 - fsl,vf610-usb
32 - const: fsl,imx27-usb
33 - items:
34 - enum:
35 - fsl,imx8dxl-usb
36 - fsl,imx8ulp-usb
37 - const: fsl,imx7ulp-usb
38 - const: fsl,imx6ul-usb
39 - items:
40 - enum:
41 - fsl,imx8mm-usb
42 - fsl,imx8mn-usb
43 - fsl,imx93-usb
44 - fsl,imx95-usb
45 - const: fsl,imx7d-usb
46 - const: fsl,imx27-usb
47 - items:
48 - enum:
49 - fsl,imx6sll-usb
50 - fsl,imx7ulp-usb
51 - const: fsl,imx6ul-usb
52 - const: fsl,imx27-usb
53
54 reg:
55 maxItems: 1
56
57 interrupts:
58 minItems: 1
59 items:
60 - description: USB controller interrupt or combine USB controller
61 and wakeup interrupts.
62 - description: Wakeup interrupt
63
64 clocks:
65 minItems: 1
66 maxItems: 3
67
68 clock-names:
69 minItems: 1
70 maxItems: 3
71
72 fsl,usbmisc:
73 description:
74 Phandler of non-core register device, with one argument that
75 indicate usb controller index
76 $ref: /schemas/types.yaml#/definitions/phandle-array
77 items:
78 - items:
79 - description: phandle to usbmisc node
80 - description: index of usb controller
81
82 disable-over-current:
83 type: boolean
84 description: disable over current detect
85
86 over-current-active-low:
87 type: boolean
88 description: over current signal polarity is active low
89
90 over-current-active-high:
91 type: boolean
92 description:
93 Over current signal polarity is active high. It's recommended to
94 specify the over current polarity.
95
96 power-active-high:
97 type: boolean
98 description: power signal polarity is active high
99
100 external-vbus-divider:
101 type: boolean
102 description: enables off-chip resistor divider for Vbus
103
104 samsung,picophy-pre-emp-curr-control:
105 description:
106 HS Transmitter Pre-Emphasis Current Control. This signal controls
107 the amount of current sourced to the USB_OTG*_DP and USB_OTG*_DN
108 pins after a J-to-K or K-to-J transition. The range is from 0x0 to
109 0x3, the default value is 0x1. Details can refer to TXPREEMPAMPTUNE0
110 bits of USBNC_n_PHY_CFG1.
111 $ref: /schemas/types.yaml#/definitions/uint32
112 minimum: 0x0
113 maximum: 0x3
114
115 samsung,picophy-dc-vol-level-adjust:
116 description:
117 HS DC Voltage Level Adjustment. Adjust the high-speed transmitter DC
118 level voltage. The range is from 0x0 to 0xf, the default value is
119 0x3. Details can refer to TXVREFTUNE0 bits of USBNC_n_PHY_CFG1.
120 $ref: /schemas/types.yaml#/definitions/uint32
121 minimum: 0x0
122 maximum: 0xf
123
124 fsl,picophy-rise-fall-time-adjust:
125 description:
126 HS Transmitter Rise/Fall Time Adjustment. Adjust the rise/fall times
127 of the high-speed transmitter waveform. It has no unit. The rise/fall
128 time will be increased or decreased by a certain percentage relative
129 to design default time. (0:-10%; 1:design default; 2:+15%; 3:+20%)
130 Details can refer to TXRISETUNE0 bit of USBNC_n_PHY_CFG1.
131 $ref: /schemas/types.yaml#/definitions/uint32
132 minimum: 0
133 maximum: 3
134 default: 1
135
136 fsl,usbphy:
137 description: phandle of usb phy that connects to the port. Use "phys" instead.
138 $ref: /schemas/types.yaml#/definitions/phandle
139 deprecated: true
140
141 required:
142 - compatible
143
144 allOf:
145 - $ref: chipidea,usb2-common.yaml#
146 - if:
147 properties:
148 phy_type:
149 const: hsic
150 required:
151 - phy_type
152 then:
153 properties:
154 pinctrl-names:
155 items:
156 - const: idle
157 - const: active
158
159 # imx27 Soc needs three clocks
160 - if:
161 properties:
162 compatible:
163 const: fsl,imx27-usb
164 then:
165 properties:
166 clocks:
167 minItems: 3
168 clock-names:
169 items:
170 - const: ipg
171 - const: ahb
172 - const: per
173
174 # imx25 and imx35 Soc need three clocks
175 - if:
176 properties:
177 compatible:
178 contains:
179 enum:
180 - fsl,imx25-usb
181 - fsl,imx35-usb
182 then:
183 properties:
184 clocks:
185 minItems: 3
186 clock-names:
187 items:
188 - const: ipg
189 - const: ahb
190 - const: per
191
192 # imx93 Soc needs two clocks
193 - if:
194 properties:
195 compatible:
196 contains:
197 enum:
198 - fsl,imx93-usb
199 - fsl,imx95-usb
200 then:
201 properties:
202 clocks:
203 minItems: 2
204 maxItems: 2
205 clock-names:
206 items:
207 - const: usb_ctrl_root
208 - const: usb_wakeup
209
210 # imx7d Soc need one clock
211 - if:
212 properties:
213 compatible:
214 items:
215 - const: fsl,imx7d-usb
216 - const: fsl,imx27-usb
217 then:
218 properties:
219 clocks:
220 maxItems: 1
221 clock-names: false
222
223 # other Soc need one clock
224 - if:
225 properties:
226 compatible:
227 contains:
228 enum:
229 - fsl,imx23-usb
230 - fsl,imx28-usb
231 - fsl,imx50-usb
232 - fsl,imx51-usb
233 - fsl,imx53-usb
234 - fsl,imx6q-usb
235 - fsl,imx6sl-usb
236 - fsl,imx6sx-usb
237 - fsl,imx6ul-usb
238 - fsl,imx8mm-usb
239 - fsl,imx8mn-usb
240 - fsl,vf610-usb
241 then:
242 properties:
243 clocks:
244 maxItems: 1
245 clock-names: false
246
247 # imx95 soc use two interrupts
248 - if:
249 properties:
250 compatible:
251 contains:
252 enum:
253 - fsl,imx95-usb
254 then:
255 properties:
256 interrupts:
257 minItems: 2
258 else:
259 properties:
260 interrupts:
261 maxItems: 1
262
263 unevaluatedProperties: false
264
265 examples:
266 - |
267 #include <dt-bindings/interrupt-controller/arm-gic.h>
268 #include <dt-bindings/clock/imx7d-clock.h>
269
270 usb@30b10000 {
271 compatible = "fsl,imx7d-usb", "fsl,imx27-usb";
272 reg = <0x30b10000 0x200>;
273 interrupts = <GIC_SPI 43 IRQ_TYPE_LEVEL_HIGH>;
274 clocks = <&clks IMX7D_USB_CTRL_CLK>;
275 fsl,usbphy = <&usbphynop1>;
276 fsl,usbmisc = <&usbmisc1 0>;
277 phy-clkgate-delay-us = <400>;
278 };
279
280 # Example for HSIC:
281 - |
282 #include <dt-bindings/interrupt-controller/arm-gic.h>
283 #include <dt-bindings/clock/imx6qdl-clock.h>
284
285 usb@2184400 {
286 compatible = "fsl,imx6q-usb", "fsl,imx27-usb";
287 reg = <0x02184400 0x200>;
288 interrupts = <0 41 IRQ_TYPE_LEVEL_HIGH>;
289 clocks = <&clks IMX6QDL_CLK_USBOH3>;
290 fsl,usbphy = <&usbphynop1>;
291 fsl,usbmisc = <&usbmisc 2>;
292 phy_type = "hsic";
293 dr_mode = "host";
294 ahb-burst-config = <0x0>;
295 tx-burst-size-dword = <0x10>;
296 rx-burst-size-dword = <0x10>;
297 pinctrl-names = "idle", "active";
298 pinctrl-0 = <&pinctrl_usbh2_idle>;
299 pinctrl-1 = <&pinctrl_usbh2_active>;
300 #address-cells = <1>;
301 #size-cells = <0>;
302
303 ethernet@1 {
304 compatible = "usb424,9730";
305 reg = <1>;
306 };
307 };
308
309 ...
310

3. 한국어 전문 번역

영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.

NXP USB2 ChipIdea controller

1-11

GPL-2.0-only 또는 BSD-2-Clause 라이선스의 이 schema는 NXP USB2 ChipIdea controller를 정의합니다. 관리자는 Xu Yang입니다.

i.MX·Vybrid compatible fallback chain

12-53

`fsl,imx27-usb`는 단독 compatible입니다. i.MX23·25·28·35·50·51·53·6Q·6SL·6SX·6UL·7D와 VF610은 SoC compatible 다음에 `fsl,imx27-usb` fallback을 둡니다.

i.MX8DXL과 i.MX8ULP는 `fsl,imx7ulp-usb`, `fsl,imx6ul-usb` 순서의 fallback을 둡니다. i.MX8MM·8MN·93·95는 `fsl,imx7d-usb`, `fsl,imx27-usb`를 뒤따릅니다. i.MX6SLL과 i.MX7ULP는 `fsl,imx6ul-usb`, `fsl,imx27-usb`를 뒤따릅니다.

properties:
  compatible:
    oneOf:
      - enum:
          - fsl,imx27-usb
      - items:
          - enum:
              - fsl,imx23-usb
              - fsl,imx25-usb
              - fsl,imx28-usb
              - fsl,imx35-usb
              - fsl,imx50-usb
              - fsl,imx51-usb
              - fsl,imx53-usb
              - fsl,imx6q-usb
              - fsl,imx6sl-usb
              - fsl,imx6sx-usb
              - fsl,imx6ul-usb
              - fsl,imx7d-usb
              - fsl,vf610-usb
          - const: fsl,imx27-usb
      - items:
          - enum:
              - fsl,imx8dxl-usb
              - fsl,imx8ulp-usb
          - const: fsl,imx7ulp-usb
          - const: fsl,imx6ul-usb
      - items:
          - enum:
              - fsl,imx8mm-usb
              - fsl,imx8mn-usb
              - fsl,imx93-usb
              - fsl,imx95-usb
          - const: fsl,imx7d-usb
          - const: fsl,imx27-usb
      - items:
          - enum:
              - fsl,imx6sll-usb
              - fsl,imx7ulp-usb
          - const: fsl,imx6ul-usb
          - const: fsl,imx27-usb

Interrupt, clock, USBMISC와 전원 신호

54-103

`reg`는 최대 한 항목입니다. Interrupt의 첫 항목은 USB controller interrupt 또는 controller와 wakeup을 결합한 interrupt이고, 두 번째 항목은 별도 wakeup interrupt입니다. Clock과 clock 이름은 각각 1~3개입니다.

`fsl,usbmisc`는 non-core register device의 phandle과 USB controller index 한 개를 함께 담습니다. `disable-over-current`는 overcurrent 검출을 끄고, `over-current-active-low`와 `over-current-active-high`는 신호 극성을 지정합니다. 극성을 명시하는 것이 권장됩니다. `power-active-high`는 power 신호를 active-high로 만들며 `external-vbus-divider`는 외부 VBUS resistor divider를 활성화합니다.

reg:
  maxItems: 1

interrupts:
  minItems: 1
  items:
    - description: USB controller interrupt or combine USB controller
                   and wakeup interrupts.
    - description: Wakeup interrupt

clocks:
  minItems: 1
  maxItems: 3

clock-names:
  minItems: 1
  maxItems: 3

fsl,usbmisc:
  description:
    Phandler of non-core register device, with one argument that
    indicate usb controller index
  $ref: /schemas/types.yaml#/definitions/phandle-array
  items:
    - items:
        - description: phandle to usbmisc node
        - description: index of usb controller

disable-over-current:
  type: boolean
  description: disable over current detect

over-current-active-low:
  type: boolean
  description: over current signal polarity is active low

over-current-active-high:
  type: boolean
  description:
    Over current signal polarity is active high. It's recommended to
    specify the over current polarity.

power-active-high:
  type: boolean
  description: power signal polarity is active high

external-vbus-divider:
  type: boolean
  description: enables off-chip resistor divider for Vbus

Samsung·FSL picoPHY tuning

104-140

`samsung,picophy-pre-emp-curr-control`은 J-to-K 또는 K-to-J 전환 뒤 USB OTG DP/DN pin에 공급되는 HS transmitter pre-emphasis current를 조절합니다. 범위는 0x0~0x3, 기본값은 0x1이며 USBNC_n_PHY_CFG1의 TXPREEMPAMPTUNE0 bit에 대응합니다.

`samsung,picophy-dc-vol-level-adjust`는 HS transmitter DC level voltage를 조절합니다. 범위는 0x0~0xf, 기본값은 0x3이며 TXVREFTUNE0 bit에 대응합니다.

`fsl,picophy-rise-fall-time-adjust`는 단위 없이 HS waveform의 rise/fall time을 설계 기본값 대비 조절합니다. 0은 -10%, 1은 기본값, 2는 +15%, 3은 +20%이고 기본값은 1입니다. 예전 PHY phandle `fsl,usbphy`는 폐기되었으므로 `phys`를 사용해야 합니다.

samsung,picophy-pre-emp-curr-control:
  description:
    HS Transmitter Pre-Emphasis Current Control. This signal controls
    the amount of current sourced to the USB_OTG*_DP and USB_OTG*_DN
    pins after a J-to-K or K-to-J transition. The range is from 0x0 to
    0x3, the default value is 0x1. Details can refer to TXPREEMPAMPTUNE0
    bits of USBNC_n_PHY_CFG1.
  $ref: /schemas/types.yaml#/definitions/uint32
  minimum: 0x0
  maximum: 0x3

samsung,picophy-dc-vol-level-adjust:
  description:
    HS DC Voltage Level Adjustment. Adjust the high-speed transmitter DC
    level voltage. The range is from 0x0 to 0xf, the default value is
    0x3. Details can refer to TXVREFTUNE0 bits of USBNC_n_PHY_CFG1.
  $ref: /schemas/types.yaml#/definitions/uint32
  minimum: 0x0
  maximum: 0xf

fsl,picophy-rise-fall-time-adjust:
  description:
    HS Transmitter Rise/Fall Time Adjustment. Adjust the rise/fall times
    of the high-speed transmitter waveform. It has no unit. The rise/fall
    time will be increased or decreased by a certain percentage relative
    to design default time. (0:-10%; 1:design default; 2:+15%; 3:+20%)
    Details can refer to TXRISETUNE0 bit of USBNC_n_PHY_CFG1.
  $ref: /schemas/types.yaml#/definitions/uint32
  minimum: 0
  maximum: 3
  default: 1

fsl,usbphy:
  description: phandle of usb phy that connects to the port. Use "phys" instead.
  $ref: /schemas/types.yaml#/definitions/phandle
  deprecated: true

공통 schema와 HSIC pinctrl

141-158

`compatible`은 필수이며 모든 공통 속성은 `chipidea,usb2-common.yaml`을 따릅니다. `phy_type = "hsic"`이면 `pinctrl-names`가 `idle`, `active` 두 state를 순서대로 가져야 합니다.

required:
  - compatible

allOf:
  - $ref: chipidea,usb2-common.yaml#
  - if:
      properties:
        phy_type:
          const: hsic
      required:
        - phy_type
    then:
      properties:
        pinctrl-names:
          items:
            - const: idle
            - const: active

i.MX27의 세 clock

159-173

i.MX27 SoC는 clock이 최소 3개이고 이름은 `ipg`, `ahb`, `per` 순서입니다.

# imx27 Soc needs three clocks
- if:
    properties:
      compatible:
        const: fsl,imx27-usb
  then:
    properties:
      clocks:
        minItems: 3
      clock-names:
        items:
          - const: ipg
          - const: ahb
          - const: per

i.MX25·i.MX35의 세 clock

174-191

Compatible에 i.MX25 또는 i.MX35 USB가 포함되면 clock이 최소 3개이고 이름은 `ipg`, `ahb`, `per` 순서입니다.

# imx25 and imx35 Soc need three clocks
- if:
    properties:
      compatible:
        contains:
          enum:
            - fsl,imx25-usb
            - fsl,imx35-usb
  then:
    properties:
      clocks:
        minItems: 3
      clock-names:
        items:
          - const: ipg
          - const: ahb
          - const: per

i.MX93·i.MX95의 두 clock

192-209

Compatible에 i.MX93 또는 i.MX95 USB가 포함되면 clock은 정확히 2개이고 이름은 `usb_ctrl_root`, `usb_wakeup` 순서입니다.

# imx93 Soc needs two clocks
- if:
    properties:
      compatible:
        contains:
          enum:
            - fsl,imx93-usb
            - fsl,imx95-usb
  then:
    properties:
      clocks:
        minItems: 2
        maxItems: 2
      clock-names:
        items:
          - const: usb_ctrl_root
          - const: usb_wakeup

i.MX7D의 단일 clock

210-222

Compatible 배열이 `fsl,imx7d-usb`, `fsl,imx27-usb`인 i.MX7D는 clock이 최대 한 개이며 `clock-names`를 사용하지 않습니다.

# imx7d Soc need one clock
- if:
    properties:
      compatible:
        items:
          - const: fsl,imx7d-usb
          - const: fsl,imx27-usb
  then:
    properties:
      clocks:
        maxItems: 1
      clock-names: false

그 밖의 SoC 단일 clock

223-246

i.MX23·28·50·51·53·6Q·6SL·6SX·6UL·8MM·8MN과 VF610은 clock이 최대 한 개이며 `clock-names`를 사용하지 않습니다.

# other Soc need one clock
- if:
    properties:
      compatible:
        contains:
          enum:
            - fsl,imx23-usb
            - fsl,imx28-usb
            - fsl,imx50-usb
            - fsl,imx51-usb
            - fsl,imx53-usb
            - fsl,imx6q-usb
            - fsl,imx6sl-usb
            - fsl,imx6sx-usb
            - fsl,imx6ul-usb
            - fsl,imx8mm-usb
            - fsl,imx8mn-usb
            - fsl,vf610-usb
  then:
    properties:
      clocks:
        maxItems: 1
      clock-names: false

i.MX95의 두 interrupt

247-264

Compatible에 `fsl,imx95-usb`가 포함되면 interrupt가 최소 2개입니다. 그 밖의 SoC에서는 interrupt가 최대 한 개입니다. Schema에 평가되지 않은 추가 속성은 허용하지 않습니다.

  # imx95 soc use two interrupts
  - if:
      properties:
        compatible:
          contains:
            enum:
              - fsl,imx95-usb
    then:
      properties:
        interrupts:
          minItems: 2
    else:
      properties:
        interrupts:
          maxItems: 1

unevaluatedProperties: false

i.MX7D 예제

265-279

예제 `usb@30b10000`은 i.MX7D와 i.MX27 fallback compatible, 0x200-byte register 영역, level-high GIC SPI 43, `IMX7D_USB_CTRL_CLK` clock을 사용합니다. 폐기된 `fsl,usbphy`로 `usbphynop1`을 참조하고 `fsl,usbmisc`는 controller index 0을 지정하며 PHY clock gate 지연은 400 us입니다.

examples:
  - |
    #include <dt-bindings/interrupt-controller/arm-gic.h>
    #include <dt-bindings/clock/imx7d-clock.h>

    usb@30b10000 {
        compatible = "fsl,imx7d-usb", "fsl,imx27-usb";
        reg = <0x30b10000 0x200>;
        interrupts = <GIC_SPI 43 IRQ_TYPE_LEVEL_HIGH>;
        clocks = <&clks IMX7D_USB_CTRL_CLK>;
        fsl,usbphy = <&usbphynop1>;
        fsl,usbmisc = <&usbmisc1 0>;
        phy-clkgate-delay-us = <400>;
    };

i.MX6Q HSIC host 예제

280-309

HSIC 예제 `usb@2184400`은 i.MX6Q와 i.MX27 fallback, 0x200-byte 영역, level-high interrupt 41, USBOH3 clock을 사용합니다. USBMISC controller index는 2이고 `phy_type`은 `hsic`, mode는 `host`입니다.

AHB burst config는 0이므로 TX와 RX burst 크기 0x10 dword 설정이 적용됩니다. `idle`, `active` pinctrl state를 각각 연결합니다. Child `ethernet@1`은 `usb424,9730` compatible과 USB address 1을 사용합니다.

  # Example for HSIC:
  - |
    #include <dt-bindings/interrupt-controller/arm-gic.h>
    #include <dt-bindings/clock/imx6qdl-clock.h>

    usb@2184400 {
        compatible = "fsl,imx6q-usb", "fsl,imx27-usb";
        reg = <0x02184400 0x200>;
        interrupts = <0 41 IRQ_TYPE_LEVEL_HIGH>;
        clocks = <&clks IMX6QDL_CLK_USBOH3>;
        fsl,usbphy = <&usbphynop1>;
        fsl,usbmisc = <&usbmisc 2>;
        phy_type = "hsic";
        dr_mode = "host";
        ahb-burst-config = <0x0>;
        tx-burst-size-dword = <0x10>;
        rx-burst-size-dword = <0x10>;
        pinctrl-names = "idle", "active";
        pinctrl-0 = <&pinctrl_usbh2_idle>;
        pinctrl-1 = <&pinctrl_usbh2_active>;
        #address-cells = <1>;
        #size-cells = <0>;

        ethernet@1 {
            compatible = "usb424,9730";
            reg = <1>;
        };
    };

...