gpiolib: use dev_err() when gpiod_configure_flags failed
When gpio-ranges property was missed to be added in the gpio node, using dev_err() to show an error message will helping to locate issues easier. Signed-off-by: Peng Fan <peng.fan@nxp.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
This commit is contained in:
committed by
Bartosz Golaszewski
parent
9164d6758a
commit
39c9049770
@@ -4237,7 +4237,7 @@ struct gpio_desc *gpiod_find_and_request(struct device *consumer,
|
||||
ret = gpiod_configure_flags(desc, con_id, lookupflags, flags);
|
||||
if (ret < 0) {
|
||||
gpiod_put(desc);
|
||||
dev_dbg(consumer, "setup of GPIO %s failed\n", name);
|
||||
dev_err(consumer, "setup of GPIO %s failed: %d\n", name, ret);
|
||||
return ERR_PTR(ret);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user