← Documents Documentation/devicetree/bindings/usb/generic-ohci.yaml GitHub 원문 ↗

Linux 6.18.37 · Devicetree Bindings / USB

Generic USB OHCI Controller

generic OHCI의 platform fallback, wakeup·port·transceiver 속성과 clock 조건을 설명합니다.

Source pathDocumentation/devicetree/bindings/usb/generic-ohci.yaml
Source versionLinux v6.18.37
TranslationDUJINLABS 전문 번역 + 해설

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

1. 요약·해설

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

요약과 해설

generic-ohci.yaml:1-182

generic OHCI의 platform fallback, wakeup·port·transceiver 속성과 clock 조건을 설명합니다. 접을 수 있는 영어 원문 전체와 한국어 전문 번역을 함께 제공하며, compatible, register, clock, interrupt, reset, PHY, source path와 원문 줄 좌표를 원형대로 보존합니다.

2. 영어 원문 전체

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

원문 전체 펼치기
1 # SPDX-License-Identifier: GPL-2.0
2 %YAML 1.2
3 ---
4 $id: http://devicetree.org/schemas/usb/generic-ohci.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
6
7 title: USB OHCI Controller
8
9 maintainers:
10 - Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11
12 properties:
13 compatible:
14 oneOf:
15 - items:
16 - enum:
17 - allwinner,sun4i-a10-ohci
18 - allwinner,sun50i-a100-ohci
19 - allwinner,sun50i-a64-ohci
20 - allwinner,sun50i-h6-ohci
21 - allwinner,sun50i-h616-ohci
22 - allwinner,sun55i-a523-ohci
23 - allwinner,sun5i-a13-ohci
24 - allwinner,sun6i-a31-ohci
25 - allwinner,sun7i-a20-ohci
26 - allwinner,sun8i-a23-ohci
27 - allwinner,sun8i-a83t-ohci
28 - allwinner,sun8i-h3-ohci
29 - allwinner,sun8i-r40-ohci
30 - allwinner,sun8i-v3s-ohci
31 - allwinner,sun9i-a80-ohci
32 - allwinner,sun20i-d1-ohci
33 - brcm,bcm3384-ohci
34 - brcm,bcm63268-ohci
35 - brcm,bcm6328-ohci
36 - brcm,bcm6358-ohci
37 - brcm,bcm6362-ohci
38 - brcm,bcm6368-ohci
39 - brcm,bcm7125-ohci
40 - brcm,bcm7346-ohci
41 - brcm,bcm7358-ohci
42 - brcm,bcm7360-ohci
43 - brcm,bcm7362-ohci
44 - brcm,bcm7420-ohci
45 - brcm,bcm7425-ohci
46 - brcm,bcm7435-ohci
47 - hpe,gxp-ohci
48 - ibm,476gtr-ohci
49 - ingenic,jz4740-ohci
50 - rockchip,rk3588-ohci
51 - snps,hsdk-v1.0-ohci
52 - const: generic-ohci
53 - enum:
54 - generic-ohci
55 - ti,ohci-omap3
56 - items:
57 - enum:
58 - cavium,octeon-6335-ohci
59 - nintendo,hollywood-usb-ohci
60 - nxp,ohci-nxp
61 - st,spear600-ohci
62 - const: usb-ohci
63
64 reg:
65 maxItems: 1
66
67 interrupts:
68 maxItems: 1
69
70 resets:
71 minItems: 1
72 maxItems: 2
73
74 clocks:
75 minItems: 1
76 maxItems: 4
77 description: |
78 In case the Renesas R-Car Gen3 SoCs:
79 - if a host only channel: first clock should be host.
80 - if a USB DRD channel: first clock should be host and second
81 one should be peripheral
82
83 power-domains:
84 maxItems: 1
85
86 big-endian:
87 $ref: /schemas/types.yaml#/definitions/flag
88 description:
89 Set this flag for HCDs with big endian descriptors and big
90 endian registers.
91
92 big-endian-desc:
93 $ref: /schemas/types.yaml#/definitions/flag
94 description:
95 Set this flag for HCDs with big endian descriptors.
96
97 big-endian-regs:
98 $ref: /schemas/types.yaml#/definitions/flag
99 description:
100 Set this flag for HCDs with big endian registers.
101
102 remote-wakeup-connected:
103 $ref: /schemas/types.yaml#/definitions/flag
104 description:
105 Remote wakeup is wired on the platform.
106
107 no-big-frame-no:
108 $ref: /schemas/types.yaml#/definitions/flag
109 description:
110 Set if frame_no lives in bits [15:0] of HCCA
111
112 num-ports:
113 $ref: /schemas/types.yaml#/definitions/uint32
114 description:
115 Overrides the detected port count
116
117 phys:
118 minItems: 1
119 maxItems: 3
120
121 phy-names:
122 const: usb
123
124 iommus:
125 maxItems: 1
126
127 dr_mode:
128 enum:
129 - host
130 - otg
131
132 transceiver:
133 $ref: /schemas/types.yaml#/definitions/phandle
134 description:
135 The associated ISP1301 device. Necessary for the UDC controller for
136 connecting to the USB physical layer.
137
138 required:
139 - compatible
140 - reg
141 - interrupts
142
143 allOf:
144 - $ref: usb-hcd.yaml
145 - if:
146 not:
147 properties:
148 compatible:
149 contains:
150 const: nxp,ohci-nxp
151 then:
152 properties:
153 transceiver: false
154 - if:
155 properties:
156 compatible:
157 contains:
158 const: rockchip,rk3588-ohci
159 then:
160 properties:
161 clocks:
162 minItems: 4
163 else:
164 properties:
165 clocks:
166 minItems: 1
167 maxItems: 3
168
169 unevaluatedProperties: false
170
171 examples:
172 - |
173 ohci0: usb@1c14400 {
174 compatible = "allwinner,sun4i-a10-ohci", "generic-ohci";
175 reg = <0x01c14400 0x100>;
176 interrupts = <64>;
177 clocks = <&usb_clk 6>, <&ahb_gates 2>;
178 phys = <&usbphy 1>;
179 phy-names = "usb";
180 };
181
182 ...
183

