summaryrefslogtreecommitdiff
path: root/drivers/serial/serial_pl01x.c
diff options
context:
space:
mode:
authorAndreas Engel <andreas.engel@ericsson.com>2008-09-08 14:30:53 +0200
committerWolfgang Denk <wd@denx.de>2008-09-09 14:42:02 +0200
commit48d0192fe869948fef14b460b5f0c85bca933693 (patch)
treebfa442b8a1db5ab3fa7aa4f33abdc8f36eb986e2 /drivers/serial/serial_pl01x.c
parent20c9226cb8cab08a111ee73db04e62d943ee0c97 (diff)
downloadu-boot-imx-48d0192fe869948fef14b460b5f0c85bca933693.zip
u-boot-imx-48d0192fe869948fef14b460b5f0c85bca933693.tar.gz
u-boot-imx-48d0192fe869948fef14b460b5f0c85bca933693.tar.bz2
Moved conditional compile into Makefile
Signed-off-by: Andreas Engel <andreas.engel@ericsson.com>
Diffstat (limited to 'drivers/serial/serial_pl01x.c')
-rw-r--r--drivers/serial/serial_pl01x.c15
1 files changed, 5 insertions, 10 deletions
diff --git a/drivers/serial/serial_pl01x.c b/drivers/serial/serial_pl01x.c
index d0497ec..c645cef 100644
--- a/drivers/serial/serial_pl01x.c
+++ b/drivers/serial/serial_pl01x.c
@@ -25,14 +25,11 @@
* MA 02111-1307 USA
*/
-/* Simple U-Boot driver for the PrimeCell PL011 UARTs on the IntegratorCP */
-/* Should be fairly simple to make it work with the PL010 as well */
+/* Simple U-Boot driver for the PrimeCell PL010/PL011 UARTs */
#include <common.h>
#include <watchdog.h>
-#if defined(CFG_PL010_SERIAL) || defined(CFG_PL011_SERIAL)
-
#include "serial_pl01x.h"
#define IO_WRITE(addr, val) (*(volatile unsigned int *)(addr) = (val))
@@ -52,7 +49,7 @@ static void pl01x_putc (int portnum, char c);
static int pl01x_getc (int portnum);
static int pl01x_tstc (int portnum);
-#ifdef CFG_PL010_SERIAL
+#ifdef CONFIG_PL010_SERIAL
int serial_init (void)
{
@@ -110,9 +107,9 @@ int serial_init (void)
return 0;
}
-#endif /* CFG_PL010_SERIAL */
+#endif /* CONFIG_PL010_SERIAL */
-#ifdef CFG_PL011_SERIAL
+#ifdef CONFIG_PL011_SERIAL
int serial_init (void)
{
@@ -157,7 +154,7 @@ int serial_init (void)
return 0;
}
-#endif /* CFG_PL011_SERIAL */
+#endif /* CONFIG_PL011_SERIAL */
void serial_putc (const char c)
{
@@ -224,5 +221,3 @@ static int pl01x_tstc (int portnum)
return !(IO_READ (port[portnum] + UART_PL01x_FR) &
UART_PL01x_FR_RXFE);
}
-
-#endif