Created
April 29, 2019 16:28
-
-
Save digitalsanity/fed66755d02de3ee6dcc1ecb92731861 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
gpio-keys { | |
> + compatible = "gpio-keys"; | |
> + #address-cells = <1>; | |
> + #size-cells = <0>; | |
#address-cells and #size-cells aren't necessary here. | |
> + autorepeat; | |
> + | |
> + pinctrl-names = "default"; | |
> + pinctrl-0 = <&power_key>; | |
> + | |
> + button@0 { | |
Nit: this doesn't have a reg property, so shouldn't have a unit address | |
in the name either - it could be named "button0" or just "button", or | |
maybe "power-key". | |
> + debounce-interval = <100>; | |
> + gpios = <&gpio0 RK_PA5 GPIO_ACTIVE_LOW>; | |
> + label = "GPIO Key Power"; | |
> + linux,code = <KEY_POWER>; | |
> + linux,input-type = <1>; | |
The binding explicitly defines 1 to be the default value, so it | |
shouldn't really need to be specified. | |
> + wakeup-source; | |
> + }; | |
> + }; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment