Subject: wheee!
To: None <port-m68k@NetBSD.ORG>
From: Theo de Raadt <deraadt@theos.com>
List: port-m68k
Date: 09/23/1995 13:19:34
i think Michael Hitch and i have fixed the illusive "you must clear
memory before booting" pmap bug. the key is that hp300's clear their
memory (or at least mike hibler thinks they do).
i knew it had to be a 68040 specific pmap_bootstrap bug, because of
various symptoms i had seen. Michael finally noticed that Sysptmap
wasn't being completely initialized on the 68040.
after making the following change, i was able to back out the
workarounds that i required (they were: 1. locore.s cleared memory
from _end to the 1M boundary; 2. i had to let *NULL work -- now i can
PG_NV it).
things appear to be working better. i hope this is the right
fix. i'll continue stress testing...
*** pmap_bootstrap.c.save Sat Sep 23 13:08:37 1995
--- pmap_bootstrap.c Sat Sep 23 03:54:09 1995
***************
*** 246,251 ****
--- 246,258 ----
*pte++ = protopte;
protopte += NBPG;
}
+ /*
+ * Invalidate all but the last remaining entries in both.
+ */
+ epte = &((u_int *)kptmpa)[NPTEPG-1];
+ while (pte < epte) {
+ *pte++ = PG_NV;
+ }
pte = &((u_int *)kptmpa)[NPTEPG-1];
*pte = lkptpa | PG_RW | PG_CI | PG_V;
} else {