svn commit: r307556 - head/sys/arm/nvidia/tegra124
Michal Meloun
mmel at FreeBSD.org
Tue Oct 18 12:21:47 UTC 2016
Author: mmel
Date: Tue Oct 18 12:21:45 2016
New Revision: 307556
URL: https://svnweb.freebsd.org/changeset/base/307556
Log:
TEGRA: Really implement early printf. The original version
was cut&pasted from another SoC.
Pointy-hat to: mmel
MFC after: 2 weeks
Modified:
head/sys/arm/nvidia/tegra124/tegra124_machdep.c
Modified: head/sys/arm/nvidia/tegra124/tegra124_machdep.c
==============================================================================
--- head/sys/arm/nvidia/tegra124/tegra124_machdep.c Tue Oct 18 10:33:28 2016 (r307555)
+++ head/sys/arm/nvidia/tegra124/tegra124_machdep.c Tue Oct 18 12:21:45 2016 (r307556)
@@ -120,18 +120,18 @@ tegra124_cpu_reset(platform_t plat)
/*
* Early putc routine for EARLY_PRINTF support. To use, add to kernel config:
- * option SOCDEV_PA=0x02000000
- * option SOCDEV_VA=0x02000000
+ * option SOCDEV_PA=0x70000000
+ * option SOCDEV_VA=0x70000000
* option EARLY_PRINTF
*/
-#if 0
+#ifdef EARLY_PRINTF
static void
tegra124_early_putc(int c)
{
- volatile uint32_t * UART_STAT_REG = (uint32_t *)0x02020098;
- volatile uint32_t * UART_TX_REG = (uint32_t *)0x02020040;
- const uint32_t UART_TXRDY = (1 << 3);
+ volatile uint32_t * UART_STAT_REG = (uint32_t *)(0x70006314);
+ volatile uint32_t * UART_TX_REG = (uint32_t *)(0x70006300);
+ const uint32_t UART_TXRDY = (1 << 6);
while ((*UART_STAT_REG & UART_TXRDY) == 0)
continue;
*UART_TX_REG = c;
More information about the svn-src-head
mailing list