gpiolib: acpi: Check for errors first in acpi_find_gpio()
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Wed, 10 Apr 2024 20:21:47 +0000 (23:21 +0300)
committerAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Thu, 11 Apr 2024 13:37:08 +0000 (16:37 +0300)
commitd8a26a18d971cd52a9b253aa2cff7dcb20187711
treedc528265b7af148494098bfd84a56deb666e3189
parent7057fc74d6886471b7dcb4faadf56bd71e28296d
gpiolib: acpi: Check for errors first in acpi_find_gpio()

It's better to parse the code when the usual pattern is being used,
i.e. checking for error condition first.

There is no functional or code generation change (tested in LLVM).

Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
drivers/gpio/gpiolib-acpi.c