Module Name:    src
Committed By:   snj
Date:           Tue Aug  4 18:12:28 UTC 2015

Modified Files:
        src/sys/arch/xen/x86 [netbsd-7]: cpu.c

Log Message:
Pull up following revision(s) (requested by prlw1 in ticket #934):
        sys/arch/xen/x86/cpu.c: revision 1.100
Move all pmap-related cpu_info initialisations, including
initializing ci_kpm_mtx, in cpu_attach_common() from cpu_init()
(ci_pmap and ci_tlbstate as already initialized in cpu_attach_common()).


To generate a diff of this commit:
cvs rdiff -u -r1.98 -r1.98.4.1 src/sys/arch/xen/x86/cpu.c

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

Modified files:

Index: src/sys/arch/xen/x86/cpu.c
diff -u src/sys/arch/xen/x86/cpu.c:1.98 src/sys/arch/xen/x86/cpu.c:1.98.4.1
--- src/sys/arch/xen/x86/cpu.c:1.98	Wed Feb 12 23:24:09 2014
+++ src/sys/arch/xen/x86/cpu.c	Tue Aug  4 18:12:28 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: cpu.c,v 1.98 2014/02/12 23:24:09 dsl Exp $	*/
+/*	$NetBSD: cpu.c,v 1.98.4.1 2015/08/04 18:12:28 snj Exp $	*/
 /* NetBSD: cpu.c,v 1.18 2004/02/20 17:35:01 yamt Exp  */
 
 /*-
@@ -66,7 +66,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.98 2014/02/12 23:24:09 dsl Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.98.4.1 2015/08/04 18:12:28 snj Exp $");
 
 #include "opt_ddb.h"
 #include "opt_multiprocessor.h"
@@ -425,6 +425,13 @@ cpu_attach_common(device_t parent, devic
 	}
 
 	KASSERT(ci->ci_cpuid == ci->ci_index);
+#ifdef __x86_64__
+	/* No user PGD mapped for this CPU yet */
+	ci->ci_xen_current_user_pgd = 0;
+#endif
+#if defined(__x86_64__) || defined(PAE)
+	mutex_init(&ci->ci_kpm_mtx, MUTEX_DEFAULT, IPL_VM);
+#endif
 	pmap_reference(pmap_kernel());
 	ci->ci_pmap = pmap_kernel();
 	ci->ci_tlbstate = TLBSTATE_STALE;
@@ -543,14 +550,6 @@ cpu_init(struct cpu_info *ci)
 			lcr4(rcr4() | CR4_OSXMMEXCPT);
 	}
 
-#ifdef __x86_64__
-	/* No user PGD mapped for this CPU yet */
-	ci->ci_xen_current_user_pgd = 0;
-#endif
-#if defined(__x86_64__) || defined(PAE)
-	mutex_init(&ci->ci_kpm_mtx, MUTEX_DEFAULT, IPL_VM);
-#endif
-
 	atomic_or_32(&ci->ci_flags, CPUF_RUNNING);
 }
 

Reply via email to