summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp/sparc/shared/uart/apbuart_cons.c
diff options
context:
space:
mode:
authorMartin Aberg <maberg@gaisler.com>2017-04-27 13:14:53 +0200
committerDaniel Hellstrom <daniel@gaisler.com>2017-05-14 12:31:57 +0200
commit229c42499ea44865acb1fb9308a9656d99dbe85e (patch)
treee47b5bb69e9e90853fc349ca59ddc4bd53ad62d7 /c/src/lib/libbsp/sparc/shared/uart/apbuart_cons.c
parentleon, irq: single CPU SMP configuration does not need IPI ISR (diff)
downloadrtems-229c42499ea44865acb1fb9308a9656d99dbe85e.tar.bz2
bsp/leon3: Cleaner namespace for LEON3 debug UART
Prefix BSP specific symbols with BSP name: dbg_uart -> leon3_debug_uart debug_uart_index -> leon3_debug_uart_index
Diffstat (limited to 'c/src/lib/libbsp/sparc/shared/uart/apbuart_cons.c')
-rw-r--r--c/src/lib/libbsp/sparc/shared/uart/apbuart_cons.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/c/src/lib/libbsp/sparc/shared/uart/apbuart_cons.c b/c/src/lib/libbsp/sparc/shared/uart/apbuart_cons.c
index c79d4084eb..e406bc01b7 100644
--- a/c/src/lib/libbsp/sparc/shared/uart/apbuart_cons.c
+++ b/c/src/lib/libbsp/sparc/shared/uart/apbuart_cons.c
@@ -48,7 +48,9 @@ extern void apbuart_outbyte_polled(
int do_cr_on_newline,
int wait_sent);
extern int apbuart_inbyte_nonblocking(struct apbuart_regs *regs);
-extern struct apbuart_regs *dbg_uart; /* The debug UART */
+#ifdef LEON3
+extern struct apbuart_regs *leon3_debug_uart; /* The debug UART */
+#endif
/* Probed hardware capabilities */
enum {
@@ -263,7 +265,7 @@ int apbuart_init1(struct drvmgr_dev *dev)
*/
db = 0;
#ifdef LEON3
- if (priv->regs == dbg_uart) {
+ if (priv->regs == leon3_debug_uart) {
db = priv->regs->ctrl & (LEON_REG_UART_CTRL_RE |
LEON_REG_UART_CTRL_TE |
LEON_REG_UART_CTRL_PE |
@@ -510,7 +512,7 @@ static void last_close(
#ifdef LEON3
/* Disable TX/RX if not used for DEBUG */
- if (uart->regs != dbg_uart)
+ if (uart->regs != leon3_debug_uart)
uart->regs->ctrl &= ~(APBUART_CTRL_RE | APBUART_CTRL_TE);
#endif
}