From owner-svn-src-all@FreeBSD.ORG Tue Apr 20 12:22:06 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D11071065672; Tue, 20 Apr 2010 12:22:06 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C09EB8FC21; Tue, 20 Apr 2010 12:22:06 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o3KCM6FX024388; Tue, 20 Apr 2010 12:22:06 GMT (envelope-from attilio@svn.freebsd.org) Received: (from attilio@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o3KCM6cc024386; Tue, 20 Apr 2010 12:22:06 GMT (envelope-from attilio@svn.freebsd.org) Message-Id: <201004201222.o3KCM6cc024386@svn.freebsd.org> From: Attilio Rao Date: Tue, 20 Apr 2010 12:22:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r206897 - head/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 20 Apr 2010 12:22:06 -0000 Author: attilio Date: Tue Apr 20 12:22:06 2010 New Revision: 206897 URL: http://svn.freebsd.org/changeset/base/206897 Log: Fix compilation in the !SMP case. Keep the interrupts disabled in order to avoid preemption problems. Reported by: tinderbox, b.f. MFC: 2 weeks X-MFC: r206878 Modified: head/sys/kern/kern_shutdown.c Modified: head/sys/kern/kern_shutdown.c ============================================================================== --- head/sys/kern/kern_shutdown.c Tue Apr 20 12:07:16 2010 (r206896) +++ head/sys/kern/kern_shutdown.c Tue Apr 20 12:22:06 2010 (r206897) @@ -496,8 +496,14 @@ shutdown_reset(void *junk, int howto) * generally, threads busy-waiting, with this spinlock held, * and waiting for responses by threads on other CPUs * (ie. smp_tlb_shootdown()). + * + * For the !SMP case it just needs to handle the former problem. */ +#ifdef SMP mtx_lock_spin(&smp_ipi_mtx); +#else + spinlock_enter(); +#endif /* cpu_boot(howto); */ /* doesn't do anything at the moment */ cpu_reset();