Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757140Ab2KHVmy (ORCPT ); Thu, 8 Nov 2012 16:42:54 -0500 Received: from cantor2.suse.de ([195.135.220.15]:47451 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756690Ab2KHVmx (ORCPT ); Thu, 8 Nov 2012 16:42:53 -0500 Date: Thu, 8 Nov 2012 22:42:42 +0100 (CET) From: Jiri Kosina To: Sasha Levin Cc: linux-kernel@vger.kernel.org, Richard Henderson , Ivan Kokshaysky , Matt Turner , Kyungmin Park , Marek Szyprowski , Joe Perches , linux-alpha@vger.kernel.org Subject: Re: [PATCH] alpha: use BUG_ON where possible In-Reply-To: <1352406191-14303-2-git-send-email-sasha.levin@oracle.com> Message-ID: References: <1352406191-14303-1-git-send-email-sasha.levin@oracle.com> <1352406191-14303-2-git-send-email-sasha.levin@oracle.com> User-Agent: Alpine 2.00 (LNX 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 646 Lines: 27 On Thu, 8 Nov 2012, Sasha Levin wrote: > Just use BUG_ON() instead of constructions such as: > > if (...) > BUG() > > A simplified version of the semantic patch that makes this transformation > is as follows: (http://coccinelle.lip6.fr/) > > // > @@ > expression e; > @@ > - if (e) BUG(); > + BUG_ON(e); Ok, I guess I am just going to apply this one. Thanks, -- Jiri Kosina SUSE Labs -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/