Axel Lin 5d92f71e68 Staging: android: timed_gpio: Fix resource leak in timed_gpio_probe error paths
If gpio_request fails, we need to free all allocated resources.
Current code uses wrong array index to access gpio_data array.
So current code actually frees gpio_data[i].gpio by j times.

This patch moves the error handling code to err_out and thus improves
readability.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-10 09:48:29 -07:00
..
2012-03-20 11:26:30 -07:00
2012-03-27 20:08:09 +02:00
2012-04-10 09:14:39 -07:00
2012-03-08 11:47:02 -08:00
2012-04-10 09:14:39 -07:00