PERFORCE change 43765 for review

Peter Wemm peter at FreeBSD.org
Wed Dec 10 13:32:18 PST 2003


http://perforce.freebsd.org/chv.cgi?CH=43765

Change 43765 by peter at peter_daintree on 2003/12/10 13:31:49

	dont do a NOP address space change, in case the TLB flush filter
	was disabled.  Also, add a placeholder for the address space borrowing.

Affected files ...

.. //depot/projects/hammer/sys/amd64/amd64/cpu_switch.S#16 edit

Differences ...

==== //depot/projects/hammer/sys/amd64/amd64/cpu_switch.S#16 (text+ko) ====

@@ -169,12 +169,19 @@
 	jz	badsw3				/* no, panic */
 #endif
 	movq	TD_PCB(%rsi),%r8
-	movl	PCPU(CPUID), %eax
 
 	/* switch address space */
 	movq	PCB_CR3(%r8),%rdx
+#ifdef LAZY_SWITCH
+	cmpq	%rdx,KPML4phys			/* Kernel address space? */
+	je	sw1
+#endif
+	movq	%cr3,%rax
+	cmpq	%rdx,%rax			/* Same address space? */
+	je	sw1
 	movq	%rdx,%cr3			/* new address space */
 
+	movl	PCPU(CPUID), %eax
 	/* Release bit from old pmap->pm_active */
 	movq	TD_PROC(%rdi), %rdx		/* oldproc */
 	movq	P_VMSPACE(%rdx), %rdx


More information about the p4-projects mailing list