Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 6 Mar 2013 09:33:05 +0000 (UTC)
From:      Andriy Gapon <avg@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org
Subject:   svn commit: r247878 - in stable/9/sys: amd64/amd64 i386/i386
Message-ID:  <201303060933.r269X5Xo057245@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: avg
Date: Wed Mar  6 09:33:04 2013
New Revision: 247878
URL: http://svnweb.freebsd.org/changeset/base/247878

Log:
  MFC r246248: cpususpend_handler: mark AP as resumed only after fully
  setting up lapic

Modified:
  stable/9/sys/amd64/amd64/mp_machdep.c
  stable/9/sys/i386/i386/mp_machdep.c
Directory Properties:
  stable/9/sys/   (props changed)

Modified: stable/9/sys/amd64/amd64/mp_machdep.c
==============================================================================
--- stable/9/sys/amd64/amd64/mp_machdep.c	Wed Mar  6 09:22:45 2013	(r247877)
+++ stable/9/sys/amd64/amd64/mp_machdep.c	Wed Mar  6 09:33:04 2013	(r247878)
@@ -1430,12 +1430,12 @@ cpususpend_handler(void)
 	while (!CPU_ISSET(cpu, &started_cpus))
 		ia32_pause();
 
-	CPU_CLR_ATOMIC(cpu, &started_cpus);
-	CPU_CLR_ATOMIC(cpu, &stopped_cpus);
-
 	/* Resume MCA and local APIC */
 	mca_resume();
 	lapic_setup(0);
+
+	CPU_CLR_ATOMIC(cpu, &started_cpus);
+	CPU_CLR_ATOMIC(cpu, &stopped_cpus);
 }
 
 /*

Modified: stable/9/sys/i386/i386/mp_machdep.c
==============================================================================
--- stable/9/sys/i386/i386/mp_machdep.c	Wed Mar  6 09:22:45 2013	(r247877)
+++ stable/9/sys/i386/i386/mp_machdep.c	Wed Mar  6 09:33:04 2013	(r247878)
@@ -1533,12 +1533,12 @@ cpususpend_handler(void)
 	while (!CPU_ISSET(cpu, &started_cpus))
 		ia32_pause();
 
-	CPU_CLR_ATOMIC(cpu, &started_cpus);
-	CPU_CLR_ATOMIC(cpu, &stopped_cpus);
-
 	/* Resume MCA and local APIC */
 	mca_resume();
 	lapic_setup(0);
+
+	CPU_CLR_ATOMIC(cpu, &started_cpus);
+	CPU_CLR_ATOMIC(cpu, &stopped_cpus);
 }
 /*
  * This is called once the rest of the system is up and running and we're



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201303060933.r269X5Xo057245>