Subject: CVS commit: src/sys/arch/sparc64/sparc64
To: None <source-changes@netbsd.org>
From: Chuck Silvers <chs@netbsd.org>
List: source-changes
Date: 01/15/2003 08:15:07
Module Name:	src
Committed By:	chs
Date:		Wed Jan 15 06:15:07 UTC 2003

Modified Files:
	src/sys/arch/sparc64/sparc64: locore.s pmap.c

Log Message:
fix two bugs in my last pmap rework:
 - in tlb_flush_all(), don't skip TLB entries with the high bit on,
   I was confused about which MMU register it was using.  it's also fine
   to use the last hardware context.
 - in pmap_create(), don't allocate a hardware context for the new pmap.
   it's unnecessary, and when this would cause us to recycle all the contexts,
   it would result in the current process's context being set to 0
   (ie. the kernel's context).  the current process could then return to
   userspace without going through the context-switch code (and thus without
   having a hardware context reallocated).  this would lead to user mappings
   being entered in the kernel's context later, causing all sorts of trouble.
   add some assertions to catch this kind of thing.


To generate a diff of this commit:
cvs rdiff -r1.160 -r1.161 src/sys/arch/sparc64/sparc64/locore.s
cvs rdiff -r1.131 -r1.132 src/sys/arch/sparc64/sparc64/pmap.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.