← Documents Documentation/devicetree/bindings/usb/dwc3-st.txt GitHub 원문 ↗

Linux 6.18.37 · Devicetree Bindings / USB

ST DWC3 Glue Logic

STiH407 DWC3 glue의 register·reset·pinctrl, 필수 dr_mode와 host core 예제를 설명합니다.

Source pathDocumentation/devicetree/bindings/usb/dwc3-st.txt
Source versionLinux v6.18.37
TranslationDUJINLABS 전문 번역 + 해설

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

1. 요약·해설

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

요약과 해설

dwc3-st.txt:1-66

STiH407 DWC3 glue의 register·reset·pinctrl, 필수 dr_mode와 host core 예제를 설명합니다. 접을 수 있는 영어 원문 전체와 한국어 전문 번역을 함께 제공하며, compatible, register, clock, interrupt, reset, PHY, power, source path와 원문 줄 좌표를 원형대로 보존합니다.

2. 영어 원문 전체

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

원문 전체 펼치기
1 ST DWC3 glue logic
2
3 This file documents the parameters for the dwc3-st driver.
4 This driver controls the glue logic used to configure the dwc3 core on
5 STiH407 based platforms.
6
7 Required properties:
8 - compatible : must be "st,stih407-dwc3"
9 - reg : glue logic base address and USB syscfg ctrl register offset
10 - reg-names : should be "reg-glue" and "syscfg-reg"
11 - st,syscon : should be phandle to system configuration node which
12 encompasses the glue registers
13 - resets : list of phandle and reset specifier pairs. There should be two entries, one
14 for the powerdown and softreset lines of the usb3 IP
15 - reset-names : list of reset signal names. Names should be "powerdown" and "softreset"
16 See: Documentation/devicetree/bindings/reset/st,stih407-powerdown.yaml
17 See: Documentation/devicetree/bindings/reset/reset.txt
18
19 - #address-cells, #size-cells : should be '1' if the device has sub-nodes
20 with 'reg' property
21
22 - pinctl-names : A pinctrl state named "default" must be defined
23 See: Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt
24
25 - pinctrl-0 : Pin control group
26 See: Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt
27
28 - ranges : allows valid 1:1 translation between child's address space and
29 parent's address space
30
31 Sub-nodes:
32 The dwc3 core should be added as subnode to ST DWC3 glue as shown in the
33 example below. The DT binding details of dwc3 can be found in:
34 Documentation/devicetree/bindings/usb/snps,dwc3.yaml
35
36 NB: The dr_mode property described in [1] is NOT optional for this driver, as the default value
37 is "otg", which isn't supported by this SoC. Valid dr_mode values for dwc3-st are either "host"
38 or "device".
39
40 [1] Documentation/devicetree/bindings/usb/usb-drd.yaml
41
42 Example:
43
44 st_dwc3: dwc3@8f94000 {
45 compatible = "st,stih407-dwc3";
46 reg = <0x08f94000 0x1000>, <0x110 0x4>;
47 reg-names = "reg-glue", "syscfg-reg";
48 st,syscfg = <&syscfg_core>;
49 resets = <&powerdown STIH407_USB3_POWERDOWN>,
50 <&softreset STIH407_MIPHY2_SOFTRESET>;
51 reset-names = "powerdown", "softreset";
52 #address-cells = <1>;
53 #size-cells = <1>;
54 pinctrl-names = "default";
55 pinctrl-0 = <&pinctrl_usb3>;
56 ranges;
57
58 dwc3: dwc3@9900000 {
59 compatible = "snps,dwc3";
60 reg = <0x09900000 0x100000>;
61 interrupts = <GIC_SPI 155 IRQ_TYPE_NONE>;
62 dr_mode = "host";
63 phy-names = "usb2-phy", "usb3-phy";
64 phys = <&usb2_picophy2>, <&phy_port2 PHY_TYPE_USB3>;
65 };
66 };
67

3. 한국어 전문 번역

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

STiH407 DWC3 glue logic

1-6

이 문서는 `dwc3-st` driver의 매개변수를 설명합니다. 이 driver는 STiH407 기반 platform에서 DWC3 core를 구성하는 glue logic을 제어합니다.

Glue register, reset과 pin control

7-30

