Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/macppc/macppc sprinkle oea_mapiodev()



details:   https://anonhg.NetBSD.org/src/rev/44080ee80b1e
branches:  trunk
changeset: 321566:44080ee80b1e
user:      macallan <macallan%NetBSD.org@localhost>
date:      Thu Mar 22 21:28:58 2018 +0000

description:
sprinkle oea_mapiodev()

diffstat:

 sys/arch/macppc/macppc/cpu.c        |  6 +++---
 sys/arch/macppc/macppc/interrupts.c |  7 ++++---
 2 files changed, 7 insertions(+), 6 deletions(-)

diffs (62 lines):

diff -r de3df4b927fd -r 44080ee80b1e sys/arch/macppc/macppc/cpu.c
--- a/sys/arch/macppc/macppc/cpu.c      Thu Mar 22 21:27:36 2018 +0000
+++ b/sys/arch/macppc/macppc/cpu.c      Thu Mar 22 21:28:58 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: cpu.c,v 1.61 2018/03/22 15:23:43 macallan Exp $        */
+/*     $NetBSD: cpu.c,v 1.62 2018/03/22 21:28:58 macallan Exp $        */
 
 /*-
  * Copyright (c) 2001 Tsubai Masanari.
@@ -33,7 +33,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.61 2018/03/22 15:23:43 macallan Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.62 2018/03/22 21:28:58 macallan Exp $");
 
 #include "opt_ppcparam.h"
 #include "opt_multiprocessor.h"
@@ -209,7 +209,7 @@
 {
 #ifdef OPENPIC
        if (openpic_base) {
-               uint32_t kl_base = (uint32_t)mapiodev(0x80000000, 0x1000, 0);
+               uint32_t kl_base = oea_mapiodev(0x80000000, 0x1000);
                uint32_t gpio = kl_base + 0x5c; /* XXX */
                u_int node, off;
                char cpupath[32];
diff -r de3df4b927fd -r 44080ee80b1e sys/arch/macppc/macppc/interrupts.c
--- a/sys/arch/macppc/macppc/interrupts.c       Thu Mar 22 21:27:36 2018 +0000
+++ b/sys/arch/macppc/macppc/interrupts.c       Thu Mar 22 21:28:58 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: interrupts.c,v 1.5 2013/04/18 16:42:46 macallan Exp $ */
+/*     $NetBSD: interrupts.c,v 1.6 2018/03/22 21:28:58 macallan Exp $ */
 
 /*-
  * Copyright (c) 2007 Michael Lorenz
@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: interrupts.c,v 1.5 2013/04/18 16:42:46 macallan Exp $");
+__KERNEL_RCSID(0, "$NetBSD: interrupts.c,v 1.6 2018/03/22 21:28:58 macallan Exp $");
 
 #include "opt_multiprocessor.h"
 
@@ -42,6 +42,7 @@
 #include <powerpc/pic/picvar.h>
 #include <powerpc/pic/ipivar.h>
 #include <dev/ofw/openfirm.h>
+#include <powerpc/oea/cpufeat.h>
 
 #include "opt_interrupt.h"
 #include "pic_openpic.h"
@@ -100,7 +101,7 @@
        aprint_debug("pic-base: %08x\n", pic_base);
 
        aprint_normal("found openpic PIC at %08x\n", pic_base);
-       setup_openpic((void *)pic_base, pass_through);
+       setup_openpic(oea_mapiodev(pic_base, 0x40000), pass_through);
 
        return TRUE;
 }



Home | Main Index | Thread Index | Old Index