]> git.baikalelectronics.ru Git - kernel.git/commit
Input: pm8941-pwrkey - abstract register offsets and event code
authorVinod Koul <vkoul@kernel.org>
Tue, 31 Jul 2018 05:57:33 +0000 (22:57 -0700)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Tue, 31 Jul 2018 06:11:16 +0000 (23:11 -0700)
commitde4a5291ac266eb716605d6731fe49ba26b61202
tree0231a630e6c4dd9d1175b7745be6a1ca25805ba9
parent6e91fa398e087d62d3b9de700abc87001740c007
Input: pm8941-pwrkey - abstract register offsets and event code

In order to support resin thru the pwrkey driver (they are very
similar in nature) we need to abstract the handling in this driver.

First we abstract pull_up_bit and status_bit along in driver data.
The event code sent for key events is quiried from DT.

Since the device can be child of pon lookup regmap and reg from
parent if lookup fails (we are child).

Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Reviewed-by: Rob Herring <robh@kernel.org>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Documentation/devicetree/bindings/input/qcom,pm8941-pwrkey.txt
drivers/input/misc/pm8941-pwrkey.c