Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit d77f37cc authored by Michael Bohan's avatar Michael Bohan Committed by Stephen Boyd
Browse files

gpio: qpnp-pin: Properly mask gpio get value



When gpios are set to input, we return the input buffer status
from the STATUS1 register when the 'get' gpiochip callback is
invoked. This register also includes a bit that indicates whether
the pin is enabled.

Check to verify the pin is enabled, and if it is then return the
properly masked 1-bit value. Otherwise return an error, since the
API is not valid in this state.

Change-Id: I715e17f076d0dbd67397812f98e308f863c59b7c
Signed-off-by: default avatarMichael Bohan <mbohan@codeaurora.org>
parent eb9f84c6
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment