Commit ecff1ced authored by David Collins's avatar David Collins
Browse files

regulator: msm-gpio-regulator: Correct gpio_request error handling



The gpio_vreg_request_gpio() function inside of the
msm-gpio-regulator driver can return successfully even if
gpio_request() has failed. This can lead to a kernel crash via
null pointer dereference when later gpio and regulator functions
are called.  Modify gpio_vreg_request_gpio() so that it returns
an error immediately if gpio_request() fails.

Change-Id: I59364eb9efda6c2149b807db9a00e782d8ae6bb8
Signed-off-by: default avatarDavid Collins <collinsd@codeaurora.org>
parent 75c34ca1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment