Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1385422

Re: [PATCH] irqdomain: fix compare_const_fl.cocci warnings

From Jon Hunter <jonathanh@nvidia.com>
Newsgroups linux.kernel
Subject Re: [PATCH] irqdomain: fix compare_const_fl.cocci warnings
Date 2016-04-22 20:30 +0200
Message-ID <rqO02-6t9-13@gated-at.bofh.it> (permalink)
References <rq3ua-2ta-17@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


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 <fengguang.wu@intel.com>
> Signed-off-by: Julia Lawall <julia.lawall@lip6.fr>
> ---
> 
> 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

Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH] irqdomain: fix compare_const_fl.cocci warnings Julia Lawall <julia.lawall@lip6.fr> - 2016-04-20 18:50 +0200
  Re: [PATCH] irqdomain: fix compare_const_fl.cocci warnings Marc Zyngier <marc.zyngier@arm.com> - 2016-04-20 19:20 +0200
  Re: [PATCH] irqdomain: fix compare_const_fl.cocci warnings Thomas Gleixner <tglx@linutronix.de> - 2016-04-22 19:50 +0200
    Re: [PATCH] irqdomain: fix compare_const_fl.cocci warnings Julia Lawall <julia.lawall@lip6.fr> - 2016-04-22 21:00 +0200
  Re: [PATCH] irqdomain: fix compare_const_fl.cocci warnings Jon Hunter <jonathanh@nvidia.com> - 2016-04-22 20:30 +0200
    Re: [PATCH] irqdomain: fix compare_const_fl.cocci warnings Julia Lawall <julia.lawall@lip6.fr> - 2016-04-22 21:10 +0200
      Re: [PATCH] irqdomain: fix compare_const_fl.cocci warnings Jon Hunter <jonathanh@nvidia.com> - 2016-04-22 21:20 +0200

csiph-web