요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
# SPDX-License-Identifier: GPL-2.0
%YAML 1.2
---
$id: http://devicetree.org/schemas/timer/arm,arch_timer_mmio.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: ARM memory mapped architected timer
maintainers:
- Marc Zyngier <marc.zyngier@arm.com>
- Mark Rutland <mark.rutland@arm.com>
description: |+
ARM cores may have a memory mapped architected timer, which provides up to 8
frames with a physical and optional virtual timer per frame.
The memory mapped timer is attached to a GIC to deliver its interrupts via SPIs.
properties:
compatible:
items:
- enum:
- arm,armv7-timer-mem
reg:
maxItems: 1
description: The control frame base address
'#address-cells':
enum: [1, 2]
'#size-cells':
const: 1
ranges: true
clock-frequency:
description: The frequency of the main counter, in Hz. Should be present
only where necessary to work around broken firmware which does not configure
CNTFRQ on all CPUs to a uniform correct value. Use of this property is
strongly discouraged; fix your firmware unless absolutely impossible.
always-on:
type: boolean
description: If present, the timer is powered through an always-on power
domain, therefore it never loses context.
arm,cpu-registers-not-fw-configured:
type: boolean
description: Firmware does not initialize any of the generic timer CPU
registers, which contain their architecturally-defined reset values. Only
supported for 32-bit systems which follow the ARMv7 architected reset
values.
arm,no-tick-in-suspend:
type: boolean
description: The main counter does not tick when the system is in
low-power system suspend on some SoCs. This behavior does not match the
Architecture Reference Manual's specification that the system counter "must
be implemented in an always-on power domain."
patternProperties:
'^frame@[0-9a-f]+$':
type: object
additionalProperties: false
description: A timer node has up to 8 frame sub-nodes, each with the following properties.
properties:
frame-number:
$ref: /schemas/types.yaml#/definitions/uint32
minimum: 0
maximum: 7
interrupts:
minItems: 1
items:
- description: physical timer irq
- description: virtual timer irq
reg:
minItems: 1
items:
- description: 1st view base address
- description: 2nd optional view base address
required:
- frame-number
- interrupts
- reg
required:
- compatible
- reg
- '#address-cells'
- '#size-cells'
additionalProperties: false
examples:
- |
timer@f0000000 {
compatible = "arm,armv7-timer-mem";
#address-cells = <1>;
#size-cells = <1>;
ranges = <0 0xf0001000 0x1000>;
reg = <0xf0000000 0x1000>;
clock-frequency = <50000000>;
frame@0 {
frame-number = <0>;
interrupts = <0 13 0x8>,
<0 14 0x8>;
reg = <0x0000 0x1000>,
<0x1000 0x1000>;
};
frame@2000 {
frame-number = <1>;
interrupts = <0 15 0x8>;
reg = <0x2000 0x1000>;
};
};
...
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
ARM memory-mapped architected timer
1-18GPL-2.0 라이선스의 이 스키마는 ARM memory-mapped architected timer를 정의합니다. Timer는 최대 8개 frame을 제공하며 각 frame에는 physical timer와 선택적인 virtual timer가 있습니다. Memory-mapped timer는 GIC에 연결되어 SPI로 interrupt를 전달합니다. Maintainer는 Marc Zyngier와 Mark Rutland입니다.
Control frame과 firmware 우회 속성
19-61Compatible은 `arm,armv7-timer-mem`입니다. `reg`는 control frame base address 한 항목이고 `#address-cells`는 1 또는 2, `#size-cells`는 1이며 `ranges`를 사용합니다. `clock-frequency`는 main counter 주파수를 Hz로 지정하지만, firmware가 모든 CPU의 `CNTFRQ`를 동일하고 올바른 값으로 설정하지 못하는 경우에만 필요합니다. 사용은 강하게 권장되지 않으며 가능하면 firmware를 고쳐야 합니다.
`always-on`은 timer가 always-on power domain에서 동작해 context를 잃지 않음을 뜻합니다. `arm,cpu-registers-not-fw-configured`는 firmware가 generic timer CPU register를 초기화하지 않았음을 나타내며 ARMv7 architected reset value를 따르는 32-bit system에서만 지원됩니다. `arm,no-tick-in-suspend`는 일부 SoC에서 low-power system suspend 중 main counter가 멈춘다는 뜻이며, system counter가 always-on power domain에 있어야 한다는 Architecture Reference Manual 명세와 일치하지 않습니다.
properties:
compatible:
items:
- enum:
- arm,armv7-timer-mem
reg:
maxItems: 1
description: The control frame base address
'#address-cells':
enum: [1, 2]
'#size-cells':
const: 1
ranges: true
clock-frequency:
description: The frequency of the main counter, in Hz. Should be present
only where necessary to work around broken firmware which does not configure
CNTFRQ on all CPUs to a uniform correct value. Use of this property is
strongly discouraged; fix your firmware unless absolutely impossible.
always-on:
type: boolean
description: If present, the timer is powered through an always-on power
domain, therefore it never loses context.
arm,cpu-registers-not-fw-configured:
type: boolean
description: Firmware does not initialize any of the generic timer CPU
registers, which contain their architecturally-defined reset values. Only
supported for 32-bit systems which follow the ARMv7 architected reset
values.
arm,no-tick-in-suspend:
type: boolean
description: The main counter does not tick when the system is in
low-power system suspend on some SoCs. This behavior does not match the
Architecture Reference Manual's specification that the system counter "must
be implemented in an always-on power domain."
Frame 번호, IRQ와 view
62-97`frame@[0-9a-f]+` 하위 node는 최대 8개입니다. `frame-number`는 0부터 7이고, `interrupts`는 physical timer IRQ 뒤에 선택적인 virtual timer IRQ가 옵니다. `reg`는 first view base address 뒤에 선택적인 second view base address가 옵니다. 각 frame에는 `frame-number`, `interrupts`, `reg`가 필수입니다. 상위 node에는 `compatible`, `reg`, `#address-cells`, `#size-cells`가 필요하며 추가 속성은 허용되지 않습니다.
patternProperties:
'^frame@[0-9a-f]+$':
type: object
additionalProperties: false
description: A timer node has up to 8 frame sub-nodes, each with the following properties.
properties:
frame-number:
$ref: /schemas/types.yaml#/definitions/uint32
minimum: 0
maximum: 7
interrupts:
minItems: 1
items:
- description: physical timer irq
- description: virtual timer irq
reg:
minItems: 1
items:
- description: 1st view base address
- description: 2nd optional view base address
required:
- frame-number
- interrupts
- reg
required:
- compatible
- reg
- '#address-cells'
- '#size-cells'
additionalProperties: false
50MHz timer와 frame 0
98-115예제 상위 timer는 control frame `0xf0000000`, frame window `0xf0001000`, main counter 50000000Hz를 지정합니다. `frame@0`은 frame number 0, physical IRQ 13과 virtual IRQ 14, 그리고 `0x0000`·`0x1000`의 두 view를 갖습니다.
- |
timer@f0000000 {
compatible = "arm,armv7-timer-mem";
#address-cells = <1>;
#size-cells = <1>;
ranges = <0 0xf0001000 0x1000>;
reg = <0xf0000000 0x1000>;
clock-frequency = <50000000>;
frame@0 {
frame-number = <0>;
interrupts = <0 13 0x8>,
<0 14 0x8>;
reg = <0x0000 0x1000>,
<0x1000 0x1000>;
};
단일 view frame 1
116-123`frame@2000`은 frame number 1이며 physical IRQ 15 하나와 `0x2000`의 단일 view만 지정합니다. Virtual timer IRQ와 second view는 선택 사항이므로 생략됩니다.
frame@2000 {
frame-number = <1>;
interrupts = <0 15 0x8>;
reg = <0x2000 0x1000>;
};
};
...
요약과 해설
arm,arch_timer_mmio.yaml:1-123ARM memory-mapped timer의 control frame, view와 physical·virtual IRQ를 설명합니다. 접을 수 있는 영어 원문 전체와 한국어 전문 번역을 함께 제공하며 register, interrupt, clock, phandle, erratum, 수치와 줄 좌표를 원형대로 보존합니다.