3. 한국어 전문 번역

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

USB OHCI controller

1-11

GPL-2.0으로 배포되는 이 schema는 USB OHCI controller를 정의합니다. 관리자는 Greg Kroah-Hartman입니다.

Platform별 OHCI compatible과 fallback

12-63

`generic-ohci` fallback 그룹에는 Allwinner Sun4i·Sun5i·Sun6i·Sun7i·Sun8i·Sun9i·Sun20i·Sun50i·Sun55i 계열, Broadcom BCM3384·63268·6328·6358·6362·6368·7125·7346·7358·7360·7362·7420·7425·7435가 포함됩니다.

같은 그룹에는 HPE GXP, IBM 476GTR, Ingenic JZ4740, Rockchip RK3588, Synopsys HSDK v1.0도 포함됩니다. standalone 값은 `generic-ohci`와 `ti,ohci-omap3`입니다.

`usb-ohci` fallback 그룹은 Cavium Octeon 6335, Nintendo Hollywood, NXP OHCI, ST SPEAr600입니다. 모든 compatible 문자열은 원문 block에 그대로 보존됩니다.

properties:
  compatible:
    oneOf:
      - items:
          - enum:
              - allwinner,sun4i-a10-ohci
              - allwinner,sun50i-a100-ohci
              - allwinner,sun50i-a64-ohci
              - allwinner,sun50i-h6-ohci
              - allwinner,sun50i-h616-ohci
              - allwinner,sun55i-a523-ohci
              - allwinner,sun5i-a13-ohci
              - allwinner,sun6i-a31-ohci
              - allwinner,sun7i-a20-ohci
              - allwinner,sun8i-a23-ohci
              - allwinner,sun8i-a83t-ohci
              - allwinner,sun8i-h3-ohci
              - allwinner,sun8i-r40-ohci
              - allwinner,sun8i-v3s-ohci
              - allwinner,sun9i-a80-ohci
              - allwinner,sun20i-d1-ohci
              - brcm,bcm3384-ohci
              - brcm,bcm63268-ohci
              - brcm,bcm6328-ohci
              - brcm,bcm6358-ohci
              - brcm,bcm6362-ohci
              - brcm,bcm6368-ohci
              - brcm,bcm7125-ohci
              - brcm,bcm7346-ohci
              - brcm,bcm7358-ohci
              - brcm,bcm7360-ohci
              - brcm,bcm7362-ohci
              - brcm,bcm7420-ohci
              - brcm,bcm7425-ohci
              - brcm,bcm7435-ohci
              - hpe,gxp-ohci
              - ibm,476gtr-ohci
              - ingenic,jz4740-ohci
              - rockchip,rk3588-ohci
              - snps,hsdk-v1.0-ohci
          - const: generic-ohci
      - enum:
          - generic-ohci
          - ti,ohci-omap3
      - items:
          - enum:
              - cavium,octeon-6335-ohci
              - nintendo,hollywood-usb-ohci
              - nxp,ohci-nxp
              - st,spear600-ohci
          - const: usb-ohci

