Documentation/devicetree/bindings/timer/img,pistachio-gptimer.yaml GitHub 원문 ↗

Linux 6.18.37 · Devicetree Bindings / Timer

Pistachio General-purpose Timer

Pistachio timer의 네 IRQ, 세 clock과 peripheral syscon을 설명합니다.

Source pathDocumentation/devicetree/bindings/timer/img,pistachio-gptimer.yaml
Source versionLinux v6.18.37
TranslationDUJINLABS 전문 번역 + 해설

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

1. 요약·해설

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

요약과 해설

img,pistachio-gptimer.yaml:1-69

Pistachio timer의 네 IRQ, 세 clock과 peripheral syscon을 설명합니다. 접을 수 있는 영어 원문 전체와 한국어 전문 번역을 함께 제공하며 compatible, interrupt, clock, register, phandle, 수치와 줄 좌표를 원형대로 보존합니다.

2. 영어 원문 전체

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

원문 전체 펼치기
1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2 %YAML 1.2
3 ---
4 $id: http://devicetree.org/schemas/img,pistachio-gptimer.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
6
7 title: Pistachio general-purpose timer
8
9 maintainers:
10 - Ezequiel Garcia <[email protected]>
11
12 properties:
13 compatible:
14 const: img,pistachio-gptimer
15
16 reg:
17 maxItems: 1
18
19 interrupts:
20 items:
21 - description: Timer0 interrupt
22 - description: Timer1 interrupt
23 - description: Timer2 interrupt
24 - description: Timer3 interrupt
25
26 clocks:
27 items:
28 - description: Fast counter clock
29 - description: Slow counter clock
30 - description: Interface clock
31
32 clock-names:
33 items:
34 - const: fast
35 - const: slow
36 - const: sys
37
38 img,cr-periph:
39 description: Peripheral control syscon phandle
40 $ref: /schemas/types.yaml#/definitions/phandle
41
42 required:
43 - compatible
44 - reg
45 - interrupts
46 - clocks
47 - clock-names
48 - img,cr-periph
49
50 additionalProperties: false
51
52 examples:
53 - |
54 #include <dt-bindings/interrupt-controller/mips-gic.h>
55 #include <dt-bindings/clock/pistachio-clk.h>
56
57 timer@18102000 {
58 compatible = "img,pistachio-gptimer";
59 reg = <0x18102000 0x100>;
60 interrupts = <GIC_SHARED 60 IRQ_TYPE_LEVEL_HIGH>,
61 <GIC_SHARED 61 IRQ_TYPE_LEVEL_HIGH>,
62 <GIC_SHARED 62 IRQ_TYPE_LEVEL_HIGH>,
63 <GIC_SHARED 63 IRQ_TYPE_LEVEL_HIGH>;
64 clocks = <&clk_periph PERIPH_CLK_COUNTER_FAST>,
65 <&clk_periph PERIPH_CLK_COUNTER_SLOW>,
66 <&cr_periph SYS_CLK_TIMER>;
67 clock-names = "fast", "slow", "sys";
68 img,cr-periph = <&cr_periph>;
69 };
70

3. 한국어 전문 번역

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

Pistachio general-purpose timer

1-11

GPL-2.0-only 또는 BSD-2-Clause 라이선스의 이 스키마는 Imagination Technologies Pistachio general-purpose timer를 정의합니다. Maintainer는 Ezequiel Garcia입니다.

네 timer IRQ와 세 clock

12-51

`compatible`은 `img,pistachio-gptimer`이고 `reg`는 최대 한 항목입니다. `interrupts`는 timer0·timer1·timer2·timer3 interrupt 네 개를 순서대로 담습니다. `clocks`는 fast counter, slow counter, interface clock 세 개이며 대응하는 `clock-names`는 `fast`, `slow`, `sys`입니다. `img,cr-periph`는 peripheral control syscon phandle입니다. 이 여섯 속성이 모두 필수이며 추가 속성은 허용되지 않습니다.

properties:
  compatible:
    const: img,pistachio-gptimer

  reg:
    maxItems: 1

  interrupts:
    items:
      - description: Timer0 interrupt
      - description: Timer1 interrupt
      - description: Timer2 interrupt
      - description: Timer3 interrupt

  clocks:
    items:
      - description: Fast counter clock
      - description: Slow counter clock
      - description: Interface clock

  clock-names:
    items:
      - const: fast
      - const: slow
      - const: sys

  img,cr-periph:
    description: Peripheral control syscon phandle
    $ref: /schemas/types.yaml#/definitions/phandle

required:
  - compatible
  - reg
  - interrupts
  - clocks
  - clock-names
  - img,cr-periph

additionalProperties: false

Pistachio GIC·clock 예제

52-69

예제는 `timer@18102000`에 0x100-byte register 영역을 두고 GIC shared interrupt 60·61·62·63을 level-high로 지정합니다. `PERIPH_CLK_COUNTER_FAST`, `PERIPH_CLK_COUNTER_SLOW`, `SYS_CLK_TIMER`를 각각 `fast`, `slow`, `sys`에 연결하고 `cr_periph`를 peripheral control syscon으로 참조합니다.

examples:
  - |
    #include <dt-bindings/interrupt-controller/mips-gic.h>
    #include <dt-bindings/clock/pistachio-clk.h>

    timer@18102000 {
        compatible = "img,pistachio-gptimer";
        reg = <0x18102000 0x100>;
        interrupts = <GIC_SHARED 60 IRQ_TYPE_LEVEL_HIGH>,
                     <GIC_SHARED 61 IRQ_TYPE_LEVEL_HIGH>,
                     <GIC_SHARED 62 IRQ_TYPE_LEVEL_HIGH>,
                     <GIC_SHARED 63 IRQ_TYPE_LEVEL_HIGH>;
        clocks = <&clk_periph PERIPH_CLK_COUNTER_FAST>,
                 <&clk_periph PERIPH_CLK_COUNTER_SLOW>,
                 <&cr_periph SYS_CLK_TIMER>;
        clock-names = "fast", "slow", "sys";
        img,cr-periph = <&cr_periph>;
    };