Documentation/devicetree/bindings/csky/cpus.txt GitHub 원문 ↗

Linux 6.18.37 · Devicetree Bindings

C-SKY CPU bindings

C-SKY SMP CPU container, core index와 compatible 바인딩입니다.

Source pathDocumentation/devicetree/bindings/csky/cpus.txt
Source versionLinux v6.18.37
TranslationDUJINLABS 전문 번역 + 해설

요약·해설, 영어 원문, 전체 번역을 구분해 실었습니다. API 이름, 코드 심벌, 소스 경로는 원문 표기를 유지합니다.

1. 요약·해설

원문의 핵심 내용을 정리하고 커널 프로그래밍에 필요한 설명을 덧붙였습니다. 아래의 전체 번역과는 별도로 작성한 해설입니다.

요약과 해설

cpus.txt:1-73

cpus container와 core별 필수 속성을 설명합니다.

2. 영어 원문 전체

번역에 사용한 Linux v6.18.37 원문입니다. 줄 번호는 해당 버전의 소스 파일을 기준으로 합니다.

원문 전체 펼치기
1 ==================
2 C-SKY CPU Bindings
3 ==================
4
5 The device tree allows to describe the layout of CPUs in a system through
6 the "cpus" node, which in turn contains a number of subnodes (ie "cpu")
7 defining properties for every cpu.
8
9 Only SMP system need to care about the cpus node and single processor
10 needn't define cpus node at all.
11
12 =====================================
13 cpus and cpu node bindings definition
14 =====================================
15
16 - cpus node
17
18 Description: Container of cpu nodes
19
20 The node name must be "cpus".
21
22 A cpus node must define the following properties:
23
24 - #address-cells
25 Usage: required
26 Value type: <u32>
27 Definition: must be set to 1
28 - #size-cells
29 Usage: required
30 Value type: <u32>
31 Definition: must be set to 0
32
33 - cpu node
34
35 Description: Describes one of SMP cores
36
37 PROPERTIES
38
39 - device_type
40 Usage: required
41 Value type: <string>
42 Definition: must be "cpu"
43 - reg
44 Usage: required
45 Value type: <u32>
46 Definition: CPU index
47 - compatible:
48 Usage: required
49 Value type: <string>
50 Definition: must contain "csky", eg:
51 "csky,610"
52 "csky,807"
53 "csky,810"
54 "csky,860"
55
56 Example:
57 --------
58
59 cpus {
60 #address-cells = <1>;
61 #size-cells = <0>;
62 cpu@0 {
63 device_type = "cpu";
64 reg = <0>;
65 status = "ok";
66 };
67
68 cpu@1 {
69 device_type = "cpu";
70 reg = <1>;
71 status = "ok";
72 };
73 };
74

3. 한국어 전문 번역

영어 원문의 문단 순서와 의미에 맞춰 전체 내용을 번역했습니다. 코드, 함수명, 코드 심벌, URL은 원문 표기를 유지합니다.

C-SKY CPU topology

1-15

C-SKY CPU 바인딩입니다. Device tree의 `cpus` node 아래 `cpu` subnode를 두어 system CPU layout과 각 CPU 속성을 기술합니다.

SMP system만 `cpus` node를 정의해야 하며 single-processor system은 이를 생략할 수 있습니다.

C-SKY CPU hierarchy
cpus#address-cells = 1, #size-cells = 0
cpu@0device_type + reg + compatible
cpu@NCPU index별 core

SMP topology는 하나의 container와 CPU index별 child로 표현합니다.

cpus 및 cpu node 속성

16-55

`cpus` container의 node 이름은 반드시 `cpus`입니다. 필수 u32 `#address-cells`는 1, `#size-cells`는 0입니다.

각 `cpu` node는 SMP core 하나를 나타냅니다. 필수 string `device_type`은 `cpu`, 필수 u32 `reg`는 CPU index입니다.

필수 string `compatible`에는 `csky`를 포함해야 하며 예시는 `csky,610`, `csky,807`, `csky,810`, `csky,860`입니다.

2-core C-SKY SMP 예제

56-73

예제는 address-cell 1, size-cell 0인 `cpus` container 아래 CPU index 0과 1을 두고 두 core의 status를 `ok`로 설정합니다.

cpus {
        #address-cells = <1>;
        #size-cells = <0>;
        cpu@0 {
                device_type = "cpu";
                reg = <0>;
                status = "ok";
        };

        cpu@1 {
                device_type = "cpu";
                reg = <1>;
                status = "ok";
        };
};