xref: /freebsd-src/sys/contrib/device-tree/Bindings/serial/mtk-uart.txt (revision c9ccf3a32da427475985b85d7df023ccfb138c27)
1c66ec88fSEmmanuel Vadot* MediaTek Universal Asynchronous Receiver/Transmitter (UART)
2c66ec88fSEmmanuel Vadot
3c66ec88fSEmmanuel VadotRequired properties:
4c66ec88fSEmmanuel Vadot- compatible should contain:
5c66ec88fSEmmanuel Vadot  * "mediatek,mt2701-uart" for MT2701 compatible UARTS
6c66ec88fSEmmanuel Vadot  * "mediatek,mt2712-uart" for MT2712 compatible UARTS
7c66ec88fSEmmanuel Vadot  * "mediatek,mt6580-uart" for MT6580 compatible UARTS
8c66ec88fSEmmanuel Vadot  * "mediatek,mt6582-uart" for MT6582 compatible UARTS
9c66ec88fSEmmanuel Vadot  * "mediatek,mt6589-uart" for MT6589 compatible UARTS
10c66ec88fSEmmanuel Vadot  * "mediatek,mt6755-uart" for MT6755 compatible UARTS
11c66ec88fSEmmanuel Vadot  * "mediatek,mt6765-uart" for MT6765 compatible UARTS
12c66ec88fSEmmanuel Vadot  * "mediatek,mt6779-uart" for MT6779 compatible UARTS
13c66ec88fSEmmanuel Vadot  * "mediatek,mt6795-uart" for MT6795 compatible UARTS
14c66ec88fSEmmanuel Vadot  * "mediatek,mt6797-uart" for MT6797 compatible UARTS
15c66ec88fSEmmanuel Vadot  * "mediatek,mt7622-uart" for MT7622 compatible UARTS
16c66ec88fSEmmanuel Vadot  * "mediatek,mt7623-uart" for MT7623 compatible UARTS
17c66ec88fSEmmanuel Vadot  * "mediatek,mt7629-uart" for MT7629 compatible UARTS
18354d7675SEmmanuel Vadot  * "mediatek,mt7986-uart", "mediatek,mt6577-uart" for MT7986 compatible UARTS
19c66ec88fSEmmanuel Vadot  * "mediatek,mt8127-uart" for MT8127 compatible UARTS
20c66ec88fSEmmanuel Vadot  * "mediatek,mt8135-uart" for MT8135 compatible UARTS
21c66ec88fSEmmanuel Vadot  * "mediatek,mt8173-uart" for MT8173 compatible UARTS
22c66ec88fSEmmanuel Vadot  * "mediatek,mt8183-uart", "mediatek,mt6577-uart" for MT8183 compatible UARTS
23*c9ccf3a3SEmmanuel Vadot  * "mediatek,mt8186-uart", "mediatek,mt6577-uart" for MT8183 compatible UARTS
246be33864SEmmanuel Vadot  * "mediatek,mt8192-uart", "mediatek,mt6577-uart" for MT8192 compatible UARTS
252eb4d8dcSEmmanuel Vadot  * "mediatek,mt8195-uart", "mediatek,mt6577-uart" for MT8195 compatible UARTS
26c66ec88fSEmmanuel Vadot  * "mediatek,mt8516-uart" for MT8516 compatible UARTS
27c66ec88fSEmmanuel Vadot  * "mediatek,mt6577-uart" for MT6577 and all of the above
28c66ec88fSEmmanuel Vadot
29c66ec88fSEmmanuel Vadot- reg: The base address of the UART register bank.
30c66ec88fSEmmanuel Vadot
31c66ec88fSEmmanuel Vadot- interrupts:
32c66ec88fSEmmanuel Vadot  index 0: an interrupt specifier for the UART controller itself
33c66ec88fSEmmanuel Vadot  index 1: optional, an interrupt specifier with edge sensitivity on Rx pin to
34c66ec88fSEmmanuel Vadot           support Rx in-band wake up. If one would like to use this feature,
35c66ec88fSEmmanuel Vadot           one must create an addtional pinctrl to reconfigure Rx pin to normal
36c66ec88fSEmmanuel Vadot           GPIO before suspend.
37c66ec88fSEmmanuel Vadot
38c66ec88fSEmmanuel Vadot- clocks : Must contain an entry for each entry in clock-names.
39c66ec88fSEmmanuel Vadot  See ../clocks/clock-bindings.txt for details.
40c66ec88fSEmmanuel Vadot- clock-names:
41c66ec88fSEmmanuel Vadot  - "baud": The clock the baudrate is derived from
42c66ec88fSEmmanuel Vadot  - "bus": The bus clock for register accesses (optional)
43c66ec88fSEmmanuel Vadot
44c66ec88fSEmmanuel VadotFor compatibility with older device trees an unnamed clock is used for the
45c66ec88fSEmmanuel Vadotbaud clock if the baudclk does not exist. Do not use this for new designs.
46c66ec88fSEmmanuel Vadot
47c66ec88fSEmmanuel VadotExample:
48c66ec88fSEmmanuel Vadot
49c66ec88fSEmmanuel Vadot	uart0: serial@11006000 {
50c66ec88fSEmmanuel Vadot		compatible = "mediatek,mt6589-uart", "mediatek,mt6577-uart";
51c66ec88fSEmmanuel Vadot		reg = <0x11006000 0x400>;
52c66ec88fSEmmanuel Vadot		interrupts = <GIC_SPI 51 IRQ_TYPE_LEVEL_LOW>,
53c66ec88fSEmmanuel Vadot			     <GIC_SPI 52 IRQ_TYPE_EDGE_FALLING>;
54c66ec88fSEmmanuel Vadot		clocks = <&uart_clk>, <&bus_clk>;
55c66ec88fSEmmanuel Vadot		clock-names = "baud", "bus";
56c66ec88fSEmmanuel Vadot		pinctrl-names = "default", "sleep";
57c66ec88fSEmmanuel Vadot		pinctrl-0 = <&uart_pin>;
58c66ec88fSEmmanuel Vadot		pinctrl-1 = <&uart_pin_sleep>;
59c66ec88fSEmmanuel Vadot	};
60