Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/evbarm/amlogic use va not pa for console bsh



details:   https://anonhg.NetBSD.org/src/rev/e13a8bdc699b
branches:  trunk
changeset: 336380:e13a8bdc699b
user:      jmcneill <jmcneill%NetBSD.org@localhost>
date:      Fri Feb 27 18:00:29 2015 +0000

description:
use va not pa for console bsh

diffstat:

 sys/arch/evbarm/amlogic/amlogic_machdep.c |  13 +++++--------
 1 files changed, 5 insertions(+), 8 deletions(-)

diffs (41 lines):

diff -r 631885a29046 -r e13a8bdc699b sys/arch/evbarm/amlogic/amlogic_machdep.c
--- a/sys/arch/evbarm/amlogic/amlogic_machdep.c Fri Feb 27 17:45:52 2015 +0000
+++ b/sys/arch/evbarm/amlogic/amlogic_machdep.c Fri Feb 27 18:00:29 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: amlogic_machdep.c,v 1.2 2015/02/27 17:35:08 jmcneill Exp $ */
+/*     $NetBSD: amlogic_machdep.c,v 1.3 2015/02/27 18:00:29 jmcneill Exp $ */
 
 /*
  * Machine dependent functions for kernel setup for TI OSK5912 board.
@@ -125,7 +125,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: amlogic_machdep.c,v 1.2 2015/02/27 17:35:08 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: amlogic_machdep.c,v 1.3 2015/02/27 18:00:29 jmcneill Exp $");
 
 #include "opt_machdep.h"
 #include "opt_ddb.h"
@@ -470,9 +470,6 @@
 void
 consinit(void)
 {
-#if NAMLOGIC_COM > 0
-       bus_space_handle_t bsh;
-#endif
        static int consinit_called = 0;
 
        if (consinit_called != 0)
@@ -483,9 +480,9 @@
        amlogic_putchar('e');
 
 #if NAMLOGIC_COM > 0
-       bus_space_subregion(&amlogic_bs_tag, amlogic_core_bsh,
-           consaddr - AMLOGIC_CORE_BASE, AMLOGIC_UART_SIZE, &bsh);
-       amlogic_com_cnattach(&amlogic_bs_tag, consaddr, conspeed, conmode);
+        const bus_space_handle_t bsh =
+            AMLOGIC_CORE_VBASE + (consaddr - AMLOGIC_CORE_BASE);
+       amlogic_com_cnattach(&amlogic_bs_tag, bsh, conspeed, conmode);
 #endif
 
 #if NUKBD > 0



Home | Main Index | Thread Index | Old Index