1MediaTek SoC built-in Bluetooth Devices
2==================================
3
4This device is a serial attached device to BTIF device and thus it must be a
5child node of the serial node with BTIF. The dt-bindings details for BTIF
6device can be known via Documentation/devicetree/bindings/serial/8250.yaml.
7
8Required properties:
9
10- compatible:	Must be
11		  "mediatek,mt7622-bluetooth": for MT7622 SoC
12- clocks:	Should be the clock specifiers corresponding to the entry in
13		clock-names property.
14- clock-names:	Should contain "ref" entries.
15- power-domains: Phandle to the power domain that the device is part of
16
17Example:
18
19	btif: serial@1100c000 {
20		compatible = "mediatek,mt7622-btif",
21			     "mediatek,mtk-btif";
22		reg = <0 0x1100c000 0 0x1000>;
23		interrupts = <GIC_SPI 90 IRQ_TYPE_LEVEL_LOW>;
24		clocks = <&pericfg CLK_PERI_BTIF_PD>;
25		clock-names = "main";
26		reg-shift = <2>;
27		reg-io-width = <4>;
28
29		bluetooth {
30			compatible = "mediatek,mt7622-bluetooth";
31			power-domains = <&scpsys MT7622_POWER_DOMAIN_WB>;
32			clocks = <&clk25m>;
33			clock-names = "ref";
34		};
35	};
36
37MediaTek UART based Bluetooth Devices
38==================================
39
40This device is a serial attached device to UART device and thus it must be a
41child node of the serial node with UART.
42
43Please refer to the following documents for generic properties:
44
45	Documentation/devicetree/bindings/serial/serial.yaml
46
47Required properties:
48
49- compatible:	Must be
50		  "mediatek,mt7663u-bluetooth": for MT7663U device
51		  "mediatek,mt7668u-bluetooth": for MT7668U device
52- vcc-supply:	Main voltage regulator
53
54If the pin controller on the platform can support both pinmux and GPIO
55control such as the most of MediaTek platform. Please use below properties.
56
57- pinctrl-names: Should be "default", "runtime"
58- pinctrl-0: Should contain UART RXD low when the device is powered up to
59	     enter proper bootstrap mode.
60- pinctrl-1: Should contain UART mode pin ctrl
61
62Else, the pin controller on the platform only can support pinmux control and
63the GPIO control still has to rely on the dedicated GPIO controller such as
64a legacy MediaTek SoC, MT7621. Please use the below properties.
65
66- boot-gpios:	GPIO same to the pin as UART RXD and used to keep LOW when
67		the device is powered up to enter proper bootstrap mode when
68- pinctrl-names: Should be "default"
69- pinctrl-0: Should contain UART mode pin ctrl
70
71Optional properties:
72
73- reset-gpios:	GPIO used to reset the device whose initial state keeps low,
74		if the GPIO is missing, then board-level design should be
75		guaranteed.
76- clocks:	Should be the clock specifiers corresponding to the entry in
77		clock-names property. If the clock is missing, then board-level
78		design should be guaranteed.
79- clock-names:	Should contain "osc" entry for the external oscillator.
80- current-speed:  Current baud rate of the device whose defaults to 921600
81
82Example:
83
84	uart1_pins_boot: uart1-default {
85		pins-dat {
86			pinmux = <MT7623_PIN_81_URXD1_FUNC_GPIO81>;
87			output-low;
88		};
89	};
90
91	uart1_pins_runtime: uart1-runtime {
92		pins-dat {
93			pinmux = <MT7623_PIN_81_URXD1_FUNC_URXD1>,
94				 <MT7623_PIN_82_UTXD1_FUNC_UTXD1>;
95		};
96	};
97
98	uart1: serial@11003000 {
99		compatible = "mediatek,mt7623-uart",
100			     "mediatek,mt6577-uart";
101		reg = <0 0x11003000 0 0x400>;
102		interrupts = <GIC_SPI 52 IRQ_TYPE_LEVEL_LOW>;
103		clocks = <&pericfg CLK_PERI_UART1_SEL>,
104			 <&pericfg CLK_PERI_UART1>;
105		clock-names = "baud", "bus";
106
107		bluetooth {
108			compatible = "mediatek,mt7663u-bluetooth";
109			vcc-supply = <&reg_5v>;
110			reset-gpios = <&pio 24 GPIO_ACTIVE_LOW>;
111			pinctrl-names = "default", "runtime";
112			pinctrl-0 = <&uart1_pins_boot>;
113			pinctrl-1 = <&uart1_pins_runtime>;
114			current-speed = <921600>;
115		};
116	};
117