요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
Marvell 8897/8997 (sd8897/sd8997) bluetooth devices (SDIO or USB based)
------
The 8997 devices supports multiple interfaces. When used on SDIO interfaces,
the btmrvl driver is used and when used on USB interface, the btusb driver is
used.
Required properties:
- compatible : should be one of the following:
* "marvell,sd8897-bt" (for SDIO)
* "marvell,sd8997-bt" (for SDIO)
* "usb1286,204e" (for USB)
Optional properties:
- marvell,cal-data: Calibration data downloaded to the device during
initialization. This is an array of 28 values(u8).
This is only applicable to SDIO devices.
- marvell,wakeup-pin: It represents wakeup pin number of the bluetooth chip.
firmware will use the pin to wakeup host system (u16).
- marvell,wakeup-gap-ms: wakeup gap represents wakeup latency of the host
platform. The value will be configured to firmware. This
is needed to work chip's sleep feature as expected (u16).
- interrupt-names: Used only for USB based devices (See below)
- interrupts : specifies the interrupt pin number to the cpu. For SDIO, the
driver will use the first interrupt specified in the interrupt
array. For USB based devices, the driver will use the interrupt
named "wakeup" from the interrupt-names and interrupt arrays.
The driver will request an irq based on this interrupt number.
During system suspend, the irq will be enabled so that the
bluetooth chip can wakeup host platform under certain
conditions. During system resume, the irq will be disabled
to make sure unnecessary interrupt is not received.
Example:
IRQ pin 119 is used as system wakeup source interrupt.
wakeup pin 13 and gap 100ms are configured so that firmware can wakeup host
using this device side pin and wakeup latency.
Example for SDIO device follows (calibration data is also available in
below example).
&mmc3 {
vmmc-supply = <&wlan_en_reg>;
bus-width = <4>;
cap-power-off-card;
keep-power-in-suspend;
#address-cells = <1>;
#size-cells = <0>;
btmrvl: bluetooth@2 {
compatible = "marvell,sd8897-bt";
reg = <2>;
interrupt-parent = <&pio>;
interrupts = <119 IRQ_TYPE_LEVEL_LOW>;
marvell,cal-data = /bits/ 8 <
0x37 0x01 0x1c 0x00 0xff 0xff 0xff 0xff 0x01 0x7f 0x04 0x02
0x00 0x00 0xba 0xce 0xc0 0xc6 0x2d 0x00 0x00 0x00 0x00 0x00
0x00 0x00 0xf0 0x00>;
marvell,wakeup-pin = /bits/ 16 <0x0d>;
marvell,wakeup-gap-ms = /bits/ 16 <0x64>;
};
};
Example for USB device:
&usb_host1_ohci {
#address-cells = <1>;
#size-cells = <0>;
mvl_bt1: bt@1 {
compatible = "usb1286,204e";
reg = <1>;
interrupt-parent = <&gpio0>;
interrupt-names = "wakeup";
interrupts = <119 IRQ_TYPE_LEVEL_LOW>;
marvell,wakeup-pin = /bits/ 16 <0x0d>;
marvell,wakeup-gap-ms = /bits/ 16 <0x64>;
};
};
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
Marvell 8897/8997 Bluetooth
1-6Marvell 8897/8997(`sd8897`/`sd8997`) Bluetooth 장치는 SDIO 또는 USB 기반입니다. 8997은 여러 interface를 지원하며 SDIO에서는 `btmrvl` driver, USB에서는 `btusb` driver를 사용합니다.
필수 compatible
7-13`compatible`은 SDIO용 `marvell,sd8897-bt` 또는 `marvell,sd8997-bt`, USB용 `usb1286,204e` 중 하나여야 합니다.
보정, wakeup과 interrupt 속성
14-35선택 `marvell,cal-data`는 초기화 중 장치에 내려보내는 28개 `u8` 값의 calibration data 배열이며 SDIO 장치에만 적용됩니다.
`marvell,wakeup-pin`은 Bluetooth chip의 wakeup pin 번호입니다. Firmware는 이 `u16` pin을 사용해 host system을 깨웁니다. `marvell,wakeup-gap-ms`는 host platform의 wakeup latency를 나타내는 `u16` 값으로 firmware에 설정되며 chip의 sleep 기능이 기대대로 동작하는 데 필요합니다.
`interrupt-names`는 USB 장치에서만 사용합니다. `interrupts`는 CPU에 연결된 interrupt pin 번호를 지정합니다. SDIO driver는 interrupt 배열의 첫 항목을 사용하고, USB driver는 `interrupt-names`와 `interrupts` 배열에서 `wakeup`이라는 interrupt를 사용해 IRQ를 요청합니다.
System suspend 중에는 Bluetooth chip이 특정 조건에서 host platform을 깨울 수 있도록 IRQ를 enable하고, resume 중에는 불필요한 interrupt를 받지 않도록 IRQ를 disable합니다.
SDIO 장치 예제
36-67예제는 IRQ pin 119를 system wakeup source interrupt로 사용합니다. Firmware가 장치 쪽 pin으로 host를 깨우도록 wakeup pin 13과 100ms latency gap을 설정하며, SDIO 예제에는 calibration data도 포함합니다.
&mmc3 {
vmmc-supply = <&wlan_en_reg>;
bus-width = <4>;
cap-power-off-card;
keep-power-in-suspend;
#address-cells = <1>;
#size-cells = <0>;
btmrvl: bluetooth@2 {
compatible = "marvell,sd8897-bt";
reg = <2>;
interrupt-parent = <&pio>;
interrupts = <119 IRQ_TYPE_LEVEL_LOW>;
marvell,cal-data = /bits/ 8 <
0x37 0x01 0x1c 0x00 0xff 0xff 0xff 0xff 0x01 0x7f 0x04 0x02
0x00 0x00 0xba 0xce 0xc0 0xc6 0x2d 0x00 0x00 0x00 0x00 0x00
0x00 0x00 0xf0 0x00>;
marvell,wakeup-pin = /bits/ 16 <0x0d>;
marvell,wakeup-gap-ms = /bits/ 16 <0x64>;
};
};
USB 장치 예제
68-83USB host 아래 주소 1의 Bluetooth 장치가 `wakeup` 이름의 active-low interrupt 119와 같은 wakeup pin 13, 100ms gap을 사용합니다.
&usb_host1_ohci {
#address-cells = <1>;
#size-cells = <0>;
mvl_bt1: bt@1 {
compatible = "usb1286,204e";
reg = <1>;
interrupt-parent = <&gpio0>;
interrupt-names = "wakeup";
interrupts = <119 IRQ_TYPE_LEVEL_LOW>;
marvell,wakeup-pin = /bits/ 16 <0x0d>;
marvell,wakeup-gap-ms = /bits/ 16 <0x64>;
};
};
요약과 해설
marvell-bt-8xxx.txt:1-83Interface별 driver 선택과 suspend wakeup 경로를 중심으로 설명합니다.