]> git.baikalelectronics.ru Git - kernel.git/commit
gpio: Propagate errors from chip->get()
authorBjorn Andersson <bjorn.andersson@sonymobile.com>
Fri, 28 Aug 2015 16:44:18 +0000 (09:44 -0700)
committerLinus Walleij <linus.walleij@linaro.org>
Mon, 14 Sep 2015 07:12:03 +0000 (09:12 +0200)
commit7d685d726162eebce9c09bd2d11ff493c4698fdd
tree8ec1e50230e9b0297253ccc7ad50903a16f7585f
parenta2a51ae70e6737fcd08075557ea5ebe4e9bc4216
gpio: Propagate errors from chip->get()

It's possible to have gpio chips hanging off unreliable remote buses
where the get() operation will fail to acquire a readout of the current
gpio state. Propagate these errors to the consumer so that they can
act on, retry or ignore these failing reads, instead of treating them as
the line being held high.

Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com>
Reviewed-by: Alexandre Courbot <acourbot@nvidia.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/gpio/gpiolib.c