요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
* Freescale Communications Processor Module
NOTE: This is an interim binding, and will likely change slightly,
as more devices are supported. The QE bindings especially are
incomplete.
* Root CPM node
Properties:
- compatible : "fsl,cpm1", "fsl,cpm2", or "fsl,qe".
- reg : A 48-byte region beginning with CPCR.
Example:
cpm@119c0 {
#address-cells = <1>;
#size-cells = <1>;
#interrupt-cells = <2>;
compatible = "fsl,mpc8272-cpm", "fsl,cpm2";
reg = <119c0 30>;
}
* Properties common to multiple CPM/QE devices
- fsl,cpm-command : This value is ORed with the opcode and command flag
to specify the device on which a CPM command operates.
- fsl,cpm-brg : Indicates which baud rate generator the device
is associated with. If absent, an unused BRG
should be dynamically allocated. If zero, the
device uses an external clock rather than a BRG.
- reg : Unless otherwise specified, the first resource represents the
scc/fcc/ucc registers, and the second represents the device's
parameter RAM region (if it has one).
* Multi-User RAM (MURAM)
The multi-user/dual-ported RAM is expressed as a bus under the CPM node.
Ranges must be set up subject to the following restrictions:
- Children's reg nodes must be offsets from the start of all muram, even
if the user-data area does not begin at zero.
- If multiple range entries are used, the difference between the parent
address and the child address must be the same in all, so that a single
mapping can cover them all while maintaining the ability to determine
CPM-side offsets with pointer subtraction. It is recommended that
multiple range entries not be used.
- A child address of zero must be translatable, even if no reg resources
contain it.
A child "data" node must exist, compatible with "fsl,cpm-muram-data", to
indicate the portion of muram that is usable by the OS for arbitrary
purposes. The data node may have an arbitrary number of reg resources,
all of which contribute to the allocatable muram pool.
Example, based on mpc8272:
muram@0 {
#address-cells = <1>;
#size-cells = <1>;
ranges = <0 0 10000>;
data@0 {
compatible = "fsl,cpm-muram-data";
reg = <0 2000 9800 800>;
};
};
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
임시 CPM/QE 바인딩
1-5이 문서는 임시 바인딩이며 지원 장치가 늘어나면 일부가 변경될 가능성이 있습니다. 특히 QE 바인딩은 아직 완전하지 않습니다.
루트 CPM 노드
6-20루트 CPM 노드의 `compatible`은 `fsl,cpm1`, `fsl,cpm2`, `fsl,qe` 가운데 하나이며 `reg`는 CPCR에서 시작하는 48바이트 영역입니다.
예제는 MPC8272 CPM2 노드의 address·size·interrupt cell 수와 CPCR register range를 정의합니다.
cpm@119c0 {
#address-cells = <1>;
#size-cells = <1>;
#interrupt-cells = <2>;
compatible = "fsl,mpc8272-cpm", "fsl,cpm2";
reg = <119c0 30>;
}
공통 CPM/QE 장치 속성
21-34`fsl,cpm-command` 값은 opcode 및 command flag와 OR되어 CPM command가 작동할 장치를 지정합니다.
`fsl,cpm-brg`는 장치와 연결된 baud rate generator를 지정합니다. 없으면 사용하지 않는 BRG를 동적으로 할당하고, 값이 0이면 BRG 대신 외부 clock을 사용합니다.
별도 지정이 없으면 첫 `reg` resource는 SCC/FCC/UCC register이고 둘째는 장치에 존재하는 parameter RAM 영역입니다.
Multi-User RAM 주소 규칙
35-55multi-user 또는 dual-ported RAM인 MURAM은 CPM 노드 아래의 bus로 표현합니다.
자식의 `reg` 주소는 user-data 영역이 0에서 시작하지 않더라도 전체 MURAM 시작점 기준 오프셋이어야 합니다. 여러 `ranges` entry를 사용한다면 모든 entry에서 parent 주소와 child 주소의 차이가 같아야 하나, 여러 entry를 사용하지 않는 것이 권장됩니다.
어떤 `reg` resource도 child 주소 0을 포함하지 않더라도 주소 0은 변환 가능해야 합니다.
OS가 임의 용도로 사용할 수 있는 MURAM 부분을 나타내려면 `fsl,cpm-muram-data` 호환 `data` 자식 노드가 필요합니다. 이 노드는 임의 개수의 `reg` resource를 가질 수 있으며 모두 할당 가능한 MURAM pool에 포함됩니다.
MPC8272 MURAM 예제
56-67예제는 0x10000 크기 MURAM bus와 두 구간으로 구성된 OS 할당 가능 data pool을 정의합니다.
muram@0 {
#address-cells = <1>;
#size-cells = <1>;
ranges = <0 0 10000>;
data@0 {
compatible = "fsl,cpm-muram-data";
reg = <0 2000 9800 800>;
};
};
요약과 해설
cpm.txt:1-67CPM/QE 내부 자원과 자식 장치의 연결 규칙을 먼저 해설하고, 접을 수 있는 영어 원문 전체와 원문 줄 좌표를 보존한 한국어 전문 번역을 제공합니다.