← Documents Documentation/devicetree/bindings/clock/clk-palmas-clk32kg-clocks.txt GitHub 원문 ↗

Linux 6.18.37 · Devicetree Bindings

Palmas 32 kHz clocks

Palmas KG/KG_AUDIO 32 kHz output과 외부 sleep control pin 바인딩입니다.

Source pathDocumentation/devicetree/bindings/clock/clk-palmas-clk32kg-clocks.txt
Source versionLinux v6.18.37
TranslationDUJINLABS 전문 번역 + 해설

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

1. 요약·해설

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

요약과 해설

clk-palmas-clk32kg-clocks.txt:1-35

ENABLE1, ENABLE2, NSLEEP 또는 register access 기반 clock 제어를 설명합니다.

2. 영어 원문 전체

번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.

원문 전체 펼치기
1 * Palmas 32KHz clocks *
2
3 Palmas device has two clock output pins for 32KHz, KG and KG_AUDIO.
4
5 This binding uses the common clock binding ./clock-bindings.txt.
6
7 Required properties:
8 - compatible : "ti,palmas-clk32kg" for clk32kg clock
9 "ti,palmas-clk32kgaudio" for clk32kgaudio clock
10 - #clock-cells : shall be set to 0.
11
12 Optional property:
13 - ti,external-sleep-control: The external enable input pins controlled the
14 enable/disable of clocks. The external enable input pins ENABLE1,
15 ENABLE2 and NSLEEP. The valid values for the external pins are:
16 PALMAS_EXT_CONTROL_PIN_ENABLE1 for ENABLE1 pin
17 PALMAS_EXT_CONTROL_PIN_ENABLE2 for ENABLE2 pin
18 PALMAS_EXT_CONTROL_PIN_NSLEEP for NSLEEP pin
19 Option 0 or missing this property means the clock is enabled/disabled
20 via register access and these pins do not have any control.
21 The macros of external control pins for DTS is defined at
22 dt-bindings/mfd/palmas.h
23
24 Example:
25 #include <dt-bindings/mfd/palmas.h>
26 ...
27 palmas: tps65913@58 {
28 ...
29 clk32kg: palmas_clk32k@0 {
30 compatible = "ti,palmas-clk32kg";
31 #clock-cells = <0>;
32 ti,external-sleep-control = <PALMAS_EXT_CONTROL_PIN_NSLEEP>;
33 };
34 ...
35 };
36

3. 한국어 전문 번역

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

Palmas 32 kHz output과 외부 sleep control

1-23

Palmas 32 kHz clock

Palmas 장치에는 32 kHz용 clock output pin `KG`와 `KG_AUDIO` 두 개가 있습니다. 이 바인딩은 공통 clock 바인딩 `./clock-bindings.txt`를 사용합니다.

`clk32kg` clock의 필수 `compatible`은 `ti,palmas-clk32kg`, `clk32kgaudio` clock은 `ti,palmas-clk32kgaudio`입니다. `#clock-cells`는 0으로 설정해야 합니다.

선택적 `ti,external-sleep-control`은 clock enable/disable을 제어하는 외부 enable input pin을 선택합니다.

유효한 값은 ENABLE1의 `PALMAS_EXT_CONTROL_PIN_ENABLE1`, ENABLE2의 `PALMAS_EXT_CONTROL_PIN_ENABLE2`, NSLEEP의 `PALMAS_EXT_CONTROL_PIN_NSLEEP`입니다.

값 0을 사용하거나 이 속성을 생략하면 register access로 clock을 enable/disable하며 외부 pin은 제어권을 갖지 않습니다. DTS용 macro는 `dt-bindings/mfd/palmas.h`에 정의되어 있습니다.

Palmas external sleep control
외부 pin제어 방식
PALMAS_EXT_CONTROL_PIN_ENABLE1ENABLE1외부 enable
PALMAS_EXT_CONTROL_PIN_ENABLE2ENABLE2외부 enable
PALMAS_EXT_CONTROL_PIN_NSLEEPNSLEEP외부 sleep
0 또는 생략없음Register access

외부 pin 선택 값과 clock 제어 방식을 정리합니다.

NSLEEP 제어 clk32kg 예

24-35

예제는 Palmas MFD 아래 0-cell `clk32kg` provider를 배치하고 NSLEEP pin으로 외부 sleep 제어를 선택합니다.

#include <dt-bindings/mfd/palmas.h>
...
palmas: tps65913@58 {
        ...
        clk32kg: palmas_clk32k@0 {
                compatible = "ti,palmas-clk32kg";
                #clock-cells = <0>;
                ti,external-sleep-control = <PALMAS_EXT_CONTROL_PIN_NSLEEP>;
        };
        ...
};