From mboxrd@z Thu Jan 1 00:00:00 1970 From: Matthew Wilcox Subject: Re: [RFC PATCH 0/2] avoid clobbering registers with J_ASSERT macro Date: Mon, 20 Aug 2007 09:46:48 -0600 Message-ID: <20070820154648.GI30019@parisc-linux.org> References: <46C5380A.8080109@redhat.com> <20070817135402.d7246766.akpm@linux-foundation.org> <46C9949D.8060000@redhat.com> <1187623324.12049.4.camel@sisko.scot.redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Chris Snook , Andrew Morton , linux-fsdevel@vger.kernel.org To: "Stephen C. Tweedie" Return-path: Received: from palinux.external.hp.com ([192.25.206.14]:57725 "EHLO mail.parisc-linux.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1759887AbXHTPqt (ORCPT ); Mon, 20 Aug 2007 11:46:49 -0400 Content-Disposition: inline In-Reply-To: <1187623324.12049.4.camel@sisko.scot.redhat.com> Sender: linux-fsdevel-owner@vger.kernel.org List-Id: linux-fsdevel.vger.kernel.org On Mon, Aug 20, 2007 at 04:22:04PM +0100, Stephen C. Tweedie wrote: > Hi, > > On Mon, 2007-08-20 at 09:18 -0400, Chris Snook wrote: > > > > How's about we just remove that printk? Do > > > > > > #define J_ASSERT(e) BUG_ON(e)? ITYM #define J_ASSERT(e) BUG_ON(!e) > It did. The original J_ASSERT predates BUG() entirely, and was added so > that we got the file/line-no information. But with the current BUG() > macro, I can't see any reason for J_ASSERT still to try to gather that > information itself. Do you still want to keep J_ASSERT, or should all uses of it be replaced with BUG_ON? (to put it another way; if you were writing JBD now, would you add your own J_ASSERT, or would you just use BUG_ON directly?) -- "Bill, look, we understand that you're interested in selling us this operating system, but compare it to ours. We can't possibly take such a retrograde step."