diff options
Diffstat (limited to 'sys/arch/sparc64/sparc64/machdep.c')
-rw-r--r-- | sys/arch/sparc64/sparc64/machdep.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/sys/arch/sparc64/sparc64/machdep.c b/sys/arch/sparc64/sparc64/machdep.c index f0e910a0351..0962d15882a 100644 --- a/sys/arch/sparc64/sparc64/machdep.c +++ b/sys/arch/sparc64/sparc64/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.89 2007/05/26 20:26:51 pedro Exp $ */ +/* $OpenBSD: machdep.c,v 1.90 2007/05/29 20:36:48 deraadt Exp $ */ /* $NetBSD: machdep.c,v 1.108 2001/07/24 19:30:14 eeh Exp $ */ /*- @@ -774,15 +774,15 @@ int dumpsize = 0; /* also for savecore */ long dumplo = 0; void -dumpconf() +dumpconf(void) { int nblks, dumpblks; - if (dumpdev == NODEV || bdevsw[major(dumpdev)].d_psize == 0) - /* No usable dump device */ + if (dumpdev == NODEV || + (nblks = (bdevsw[major(dumpdev)].d_psize)(dumpdev)) == 0) + return; + if (nblks <= ctod(1)) return; - - nblks = (*bdevsw[major(dumpdev)].d_psize)(dumpdev); dumpblks = ctod(physmem) + pmap_dumpsize(); if (dumpblks > (nblks - ctod(1))) |