]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/commitdiff
serial: imx: Use generic uart-has-rtscts DT property
authorGeert Uytterhoeven <geert+renesas@glider.be>
Fri, 22 Apr 2016 15:22:21 +0000 (17:22 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 30 Apr 2016 16:26:55 +0000 (09:26 -0700)
Convert the Freescale IMX UART driver from using the vendor-specific
"fsl,uart-has-rtscts" to the generic "uart-has-rtscts" DT property, as
documented by the Generic Serial DT Bindings.

The old vendor-specific property is still recognized by the driver for
backwards compatibility, but deprecated.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Documentation/devicetree/bindings/serial/fsl-imx-uart.txt
drivers/tty/serial/imx.c

index ed94c217c98d18a655aa4df150de7b62f1e17440..1e82802d8e322db5ef5ae509234c7e017f4032b7 100644 (file)
@@ -6,7 +6,7 @@ Required properties:
 - interrupts : Should contain uart interrupt
 
 Optional properties:
-- fsl,uart-has-rtscts : Indicate the uart has rts and cts
+- uart-has-rtscts : Indicate the uart has rts and cts
 - fsl,irda-mode : Indicate the uart supports irda mode
 - fsl,dte-mode : Indicate the uart works in DTE mode. The uart works
                   in DCE mode by default.
@@ -24,6 +24,6 @@ uart1: serial@73fbc000 {
        compatible = "fsl,imx51-uart", "fsl,imx21-uart";
        reg = <0x73fbc000 0x4000>;
        interrupts = <31>;
-       fsl,uart-has-rtscts;
+       uart-has-rtscts;
        fsl,dte-mode;
 };
index 4b38392f4bd6fd5c15a22d078f9c8d13643e75eb..0df2b1c091aea5860a0b42240e49c2acd72f9ca3 100644 (file)
@@ -1980,7 +1980,8 @@ static int serial_imx_probe_dt(struct imx_port *sport,
        }
        sport->port.line = ret;
 
-       if (of_get_property(np, "fsl,uart-has-rtscts", NULL))
+       if (of_get_property(np, "uart-has-rtscts", NULL) ||
+           of_get_property(np, "fsl,uart-has-rtscts", NULL) /* deprecated */)
                sport->have_rtscts = 1;
 
        if (of_get_property(np, "fsl,dte-mode", NULL))