← Documents Documentation/devicetree/bindings/usb/smsc,usb3503.yaml GitHub 원문 ↗

Linux 6.18.37 · Devicetree Bindings / USB

SMSC USB3503 High-Speed Hub Controller

USB3503·USB3803 hub의 GPIO, initial mode와 REFCLK 조건을 설명합니다.

Source pathDocumentation/devicetree/bindings/usb/smsc,usb3503.yaml
Source versionLinux v6.18.37
TranslationDUJINLABS 전문 번역 + 해설

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

1. 요약·해설

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

요약과 해설

smsc,usb3503.yaml:1-159

USB3503·USB3803 hub의 GPIO, initial mode와 REFCLK 조건을 설명합니다. 접을 수 있는 영어 원문 전체와 한국어 전문 번역을 함께 제공하며, compatible, register, GPIO, clock, PHY, hub mode, 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/smsc,usb3503.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
6
7 title: SMSC USB3503 High-Speed Hub Controller
8
9 maintainers:
10 - Dongjin Kim <tobetter@gmail.com>
11
12 properties:
13 compatible:
14 enum:
15 - smsc,usb3503
16 - smsc,usb3503a
17 - smsc,usb3803
18
19 reg:
20 maxItems: 1
21
22 connect-gpios:
23 maxItems: 1
24 description: >
25 GPIO for connect
26
27 intn-gpios:
28 maxItems: 1
29 description: >
30 GPIO for interrupt
31
32 reset-gpios:
33 maxItems: 1
34 description: >
35 GPIO for reset
36
37 bypass-gpios:
38 maxItems: 1
39 description: >
40 GPIO for bypass.
41 Control signal to select between HUB MODE and BYPASS MODE.
42
43 disabled-ports:
44 $ref: /schemas/types.yaml#/definitions/uint32-array
45 minItems: 1
46 maxItems: 3
47 items:
48 minimum: 1
49 maximum: 3
50 description: >
51 Specifies the ports unused using their port number. Do not describe this
52 property if all ports have to be enabled.
53
54 initial-mode:
55 $ref: /schemas/types.yaml#/definitions/uint32
56 description: >
57 Specifies initial mode. 1 for Hub mode, 2 for standby mode and 3 for bypass mode.
58 In bypass mode the downstream port 3 is connected to the upstream port with low
59 switch resistance R_on.
60
61 clocks:
62 maxItems: 1
63 description: >
64 Clock used for driving REFCLK signal. If not provided the driver assumes
65 that clock signal is always available, its rate is specified by REF_SEL
66 pins and a value from the primary reference clock frequencies table is
67 used.
68
69 clock-names:
70 const: refclk
71
72 refclk-frequency:
73 $ref: /schemas/types.yaml#/definitions/uint32
74 description: >
75 Frequency of the REFCLK signal as defined by REF_SEL pins. If not
76 provided, driver will not set rate of the REFCLK signal and assume that a
77 value from the primary reference clock frequencies table is used.
78
79 required:
80 - compatible
81
82 allOf:
83 - if:
84 not:
85 properties:
86 compatible:
87 enum:
88 - smsc,usb3803
89 then:
90 properties:
91 bypass-gpios: false
92
93 - if:
94 required:
95 - bypass-gpios
96 then:
97 properties:
98 initial-mode:
99 enum: [1, 2, 3]
100 else:
101 properties:
102 initial-mode:
103 enum: [1, 2]
104
105 additionalProperties: false
106
107 examples:
108 - |
109 i2c {
110 #address-cells = <1>;
111 #size-cells = <0>;
112
113 usb-hub@8 {
114 compatible = "smsc,usb3503";
115 reg = <0x08>;
116 connect-gpios = <&gpx3 0 1>;
117 disabled-ports = <2 3>;
118 intn-gpios = <&gpx3 4 1>;
119 reset-gpios = <&gpx3 5 1>;
120 initial-mode = <1>;
121 clocks = <&clks 80>;
122 clock-names = "refclk";
123 };
124 };
125
126 - |
127 i2c {
128 #address-cells = <1>;
129 #size-cells = <0>;
130
131 usb-hub@8 {
132 compatible = "smsc,usb3803";
133 reg = <0x08>;
134 connect-gpios = <&gpx3 0 1>;
135 disabled-ports = <2 3>;
136 intn-gpios = <&gpx3 4 1>;
137 reset-gpios = <&gpx3 5 1>;
138 bypass-gpios = <&gpx3 6 1>;
139 initial-mode = <3>;
140 clocks = <&clks 80>;
141 clock-names = "refclk";
142 };
143 };
144
145 - |
146 #include <dt-bindings/gpio/gpio.h>
147
148 usb-hub {
149 /* I2C is not connected */
150 compatible = "smsc,usb3503";
151 initial-mode = <1>; /* initialize in HUB mode */
152 disabled-ports = <1>;
153 intn-gpios = <&pio 7 5 GPIO_ACTIVE_HIGH>; /* PH5 */
154 reset-gpios = <&pio 4 16 GPIO_ACTIVE_LOW>; /* PE16 */
155 connect-gpios = <&pio 4 17 GPIO_ACTIVE_HIGH>; /* PE17 */
156 refclk-frequency = <19200000>;
157 };
158
159 ...
160

3. 한국어 전문 번역

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

SMSC USB3503 High-Speed hub

1-11

GPL-2.0으로 배포되는 이 스키마는 SMSC USB3503 High-Speed Hub Controller를 정의합니다. 관리자는 Dongjin Kim입니다.

GPIO, disabled port와 initial mode

12-60

compatible은 `smsc,usb3503`, `smsc,usb3503a`, `smsc,usb3803` 가운데 하나이고 register 영역은 하나입니다. `connect-gpios`, `intn-gpios`, `reset-gpios`는 각각 connect, interrupt, reset 신호를 제어합니다.

