ARM: nomadik: selectively enable UART0 on boards
authorLinus Walleij <linus.walleij@linaro.org>
Thu, 23 Jul 2015 21:14:20 +0000 (23:14 +0200)
committerOlof Johansson <olof@lixom.net>
Tue, 11 Aug 2015 13:29:58 +0000 (15:29 +0200)
The S8815 board is using RX/TX on UART0, and the NHK8815 is
using RX/TX and CTS/RTS (the latter connected to a Bluetooth
chip). Activate the right groups with the u0 UART0 function
on each board and undisable it. Get rid of the old erroneous
default definition from the SoC file.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Olof Johansson <olof@lixom.net>
arch/arm/boot/dts/ste-nomadik-nhk15.dts
arch/arm/boot/dts/ste-nomadik-s8815.dts
arch/arm/boot/dts/ste-nomadik-stn8815.dtsi

index 0e167ed2857b9fe162c53079440064850de2f3d6..9d888b0e75af3c59aeb2acd8fb13e7a72fe0a741 100644 (file)
        };
 
        aliases {
+               serial0 = &uart0;
                serial1 = &uart1;
                stmpe-i2c0 = &stmpe0;
                stmpe-i2c1 = &stmpe1;
        };
 
        pinctrl {
+               uart0 {
+                       uart0_nhk_mode: uart0_mux {
+                               u0_default_mux {
+                                       function = "u0";
+                                       groups = "u0txrx_a_1", "u0ctsrts_a_1";
+                               };
+                       };
+               };
+
                stmpe2401_1 {
                        stmpe2401_1_nhk_mode: stmpe2401_1_nhk {
                                nhk_cfg1 {
        };
 
        amba {
+               /* Activate RX/TX and CTS/RTS on UART 0 */
+               uart0: uart@101fd000 {
+                       pinctrl-names = "default";
+                       pinctrl-0 = <&uart0_nhk_mode>;
+                       status = "okay";
+               };
                mmcsd: sdi@101f6000 {
                        cd-gpios = <&stmpe_gpio44 7 GPIO_ACTIVE_LOW>;
                        wp-gpios = <&stmpe_gpio44 18 GPIO_ACTIVE_HIGH>;
index edcfe2413ee7f61cb1cfa4668d7d339039d467cc..11b5e34150b835d002e473a49a75ba49e867ed78 100644 (file)
@@ -16,6 +16,7 @@
        };
 
        aliases {
+               serial0 = &uart0;
                serial1 = &uart1;
        };
 
                pinctrl-names = "default";
                pinctrl-0 = <&cd_default_mode>;
 
+               uart0 {
+                       /* Only use RX/TX pins */
+                       uart0_s8815_mode: uart0_mux {
+                               u0_default_mux {
+                                       function = "u0";
+                                       groups = "u0txrx_a_1";
+                               };
+                       };
+               };
                mmcsd-cd {
                        cd_default_mode: cd_default {
                                cd_default_cfg1 {
        };
 
 
-       /* Configure card detect for the uSD slot */
        amba {
+               /* Activate RXTX on UART 0 */
+               uart0: uart@101fd000 {
+                       pinctrl-names = "default";
+                       pinctrl-0 = <&uart0_s8815_mode>;
+                       status = "okay";
+               };
+               /* Configure card detect for the uSD slot */
                mmcsd: sdi@101f6000 {
                        cd-gpios = <&gpio3 15 GPIO_ACTIVE_LOW>;
                };
index ef794a33b4dcc2ddf2076a0e27ff948e01d67d44..f68988ac800c764dffcd9ec6140473c693ac63f9 100644 (file)
        pinctrl {
                compatible = "stericsson,stn8815-pinctrl";
                /* Pin configurations */
-               uart0 {
-                       uart0_default_mux: uart0_mux {
-                               u0_default_mux {
-                                       function = "u0";
-                                       groups = "u0_a_1";
-                               };
-                       };
-               };
                uart1 {
                        uart1_default_mux: uart1_mux {
                                u1_default_mux {
                        interrupts = <12>;
                        clocks = <&uart0clk>, <&pclkuart0>;
                        clock-names = "uartclk", "apb_pclk";
-                       pinctrl-names = "default";
-                       pinctrl-0 = <&uart0_default_mux>;
                        status = "disabled";
                };