Allow to compile with DEBUG_PMAP defined.
authormpi <mpi@openbsd.org>
Sat, 26 Apr 2014 14:19:04 +0000 (14:19 +0000)
committermpi <mpi@openbsd.org>
Sat, 26 Apr 2014 14:19:04 +0000 (14:19 +0000)
sys/arch/powerpc/powerpc/pmap.c

index c9f1f19..a27258e 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: pmap.c,v 1.127 2014/04/01 20:42:39 mpi Exp $ */
+/*     $OpenBSD: pmap.c,v 1.128 2014/04/26 14:19:04 mpi Exp $ */
 
 /*
  * Copyright (c) 2001, 2002, 2007 Dale Rahn.
@@ -2666,12 +2666,12 @@ void
 print_pteg(pmap_t pm, vaddr_t va)
 {
        int sr, idx;
-       struct pte *ptp;
+       struct pte_32 *ptp;
 
        sr = ptesr(pm->pm_sr, va);
        idx = pteidx(sr,  va);
 
-       ptp = pmap_ptable + idx  * 8;
+       ptp = pmap_ptable32 + idx  * 8;
        db_printf("va %x, sr %x, idx %x\n", va, sr, idx);
 
        db_printf("%08x %08x %08x %08x  %08x %08x %08x %08x\n",
@@ -2680,7 +2680,7 @@ print_pteg(pmap_t pm, vaddr_t va)
        db_printf("%08x %08x %08x %08x  %08x %08x %08x %08x\n",
            ptp[0].pte_lo, ptp[1].pte_lo, ptp[2].pte_lo, ptp[3].pte_lo,
            ptp[4].pte_lo, ptp[5].pte_lo, ptp[6].pte_lo, ptp[7].pte_lo);
-       ptp = pmap_ptable + (idx ^ pmap_ptab_mask) * 8;
+       ptp = pmap_ptable32 + (idx ^ pmap_ptab_mask) * 8;
        db_printf("%08x %08x %08x %08x  %08x %08x %08x %08x\n",
            ptp[0].pte_hi, ptp[1].pte_hi, ptp[2].pte_hi, ptp[3].pte_hi,
            ptp[4].pte_hi, ptp[5].pte_hi, ptp[6].pte_hi, ptp[7].pte_hi);
@@ -2709,9 +2709,9 @@ pmap_print_pted(struct pte_desc *pted, int(*print)(const char *, ...))
                        print("ptehi %x ptelo %x ptp %x Aptp %x\n",
                            pted->p.pted_pte64.pte_hi,
                            pted->p.pted_pte64.pte_lo,
-                           pmap_ptable +
+                           pmap_ptable64 +
                                8*pteidx(ptesr(pted->pted_pmap->pm_sr, va), va),
-                           pmap_ptable +
+                           pmap_ptable64 +
                                8*(pteidx(ptesr(pted->pted_pmap->pm_sr, va), va)
                                    ^ pmap_ptab_mask)
                            );
@@ -2719,9 +2719,9 @@ pmap_print_pted(struct pte_desc *pted, int(*print)(const char *, ...))
                        print("ptehi %x ptelo %x ptp %x Aptp %x\n",
                            pted->p.pted_pte32.pte_hi,
                            pted->p.pted_pte32.pte_lo,
-                           pmap_ptable +
+                           pmap_ptable32 +
                                8*pteidx(ptesr(pted->pted_pmap->pm_sr, va), va),
-                           pmap_ptable +
+                           pmap_ptable32 +
                                8*(pteidx(ptesr(pted->pted_pmap->pm_sr, va), va)
                                    ^ pmap_ptab_mask)
                            );