Merge tag 'iwlwifi-next-for-kalle-2014-12-30' of https://git.kernel.org/pub/scm/linux...
[cascardo/linux.git] / arch / powerpc / kernel / udbg_16550.c
index 6e7c492..411116c 100644 (file)
@@ -69,8 +69,12 @@ static void udbg_uart_putc(char c)
 
 static int udbg_uart_getc_poll(void)
 {
-       if (!udbg_uart_in || !(udbg_uart_in(UART_LSR) & LSR_DR))
+       if (!udbg_uart_in)
+               return -1;
+
+       if (!(udbg_uart_in(UART_LSR) & LSR_DR))
                return udbg_uart_in(UART_RBR);
+
        return -1;
 }