* [PATCH 1/4] ARM: STi: DT: add keyscan for stih415
2014-05-05 15:38 [PATCH 0/4] Enable ST Keyscan driver Gabriel FERNANDEZ
@ 2014-05-05 15:38 ` Gabriel FERNANDEZ
2014-05-05 15:38 ` [PATCH 2/4] ARM: STi: DT: add keyscan for stih416 Gabriel FERNANDEZ
` (3 subsequent siblings)
4 siblings, 0 replies; 7+ messages in thread
From: Gabriel FERNANDEZ @ 2014-05-05 15:38 UTC (permalink / raw)
To: linux-arm-kernel
Add keyscan support for stih415.
It is put disabled by default because it is not enabled on all boards
Also there are PIOs conflict with already claimed lines.
Signed-off-by: Giuseppe Condorelli <giuseppe.condorelli@st•com>
Signed-off-by: Gabriel Fernandez <gabriel.fernandez@linaro•org>
---
arch/arm/boot/dts/stih415-pinctrl.dtsi | 16 ++++++++++++++++
arch/arm/boot/dts/stih415.dtsi | 12 ++++++++++++
2 files changed, 28 insertions(+)
diff --git a/arch/arm/boot/dts/stih415-pinctrl.dtsi b/arch/arm/boot/dts/stih415-pinctrl.dtsi
index 81df870..8509a03 100644
--- a/arch/arm/boot/dts/stih415-pinctrl.dtsi
+++ b/arch/arm/boot/dts/stih415-pinctrl.dtsi
@@ -102,6 +102,22 @@
};
};
+ keyscan {
+ pinctrl_keyscan: keyscan {
+ st,pins {
+ keyin0 = <&PIO0 2 ALT2 IN>;
+ keyin1 = <&PIO0 3 ALT2 IN>;
+ keyin2 = <&PIO0 4 ALT2 IN>;
+ keyin3 = <&PIO2 6 ALT2 IN>;
+
+ keyout0 = <&PIO1 6 ALT2 OUT>;
+ keyout1 = <&PIO1 7 ALT2 OUT>;
+ keyout2 = <&PIO0 6 ALT2 OUT>;
+ keyout3 = <&PIO2 7 ALT2 OUT>;
+ };
+ };
+ };
+
sbc_i2c0 {
pinctrl_sbc_i2c0_default: sbc_i2c0-default {
st,pins {
diff --git a/arch/arm/boot/dts/stih415.dtsi b/arch/arm/boot/dts/stih415.dtsi
index d89064c..ba0905c 100644
--- a/arch/arm/boot/dts/stih415.dtsi
+++ b/arch/arm/boot/dts/stih415.dtsi
@@ -206,5 +206,17 @@
pinctrl-0 = <&pinctrl_ir>;
resets = <&softreset STIH415_IRB_SOFTRESET>;
};
+
+ keyscan: keyscan at fe4b0000 {
+ compatible = "st,sti-keyscan";
+ status = "disabled";
+ reg = <0xfe4b0000 0x2000>;
+ interrupts = <GIC_SPI 212 IRQ_TYPE_NONE>;
+ clocks = <&CLK_SYSIN>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&pinctrl_keyscan>;
+ resets = <&powerdown STIH415_KEYSCAN_POWERDOWN>,
+ <&softreset STIH415_KEYSCAN_SOFTRESET>;
+ };
};
};
--
1.9.1
^ permalink raw reply related [flat|nested] 7+ messages in thread* [PATCH 2/4] ARM: STi: DT: add keyscan for stih416
2014-05-05 15:38 [PATCH 0/4] Enable ST Keyscan driver Gabriel FERNANDEZ
2014-05-05 15:38 ` [PATCH 1/4] ARM: STi: DT: add keyscan for stih415 Gabriel FERNANDEZ
@ 2014-05-05 15:38 ` Gabriel FERNANDEZ
2014-05-05 15:38 ` [PATCH 3/4] ARM: STi: DT: add keyscan for stih41x-b2000 Gabriel FERNANDEZ
` (2 subsequent siblings)
4 siblings, 0 replies; 7+ messages in thread
From: Gabriel FERNANDEZ @ 2014-05-05 15:38 UTC (permalink / raw)
To: linux-arm-kernel
Add keyscan support for stih416.
It is disabled by default given that it is not enabled on all boards.
Also there are PIOs conflict with already claimed lines.
Signed-off-by: Giuseppe Condorelli <giuseppe.condorelli@st•com>
Signed-off-by: Gabriel Fernandez <gabriel.fernandez@linaro•org>
---
arch/arm/boot/dts/stih416-pinctrl.dtsi | 16 ++++++++++++++++
arch/arm/boot/dts/stih416.dtsi | 12 ++++++++++++
2 files changed, 28 insertions(+)
diff --git a/arch/arm/boot/dts/stih416-pinctrl.dtsi b/arch/arm/boot/dts/stih416-pinctrl.dtsi
index 250d5ec..ee6c119 100644
--- a/arch/arm/boot/dts/stih416-pinctrl.dtsi
+++ b/arch/arm/boot/dts/stih416-pinctrl.dtsi
@@ -122,6 +122,22 @@
};
};
+ keyscan {
+ pinctrl_keyscan: keyscan {
+ st,pins {
+ keyin0 = <&PIO0 2 ALT2 IN>;
+ keyin1 = <&PIO0 3 ALT2 IN>;
+ keyin2 = <&PIO0 4 ALT2 IN>;
+ keyin3 = <&PIO2 6 ALT2 IN>;
+
+ keyout0 = <&PIO1 6 ALT2 OUT>;
+ keyout1 = <&PIO1 7 ALT2 OUT>;
+ keyout2 = <&PIO0 6 ALT2 OUT>;
+ keyout3 = <&PIO2 7 ALT2 OUT>;
+ };
+ };
+ };
+
sbc_i2c0 {
pinctrl_sbc_i2c0_default: sbc_i2c0-default {
st,pins {
diff --git a/arch/arm/boot/dts/stih416.dtsi b/arch/arm/boot/dts/stih416.dtsi
index 78746d2..d3bc263 100644
--- a/arch/arm/boot/dts/stih416.dtsi
+++ b/arch/arm/boot/dts/stih416.dtsi
@@ -224,5 +224,17 @@
status = "disabled";
};
+
+ keyscan: keyscan at fe4b0000 {
+ compatible = "st,sti-keyscan";
+ status = "disabled";
+ reg = <0xfe4b0000 0x2000>;
+ interrupts = <GIC_SPI 212 IRQ_TYPE_NONE>;
+ clocks = <&CLK_SYSIN>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&pinctrl_keyscan>;
+ resets = <&powerdown STIH416_KEYSCAN_POWERDOWN>,
+ <&softreset STIH416_KEYSCAN_SOFTRESET>;
+ };
};
};
--
1.9.1
^ permalink raw reply related [flat|nested] 7+ messages in thread* [PATCH 3/4] ARM: STi: DT: add keyscan for stih41x-b2000
2014-05-05 15:38 [PATCH 0/4] Enable ST Keyscan driver Gabriel FERNANDEZ
2014-05-05 15:38 ` [PATCH 1/4] ARM: STi: DT: add keyscan for stih415 Gabriel FERNANDEZ
2014-05-05 15:38 ` [PATCH 2/4] ARM: STi: DT: add keyscan for stih416 Gabriel FERNANDEZ
@ 2014-05-05 15:38 ` Gabriel FERNANDEZ
2014-05-05 15:38 ` [PATCH 4/4] ARM: multi_v7_defconfig: add ST Keyscan driver Gabriel FERNANDEZ
2014-05-06 12:39 ` [PATCH 0/4] Enable " Srinivas Kandagatla
4 siblings, 0 replies; 7+ messages in thread
From: Gabriel FERNANDEZ @ 2014-05-05 15:38 UTC (permalink / raw)
To: linux-arm-kernel
Add keyscan setup for stih415/h416 b2000.
Both have same raw/column lines number, debounce time and keymap.
Signed-off-by: Giuseppe Condorelli <giuseppe.condorelli@st•com>
Signed-off-by: Gabriel Fernandez <gabriel.fernandez@linaro•org>
---
arch/arm/boot/dts/stih41x-b2000.dtsi | 23 +++++++++++++++++++++++
1 file changed, 23 insertions(+)
diff --git a/arch/arm/boot/dts/stih41x-b2000.dtsi b/arch/arm/boot/dts/stih41x-b2000.dtsi
index bf65c49..403bf1b 100644
--- a/arch/arm/boot/dts/stih41x-b2000.dtsi
+++ b/arch/arm/boot/dts/stih41x-b2000.dtsi
@@ -6,6 +6,7 @@
* it under the terms of the GNU General Public License version 2 as
* publishhed by the Free Software Foundation.
*/
+#include <dt-bindings/input/input.h>
/ {
memory{
@@ -68,5 +69,27 @@
snps,reset-active-low;
snps,reset-delays-us = <0 10000 10000>;
};
+
+ keyscan: keyscan at fe4b0000 {
+ keypad,num-rows = <4>;
+ keypad,num-columns = <4>;
+ st,debounce-us = <5000>;
+ linux,keymap = < MATRIX_KEY(0x00, 0x00, KEY_F13)
+ MATRIX_KEY(0x00, 0x01, KEY_F9)
+ MATRIX_KEY(0x00, 0x02, KEY_F5)
+ MATRIX_KEY(0x00, 0x03, KEY_F1)
+ MATRIX_KEY(0x01, 0x00, KEY_F14)
+ MATRIX_KEY(0x01, 0x01, KEY_F10)
+ MATRIX_KEY(0x01, 0x02, KEY_F6)
+ MATRIX_KEY(0x01, 0x03, KEY_F2)
+ MATRIX_KEY(0x02, 0x00, KEY_F15)
+ MATRIX_KEY(0x02, 0x01, KEY_F11)
+ MATRIX_KEY(0x02, 0x02, KEY_F7)
+ MATRIX_KEY(0x02, 0x03, KEY_F3)
+ MATRIX_KEY(0x03, 0x00, KEY_F16)
+ MATRIX_KEY(0x03, 0x01, KEY_F12)
+ MATRIX_KEY(0x03, 0x02, KEY_F8)
+ MATRIX_KEY(0x03, 0x03, KEY_F4) >;
+ };
};
};
--
1.9.1
^ permalink raw reply related [flat|nested] 7+ messages in thread