From owner-svn-src-head@FreeBSD.ORG Fri Apr 24 03:17:23 2015 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id D90EB85B; Fri, 24 Apr 2015 03:17:22 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BAABB1889; Fri, 24 Apr 2015 03:17:22 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id t3O3HMf2083782; Fri, 24 Apr 2015 03:17:22 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id t3O3HL0v083778; Fri, 24 Apr 2015 03:17:21 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201504240317.t3O3HL0v083778@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Fri, 24 Apr 2015 03:17:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r281915 - in head: share/man/man9 sys/kern sys/sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 24 Apr 2015 03:17:23 -0000 Author: markj Date: Fri Apr 24 03:17:21 2015 New Revision: 281915 URL: https://svnweb.freebsd.org/changeset/base/281915 Log: Make vpanic() externally visible so that it can be called as part of the DTrace panic() action. Differential Revision: https://reviews.freebsd.org/D2349 Reviewed by: avg MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Division Modified: head/share/man/man9/Makefile head/share/man/man9/panic.9 head/sys/kern/kern_shutdown.c head/sys/sys/systm.h Modified: head/share/man/man9/Makefile ============================================================================== --- head/share/man/man9/Makefile Fri Apr 24 02:43:02 2015 (r281914) +++ head/share/man/man9/Makefile Fri Apr 24 03:17:21 2015 (r281915) @@ -1135,6 +1135,7 @@ MLINKS+=osd.9 osd_call.9 \ osd.9 osd_get.9 \ osd.9 osd_register.9 \ osd.9 osd_set.9 +MLINKS+=panic.9 vpanic.9 MLINKS+=pbuf.9 getpbuf.9 \ pbuf.9 relpbuf.9 \ pbuf.9 trypbuf.9 Modified: head/share/man/man9/panic.9 ============================================================================== --- head/share/man/man9/panic.9 Fri Apr 24 02:43:02 2015 (r281914) +++ head/share/man/man9/panic.9 Fri Apr 24 03:17:21 2015 (r281915) @@ -31,7 +31,7 @@ .\" .\" $FreeBSD$ .\" -.Dd August 11, 1995 +.Dd April 23, 2015 .Dt PANIC 9 .Os .Sh NAME @@ -42,10 +42,14 @@ .In sys/systm.h .Ft void .Fn panic "const char *fmt" ... +.Ft void +.Fn vpanic "const char *fmt" "va_list ap" .Sh DESCRIPTION The .Fn panic -function terminates the running system. +and +.Fn vpanic +functions terminate the running system. The message .Fa fmt is a Modified: head/sys/kern/kern_shutdown.c ============================================================================== --- head/sys/kern/kern_shutdown.c Fri Apr 24 02:43:02 2015 (r281914) +++ head/sys/kern/kern_shutdown.c Fri Apr 24 03:17:21 2015 (r281915) @@ -154,7 +154,6 @@ static void poweroff_wait(void *, int); static void shutdown_halt(void *junk, int howto); static void shutdown_panic(void *junk, int howto); static void shutdown_reset(void *junk, int howto); -static void vpanic(const char *fmt, va_list ap) __dead2; /* register various local shutdown events */ static void @@ -676,7 +675,7 @@ panic(const char *fmt, ...) vpanic(fmt, ap); } -static void +void vpanic(const char *fmt, va_list ap) { #ifdef SMP Modified: head/sys/sys/systm.h ============================================================================== --- head/sys/sys/systm.h Fri Apr 24 02:43:02 2015 (r281914) +++ head/sys/sys/systm.h Fri Apr 24 03:17:21 2015 (r281915) @@ -187,6 +187,7 @@ void *phashinit(int count, struct malloc void g_waitidle(void); void panic(const char *, ...) __dead2 __printflike(1, 2); +void vpanic(const char *, __va_list) __dead2 __printflike(1, 0); void cpu_boot(int); void cpu_flush_dcache(void *, size_t);