요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/trigger-source/gpio-trigger.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: Generic trigger source using GPIO
description: A GPIO used as a trigger source.
maintainers:
- Jonathan Santos <Jonathan.Santos@analog.com>
properties:
compatible:
const: gpio-trigger
'#trigger-source-cells':
const: 0
gpios:
maxItems: 1
description: GPIO to be used as a trigger source.
required:
- compatible
- '#trigger-source-cells'
- gpios
additionalProperties: false
examples:
- |
#include <dt-bindings/gpio/gpio.h>
trigger {
compatible = "gpio-trigger";
#trigger-source-cells = <0>;
gpios = <&gpio1 15 GPIO_ACTIVE_HIGH>;
};
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
Generic GPIO trigger source
1-13GPL-2.0-only 또는 BSD-2-Clause 라이선스의 이 스키마는 GPIO 하나를 trigger source로 사용하는 generic provider를 정의합니다. Maintainer는 Jonathan Santos입니다.
GPIO와 zero-cell specifier
14-31`compatible`은 `gpio-trigger`입니다. `#trigger-source-cells`는 0이므로 consumer가 추가 argument를 전달하지 않습니다. `gpios`는 trigger source로 사용할 GPIO 한 개입니다. 세 속성이 모두 필수이며 추가 속성은 허용하지 않습니다.
properties:
compatible:
const: gpio-trigger
'#trigger-source-cells':
const: 0
gpios:
maxItems: 1
description: GPIO to be used as a trigger source.
required:
- compatible
- '#trigger-source-cells'
- gpios
additionalProperties: false
Active-high GPIO trigger
32-40예제 `trigger` node는 GPIO controller `gpio1`의 line 15를 active-high trigger source로 지정합니다.
examples:
- |
#include <dt-bindings/gpio/gpio.h>
trigger {
compatible = "gpio-trigger";
#trigger-source-cells = <0>;
gpios = <&gpio1 15 GPIO_ACTIVE_HIGH>;
};
요약과 해설
gpio-trigger.yaml:1-40GPIO를 argument 없는 generic trigger source로 사용하는 방법을 설명합니다. 접을 수 있는 영어 원문 전체와 한국어 전문 번역을 함께 제공하며 compatible, interrupt, register, GPIO, phandle, 수치와 줄 좌표를 원형대로 보존합니다.