← Documents Documentation/devicetree/bindings/watchdog/realtek,otto-wdt.yaml GitHub 원문 ↗

Linux 6.18.37 · Devicetree Bindings / Watchdog

Realtek Otto Watchdog

Realtek Otto 워치독의 두 timeout phase와 세 가지 reset mode를 설명합니다.

Source pathDocumentation/devicetree/bindings/watchdog/realtek,otto-wdt.yaml
Source versionLinux v6.18.37
TranslationDUJINLABS 전문 번역 + 해설

요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.

1. 요약·해설

원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.

요약과 해설

realtek,otto-wdt.yaml:1-90

Realtek Otto 워치독의 두 timeout phase와 세 가지 reset mode를 설명합니다. 접을 수 있는 영어 원문 전체와 한국어 전문 번역을 함께 제공하며, compatible, register, clock, interrupt, reset, timeout, 예제와 원문 줄 좌표를 원형대로 보존합니다.

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/watchdog/realtek,otto-wdt.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
6
7 title: Realtek Otto watchdog timer
8
9 maintainers:
10 - Sander Vanheule <[email protected]>
11
12 description: |
13 The timer has two timeout phases. Both phases have a maximum duration of 32
14 prescaled clock ticks, which is ca. 43s with a bus clock of 200MHz. The
15 minimum duration of each phase is one tick. Each phase can trigger an
16 interrupt, although the phase 2 interrupt will occur with the system reset.
17 - Phase 1: During this phase, the WDT can be pinged to reset the timeout.
18 - Phase 2: Starts after phase 1 has timed out, and only serves to give the
19 system some time to clean up, or notify others that it's going to reset.
20 During this phase, pinging the WDT has no effect, and a reset is
21 unavoidable, unless the WDT is disabled.
22
23 allOf:
24 - $ref: watchdog.yaml#
25
26 properties:
27 compatible:
28 enum:
29 - realtek,rtl8380-wdt
30 - realtek,rtl8390-wdt
31 - realtek,rtl9300-wdt
32 - realtek,rtl9310-wdt
33
34 reg:
35 maxItems: 1
36
37 clocks:
38 maxItems: 1
39
40 interrupts:
41 items:
42 - description: interrupt specifier for pretimeout
43 - description: interrupt specifier for timeout
44
45 interrupt-names:
46 items:
47 - const: phase1
48 - const: phase2
49
50 realtek,reset-mode:
51 $ref: /schemas/types.yaml#/definitions/string
52 description: |
53 Specify how the system is reset after a timeout. Defaults to "cpu" if
54 left unspecified.
55 oneOf:
56 - description: Reset the entire chip
57 const: soc
58 - description: |
59 Reset the CPU and IPsec engine, but leave other peripherals untouched
60 const: cpu
61 - description: |
62 Reset the execution pointer, but don't actually reset any hardware
63 const: software
64
65 required:
66 - compatible
67 - reg
68 - clocks
69 - interrupts
70 - interrupt-names
71
72 unevaluatedProperties: false
73
74 examples:
75 - |
76 watchdog: watchdog@3150 {
77 compatible = "realtek,rtl8380-wdt";
78 reg = <0x3150 0xc>;
79
80 realtek,reset-mode = "soc";
81
82 clocks = <&lxbus_clock>;
83 timeout-sec = <20>;
84
85 interrupt-parent = <&rtlintc>;
86 interrupt-names = "phase1", "phase2";
87 interrupts = <19>, <18>;
88 };
89
90 ...
91

3. 한국어 전문 번역

영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.

Realtek Otto 워치독

1-11

GPL-2.0-only 또는 BSD-2-Clause로 배포되는 이 스키마는 Realtek Otto Watchdog Timer를 정의합니다. 관리자는 Sander Vanheule입니다.

두 단계 timeout 동작

12-25

timer에는 두 timeout phase가 있습니다. 각 phase의 최대 길이는 prescaled clock 32 tick이며 bus clock이 200MHz이면 약 43초입니다. 각 phase의 최소 길이는 1 tick이고 둘 다 interrupt를 발생시킬 수 있지만 phase 2 interrupt는 system reset과 함께 발생합니다.

Phase 1에서는 WDT를 ping해 timeout을 다시 시작할 수 있습니다. Phase 2는 phase 1 timeout 뒤 시작되어 시스템이 정리하거나 다른 구성 요소에 reset 예정임을 알릴 시간을 줍니다. 이 단계에서는 ping이 효과가 없고 WDT를 disable하지 않는 한 reset을 피할 수 없습니다.

지원 SoC와 phase interrupt

26-49

`compatible`은 `realtek,rtl8380-wdt`, `realtek,rtl8390-wdt`, `realtek,rtl9300-wdt`, `realtek,rtl9310-wdt` 가운데 하나입니다. `reg`와 `clocks`는 각각 항목 하나만 받습니다.

`interrupts`는 pretimeout과 timeout specifier를 이 순서로 제공하며 `interrupt-names`는 각각 `phase1`, `phase2`입니다.

properties:
  compatible:
    enum:
      - realtek,rtl8380-wdt
      - realtek,rtl8390-wdt
      - realtek,rtl9300-wdt
      - realtek,rtl9310-wdt

  reg:
    maxItems: 1

  clocks:
    maxItems: 1

  interrupts:
    items:
      - description: interrupt specifier for pretimeout
      - description: interrupt specifier for timeout

  interrupt-names:
    items:
      - const: phase1
      - const: phase2

reset 범위를 선택하는 reset-mode

50-73

`realtek,reset-mode`는 timeout 뒤 시스템을 reset하는 방법을 지정하는 문자열이며 생략하면 `cpu`가 기본입니다. `soc`는 chip 전체를 reset합니다. `cpu`는 CPU와 IPsec engine만 reset하고 다른 주변 장치는 유지합니다. `software`는 execution pointer만 reset하고 실제 hardware는 reset하지 않습니다.

`compatible`, `reg`, `clocks`, `interrupts`, `interrupt-names`가 모두 필수이며 평가되지 않은 속성은 허용하지 않습니다.

  realtek,reset-mode:
    $ref: /schemas/types.yaml#/definitions/string
    description: |
      Specify how the system is reset after a timeout. Defaults to "cpu" if
      left unspecified.
    oneOf:
      - description: Reset the entire chip
        const: soc
      - description: |
          Reset the CPU and IPsec engine, but leave other peripherals untouched
        const: cpu
      - description: |
          Reset the execution pointer, but don't actually reset any hardware
        const: software

required:
  - compatible
  - reg
  - clocks
  - interrupts
  - interrupt-names

unevaluatedProperties: false

RTL8380 SoC reset 예제

74-90

예제는 주소 `0x3150`, 크기 `0xc`인 RTL8380 워치독의 reset mode를 `soc`로 설정합니다. `lxbus_clock`, timeout 20초, phase1·phase2 interrupt 19와 18을 연결합니다.

examples:
  - |
    watchdog: watchdog@3150 {
        compatible = "realtek,rtl8380-wdt";
        reg = <0x3150 0xc>;

        realtek,reset-mode = "soc";

        clocks = <&lxbus_clock>;
        timeout-sec = <20>;

        interrupt-parent = <&rtlintc>;
        interrupt-names = "phase1", "phase2";
        interrupts = <19>, <18>;
    };

...