Commit 7057fc74 authored by Andy Shevchenko's avatar Andy Shevchenko
Browse files

gpiolib: acpi: Remove never true check in acpi_get_gpiod_by_index()



The acpi_get_gpiod_by_index() never is called with adev being NULL.
Remove the redundant check.

Acked-by: default avatarMika Westerberg <mika.westerberg@linux.intel.com>
Signed-off-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
parent ace0ebe5
Loading
Loading
Loading
Loading
+0 −3
Original line number Diff line number Diff line
@@ -873,9 +873,6 @@ static struct gpio_desc *acpi_get_gpiod_by_index(struct acpi_device *adev,
	struct acpi_gpio_lookup lookup;
	int ret;

	if (!adev)
		return ERR_PTR(-ENODEV);

	memset(&lookup, 0, sizeof(lookup));
	lookup.index = index;