serial: exar: Preconfigure xr17v35x MPIOs as output
authorJan Kiszka <jan.kiszka@siemens.com>
Sat, 13 May 2017 07:28:59 +0000 (09:28 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 18 May 2017 14:26:40 +0000 (16:26 +0200)
This is the safe default for GPIOs with unknown external wiring.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/8250/8250_exar.c

index 2a8f00d96e6b15fa73864447b5bc90a0ac5c70bc..0a20f7185094bb4aa1d104fe18d2d6f6510271ec 100644 (file)
@@ -176,13 +176,13 @@ static void setup_gpio(u8 __iomem *p)
        writeb(0x00, p + UART_EXAR_MPIOLVL_7_0);
        writeb(0x00, p + UART_EXAR_MPIO3T_7_0);
        writeb(0x00, p + UART_EXAR_MPIOINV_7_0);
-       writeb(0x00, p + UART_EXAR_MPIOSEL_7_0);
+       writeb(0xff, p + UART_EXAR_MPIOSEL_7_0);
        writeb(0x00, p + UART_EXAR_MPIOOD_7_0);
        writeb(0x00, p + UART_EXAR_MPIOINT_15_8);
        writeb(0x00, p + UART_EXAR_MPIOLVL_15_8);
        writeb(0x00, p + UART_EXAR_MPIO3T_15_8);
        writeb(0x00, p + UART_EXAR_MPIOINV_15_8);
-       writeb(0x00, p + UART_EXAR_MPIOSEL_15_8);
+       writeb(0xff, p + UART_EXAR_MPIOSEL_15_8);
        writeb(0x00, p + UART_EXAR_MPIOOD_15_8);
 }