Skip to contentSkip to conversation

ARM: dts: imx53-qsb: Fix gpio button polarity

PATCH New Sascha Hauer 2 participants 2 messages Mar 1, 2016

Subsystems (2)
lore
Share & tools
lore

Sascha Hauer

author maintainer
#0 lore raw

PATCH 1/1 ARM: dts: imx53-qsb: Fix gpio button polarity

The polarity of the gpio buttons is defined to '0' which is active high. The buttons are active low though which has been verified by testing it and by looking into the schematics. While at it use defines rathers than numbers for the key codes.

---
 arch/arm/boot/dts/imx53-qsb-common.dtsi | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
arch/arm/boot/dts/imx53-qsb-common.dtsi +6 -6
index 53fd75c..e340bcc 100644
@@ -59,21 +59,21 @@
 
 		power {
 			label = "Power Button";
-			gpios = <&gpio1 8 0>;
-			linux,code = <116>; /* KEY_POWER */
+			gpios = <&gpio1 8 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_POWER>;
 		};
 
 		volume-up {
 			label = "Volume Up";
-			gpios = <&gpio2 14 0>;
-			linux,code = <115>; /* KEY_VOLUMEUP */
+			gpios = <&gpio2 14 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_VOLUMEUP>;
 			gpio-key,wakeup;
 		};
 
 		volume-down {
 			label = "Volume Down";
-			gpios = <&gpio2 15 0>;
-			linux,code = <114>; /* KEY_VOLUMEDOWN */
+			gpios = <&gpio2 15 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_VOLUMEDOWN>;
 			gpio-key,wakeup;
 		};
 	};
Signature · 1 line
2.7.0
Applied
#1 lore raw

PATCH 1/1 ARM: dts: imx53-qsb: Fix gpio button polarity

Quoted 6 lines · Sascha Hauer

The polarity of the gpio buttons is defined to '0' which is active high. The buttons are active low though which has been verified by testing it and by looking into the schematics. While at it use defines rathers than numbers for the key codes.

Applied, thanks.