요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
%YAML 1.2
---
$id: http://devicetree.org/schemas/usb/cdns,usb3.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: Cadence USBSS-DRD controller
maintainers:
- Pawel Laszczak <pawell@cadence.com>
properties:
compatible:
const: cdns,usb3
reg:
items:
- description: OTG controller registers
- description: XHCI Host controller registers
- description: DEVICE controller registers
reg-names:
items:
- const: otg
- const: xhci
- const: dev
interrupts:
minItems: 3
items:
- description: XHCI host controller interrupt
- description: Device controller interrupt
- description: OTG/DRD controller interrupt
- description: interrupt used to wake up core, e.g when usbcmd.rs is
cleared by xhci core, this interrupt is optional
interrupt-names:
minItems: 3
items:
- const: host
- const: peripheral
- const: otg
- const: wakeup
port:
$ref: /schemas/graph.yaml#/properties/port
description:
This port is used with the 'usb-role-switch' property to connect the
cdns3 to type C connector.
maximum-speed:
enum: [super-speed, high-speed, full-speed]
phys:
minItems: 1
maxItems: 2
phy-names:
minItems: 1
maxItems: 2
items:
anyOf:
- const: cdns3,usb2-phy
- const: cdns3,usb3-phy
cdns,on-chip-buff-size:
description:
size of memory intended as internal memory for endpoints
buffers expressed in KB
$ref: /schemas/types.yaml#/definitions/uint16
cdns,phyrst-a-enable:
description: Enable resetting of PHY if Rx fail is detected
type: boolean
dependencies:
port: [ usb-role-switch ]
required:
- compatible
- reg
- reg-names
- interrupts
- interrupt-names
allOf:
- $ref: usb-drd.yaml#
unevaluatedProperties: false
examples:
- |
#include <dt-bindings/interrupt-controller/arm-gic.h>
bus {
#address-cells = <2>;
#size-cells = <2>;
usb@6000000 {
compatible = "cdns,usb3";
reg = <0x00 0x6000000 0x00 0x10000>,
<0x00 0x6010000 0x00 0x10000>,
<0x00 0x6020000 0x00 0x10000>;
reg-names = "otg", "xhci", "dev";
interrupts = <GIC_SPI 96 IRQ_TYPE_LEVEL_HIGH>,
<GIC_SPI 102 IRQ_TYPE_LEVEL_HIGH>,
<GIC_SPI 120 IRQ_TYPE_LEVEL_HIGH>;
interrupt-names = "host", "peripheral", "otg";
maximum-speed = "super-speed";
dr_mode = "otg";
};
};
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
Cadence USBSS-DRD controller
1-11GPL-2.0-only 또는 BSD-2-Clause 라이선스의 이 schema는 Cadence USBSS-DRD controller를 정의합니다. 관리자는 Pawel Laszczak입니다.
세 register 영역과 interrupt
12-44`compatible`은 `cdns,usb3`입니다. `reg`는 OTG, XHCI host, DEVICE controller register 영역 3개이고 `reg-names`는 `otg`, `xhci`, `dev` 순서입니다.
Interrupt는 최소 3개입니다. 순서대로 XHCI host, device, OTG/DRD interrupt가 필수이고 네 번째 wakeup interrupt는 선택 사항입니다. Wakeup interrupt는 예를 들어 XHCI core가 `usbcmd.rs`를 clear할 때 core를 깨우는 데 사용합니다. 이름은 `host`, `peripheral`, `otg`, 선택적인 `wakeup` 순서입니다.
properties:
compatible:
const: cdns,usb3
reg:
items:
- description: OTG controller registers
- description: XHCI Host controller registers
- description: DEVICE controller registers
reg-names:
items:
- const: otg
- const: xhci
- const: dev
interrupts:
minItems: 3
items:
- description: XHCI host controller interrupt
- description: Device controller interrupt
- description: OTG/DRD controller interrupt
- description: interrupt used to wake up core, e.g when usbcmd.rs is
cleared by xhci core, this interrupt is optional
interrupt-names:
minItems: 3
items:
- const: host
- const: peripheral
- const: otg
- const: wakeup
Role switch, 속도, PHY와 endpoint buffer
45-75`port`는 graph schema의 port를 따르며 `usb-role-switch`와 함께 Cadence USB3 controller를 Type-C connector에 연결합니다. `maximum-speed`는 `super-speed`, `high-speed`, `full-speed` 중 하나입니다.
PHY는 1~2개이고 이름도 1~2개입니다. 각 이름은 `cdns3,usb2-phy` 또는 `cdns3,usb3-phy`입니다. `cdns,on-chip-buff-size`는 endpoint buffer용 내부 memory 크기를 KB 단위 uint16으로 지정합니다. Boolean `cdns,phyrst-a-enable`은 RX 실패를 감지했을 때 PHY reset을 활성화합니다.
port:
$ref: /schemas/graph.yaml#/properties/port
description:
This port is used with the 'usb-role-switch' property to connect the
cdns3 to type C connector.
maximum-speed:
enum: [super-speed, high-speed, full-speed]
phys:
minItems: 1
maxItems: 2
phy-names:
minItems: 1
maxItems: 2
items:
anyOf:
- const: cdns3,usb2-phy
- const: cdns3,usb3-phy
cdns,on-chip-buff-size:
description:
size of memory intended as internal memory for endpoints
buffers expressed in KB
$ref: /schemas/types.yaml#/definitions/uint16
cdns,phyrst-a-enable:
description: Enable resetting of PHY if Rx fail is detected
type: boolean
Dependency와 DRD 공통 schema
76-90`port`를 사용하려면 `usb-role-switch`가 필요합니다. 필수 속성은 `compatible`, `reg`, `reg-names`, `interrupts`, `interrupt-names`입니다. 공통 `usb-drd.yaml`을 참조하며 평가되지 않은 추가 속성은 허용하지 않습니다.
dependencies:
port: [ usb-role-switch ]
required:
- compatible
- reg
- reg-names
- interrupts
- interrupt-names
allOf:
- $ref: usb-drd.yaml#
unevaluatedProperties: false
Cadence DRD 예제
91-111예제 `usb@6000000`은 OTG, XHCI, device에 각각 0x10000-byte register 영역을 배정합니다. Level-high GIC SPI 96, 102, 120은 각각 `host`, `peripheral`, `otg` interrupt입니다.
최대 속도는 `super-speed`이고 `dr_mode`는 `otg`입니다. 예제에는 선택적인 wakeup interrupt나 PHY가 없습니다.
examples:
- |
#include <dt-bindings/interrupt-controller/arm-gic.h>
bus {
#address-cells = <2>;
#size-cells = <2>;
usb@6000000 {
compatible = "cdns,usb3";
reg = <0x00 0x6000000 0x00 0x10000>,
<0x00 0x6010000 0x00 0x10000>,
<0x00 0x6020000 0x00 0x10000>;
reg-names = "otg", "xhci", "dev";
interrupts = <GIC_SPI 96 IRQ_TYPE_LEVEL_HIGH>,
<GIC_SPI 102 IRQ_TYPE_LEVEL_HIGH>,
<GIC_SPI 120 IRQ_TYPE_LEVEL_HIGH>;
interrupt-names = "host", "peripheral", "otg";
maximum-speed = "super-speed";
dr_mode = "otg";
};
};
요약과 해설
cdns,usb3.yaml:1-111Cadence USBSS-DRD의 OTG·XHCI·device resource, Type-C role switch, PHY와 endpoint buffer 속성을 설명합니다. 접을 수 있는 영어 원문 전체와 한국어 전문 번역을 함께 제공하며, compatible, register, clock, interrupt, GPIO, PHY, endpoint, source path와 원문 줄 좌표를 원형대로 보존합니다.