Register, reset, clock과 power domain

64-85

register 영역과 interrupt는 각각 최대 하나, reset은 1~2개, clock은 1~4개, power domain은 최대 하나입니다.

Renesas R-Car Gen3에서 host-only channel의 첫 clock은 host입니다. USB DRD channel은 첫 clock이 host, 둘째 clock이 peripheral이어야 합니다.

reg:
  maxItems: 1

interrupts:
  maxItems: 1

resets:
  minItems: 1
  maxItems: 2

clocks:
  minItems: 1
  maxItems: 4
  description: |
    In case the Renesas R-Car Gen3 SoCs:
      - if a host only channel: first clock should be host.
      - if a USB DRD channel: first clock should be host and second
        one should be peripheral

power-domains:
  maxItems: 1

Endian, wakeup, port와 transceiver

86-137

`big-endian`, `big-endian-desc`, `big-endian-regs`는 각각 descriptor와 register 모두, descriptor만, register만 big-endian인 controller를 표시합니다.

`remote-wakeup-connected`는 platform에 remote wakeup이 배선됐음을 뜻합니다. `no-big-frame-no`는 `frame_no`가 HCCA bit [15:0]에 있음을 표시하고 `num-ports`는 감지된 port 수를 덮어씁니다.

PHY는 1~3개이고 이름은 `usb`입니다. IOMMU는 최대 하나, `dr_mode`는 `host` 또는 `otg`입니다. `transceiver`는 연결된 ISP1301 device phandle이며 UDC controller를 USB physical layer에 연결할 때 필요합니다.

big-endian:
  $ref: /schemas/types.yaml#/definitions/flag
  description:
    Set this flag for HCDs with big endian descriptors and big
    endian registers.

big-endian-desc:
  $ref: /schemas/types.yaml#/definitions/flag
  description:
    Set this flag for HCDs with big endian descriptors.

big-endian-regs:
  $ref: /schemas/types.yaml#/definitions/flag
  description:
    Set this flag for HCDs with big endian registers.

remote-wakeup-connected:
  $ref: /schemas/types.yaml#/definitions/flag
  description:
    Remote wakeup is wired on the platform.

no-big-frame-no:
  $ref: /schemas/types.yaml#/definitions/flag
  description:
    Set if frame_no lives in bits [15:0] of HCCA

num-ports:
  $ref: /schemas/types.yaml#/definitions/uint32
  description:
    Overrides the detected port count

phys:
  minItems: 1
  maxItems: 3

phy-names:
  const: usb

iommus:
  maxItems: 1

dr_mode:
  enum:
    - host
    - otg

transceiver:
  $ref: /schemas/types.yaml#/definitions/phandle
  description:
    The associated ISP1301 device. Necessary for the UDC controller for
    connecting to the USB physical layer.

필수 속성과 platform 조건

138-170

필수 속성은 `compatible`, `reg`, `interrupts`이고 공통 `usb-hcd.yaml`을 상속합니다.

NXP `nxp,ohci-nxp` compatible이 아닌 controller에는 `transceiver`를 허용하지 않습니다. Rockchip RK3588 OHCI는 clock을 최소 4개 요구하고, 그 밖의 controller는 1~3개를 허용합니다.

상속 schema까지 평가한 뒤 남는 추가 속성은 허용하지 않습니다.

required:
  - compatible
  - reg
  - interrupts

allOf:
  - $ref: usb-hcd.yaml
  - if:
      not:
        properties:
          compatible:
            contains:
              const: nxp,ohci-nxp
    then:
      properties:
        transceiver: false
  - if:
      properties:
        compatible:
          contains:
            const: rockchip,rk3588-ohci
    then:
      properties:
        clocks:
          minItems: 4
    else:
      properties:
        clocks:
          minItems: 1
          maxItems: 3

unevaluatedProperties: false

Allwinner OHCI 예제

171-182

예제 `usb@1c14400`은 Allwinner Sun4i A10과 `generic-ohci` fallback, 0x100-byte register 영역, interrupt 64, USB clock과 AHB gate clock, USB PHY와 `usb` PHY 이름을 사용합니다.

examples:
  - |
      ohci0: usb@1c14400 {
          compatible = "allwinner,sun4i-a10-ohci", "generic-ohci";
          reg = <0x01c14400 0x100>;
          interrupts = <64>;
          clocks = <&usb_clk 6>, <&ahb_gates 2>;
          phys = <&usbphy 1>;
          phy-names = "usb";
      };

...