Wolfgang Wallner 854901ccd4 gpio: Return -ENODEV if gpio_hog_lookup_name() is empty
If CONFIG_GPIO_HOG is not set, then gpio_hog_lookup_name() is empty,
and thus does not initialize any of its parameters. It does still
return 0 though, and so any calling function might assume that the
parameters have been initialized successfully.

Change the return value to -ENODEV in this case, as the function
would in the case when CONFIG_GPIO_HOG is set but the gpio hog
could not be found.

Signed-off-by: Wolfgang Wallner <wolfgang.wallner@br-automation.com>
Reviewed-by: Heiko Schocher <hs@nabladev.com>
2025-11-06 08:20:22 -06:00
..
2025-10-10 10:26:53 -06:00
2025-10-10 10:26:53 -06:00
2023-11-02 11:30:18 +01:00