`bypass-gpios`는 HUB MODE와 BYPASS MODE를 선택합니다. `disabled-ports`는 사용하지 않을 downstream port 번호 1~3을 최대 세 개 지정하며 모든 port를 쓸 때는 생략합니다. `initial-mode`는 1=hub, 2=standby, 3=bypass이고 bypass에서는 downstream port 3이 낮은 switch resistance `R_on`으로 upstream port에 연결됩니다.

properties:
  compatible:
    enum:
      - smsc,usb3503
      - smsc,usb3503a
      - smsc,usb3803

  reg:
    maxItems: 1

  connect-gpios:
    maxItems: 1
    description: >
      GPIO for connect

  intn-gpios:
    maxItems: 1
    description: >
      GPIO for interrupt

  reset-gpios:
    maxItems: 1
    description: >
      GPIO for reset

  bypass-gpios:
    maxItems: 1
    description: >
      GPIO for bypass.
      Control signal to select between HUB MODE and BYPASS MODE.

  disabled-ports:
    $ref: /schemas/types.yaml#/definitions/uint32-array
    minItems: 1
    maxItems: 3
    items:
      minimum: 1
      maximum: 3
    description: >
      Specifies the ports unused using their port number. Do not describe this
      property if all ports have to be enabled.

  initial-mode:
    $ref: /schemas/types.yaml#/definitions/uint32
    description: >
      Specifies initial mode. 1 for Hub mode, 2 for standby mode and 3 for bypass mode.
      In bypass mode the downstream port 3 is connected to the upstream port with low
      switch resistance R_on.

REFCLK 공급과 주파수

61-78

선택적인 clock 하나는 REFCLK 신호를 구동하며 이름은 `refclk`입니다. clock을 제공하지 않으면 driver는 신호가 항상 존재하고 REF_SEL pin이 primary reference clock 표의 주파수를 선택한다고 가정합니다.

`refclk-frequency`는 REF_SEL pin이 정의하는 REFCLK 주파수입니다. 이를 생략하면 driver가 rate를 설정하지 않고 primary reference clock 표의 값을 사용한다고 가정합니다.

clocks:
  maxItems: 1
  description: >
    Clock used for driving REFCLK signal. If not provided the driver assumes
    that clock signal is always available, its rate is specified by REF_SEL
    pins and a value from the primary reference clock frequencies table is
    used.

clock-names:
  const: refclk

refclk-frequency:
  $ref: /schemas/types.yaml#/definitions/uint32
  description: >
    Frequency of the REFCLK signal as defined by REF_SEL pins. If not
    provided, driver will not set rate of the REFCLK signal and assume that a
    value from the primary reference clock frequencies table is used.

모델별 bypass와 mode 제약

79-106

공통 필수 속성은 `compatible`뿐입니다. USB3803이 아닌 모델에서는 `bypass-gpios`를 허용하지 않습니다. bypass GPIO가 있으면 initial mode 1·2·3을, 없으면 1·2만 허용합니다. 정의되지 않은 추가 속성은 허용하지 않습니다.

required:
  - compatible

allOf:
  - if:
      not:
        properties:
          compatible:
            enum:
              - smsc,usb3803
    then:
      properties:
        bypass-gpios: false

  - if:
      required:
        - bypass-gpios
    then:
      properties:
        initial-mode:
          enum: [1, 2, 3]
    else:
      properties:
        initial-mode:
          enum: [1, 2]

additionalProperties: false

USB3503·USB3803·비-I2C 예제

107-159

첫 I2C 예제 `usb-hub@8`은 USB3503, 주소 0x08, connect·interrupt·reset GPIO, disabled port 2·3, hub initial mode 1과 `refclk` clock을 사용합니다.

둘째 예제는 USB3803에 bypass GPIO와 initial mode 3을 추가해 BYPASS MODE를 선택합니다. 셋째 예제는 I2C가 연결되지 않은 USB3503으로 hub mode 1, disabled port 1, 세 GPIO와 19.2 MHz `refclk-frequency`를 직접 지정합니다.

examples:
  - |
    i2c {
        #address-cells = <1>;
        #size-cells = <0>;

        usb-hub@8 {
            compatible = "smsc,usb3503";
            reg = <0x08>;
            connect-gpios = <&gpx3 0 1>;
            disabled-ports = <2 3>;
            intn-gpios = <&gpx3 4 1>;
            reset-gpios = <&gpx3 5 1>;
            initial-mode = <1>;
            clocks = <&clks 80>;
            clock-names = "refclk";
        };
    };

  - |
    i2c {
        #address-cells = <1>;
        #size-cells = <0>;

        usb-hub@8 {
            compatible = "smsc,usb3803";
            reg = <0x08>;
            connect-gpios = <&gpx3 0 1>;
            disabled-ports = <2 3>;
            intn-gpios = <&gpx3 4 1>;
            reset-gpios = <&gpx3 5 1>;
            bypass-gpios = <&gpx3 6 1>;
            initial-mode = <3>;
            clocks = <&clks 80>;
            clock-names = "refclk";
        };
    };

  - |
    #include <dt-bindings/gpio/gpio.h>

    usb-hub {
        /* I2C is not connected */
        compatible = "smsc,usb3503";
        initial-mode = <1>; /* initialize in HUB mode */
        disabled-ports = <1>;
        intn-gpios = <&pio 7 5 GPIO_ACTIVE_HIGH>; /* PH5 */
        reset-gpios = <&pio 4 16 GPIO_ACTIVE_LOW>; /* PE16 */
        connect-gpios = <&pio 4 17 GPIO_ACTIVE_HIGH>; /* PE17 */
        refclk-frequency = <19200000>;
    };

...