Commit 2a6fc3cb authored by Dmitry Osipenko's avatar Dmitry Osipenko Committed by Thierry Reding

drm/tegra: Fix gpiod_get_from_of_node() regression

That function now returns ERR_PTR instead of NULL if "hpd-gpio" is not
present in device-tree. The offending patch missed to adapt the Tegra's
DRM driver for the API change.

Fixes: 025bf377 ("gpio: Fix return value mismatch of function gpiod_get_from_of_node()")
Signed-off-by: default avatarDmitry Osipenko <digetx@gmail.com>
Acked-by: default avatarJon Hunter <jonathanh@nvidia.com>
Signed-off-by: default avatarThierry Reding <treding@nvidia.com>
parent 5f9e832c
...@@ -126,8 +126,12 @@ int tegra_output_probe(struct tegra_output *output) ...@@ -126,8 +126,12 @@ int tegra_output_probe(struct tegra_output *output)
"nvidia,hpd-gpio", 0, "nvidia,hpd-gpio", 0,
GPIOD_IN, GPIOD_IN,
"HDMI hotplug detect"); "HDMI hotplug detect");
if (IS_ERR(output->hpd_gpio)) if (IS_ERR(output->hpd_gpio)) {
return PTR_ERR(output->hpd_gpio); if (PTR_ERR(output->hpd_gpio) != -ENOENT)
return PTR_ERR(output->hpd_gpio);
output->hpd_gpio = NULL;
}
if (output->hpd_gpio) { if (output->hpd_gpio) {
err = gpiod_to_irq(output->hpd_gpio); err = gpiod_to_irq(output->hpd_gpio);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment