From owner-freebsd-arch@FreeBSD.ORG Thu Nov 15 23:17:10 2012 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id A74409BA; Thu, 15 Nov 2012 23:17:10 +0000 (UTC) (envelope-from bright@mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 75A2C8FC08; Thu, 15 Nov 2012 23:17:10 +0000 (UTC) Received: from kruse-124.4.ixsystems.com (drawbridge.ixsystems.com [206.40.55.65]) by elvis.mu.org (Postfix) with ESMTPSA id 4B4B61A3D8D; Thu, 15 Nov 2012 15:17:04 -0800 (PST) Message-ID: <50A57815.4060104@mu.org> Date: Thu, 15 Nov 2012 15:17:41 -0800 From: Alfred Perlstein User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:16.0) Gecko/20121026 Thunderbird/16.0.2 MIME-Version: 1.0 To: Adrian Chadd Subject: Re: [RFQ] make witness panic an option References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.14 Cc: freebsd-hackers@freebsd.org, freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Nov 2012 23:17:10 -0000 On 11/14/12 10:15 PM, Adrian Chadd wrote: > Hi all, > > When debugging and writing wireless drivers/stack code, I like to > sprinkle lots of locking assertions everywhere. However, this does > cause things to panic quite often during active development. > > This patch (against stable/9) makes the actual panic itself > configurable. It still prints the message regardless. > > This has allowed me to sprinkle more locking assertions everywhere to > investigate whether particular paths have been hit or not. I don't > necessarily want those to panic the kernel. > > I'd like everyone to consider this for FreeBSD-HEAD. > > Thanks! Adrian, you seem be getting reluctance on your patch which is surprising since we have "witness_kdb" option which pretty much does exactly what you want... ...except where you need it to. That is unfortunate. Perhaps if you switched those panics to a WITNESS_WARN that would do what you need/want? You could pass a special flag into WITNESS_WARN that said "i'm going to pass you a NULL ptr for lock object... just behave as if there was an error". that should make things more concise. Will that be sufficient? -Alfred > > > > Adrian > > > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org"