提交 b9fa3b62 编写于 作者: L Ludovic Desroches 提交者: Zheng Zengkai

ARM: dts: at91: change the key code of the gpio key

stable inclusion
from stable-5.10.36
commit 125b3590d1fba5a8fe39c48b9a4eb732e7c336bd
bugzilla: 51867
CVE: NA

--------------------------------

[ Upstream commit ca7a049a ]

Having a button code and not a key code causes issues with libinput.
udev won't set ID_INPUT_KEY. If it is forced, then it causes a bug
within libinput.
Signed-off-by: NLudovic Desroches <ludovic.desroches@microchip.com>
Signed-off-by: NNicolas Ferre <nicolas.ferre@microchip.com>
Link: https://lore.kernel.org/r/20210402130227.21478-1-nicolas.ferre@microchip.comSigned-off-by: NSasha Levin <sashal@kernel.org>
Signed-off-by: NChen Jun <chenjun102@huawei.com>
Acked-by: NWeilong Chen <chenweilong@huawei.com>
Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
上级 8aea991d
......@@ -8,6 +8,7 @@
*/
/dts-v1/;
#include "sam9x60.dtsi"
#include <dt-bindings/input/input.h>
/ {
model = "Microchip SAM9X60-EK";
......@@ -84,7 +85,7 @@
sw1 {
label = "SW1";
gpios = <&pioD 18 GPIO_ACTIVE_LOW>;
linux,code=<0x104>;
linux,code=<KEY_PROG1>;
wakeup-source;
};
};
......
......@@ -11,6 +11,7 @@
#include "at91-sama5d27_som1.dtsi"
#include <dt-bindings/mfd/atmel-flexcom.h>
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
/ {
model = "Atmel SAMA5D27 SOM1 EK";
......@@ -467,7 +468,7 @@
pb4 {
label = "USER";
gpios = <&pioA PIN_PA29 GPIO_ACTIVE_LOW>;
linux,code = <0x104>;
linux,code = <KEY_PROG1>;
wakeup-source;
};
};
......
......@@ -8,6 +8,7 @@
*/
/dts-v1/;
#include "at91-sama5d27_wlsom1.dtsi"
#include <dt-bindings/input/input.h>
/ {
model = "Microchip SAMA5D27 WLSOM1 EK";
......@@ -35,7 +36,7 @@
sw4 {
label = "USER BUTTON";
gpios = <&pioA PIN_PB2 GPIO_ACTIVE_LOW>;
linux,code = <0x104>;
linux,code = <KEY_PROG1>;
wakeup-source;
};
};
......
......@@ -12,6 +12,7 @@
#include "sama5d2.dtsi"
#include "sama5d2-pinfunc.h"
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
#include <dt-bindings/mfd/atmel-flexcom.h>
/ {
......@@ -51,7 +52,7 @@
sw4 {
label = "USER_PB1";
gpios = <&pioA PIN_PD0 GPIO_ACTIVE_LOW>;
linux,code = <0x104>;
linux,code = <KEY_PROG1>;
wakeup-source;
};
};
......
......@@ -11,6 +11,7 @@
#include "sama5d2-pinfunc.h"
#include <dt-bindings/mfd/atmel-flexcom.h>
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
#include <dt-bindings/pinctrl/at91.h>
/ {
......@@ -403,7 +404,7 @@
bp1 {
label = "PB_USER";
gpios = <&pioA PIN_PA10 GPIO_ACTIVE_LOW>;
linux,code = <0x104>;
linux,code = <KEY_PROG1>;
wakeup-source;
};
};
......
......@@ -10,6 +10,7 @@
#include "sama5d2-pinfunc.h"
#include <dt-bindings/mfd/atmel-flexcom.h>
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
#include <dt-bindings/regulator/active-semi,8945a-regulator.h>
/ {
......@@ -713,7 +714,7 @@
bp1 {
label = "PB_USER";
gpios = <&pioA PIN_PB9 GPIO_ACTIVE_LOW>;
linux,code = <0x104>;
linux,code = <KEY_PROG1>;
wakeup-source;
};
};
......
......@@ -7,6 +7,7 @@
*/
/dts-v1/;
#include "sama5d36.dtsi"
#include <dt-bindings/input/input.h>
/ {
model = "SAMA5D3 Xplained";
......@@ -354,7 +355,7 @@
bp3 {
label = "PB_USER";
gpios = <&pioE 29 GPIO_ACTIVE_LOW>;
linux,code = <0x104>;
linux,code = <KEY_PROG1>;
wakeup-source;
};
};
......
......@@ -7,6 +7,7 @@
*/
/dts-v1/;
#include "at91sam9260.dtsi"
#include <dt-bindings/input/input.h>
/ {
model = "Atmel at91sam9260ek";
......@@ -156,7 +157,7 @@
btn4 {
label = "Button 4";
gpios = <&pioA 31 GPIO_ACTIVE_LOW>;
linux,code = <0x104>;
linux,code = <KEY_PROG1>;
wakeup-source;
};
};
......
......@@ -5,6 +5,7 @@
* Copyright (C) 2012 Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
*/
#include "at91sam9g20.dtsi"
#include <dt-bindings/input/input.h>
/ {
......@@ -234,7 +235,7 @@
btn4 {
label = "Button 4";
gpios = <&pioA 31 GPIO_ACTIVE_LOW>;
linux,code = <0x104>;
linux,code = <KEY_PROG1>;
wakeup-source;
};
};
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册