Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 17 Oct 2010 14:25:55 +0000 (UTC)
From:      Marius Strobl <marius@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org
Subject:   svn commit: r213977 - stable/8/sys/sparc64/sparc64
Message-ID:  <201010171425.o9HEPtRp034137@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: marius
Date: Sun Oct 17 14:25:55 2010
New Revision: 213977
URL: http://svn.freebsd.org/changeset/base/213977

Log:
  MFC: r213868
  
  - In the spirit of r212559 add a comment describing what will eventually
    lower the PIL.
  - Just as with the AP ensure that the (S)TICK timer(s) are in a known
    state when starting BSPs.

Modified:
  stable/8/sys/sparc64/sparc64/mp_machdep.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/amd64/include/xen/   (props changed)
  stable/8/sys/cddl/contrib/opensolaris/   (props changed)
  stable/8/sys/contrib/dev/acpica/   (props changed)
  stable/8/sys/contrib/pf/   (props changed)
  stable/8/sys/dev/xen/xenpci/   (props changed)

Modified: stable/8/sys/sparc64/sparc64/mp_machdep.c
==============================================================================
--- stable/8/sys/sparc64/sparc64/mp_machdep.c	Sun Oct 17 14:25:01 2010	(r213976)
+++ stable/8/sys/sparc64/sparc64/mp_machdep.c	Sun Oct 17 14:25:55 2010	(r213977)
@@ -431,6 +431,12 @@ cpu_mp_bootstrap(struct pcpu *pc)
 	 */
 	cache_enable(pc->pc_impl);
 
+	/*
+	 * Clear (S)TICK timer(s) (including NPT) and ensure they are stopped.
+	 */
+	tick_clear(pc->pc_impl);
+	tick_stop(pc->pc_impl);
+
 	/* Lock the kernel TSB in the TLB. */
 	pmap_map_tsb();
 
@@ -443,7 +449,11 @@ cpu_mp_bootstrap(struct pcpu *pc)
 	/* Initialize global registers. */
 	cpu_setregs(pc);
 
-	/* Enable interrupts. */
+	/*
+	 * Enable interrupts.
+	 * Note that the PIL we be lowered indirectly via sched_throw(NULL)
+	 * when fake spinlock held by the idle thread eventually is released.
+	 */
 	wrpr(pstate, 0, PSTATE_KERNEL);
 
 	/* Start the (S)TICK interrupts. */



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