Date: Tue, 5 Feb 2002 20:30:26 -0800 (PST) From: John Baldwin <jhb@FreeBSD.org> To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/alpha/alpha pmap.c src/sys/alpha/include pmap.h src/sys/kern subr_witness.c Message-ID: <200202060430.g164UQX09984@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
jhb 2002/02/05 20:30:26 PST Modified files: sys/alpha/alpha pmap.c sys/alpha/include pmap.h sys/kern subr_witness.c Log: Fixes for alpha pmap on SMP machines: - Create a private list of active pmaps rather than abusing the list of all processes when we need to look up pmaps. The process list needs a sx lock and we can't be getting sx locks in the middle of cpu_switch() (pmap_activate() can call pmap_get_asn() from cpu_switch()). Instead, we protect the list with a spinlock. This also means the list is shorter since a pmap can be used by more than one process and we could (at least in thoery) dink with pmap's more than once, but now we only touch each pmap once when we have to update all of them. - Wrap pmap_activate()'s code to get a new ASN in an explicit critical section so that when it is called while doing an exec() we can't get preempted. - Replace splhigh() in pmap_growkernel() with a critical section to prevent preemption while we are adjusting the kernel page tables. - Fixes abuse of PCPU_GET(), which doesn't return an L-value. - Also adds some slight cleanups to the ASN handling by adding some macros instead of magic numbers in relation to the ASN and ASN generations. Reviewed by: dfr Revision Changes Path 1.82 +58 -50 src/sys/alpha/alpha/pmap.c 1.15 +7 -2 src/sys/alpha/include/pmap.h 1.96 +1 -0 src/sys/kern/subr_witness.c To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200202060430.g164UQX09984>