Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753531AbcDVSVr (ORCPT ); Fri, 22 Apr 2016 14:21:47 -0400 Received: from hqemgate16.nvidia.com ([216.228.121.65]:9169 "EHLO hqemgate16.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752819AbcDVSVq (ORCPT ); Fri, 22 Apr 2016 14:21:46 -0400 X-PGP-Universal: processed; by hqnvupgp07.nvidia.com on Fri, 22 Apr 2016 11:21:34 -0700 Subject: Re: [PATCH] irqdomain: fix compare_const_fl.cocci warnings To: Julia Lawall , Jiang Liu , Marc Zyngier , "Thomas Gleixner" , , References: X-Nvconfidentiality: public From: Jon Hunter Message-ID: <571A6BAF.8040006@nvidia.com> Date: Fri, 22 Apr 2016 19:21:35 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0 MIME-Version: 1.0 In-Reply-To: X-Originating-IP: [10.26.11.57] X-ClientProxiedBy: UKMAIL102.nvidia.com (10.26.138.15) To UKMAIL101.nvidia.com (10.26.138.13) Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1071 Lines: 35 On 20/04/16 17:49, Julia Lawall wrote: > Move constants to the right of binary operators. > > Generated by: scripts/coccinelle/misc/compare_const_fl.cocci > > Signed-off-by: Fengguang Wu > Signed-off-by: Julia Lawall > --- > > Not a big deal, but the transformed code looks better to me. > > irqdomain.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > --- a/kernel/irq/irqdomain.c > +++ b/kernel/irq/irqdomain.c > @@ -618,7 +618,7 @@ unsigned int irq_create_fwspec_mapping(s > * If the trigger type has not been set yet, then set > * it now and return the interrupt number. > */ > - if (IRQ_TYPE_NONE == irq_get_trigger_type(virq)) { > + if (irq_get_trigger_type(virq) == IRQ_TYPE_NONE) { > irq_set_irq_type(virq, type); > return virq; > } What branch is this from? Looks very familiar and related to some changes I have been working on, but in my latest version I already have this as shown above [0]. Cheers Jon [0] http://marc.info/?l=linux-tegra&m=146115064322071&w=2