]> git.kernelconcepts.de Git - karo-tx-uboot.git/commitdiff
serial: ns16550: Call usbtty_poll only in non-SPL build
authorMarek Vasut <marex@denx.de>
Sat, 15 Sep 2012 08:25:19 +0000 (10:25 +0200)
committerTom Rini <trini@ti.com>
Mon, 15 Oct 2012 18:53:58 +0000 (11:53 -0700)
Having both USBTTY and CONFIG_SERIAL_MULTI enabled in SPL, the
usbtty.c file is protected in Makefile to not be compiled into
the SPL. Yet, the ns16550 serial driver does not contain such
protection. Add it to avoid missing symbol error.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Marek Vasut <marek.vasut@gmail.com>
Cc: Tom Rini <trini@ti.com>
drivers/serial/ns16550.c

index facadd2f5c3e31f59f09829c46a22cc4feb022e4..9027781445f447efc63483294b2bf564947842df 100644 (file)
@@ -101,7 +101,7 @@ void NS16550_putc(NS16550_t com_port, char c)
 char NS16550_getc(NS16550_t com_port)
 {
        while ((serial_in(&com_port->lsr) & UART_LSR_DR) == 0) {
-#ifdef CONFIG_USB_TTY
+#if !defined(CONFIG_SPL_BUILD) && defined(CONFIG_USB_TTY)
                extern void usbtty_poll(void);
                usbtty_poll();
 #endif