Source-Changes-HG archive

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

[src/netbsd-1-5]: src/sys/arch/sparc64/sparc64 pull up 1.86 (approved by thor...



details:   https://anonhg.NetBSD.org/src/rev/d81b878527e2
branches:  netbsd-1-5
changeset: 488946:d81b878527e2
user:      mrg <mrg%NetBSD.org@localhost>
date:      Mon Aug 07 01:23:34 2000 +0000

description:
pull up 1.86 (approved by thorpej):
>`mem' is now a pointer, not an array.  Fixes kernel coredumps.

diffstat:

 sys/arch/sparc64/sparc64/machdep.c |  15 ++++-----------
 1 files changed, 4 insertions(+), 11 deletions(-)

diffs (52 lines):

diff -r 495fcde501f3 -r d81b878527e2 sys/arch/sparc64/sparc64/machdep.c
--- a/sys/arch/sparc64/sparc64/machdep.c        Mon Aug 07 01:22:27 2000 +0000
+++ b/sys/arch/sparc64/sparc64/machdep.c        Mon Aug 07 01:23:34 2000 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: machdep.c,v 1.68.2.4 2000/08/07 01:07:25 mrg Exp $ */
+/*     $NetBSD: machdep.c,v 1.68.2.5 2000/08/07 01:23:34 mrg Exp $ */
 
 /*-
  * Copyright (c) 1996, 1997, 1998 The NetBSD Foundation, Inc.
@@ -888,7 +888,7 @@
        register int (*dump)    __P((dev_t, daddr_t, caddr_t, size_t));
        int error = 0;
        register struct mem_region *mp;
-       extern struct mem_region mem[];
+       extern struct mem_region *mem;
 
        /* copy registers to memory */
        snapshot(cpcb);
@@ -931,16 +931,15 @@
                unsigned i = 0, n;
                paddr_t maddr = mp->start;
 
+#if 0
+               /* Remind me: why don't we dump page 0 ? */
                if (maddr == 0) {
                        /* Skip first page at physical address 0 */
                        maddr += NBPG;
                        i += NBPG;
                        blkno += btodb(NBPG);
                }
-#if 0
-printf("dumping segment at %llx\n", maddr);
 #endif
-
                for (; i < mp->size; i += n) {
                        n = mp->size - i;
                        if (n > BYTES_PER_DUMP)
@@ -951,14 +950,8 @@
                                printf("%d ", i / (1024*1024));
                        (void) pmap_enter(pmap_kernel(), dumpspace, maddr,
                                        VM_PROT_READ, VM_PROT_READ|PMAP_WIRED);
-#if 0
-printf("calling dump of %llx\n", maddr);
-#endif
                        error = (*dump)(dumpdev, blkno,
                                        (caddr_t)dumpspace, (int)n);
-#if 0
-printf("%llx done\n", maddr);
-#endif
                        pmap_remove(pmap_kernel(), dumpspace, dumpspace + n);
                        if (error)
                                break;



Home | Main Index | Thread Index | Old Index