linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: troy.kisky@boundarydevices.com (Troy Kisky)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH V2 08/13] ARM: dts: imx6qdl-sabrelite: add gpio-keys
Date: Mon, 16 Dec 2013 18:12:58 -0700	[thread overview]
Message-ID: <1387242783-1462-9-git-send-email-troy.kisky@boundarydevices.com> (raw)
In-Reply-To: <1387242783-1462-1-git-send-email-troy.kisky@boundarydevices.com>

Add power, menu, home, back, volume up, and volume down
buttons.

Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com>

---
v2: add #include <dt-bindings/input/input.h>
to substitute KEY_POWER for 116
---
 arch/arm/boot/dts/imx6qdl-sabrelite.dtsi | 54 ++++++++++++++++++++++++++++++++
 1 file changed, 54 insertions(+)

diff --git a/arch/arm/boot/dts/imx6qdl-sabrelite.dtsi b/arch/arm/boot/dts/imx6qdl-sabrelite.dtsi
index 29f0b40..36ffbb2 100644
--- a/arch/arm/boot/dts/imx6qdl-sabrelite.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-sabrelite.dtsi
@@ -9,6 +9,8 @@
  * http://www.opensource.org/licenses/gpl-license.html
  * http://www.gnu.org/copyleft/gpl.html
  */
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
 
 / {
 	memory {
@@ -49,6 +51,46 @@
 		};
 	};
 
+	gpio-keys {
+		compatible = "gpio-keys";
+		power {
+			label = "Power Button";
+			gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_POWER>;
+			gpio-key,wakeup;
+		};
+
+		menu {
+			label = "Menu";
+			gpios = <&gpio2 1 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_MENU>;
+		};
+
+		home {
+			label = "Home";
+			gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_HOME>;
+		};
+
+		back {
+			label = "Back";
+			gpios = <&gpio2 2 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_BACK>;
+		};
+
+		volume-up {
+			label = "Volume Up";
+			gpios = <&gpio7 13 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_VOLUMEUP>;
+		};
+
+		volume-down {
+			label = "Volume Down";
+			gpios = <&gpio4 5 GPIO_ACTIVE_LOW>;
+			linux,code = <KEY_VOLUMEDOWN>;
+		};
+	};
+
 	sound {
 		compatible = "fsl,imx6q-sabrelite-sgtl5000",
 			     "fsl,imx-audio-sgtl5000";
@@ -116,6 +158,18 @@
 			fsl,pins = <
 				/* SGTL5000 sys_mclk */
 				MX6QDL_PAD_GPIO_0__CCM_CLKO1    0x030b0
+				/* Power Button */
+				MX6QDL_PAD_NANDF_D3__GPIO2_IO03	0x1b0b0
+				/* Menu Button */
+				MX6QDL_PAD_NANDF_D1__GPIO2_IO01	0x1b0b0
+				/* Home Button */
+				MX6QDL_PAD_NANDF_D4__GPIO2_IO04	0x1b0b0
+				/* Back Button */
+				MX6QDL_PAD_NANDF_D2__GPIO2_IO02	0x1b0b0
+				/* Volume Up Button */
+				MX6QDL_PAD_GPIO_18__GPIO7_IO13	0x1b0b0
+				/* Volume Down Button */
+				MX6QDL_PAD_GPIO_19__GPIO4_IO05	0x1b0b0
 			>;
 		};
 
-- 
1.8.1.2

  parent reply	other threads:[~2013-12-17  1:12 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-17  1:12 [PATCH V2 00/13] Update Sabre Lite Troy Kisky
2013-12-17  1:12 ` [PATCH V2 01/13] ARM: dts: imx6qdl-sabrelite: move pcie to imx6qdl-sabrelite.dtsi Troy Kisky
2013-12-17  1:12 ` [PATCH V2 02/13] ARM: dts: imx6qdl-sabrelite: move USDHC4 CD to pinctrl_usdhc4 Troy Kisky
2013-12-17  1:12 ` [PATCH V2 03/13] ARM: dts: imx6qdl-sabrelite: move USDHC3 CD/WP to pinctrl_usdhc3 Troy Kisky
2013-12-17  1:12 ` [PATCH V2 04/13] ARM: dts: imx6qdl-sabrelite: move spi-nor CS to pinctrl_ecspi1 Troy Kisky
2013-12-17  1:12 ` [PATCH V2 05/13] ARM: dts: imx6qdl-sabrelite: move usbotg power enable to pinctrl_usbotg Troy Kisky
2013-12-17  1:12 ` [PATCH V2 06/13] ARM: dts: imx6qdl-sabrelite: move phy reset to pinctrl_enet Troy Kisky
2013-12-17  1:12 ` [PATCH V2 07/13] ARM: dts: imx6qdl-sabrelite: explicitly set pad for SGTL5000 sys_mclk Troy Kisky
2013-12-17  1:12 ` Troy Kisky [this message]
2013-12-17 13:46   ` [PATCH V2 08/13] ARM: dts: imx6qdl-sabrelite: add gpio-keys Shawn Guo
2013-12-17  1:12 ` [PATCH V2 09/13] ARM: dts: imx6qdl-sabrelite: add pwms for backlights Troy Kisky
2013-12-17  1:13 ` [PATCH V2 10/13] ARM: dts: imx6qdl-sabrelite: add skews for Micrel phy Troy Kisky
2013-12-17  1:13 ` [PATCH V2 11/13] ARM: dts: imx6qdl-sabrelite: fix ENET group Troy Kisky
2013-12-17  1:13 ` [PATCH V2 12/13] ARM: dts: imx6qdl-sabrelite: Add over-current pin to usbotg Troy Kisky
2013-12-17  1:13 ` [PATCH V2 13/13] ARM: dts: imx: add nitrogen6x board Troy Kisky
2013-12-17 13:48   ` Shawn Guo
2013-12-17 18:49     ` Troy Kisky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1387242783-1462-9-git-send-email-troy.kisky@boundarydevices.com \
    --to=troy.kisky@boundarydevices.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).