Ricardo Ribalda Delgado 19a4fbffc9 gpiolib: Free the last requested descriptor
The current code only frees N-1 gpios if an error occurs during
gpiod_set_transitory, gpiod_direction_output or gpiod_direction_input.
Leading to gpios that cannot be used by userspace nor other drivers.

Cc: Timur Tabi <timur@codeaurora.org>
Cc: stable@vger.kernel.org
Fixes: ab3dbcf78f60f46d ("gpioib: do not free unrequested descriptors)
Reported-by: Jan Lorenzen <jl@newtec.dk>
Reported-by: Jim Paris <jim@jtan.com>
Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2018-09-18 16:36:05 -07:00
..
2018-03-19 01:50:07 +01:00
2018-05-16 14:35:24 +02:00
2018-03-19 01:50:29 +01:00
2018-08-10 23:19:17 +02:00
2018-05-16 14:35:24 +02:00
2018-05-24 17:09:41 +02:00
2017-12-22 15:24:31 +01:00
2018-01-09 14:51:00 +01:00
2017-08-23 09:21:54 +02:00
2018-08-20 15:38:44 -07:00
2018-08-20 15:38:44 -07:00