linux-omap.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Grygorii Strashko <grygorii.strashko@ti.com>
To: Krzysztof Kozlowski <krzk@kernel.org>,
	Ray Jui <rjui@broadcom.com>,
	Linus Walleij <linus.walleij@linaro.org>,
	Bartosz Golaszewski <bgolaszewski@baylibre.com>,
	Florian Fainelli <f.fainelli@gmail.com>,
	Scott Branden <sbranden@broadcom.com>,
	<bcm-kernel-feedback-list@broadcom.com>,
	Keerthy <j-keerthy@ti.com>,
	Santosh Shilimkar <ssantosh@kernel.org>,
	Kevin Hilman <khilman@kernel.org>,
	Michal Simek <michal.simek@xilinx.com>,
	<linux-gpio@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
	<linux-omap@vger.kernel.org>,
	<linux-arm-kernel@lists.infradead.org>
Subject: Re: [PATCH 3/6] gpio: omap: Simplify with dev_err_probe()
Date: Fri, 28 Aug 2020 11:01:00 +0300	[thread overview]
Message-ID: <0013c2d6-6587-3646-35f2-3804fb5b244c@ti.com> (raw)
In-Reply-To: <20200827200827.26462-3-krzk@kernel.org>



On 27/08/2020 23:08, Krzysztof Kozlowski wrote:
> Common pattern of handling deferred probe can be simplified with
> dev_err_probe().  Less code and also it prints the error value.
> 
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> ---
>   drivers/gpio/gpio-omap.c | 5 +----
>   1 file changed, 1 insertion(+), 4 deletions(-)
> 
> diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c
> index 7fbe0c9e1fc1..2dc12f4addbd 100644
> --- a/drivers/gpio/gpio-omap.c
> +++ b/drivers/gpio/gpio-omap.c
> @@ -1394,10 +1394,7 @@ static int omap_gpio_probe(struct platform_device *pdev)
>   	if (bank->irq <= 0) {
>   		if (!bank->irq)
>   			bank->irq = -ENXIO;
> -		if (bank->irq != -EPROBE_DEFER)
> -			dev_err(dev,
> -				"can't get irq resource ret=%d\n", bank->irq);
> -		return bank->irq;
> +		return dev_err_probe(dev, bank->irq, "can't get irq resource\n");
>   	}
>   
>   	bank->chip.parent = dev;
> 

Acked-by: Grygorii Strashko <grygorii.strashko@ti.com>

-- 
Best regards,
grygorii

  reply	other threads:[~2020-08-28  8:01 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-27 20:08 [PATCH 1/6] gpio: bcm-kona: Simplify with dev_err_probe() Krzysztof Kozlowski
2020-08-27 20:08 ` [PATCH 2/6] gpio: davinci: " Krzysztof Kozlowski
2020-08-27 20:08 ` [PATCH 3/6] gpio: omap: " Krzysztof Kozlowski
2020-08-28  8:01   ` Grygorii Strashko [this message]
2020-08-27 20:08 ` [PATCH 4/6] gpio: pca953x: " Krzysztof Kozlowski
2020-08-27 20:08 ` [PATCH 5/6] gpio: pisosr: " Krzysztof Kozlowski
2020-08-27 20:08 ` [PATCH 6/6] gpio: zynq: " Krzysztof Kozlowski
2020-08-28  5:20   ` Michal Simek
2020-09-12  9:26   ` Linus Walleij
2020-08-28 10:03 ` [PATCH 1/6] gpio: bcm-kona: " Andy Shevchenko
2020-08-28 17:15 ` Florian Fainelli
2020-08-28 18:17 ` Bartosz Golaszewski
2020-09-12  9:27   ` Linus Walleij

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0013c2d6-6587-3646-35f2-3804fb5b244c@ti.com \
    --to=grygorii.strashko@ti.com \
    --cc=bcm-kernel-feedback-list@broadcom.com \
    --cc=bgolaszewski@baylibre.com \
    --cc=f.fainelli@gmail.com \
    --cc=j-keerthy@ti.com \
    --cc=khilman@kernel.org \
    --cc=krzk@kernel.org \
    --cc=linus.walleij@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=michal.simek@xilinx.com \
    --cc=rjui@broadcom.com \
    --cc=sbranden@broadcom.com \
    --cc=ssantosh@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).