mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-05 09:49:58 -04:00
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: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
This commit is contained in:
@@ -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;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user