linux_driver/input_sub_system/lubancat-button-input-overlay.dts
2024-11-19 11:37:38 +08:00

26 lines
776 B
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/dts-v1/;
/plugin/;
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/pinctrl/rockchip.h>
#include <dt-bindings/interrupt-controller/irq.h>
&{/} {
input_button: input_button {
status = "okay";
compatible = "input_button";
button-gpios = <&gpio0 RK_PB0 GPIO_ACTIVE_HIGH>; //引脚可以根据具体板卡修改,这里以GPIO0_B0
pinctrl-names = "default";
pinctrl-0 = <&input_button_pin>;
interrupt-parent = <&gpio0>;
interrupts = <RK_PB0 IRQ_TYPE_EDGE_BOTH>;
};
};
&{/pinctrl} {
pinctrl_button {
input_button_pin: input_button_pin {
rockchip,pins = <0 RK_PB0 RK_FUNC_GPIO &pcfg_pull_none>;
};
};
};