Source-Changes-HG archive

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

[src/sommerfeld_i386mp_1]: src/sys/arch/i386/i386 Fix a merge botch which cau...



details:   https://anonhg.NetBSD.org/src/rev/84c4f79fd652
branches:  sommerfeld_i386mp_1
changeset: 482356:84c4f79fd652
user:      sommerfeld <sommerfeld%NetBSD.org@localhost>
date:      Mon Jan 08 13:57:23 2001 +0000

description:
Fix a merge botch which caused to fail to find the end of memory on
some systems.

diffstat:

 sys/arch/i386/i386/machdep.c |  16 ++++++++--------
 sys/arch/i386/i386/pmap.c    |  25 ++-----------------------
 2 files changed, 10 insertions(+), 31 deletions(-)

diffs (121 lines):

diff -r 600869641dbe -r 84c4f79fd652 sys/arch/i386/i386/machdep.c
--- a/sys/arch/i386/i386/machdep.c      Sun Jan 07 22:59:23 2001 +0000
+++ b/sys/arch/i386/i386/machdep.c      Mon Jan 08 13:57:23 2001 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: machdep.c,v 1.376.2.14 2001/01/07 22:59:24 sommerfeld Exp $    */
+/*     $NetBSD: machdep.c,v 1.376.2.15 2001/01/08 13:57:23 sommerfeld Exp $    */
 
 /*-
  * Copyright (c) 1996, 1997, 1998, 2000 The NetBSD Foundation, Inc.
@@ -1899,7 +1899,7 @@
 
 #ifdef MULTIPROCESSOR
        /* leave room for bioscall just to avoid too much chaos */
-       avail_start = 4*NBPG;   /* save us a page for trampoline code and
+       avail_start = 4*PAGE_SIZE;      /* save us a page for trampoline code and
                                 one additional PT page! */
 #else
 #if NBIOSCALL > 0
@@ -1923,11 +1923,11 @@
         */
        bim = lookup_bootinfo(BTINFO_MEMMAP);
        if (bim != NULL && bim->num > 0) {
-#if DEBUG_MEMLOAD
+#ifdef DEBUG_MEMLOAD
                printf("BIOS MEMORY MAP (%d ENTRIES):\n", bim->num);
 #endif
                for (x = 0; x < bim->num; x++) {
-#if DEBUG_MEMLOAD
+#ifdef DEBUG_MEMLOAD
                        printf("    addr 0x%qx  size 0x%qx  type 0x%x\n",
                            bim->entry[x].addr,
                            bim->entry[x].size,
@@ -2134,7 +2134,7 @@
                                        tmp = (16 * 1024 * 1024);
                                else
                                        tmp = seg_end;
-#if DEBUG_MEMLOAD
+#ifdef DEBUG_MEMLOAD
                                printf("loading 0x%qx-0x%qx (0x%lx-0x%lx)\n",
                                    seg_start, tmp,
                                    atop(seg_start), atop(tmp));
@@ -2146,7 +2146,7 @@
                        }
 
                        if (seg_start != seg_end) {
-#if DEBUG_MEMLOAD
+#ifdef DEBUG_MEMLOAD
                                printf("loading 0x%qx-0x%qx (0x%lx-0x%lx)\n",
                                    seg_start, seg_end,
                                    atop(seg_start), atop(seg_end));
@@ -2167,7 +2167,7 @@
                                        tmp = (16 * 1024 * 1024);
                                else
                                        tmp = seg_end1;
-#if DEBUG_MEMLOAD
+#ifdef DEBUG_MEMLOAD
                                printf("loading 0x%qx-0x%qx (0x%lx-0x%lx)\n",
                                    seg_start1, tmp,
                                    atop(seg_start1), atop(tmp));
@@ -2179,7 +2179,7 @@
                        }
 
                        if (seg_start1 != seg_end1) {
-#if DEBUG_MEMLOAD
+#ifdef DEBUG_MEMLOAD
                                printf("loading 0x%qx-0x%qx (0x%lx-0x%lx)\n",
                                    seg_start1, seg_end1,
                                    atop(seg_start1), atop(seg_end1));
diff -r 600869641dbe -r 84c4f79fd652 sys/arch/i386/i386/pmap.c
--- a/sys/arch/i386/i386/pmap.c Sun Jan 07 22:59:23 2001 +0000
+++ b/sys/arch/i386/i386/pmap.c Mon Jan 08 13:57:23 2001 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: pmap.c,v 1.83.2.26 2001/01/07 22:59:24 sommerfeld Exp $        */
+/*     $NetBSD: pmap.c,v 1.83.2.27 2001/01/08 13:57:24 sommerfeld Exp $        */
 
 /*
  *
@@ -336,7 +336,7 @@
 
 /*
  * i386 physical memory comes in a big contig chunk with a small
- * hole toward the front of it...  the following 4 paddr_t's
+ * hole toward the front of it...  the following two paddr_t's
  * (shared with machdep.c) describe the physical address space
  * of this machine.
  */
@@ -840,26 +840,6 @@
        int i;
 
        /*
-        * set the page size (default value is 4K which is ok)
-        */
-
-       uvm_setpagesize();
-
-       /*
-        * a quick sanity check
-        */
-
-       if (PAGE_SIZE != NBPG)
-               panic("pmap_bootstrap: PAGE_SIZE != NBPG");
-
-       /*
-        * use the very last page of physical memory for the message buffer
-        */
-
-       avail_end -= i386_round_page(MSGBUFSIZE);
-       msgbuf_paddr = avail_end;
-
-       /*
         * set up our local static global vars that keep track of the
         * usage of KVM before kernel_map is set up
         */
@@ -1019,7 +999,6 @@
 
        idt_vaddr = virtual_avail;                      /* don't need pte */
        virtual_avail += PAGE_SIZE;
-       avail_end -= PAGE_SIZE;
        idt_paddr = avail_start;                        /* steal a page */
        avail_start += PAGE_SIZE;
 



Home | Main Index | Thread Index | Old Index