]> rtime.felk.cvut.cz Git - hercules2020/nv-tegra/linux-4.4.git/commitdiff
arm: dts: add gpio keys dtsi for Green Arrow
authorIan Chang <ianc@nvidia.com>
Mon, 2 Mar 2015 06:38:11 +0000 (14:38 +0800)
committerDan Willemsen <dwillemsen@nvidia.com>
Sun, 5 Apr 2015 01:57:42 +0000 (18:57 -0700)
Adding keys dsti for Green Arrow (P2267)

bug 200081186

Change-Id: Id4b3e2651deb910764e56399eede4d5018a20b7e
Signed-off-by: Ian Chang <ianc@nvidia.com>
Reviewed-on: http://git-master/r/712433
Reviewed-by: Robert Shih <rshih@nvidia.com>
Tested-by: Robert Shih <rshih@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
arch/arm/boot/dts/tegra124-green-arrow-p2267-base-a00.dts
arch/arm/boot/dts/tegra124-platforms/tegra124-green-arrow-keys-p2267-1000-a00.dtsi [new file with mode: 0644]

index 2b708dbfdf2e8d5db11a5540254f6c47259b614c..2de3e738bc6c72696986315ef764e377c953a1f2 100644 (file)
@@ -20,9 +20,9 @@
 #include "tegra124-platforms/tegra124-green-arrow-pinmux-p2267-1000-a00.dtsi"
 #include "tegra124-platforms/tegra124-green-arrow-p2267-io-common.dtsi"
 #include "tegra124-platforms/tegra124-green-arrow-p2267-powertree-e1936-1000-a00.dtsi"
-#include "tegra124-platforms/tegra124-tn8-keys-p1761-1270-a03.dtsi"
 #include "tegra124-platforms/tegra124-green-arrow-touch.dtsi"
 #include "tegra124-platforms/tegra124-green-arrow-p2267-sensor-1000-a00.dtsi"
+#include "tegra124-platforms/tegra124-green-arrow-keys-p2267-1000-a00.dtsi"
 
 / {
        model = "NVIDIA Tegra124 Green Arrow FFD";
                linux,initrd-start = <0x85000000>;
                linux,initrd-end = <0x851bc400>;
        };
-
-       gpio-keys {
-               camera_focus {
-                       status = "disabled";
-               };
-       };
 };
diff --git a/arch/arm/boot/dts/tegra124-platforms/tegra124-green-arrow-keys-p2267-1000-a00.dtsi b/arch/arm/boot/dts/tegra124-platforms/tegra124-green-arrow-keys-p2267-1000-a00.dtsi
new file mode 100644 (file)
index 0000000..6c1c8c9
--- /dev/null
@@ -0,0 +1,61 @@
+/*
+ * Copyright (c) 2015, NVIDIA CORPORATION.  All rights reserved.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
+ * more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program.  If not, see <http://www.gnu.org/licenses/>.
+*/
+
+
+#include <dt-bindings/gpio/tegra-gpio.h>
+#include <dt-bindings/input/input.h>
+
+/ {
+       gpio-keys {
+               compatible = "gpio-keys";
+
+               power {
+                       label = "Power";
+                       gpios = <&gpio TEGRA_GPIO(Q, 0) GPIO_ACTIVE_LOW>;
+                       linux,code = <KEY_POWER>;
+                       gpio-key,wakeup;
+               };
+
+               volume_down {
+                       label = "Volume Down";
+                       gpios = <&gpio TEGRA_GPIO(Q, 7) GPIO_ACTIVE_LOW>;
+                       linux,code = <KEY_VOLUMEDOWN>;
+               };
+
+               volume_up {
+                       label = "Volume Up";
+                       gpios = <&gpio TEGRA_GPIO(Q, 6) GPIO_ACTIVE_LOW>;
+                       linux,code = <KEY_VOLUMEUP>;
+               };
+
+               sw_table_mode {
+                       label = "SW Table Mode";
+                       gpios = <&gpio TEGRA_GPIO(W, 3) GPIO_ACTIVE_LOW>;
+                       linux,code = <SW_TABLET_MODE>;
+                       linux,input-type = <EV_SW>;
+                       gpio-key,wakeup;
+               };
+               sw_lid {
+                       label = "SW LID";
+                       gpios = <&gpio TEGRA_GPIO(R, 4) GPIO_ACTIVE_LOW>;
+                       linux,code = <SW_LID>;
+                       linux,input-type = <EV_SW>;
+                       gpio-key,wakeup;
+                       debounce-interval = <300>;
+               };
+       };
+};