Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/news68k/news68k Remove hp300 derived "last kernel P...



details:   https://anonhg.NetBSD.org/src/rev/7abde886a18e
branches:  trunk
changeset: 502144:7abde886a18e
user:      tsutsui <tsutsui%NetBSD.org@localhost>
date:      Fri Jan 12 16:19:18 2001 +0000

description:
Remove hp300 derived "last kernel PT page" stuff. (sync with luna68k/x68k)

diffstat:

 sys/arch/news68k/news68k/pmap_bootstrap.c |  44 ++----------------------------
 1 files changed, 3 insertions(+), 41 deletions(-)

diffs (103 lines):

diff -r efeb6169ab11 -r 7abde886a18e sys/arch/news68k/news68k/pmap_bootstrap.c
--- a/sys/arch/news68k/news68k/pmap_bootstrap.c Fri Jan 12 16:03:59 2001 +0000
+++ b/sys/arch/news68k/news68k/pmap_bootstrap.c Fri Jan 12 16:19:18 2001 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: pmap_bootstrap.c,v 1.3 2000/06/29 08:02:52 mrg Exp $   */
+/*     $NetBSD: pmap_bootstrap.c,v 1.4 2001/01/12 16:19:18 tsutsui Exp $       */
 
 /* 
  * Copyright (c) 1991, 1993
@@ -94,7 +94,7 @@
        paddr_t nextpa;
        paddr_t firstpa;
 {
-       paddr_t kstpa, kptpa, iiopa, eiopa, kptmpa, lkptpa, p0upa;
+       paddr_t kstpa, kptpa, iiopa, eiopa, kptmpa, p0upa;
        u_int nptpages, kstsize;
        st_entry_t protoste, *ste;
        pt_entry_t protopte, *pte, *epte;
@@ -121,8 +121,6 @@
         *
         *      kptmpa          kernel PT map           1 page
         *
-        *      lkptpa          last kernel PT page     1 page
-        *
         *      p0upa           proc 0 u-area           UPAGES pages
         *
         * The KVA corresponding to any of these PAs is:
@@ -155,8 +153,6 @@
        iiopa = eiopa - iiomapsize * sizeof(pt_entry_t);
        kptmpa = nextpa;
        nextpa += NBPG;
-       lkptpa = nextpa;
-       nextpa += NBPG;
        p0upa = nextpa;
        nextpa += USPACE;
 
@@ -244,17 +240,6 @@
                pte = &((u_int *)kstpa)[kstsize*NPTEPG - SG4_LEV2SIZE];
                *ste = (u_int)pte | SG_U | SG_RW | SG_V;
                /*
-                * Now initialize the final portion of that block of
-                * descriptors to map the "last PT page".
-                */
-               pte = &((u_int *)kstpa)[kstsize*NPTEPG - NPTEPG/SG4_LEV3SIZE];
-               epte = &pte[NPTEPG/SG4_LEV3SIZE];
-               protoste = lkptpa | SG_U | SG_RW | SG_V;
-               while (pte < epte) {
-                       *pte++ = protoste;
-                       protoste += (SG4_LEV3SIZE * sizeof(st_entry_t));
-               }
-               /*
                 * Initialize Sysptmap
                 */
                pte = (u_int *)kptmpa;
@@ -267,11 +252,10 @@
                /*
                 * Invalidate all but the last remaining entry.
                 */
-               epte = &((u_int *)kptmpa)[NPTEPG-1];
+               epte = &((u_int *)kptmpa)[NPTEPG];
                while (pte < epte) {
                        *pte++ = PG_NV;
                }
-               *pte = lkptpa | PG_RW | PG_CI | PG_V;
        } else
 #endif
        {
@@ -294,35 +278,13 @@
                /*
                 * Invalidate all but the last remaining entries in both.
                 */
-#if 1 /* XXX lkptpa is needed only hp300? */
-               epte = &((u_int *)kptmpa)[NPTEPG-1];
-#else
                epte = &((u_int *)kptmpa)[NPTEPG];
-#endif
                while (pte < epte) {
                        *ste++ = SG_NV;
                        *pte++ = PG_NV;
                }
-               /*
-                * Initialize the last to point to point to the page
-                * table page allocated earlier.
-                */
-#if 1
-               *ste = lkptpa | SG_RW | SG_V;
-               *pte = lkptpa | PG_RW | PG_CI | PG_V;
-#endif
        }
        /*
-        * Invalidate all but the final entry in the last kernel PT page
-        * (u-area PTEs will be validated later).  The final entry maps
-        * the last page of physical memory.
-        */
-       pte = (u_int *)lkptpa;
-       epte = &pte[NPTEPG];
-       while (pte < epte)
-               *pte++ = PG_NV;
-
-       /*
         * Initialize kernel page table.
         * Start by invalidating the `nptpages' that we have allocated.
         */



Home | Main Index | Thread Index | Old Index