[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20191008172558.5955-1-miquel.raynal@bootlin.com>
Date: Tue, 8 Oct 2019 19:25:58 +0200
From: Miquel Raynal <miquel.raynal@...tlin.com>
To: Stephen Boyd <swboyd@...omium.org>, linux-kernel@...r.kernel.org
Cc: Miquel Raynal <miquel.raynal@...tlin.com>,
Vignesh Raghavendra <vigneshr@...com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Richard Weinberger <richard@....at>,
Marek Vasut <marek.vasut@...il.com>,
linux-mtd@...ts.infradead.org,
Brian Norris <computersforpeace@...il.com>,
David Woodhouse <dwmw2@...radead.org>
Subject: Re: [PATCH v6 30/57] mtd: Remove dev_err() usage after platform_get_irq()
On Tue, 2019-07-30 at 18:15:30 UTC, Stephen Boyd wrote:
> We don't need dev_err() messages when platform_get_irq() fails now that
> platform_get_irq() prints an error message itself when something goes
> wrong. Let's remove these prints with a simple semantic patch.
>
> // <smpl>
> @@
> expression ret;
> struct platform_device *E;
> @@
>
> ret =
> (
> platform_get_irq(E, ...)
> |
> platform_get_irq_byname(E, ...)
> );
>
> if ( \( ret < 0 \| ret <= 0 \) )
> {
> (
> -if (ret != -EPROBE_DEFER)
> -{ ...
> -dev_err(...);
> -... }
> |
> ...
> -dev_err(...);
> )
> ...
> }
> // </smpl>
>
> While we're here, remove braces on if statements that only have one
> statement (manually).
>
> Cc: David Woodhouse <dwmw2@...radead.org>
> Cc: Brian Norris <computersforpeace@...il.com>
> Cc: Marek Vasut <marek.vasut@...il.com>
> Cc: Miquel Raynal <miquel.raynal@...tlin.com>
> Cc: Richard Weinberger <richard@....at>
> Cc: Vignesh Raghavendra <vigneshr@...com>
> Cc: linux-mtd@...ts.infradead.org
> Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
> Signed-off-by: Stephen Boyd <swboyd@...omium.org>
Applied to https://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git mtd/next, thanks.
Miquel
Powered by blists - more mailing lists