OSDN Git Service

regulator: gpio: Fix some error handling paths in 'gpio_regulator_probe()'
authorChristophe Jaillet <christophe.jaillet@wanadoo.fr>
Tue, 13 Mar 2018 20:33:11 +0000 (21:33 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 30 May 2018 05:50:45 +0000 (07:50 +0200)
commit121de4edcab749b1ab69c47b5c2a1dec8a0d40ef
tree807aa592e0b29fa3c98b8c033f4620a6af5f8b71
parent19434e74192e86218f3a727cbd90000148618249
regulator: gpio: Fix some error handling paths in 'gpio_regulator_probe()'

[ Upstream commit ed8cffda27dea6fd3dafb3ee881c5a786edac9ca ]

Re-order error handling code and gotos to avoid leaks in error handling
paths.

Fixes: 9f946099fe19 ("regulator: gpio: fix parsing of gpio list")
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/regulator/gpio-regulator.c