All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Niklas Söderlund" <niklas.soderlund@ragnatech.se>
To: Geert Uytterhoeven <geert+renesas@glider.be>
Cc: Linus Walleij <linus.walleij@linaro.org>,
	Bartosz Golaszewski <bgolaszewski@baylibre.com>,
	linux-gpio@vger.kernel.org, linux-renesas-soc@vger.kernel.org
Subject: Re: [PATCH] gpio: rcar: Always use local variable dev in gpio_rcar_probe()
Date: Wed, 14 Jul 2021 16:31:46 +0200	[thread overview]
Message-ID: <YO71UmT5tqOpSxcB@oden.dyn.berto.se> (raw)
In-Reply-To: <c2d40c6934507ee694be43cda24387a1feef7b10.1626267044.git.geert+renesas@glider.be>

Hi Geert,

On 2021-07-14 14:51:13 +0200, Geert Uytterhoeven wrote:
> As we have already have a pointer to the device structure in a local
> variable in gpio_rcar_probe(), we can just use "dev" instead of
> "p->dev".
> 
> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>

Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>

> ---
>  drivers/gpio/gpio-rcar.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/gpio/gpio-rcar.c b/drivers/gpio/gpio-rcar.c
> index e7092d5fe700d2ce..ae1ffb2b230d4a32 100644
> --- a/drivers/gpio/gpio-rcar.c
> +++ b/drivers/gpio/gpio-rcar.c
> @@ -564,9 +564,9 @@ static int gpio_rcar_probe(struct platform_device *pdev)
>  	}
>  
>  	if (p->info.has_inen) {
> -		pm_runtime_get_sync(p->dev);
> +		pm_runtime_get_sync(dev);
>  		gpio_rcar_enable_inputs(p);
> -		pm_runtime_put(p->dev);
> +		pm_runtime_put(dev);
>  	}
>  
>  	dev_info(dev, "driving %d GPIOs\n", npins);
> -- 
> 2.25.1
> 

-- 
Regards,
Niklas Söderlund

  reply	other threads:[~2021-07-14 14:31 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-14 12:51 [PATCH] gpio: rcar: Always use local variable dev in gpio_rcar_probe() Geert Uytterhoeven
2021-07-14 14:31 ` Niklas Söderlund [this message]
2021-07-16  8:22 ` Bartosz Golaszewski

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=YO71UmT5tqOpSxcB@oden.dyn.berto.se \
    --to=niklas.soderlund@ragnatech.se \
    --cc=bgolaszewski@baylibre.com \
    --cc=geert+renesas@glider.be \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-renesas-soc@vger.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.