Commit e56bb922 authored by Dmitry Torokhov's avatar Dmitry Torokhov Committed by Greg Kroah-Hartman

ACPI / gpio: do not fall back to parsing _CRS when we get a deferral

commit 693bdaa1 upstream.

If, while locating GPIOs by name, we get probe deferral, we should
immediately report it to caller rather than trying to fall back to parsing
unnamed GPIOs from _CRS block.
Signed-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
Acked-by: default avatarMika Westerberg <mika.westerberg@linux.intel.com>
Acked-and-Tested-by: default avatarHans de Goede <hdegoede@redhat.com>
Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 1c9925e6
...@@ -572,8 +572,10 @@ struct gpio_desc *acpi_find_gpio(struct device *dev, ...@@ -572,8 +572,10 @@ struct gpio_desc *acpi_find_gpio(struct device *dev,
} }
desc = acpi_get_gpiod_by_index(adev, propname, idx, &info); desc = acpi_get_gpiod_by_index(adev, propname, idx, &info);
if (!IS_ERR(desc) || (PTR_ERR(desc) == -EPROBE_DEFER)) if (!IS_ERR(desc))
break; break;
if (PTR_ERR(desc) == -EPROBE_DEFER)
return ERR_CAST(desc);
} }
/* Then from plain _CRS GPIOs */ /* Then from plain _CRS GPIOs */
......
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