`compatible`은 `st,stih407-dwc3`이어야 합니다. `reg`에는 glue logic base address와 USB syscfg control register offset을 넣고, `reg-names`는 `reg-glue`, `syscfg-reg` 순서입니다. 원문 요구 사항의 `st,syscon`은 glue register를 포함하는 system configuration node의 phandle입니다.

`resets`에는 USB3 IP의 powerdown line과 softreset line을 위한 phandle·reset specifier 쌍 두 개가 필요하며 이름은 `powerdown`, `softreset`입니다. 관련 binding 경로는 `Documentation/devicetree/bindings/reset/st,stih407-powerdown.yaml`과 `Documentation/devicetree/bindings/reset/reset.txt`입니다.

`reg`를 가진 sub-node가 있으면 `#address-cells`와 `#size-cells`는 1입니다. 원문에 적힌 `pinctl-names`의 `default` state와 `pinctrl-0` pin control group이 필요합니다. `ranges`는 child와 parent address space 사이의 유효한 1:1 translation을 허용합니다.

Required properties:
 - compatible        : must be "st,stih407-dwc3"
 - reg                : glue logic base address and USB syscfg ctrl register offset
 - reg-names        : should be "reg-glue" and "syscfg-reg"
 - st,syscon        : should be phandle to system configuration node which
                  encompasses the glue registers
 - resets        : list of phandle and reset specifier pairs. There should be two entries, one
                  for the powerdown and softreset lines of the usb3 IP
 - reset-names        : list of reset signal names. Names should be "powerdown" and "softreset"
See: Documentation/devicetree/bindings/reset/st,stih407-powerdown.yaml
See: Documentation/devicetree/bindings/reset/reset.txt

 - #address-cells, #size-cells : should be '1' if the device has sub-nodes
   with 'reg' property

 - pinctl-names        : A pinctrl state named "default" must be defined
See: Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt

 - pinctrl-0        : Pin control group
See: Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt

 - ranges        : allows valid 1:1 translation between child's address space and
                  parent's address space

DWC3 sub-node와 필수 dr_mode

31-41

ST DWC3 glue 아래에는 예제처럼 DWC3 core를 sub-node로 추가해야 하며 상세 binding은 `Documentation/devicetree/bindings/usb/snps,dwc3.yaml`에 있습니다.

이 driver에서 `dr_mode`는 선택 사항이 아닙니다. 기본값 `otg`를 이 SoC가 지원하지 않으므로 `host` 또는 `device`를 명시해야 합니다. 이 속성의 공통 정의는 `Documentation/devicetree/bindings/usb/usb-drd.yaml`을 참조합니다.

ST glue와 host-mode core 예제

42-66

예제 glue node는 두 register 영역과 `reg-glue`·`syscfg-reg` 이름, system configuration phandle, powerdown·softreset 두 reset, default pinctrl, 빈 `ranges`를 설정합니다. 예제에는 요구 사항의 `st,syscon`과 달리 원문 그대로 `st,syscfg`가 쓰였습니다.

child DWC3 core는 `snps,dwc3`, 0x100000-byte register 영역, GIC SPI 155, host mode, USB2·USB3 PHY 두 개를 사용합니다.

Example:

st_dwc3: dwc3@8f94000 {
        compatible        = "st,stih407-dwc3";
        reg                = <0x08f94000 0x1000>, <0x110 0x4>;
        reg-names        = "reg-glue", "syscfg-reg";
        st,syscfg        = <&syscfg_core>;
        resets                = <&powerdown STIH407_USB3_POWERDOWN>,
                          <&softreset STIH407_MIPHY2_SOFTRESET>;
        reset-names        = "powerdown", "softreset";
        #address-cells        = <1>;
        #size-cells        = <1>;
        pinctrl-names        = "default";
        pinctrl-0        = <&pinctrl_usb3>;
        ranges;

        dwc3: dwc3@9900000 {
                compatible        = "snps,dwc3";
                reg                = <0x09900000 0x100000>;
                interrupts        = <GIC_SPI 155 IRQ_TYPE_NONE>;
                dr_mode                = "host";
                phy-names        = "usb2-phy", "usb3-phy";
                phys                = <&usb2_picophy2>, <&phy_port2 PHY_TYPE_USB3>;
        };
};