16be33864SEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 26be33864SEmmanuel Vadot%YAML 1.2 36be33864SEmmanuel Vadot--- 46be33864SEmmanuel Vadot$id: http://devicetree.org/schemas/serial/fsl-imx-uart.yaml# 56be33864SEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml# 66be33864SEmmanuel Vadot 76be33864SEmmanuel Vadottitle: Freescale i.MX Universal Asynchronous Receiver/Transmitter (UART) 86be33864SEmmanuel Vadot 96be33864SEmmanuel Vadotmaintainers: 105def4c47SEmmanuel Vadot - Fabio Estevam <festevam@gmail.com> 116be33864SEmmanuel Vadot 126be33864SEmmanuel Vadotproperties: 136be33864SEmmanuel Vadot compatible: 146be33864SEmmanuel Vadot oneOf: 156be33864SEmmanuel Vadot - const: fsl,imx1-uart 166be33864SEmmanuel Vadot - const: fsl,imx21-uart 176be33864SEmmanuel Vadot - items: 186be33864SEmmanuel Vadot - enum: 196be33864SEmmanuel Vadot - fsl,imx25-uart 206be33864SEmmanuel Vadot - fsl,imx27-uart 216be33864SEmmanuel Vadot - fsl,imx31-uart 226be33864SEmmanuel Vadot - fsl,imx35-uart 236be33864SEmmanuel Vadot - fsl,imx50-uart 246be33864SEmmanuel Vadot - fsl,imx51-uart 256be33864SEmmanuel Vadot - fsl,imx53-uart 266be33864SEmmanuel Vadot - fsl,imx6q-uart 276be33864SEmmanuel Vadot - const: fsl,imx21-uart 286be33864SEmmanuel Vadot - items: 296be33864SEmmanuel Vadot - enum: 306be33864SEmmanuel Vadot - fsl,imx6sl-uart 316be33864SEmmanuel Vadot - fsl,imx6sll-uart 326be33864SEmmanuel Vadot - fsl,imx6sx-uart 336be33864SEmmanuel Vadot - const: fsl,imx6q-uart 346be33864SEmmanuel Vadot - const: fsl,imx21-uart 356be33864SEmmanuel Vadot - items: 366be33864SEmmanuel Vadot - enum: 376be33864SEmmanuel Vadot - fsl,imx6ul-uart 386be33864SEmmanuel Vadot - fsl,imx7d-uart 396be33864SEmmanuel Vadot - fsl,imx8mm-uart 406be33864SEmmanuel Vadot - fsl,imx8mn-uart 416be33864SEmmanuel Vadot - fsl,imx8mp-uart 426be33864SEmmanuel Vadot - fsl,imx8mq-uart 436be33864SEmmanuel Vadot - const: fsl,imx6q-uart 446be33864SEmmanuel Vadot 456be33864SEmmanuel Vadot reg: 466be33864SEmmanuel Vadot maxItems: 1 476be33864SEmmanuel Vadot 48fac71e4eSEmmanuel Vadot clocks: 49fac71e4eSEmmanuel Vadot maxItems: 2 50fac71e4eSEmmanuel Vadot 51fac71e4eSEmmanuel Vadot clock-names: 52fac71e4eSEmmanuel Vadot items: 53fac71e4eSEmmanuel Vadot - const: ipg 54fac71e4eSEmmanuel Vadot - const: per 55fac71e4eSEmmanuel Vadot 56fac71e4eSEmmanuel Vadot dmas: 57fac71e4eSEmmanuel Vadot items: 58fac71e4eSEmmanuel Vadot - description: DMA controller phandle and request line for RX 59fac71e4eSEmmanuel Vadot - description: DMA controller phandle and request line for TX 60fac71e4eSEmmanuel Vadot 61fac71e4eSEmmanuel Vadot dma-names: 62fac71e4eSEmmanuel Vadot items: 63fac71e4eSEmmanuel Vadot - const: rx 64fac71e4eSEmmanuel Vadot - const: tx 65fac71e4eSEmmanuel Vadot 666be33864SEmmanuel Vadot interrupts: 67*8d13bc63SEmmanuel Vadot items: 68*8d13bc63SEmmanuel Vadot - description: UART RX Interrupt 69*8d13bc63SEmmanuel Vadot - description: UART TX Interrupt 70*8d13bc63SEmmanuel Vadot - description: UART RTS Interrupt 71*8d13bc63SEmmanuel Vadot minItems: 1 726be33864SEmmanuel Vadot 7384943d6fSEmmanuel Vadot wakeup-source: true 7484943d6fSEmmanuel Vadot 756be33864SEmmanuel Vadot fsl,dte-mode: 766be33864SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/flag 776be33864SEmmanuel Vadot description: | 786be33864SEmmanuel Vadot Indicate the uart works in DTE mode. The uart works in DCE mode by default. 796be33864SEmmanuel Vadot 806be33864SEmmanuel Vadot fsl,inverted-tx: 816be33864SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/flag 826be33864SEmmanuel Vadot description: | 836be33864SEmmanuel Vadot Indicate that the hardware attached to the peripheral inverts the signal 846be33864SEmmanuel Vadot transmitted, and that the peripheral should invert its output using the 856be33864SEmmanuel Vadot INVT registers. 866be33864SEmmanuel Vadot 876be33864SEmmanuel Vadot fsl,inverted-rx: 886be33864SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/flag 896be33864SEmmanuel Vadot description: | 906be33864SEmmanuel Vadot Indicate that the hardware attached to the peripheral inverts the signal 916be33864SEmmanuel Vadot received, and that the peripheral should invert its input using the 926be33864SEmmanuel Vadot INVR registers. 936be33864SEmmanuel Vadot 945956d97fSEmmanuel Vadot fsl,dma-info: 955956d97fSEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32-array 965956d97fSEmmanuel Vadot minItems: 2 975956d97fSEmmanuel Vadot maxItems: 2 985956d97fSEmmanuel Vadot description: | 995956d97fSEmmanuel Vadot First cell contains the size of DMA buffer chunks, second cell contains 1005956d97fSEmmanuel Vadot the amount of chunks used for the device. Multiplying both numbers is 1015956d97fSEmmanuel Vadot the total size of memory used for receiving data. 1025956d97fSEmmanuel Vadot When not being configured the system will use default settings, which 1035956d97fSEmmanuel Vadot are sensible for most use cases. If you need low latency processing on 1045956d97fSEmmanuel Vadot slow connections this needs to be configured appropriately. 1055956d97fSEmmanuel Vadot 1066be33864SEmmanuel Vadotrequired: 1076be33864SEmmanuel Vadot - compatible 1086be33864SEmmanuel Vadot - reg 109fac71e4eSEmmanuel Vadot - clocks 110fac71e4eSEmmanuel Vadot - clock-names 1116be33864SEmmanuel Vadot - interrupts 1126be33864SEmmanuel Vadot 113*8d13bc63SEmmanuel VadotallOf: 114*8d13bc63SEmmanuel Vadot - $ref: serial.yaml# 115*8d13bc63SEmmanuel Vadot - $ref: rs485.yaml# 116*8d13bc63SEmmanuel Vadot 117*8d13bc63SEmmanuel Vadot - if: 118*8d13bc63SEmmanuel Vadot properties: 119*8d13bc63SEmmanuel Vadot compatible: 120*8d13bc63SEmmanuel Vadot contains: 121*8d13bc63SEmmanuel Vadot const: fsl,imx1-uart 122*8d13bc63SEmmanuel Vadot then: 123*8d13bc63SEmmanuel Vadot properties: 124*8d13bc63SEmmanuel Vadot interrupts: 125*8d13bc63SEmmanuel Vadot minItems: 3 126*8d13bc63SEmmanuel Vadot maxItems: 3 127*8d13bc63SEmmanuel Vadot else: 128*8d13bc63SEmmanuel Vadot properties: 129*8d13bc63SEmmanuel Vadot interrupts: 130*8d13bc63SEmmanuel Vadot maxItems: 1 131*8d13bc63SEmmanuel Vadot 1326be33864SEmmanuel VadotunevaluatedProperties: false 1336be33864SEmmanuel Vadot 1346be33864SEmmanuel Vadotexamples: 1356be33864SEmmanuel Vadot - | 136fac71e4eSEmmanuel Vadot #include <dt-bindings/clock/imx5-clock.h> 137fac71e4eSEmmanuel Vadot 1386be33864SEmmanuel Vadot aliases { 1396be33864SEmmanuel Vadot serial0 = &uart1; 1406be33864SEmmanuel Vadot }; 1416be33864SEmmanuel Vadot 1426be33864SEmmanuel Vadot uart1: serial@73fbc000 { 1436be33864SEmmanuel Vadot compatible = "fsl,imx51-uart", "fsl,imx21-uart"; 1446be33864SEmmanuel Vadot reg = <0x73fbc000 0x4000>; 1456be33864SEmmanuel Vadot interrupts = <31>; 146fac71e4eSEmmanuel Vadot clocks = <&clks IMX5_CLK_UART1_IPG_GATE>, 147fac71e4eSEmmanuel Vadot <&clks IMX5_CLK_UART1_PER_GATE>; 148fac71e4eSEmmanuel Vadot clock-names = "ipg", "per"; 149fac71e4eSEmmanuel Vadot dmas = <&sdma 18 4 1>, <&sdma 19 4 2>; 150fac71e4eSEmmanuel Vadot dma-names = "rx", "tx"; 1516be33864SEmmanuel Vadot uart-has-rtscts; 1526be33864SEmmanuel Vadot fsl,dte-mode; 1536be33864SEmmanuel Vadot }; 154