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
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-stable-9
To unsubscribe, send any mail to "[email protected]"

Reply via email to