Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 16 Oct 2010 20:01:41 +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-7@freebsd.org
Subject:   svn commit: r213935 - stable/7/sys/kern
Message-ID:  <201010162001.o9GK1fuP088464@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: avg
Date: Sat Oct 16 20:01:41 2010
New Revision: 213935
URL: http://svn.freebsd.org/changeset/base/213935

Log:
  MFC r213648: panic_cpu variable should be volatile

Modified:
  stable/7/sys/kern/kern_shutdown.c
Directory Properties:
  stable/7/sys/   (props changed)
  stable/7/sys/cddl/contrib/opensolaris/   (props changed)
  stable/7/sys/contrib/dev/acpica/   (props changed)
  stable/7/sys/contrib/pf/   (props changed)

Modified: stable/7/sys/kern/kern_shutdown.c
==============================================================================
--- stable/7/sys/kern/kern_shutdown.c	Sat Oct 16 19:58:49 2010	(r213934)
+++ stable/7/sys/kern/kern_shutdown.c	Sat Oct 16 20:01:41 2010	(r213935)
@@ -497,10 +497,6 @@ shutdown_reset(void *junk, int howto)
 	/* NOTREACHED */ /* assuming reset worked */
 }
 
-#ifdef SMP
-static u_int panic_cpu = NOCPU;
-#endif
-
 /*
  * Panic is called on unresolvable fatal errors.  It prints "panic: mesg",
  * and then reboots.  If we are called twice, then we avoid trying to sync
@@ -509,6 +505,9 @@ static u_int panic_cpu = NOCPU;
 void
 panic(const char *fmt, ...)
 {
+#ifdef SMP
+	static volatile u_int panic_cpu = NOCPU;
+#endif
 	struct thread *td = curthread;
 	int bootopt, newpanic;
 	va_list ap;



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