summaryrefslogtreecommitdiffstats
path: root/arch/mips/netlogic/common/earlycons.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/mips/netlogic/common/earlycons.c')
-rw-r--r--arch/mips/netlogic/common/earlycons.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/arch/mips/netlogic/common/earlycons.c b/arch/mips/netlogic/common/earlycons.c
index 28c8fa7a8503..f193f7b3bd81 100644
--- a/arch/mips/netlogic/common/earlycons.c
+++ b/arch/mips/netlogic/common/earlycons.c
@@ -38,13 +38,22 @@
#include <asm/mipsregs.h>
#include <asm/netlogic/haldefs.h>
+#if defined(CONFIG_CPU_XLP)
+#include <asm/netlogic/xlp-hal/iomap.h>
+#include <asm/netlogic/xlp-hal/uart.h>
+#elif defined(CONFIG_CPU_XLR)
#include <asm/netlogic/xlr/iomap.h>
+#endif
void prom_putchar(char c)
{
uint64_t uartbase;
+#if defined(CONFIG_CPU_XLP)
+ uartbase = nlm_get_uart_regbase(0, 0);
+#elif defined(CONFIG_CPU_XLR)
uartbase = nlm_mmio_base(NETLOGIC_IO_UART_0_OFFSET);
+#endif
while (nlm_read_reg(uartbase, UART_LSR) == 0)
;
nlm_write_reg(uartbase, UART_TX, c);
OpenPOWER on IntegriCloud