From b0f30511098b720497241eb40f5a34a99504539d Mon Sep 17 00:00:00 2001 From: Michael Shalayeff Date: Thu, 16 Jan 2003 19:39:24 +0000 Subject: slightely better memory regions validity check; weingart@ idea and ok --- sys/arch/i386/i386/machdep.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) (limited to 'sys/arch/i386') diff --git a/sys/arch/i386/i386/machdep.c b/sys/arch/i386/i386/machdep.c index 9e5c29904e5..08b4f9a258d 100644 --- a/sys/arch/i386/i386/machdep.c +++ b/sys/arch/i386/i386/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.219 2003/01/16 04:15:17 art Exp $ */ +/* $OpenBSD: machdep.c,v 1.220 2003/01/16 19:39:23 mickey Exp $ */ /* $NetBSD: machdep.c,v 1.214 1996/11/10 03:16:17 thorpej Exp $ */ /*- @@ -2186,16 +2186,8 @@ init386(paddr_t first_avail) printf(" %u-%u", a, e); #endif - /* skip zero sized regions */ - if (im->size == 0) { -#ifdef DEBUG - printf("-Z"); -#endif - continue; - } - /* skip shorter than page regions */ - if ((e - a) < NBPG) { + if (a >= e || (e - a) < NBPG) { #ifdef DEBUG printf("-S"); #endif -- cgit v1.2.3