linux-tegra.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Agner <stefan@agner.ch>
To: thierry.reding@gmail.com, airlied@linux.ie
Cc: jonathanh@nvidia.com, dri-devel@lists.freedesktop.org,
	linux-tegra@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] drm/tegra: return with probe defer if GPIO subsystem is not ready
Date: Thu, 06 Sep 2018 16:31:42 -0700	[thread overview]
Message-ID: <de84d04c902d1f7f22b6f024b853a1c7@agner.ch> (raw)
In-Reply-To: <20180726133606.14587-1-stefan@agner.ch>

On 26.07.2018 06:36, Stefan Agner wrote:
> If the GPIO subsystem is not ready make sure to return -EPROBE_DEFER
> instead of silently continuing without HPD.
> 
> Reported-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
> Signed-off-by: Stefan Agner <stefan@agner.ch>

I think this did not get merged yet, any chance to get it in?

--
Stefan

> ---
>  drivers/gpu/drm/tegra/output.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/tegra/output.c b/drivers/gpu/drm/tegra/output.c
> index ffe34bd0bb9d..4bcefe455afd 100644
> --- a/drivers/gpu/drm/tegra/output.c
> +++ b/drivers/gpu/drm/tegra/output.c
> @@ -133,7 +133,9 @@ int tegra_output_probe(struct tegra_output *output)
>  	output->hpd_gpio = of_get_named_gpio_flags(output->of_node,
>  						   "nvidia,hpd-gpio", 0,
>  						   &output->hpd_gpio_flags);
> -	if (gpio_is_valid(output->hpd_gpio)) {
> +	if (output->hpd_gpio == -EPROBE_DEFER) {
> +		return -EPROBE_DEFER;
> +	} else if (gpio_is_valid(output->hpd_gpio)) {
>  		unsigned long flags;
>  
>  		err = gpio_request_one(output->hpd_gpio, GPIOF_DIR_IN,

  reply	other threads:[~2018-09-06 23:31 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-26 13:36 [PATCH] drm/tegra: return with probe defer if GPIO subsystem is not ready Stefan Agner
2018-09-06 23:31 ` Stefan Agner [this message]
2019-07-26 14:23   ` Stefan Agner
2019-07-26 14:46     ` Dmitry Osipenko
2019-07-26 14:57       ` Stefan Agner
2019-07-26 15:00         ` Dmitry Osipenko

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=de84d04c902d1f7f22b6f024b853a1c7@agner.ch \
    --to=stefan@agner.ch \
    --cc=airlied@linux.ie \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=jonathanh@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=thierry.reding@gmail.com \
    /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).