요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
* Renesas "Type-AXI" NBPFAXI* DMA controllers
* DMA controller
Required properties
- compatible: must be one of
"renesas,nbpfaxi64dmac1b4"
"renesas,nbpfaxi64dmac1b8"
"renesas,nbpfaxi64dmac1b16"
"renesas,nbpfaxi64dmac4b4"
"renesas,nbpfaxi64dmac4b8"
"renesas,nbpfaxi64dmac4b16"
"renesas,nbpfaxi64dmac8b4"
"renesas,nbpfaxi64dmac8b8"
"renesas,nbpfaxi64dmac8b16"
- #dma-cells: must be 2: the first integer is a terminal number, to which this
slave is connected, the second one is flags. Flags is a bitmask
with the following bits defined:
#define NBPF_SLAVE_RQ_HIGH 1
#define NBPF_SLAVE_RQ_LOW 2
#define NBPF_SLAVE_RQ_LEVEL 4
Optional properties:
- max-burst-mem-read: limit burst size for memory reads
(DMA_MEM_TO_MEM/DMA_MEM_TO_DEV) to this value, specified in bytes, rather
than using the maximum burst size allowed by the hardware's buffer size.
- max-burst-mem-write: limit burst size for memory writes
(DMA_DEV_TO_MEM/DMA_MEM_TO_MEM) to this value, specified in bytes, rather
than using the maximum burst size allowed by the hardware's buffer size.
If both max-burst-mem-read and max-burst-mem-write are set, DMA_MEM_TO_MEM
will use the lower value.
You can use dma-channels and dma-requests as described in dma.txt, although they
won't be used, this information is derived from the compatibility string.
Example:
dma: dma-controller@48000000 {
compatible = "renesas,nbpfaxi64dmac8b4";
reg = <0x48000000 0x400>;
interrupts = <0 12 0x4
0 13 0x4
0 14 0x4
0 15 0x4
0 16 0x4
0 17 0x4
0 18 0x4
0 19 0x4>;
#dma-cells = <2>;
dma-channels = <8>;
dma-requests = <8>;
};
* DMA client
Required properties:
dmas and dma-names are required, as described in dma.txt.
Example:
#include <dt-bindings/dma/nbpfaxi.h>
...
dmas = <&dma 0 (NBPF_SLAVE_RQ_HIGH | NBPF_SLAVE_RQ_LEVEL)
&dma 1 (NBPF_SLAVE_RQ_HIGH | NBPF_SLAVE_RQ_LEVEL)>;
dma-names = "rx", "tx";
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
Renesas NBPFAXI controller 속성
1-37Renesas Type-AXI NBPFAXI DMA controller 바인딩입니다. `compatible`은 `renesas,nbpfaxi64dmac1b4`, `renesas,nbpfaxi64dmac1b8`, `renesas,nbpfaxi64dmac1b16`, `renesas,nbpfaxi64dmac4b4`, `renesas,nbpfaxi64dmac4b8`, `renesas,nbpfaxi64dmac4b16`, `renesas,nbpfaxi64dmac8b4`, `renesas,nbpfaxi64dmac8b8`, `renesas,nbpfaxi64dmac8b16` variant 가운데 하나입니다.
`#dma-cells = <2>`이며 첫 integer는 slave가 연결된 terminal number, 두 번째는 flag bitmask입니다. `NBPF_SLAVE_RQ_HIGH`는 1, `NBPF_SLAVE_RQ_LOW`는 2, `NBPF_SLAVE_RQ_LEVEL`은 4입니다.
선택 `max-burst-mem-read`는 `DMA_MEM_TO_MEM`/`DMA_MEM_TO_DEV` memory read burst를 byte 단위로 제한하고, `max-burst-mem-write`는 `DMA_DEV_TO_MEM`/`DMA_MEM_TO_MEM` write burst를 제한합니다. 둘 다 설정하면 memory-to-memory transfer는 더 작은 값을 사용합니다.
`dma-channels`와 `dma-requests`를 `dma.txt` 형식으로 둘 수 있지만 사용되지는 않습니다. 이 정보는 compatible string에서 파생됩니다.
두 번째 DMA specifier cell에 넣는 request flag를 정리합니다.
Transfer direction에 따라 read/write 제한을 적용하며 memory-to-memory는 더 작은 값으로 제한합니다.
8-channel NBPFAXI 예제
38-55예제 `renesas,nbpfaxi64dmac8b4` controller는 0x400-byte register 영역, interrupt 12부터 19까지 여덟 개, 2-cell specifier와 8 channel/8 request를 선언합니다.
dma: dma-controller@48000000 {
compatible = "renesas,nbpfaxi64dmac8b4";
reg = <0x48000000 0x400>;
interrupts = <0 12 0x4
0 13 0x4
0 14 0x4
0 15 0x4
0 16 0x4
0 17 0x4
0 18 0x4
0 19 0x4>;
#dma-cells = <2>;
dma-channels = <8>;
dma-requests = <8>;
};
NBPFAXI RX/TX client
56-69DMA client에는 `dma.txt`에 설명된 `dmas`와 `dma-names`가 필요합니다. 예제는 `dt-bindings/dma/nbpfaxi.h`를 include하고 terminal 0/1에 `NBPF_SLAVE_RQ_HIGH | NBPF_SLAVE_RQ_LEVEL` flag를 적용해 RX/TX channel을 요청합니다.
#include <dt-bindings/dma/nbpfaxi.h>
...
dmas = <&dma 0 (NBPF_SLAVE_RQ_HIGH | NBPF_SLAVE_RQ_LEVEL)
&dma 1 (NBPF_SLAVE_RQ_HIGH | NBPF_SLAVE_RQ_LEVEL)>;
dma-names = "rx", "tx";
요약과 해설
renesas,nbpfaxi.txt:1-69Compatible variant, request flag와 RX/TX client를 설명합니다.