When handling a page fault, panic if the map is NULL so that we don't

dereference it when doing handled or modified emulation. This can happen
if fault are taken during early parts of the bootstrap, resulting in
recursive faulting.
This commit is contained in:
mark 1999-04-06 06:35:03 +00:00
parent b1ec416993
commit c05b9ed27a

View File

@ -1,4 +1,4 @@
/* $NetBSD: fault.c,v 1.41 1999/03/26 22:00:24 mycroft Exp $ */
/* $NetBSD: fault.c,v 1.42 1999/04/06 06:35:03 mark Exp $ */
/*
* Copyright (c) 1994-1997 Mark Brinicombe.
@ -368,6 +368,9 @@ copyfault:
printf("vmmap=%p ", map);
#endif
if (map == NULL)
panic("No map for fault address\n");
/*
* We need to know whether the page should be mapped
* as R or R/W. The MMU does not give us the info as