this patch is based on linux master branch, implementation as following:
- add the i2c pinctrl which needed for using at91sam9n12 TWI
- enable qt1070
- trival fix for the gpio-key pin number
Changes in v2:
- remove comments as use micro
- using micro for interrupt trigger mode
Bo Shen (3):
arm: atmel: at91sam9n12: add pinctrl of TWI
arm: atmel: at91sam9n12: add qt1070 support
arm: atmel: at91sam9n12: correct pin number of gpio-key
arch/arm/boot/dts/at91sam9n12.dtsi | 20 ++++++++++++++++++++
arch/arm/boot/dts/at91sam9n12ek.dts | 18 +++++++++++++++++-
2 files changed, 37 insertions(+), 1 deletion(-)
--
1.7.9.5
add pinctrl of TWI for at91sam9n12 SoC
Signed-off-by: Bo Shen <[email protected]>
---
Changes in v2:
- remove comments as use micro
arch/arm/boot/dts/at91sam9n12.dtsi | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/arch/arm/boot/dts/at91sam9n12.dtsi b/arch/arm/boot/dts/at91sam9n12.dtsi
index bb7f564..9fb7ffd 100644
--- a/arch/arm/boot/dts/at91sam9n12.dtsi
+++ b/arch/arm/boot/dts/at91sam9n12.dtsi
@@ -291,6 +291,22 @@
};
};
+ i2c0 {
+ pinctrl_i2c0: i2c0-0 {
+ atmel,pins =
+ <AT91_PIOA 30 AT91_PERIPH_A AT91_PINCTRL_NONE
+ AT91_PIOA 31 AT91_PERIPH_A AT91_PINCTRL_NONE>;
+ };
+ };
+
+ i2c1 {
+ pinctrl_i2c1: i2c1-0 {
+ atmel,pins =
+ <AT91_PIOC 0 AT91_PERIPH_C AT91_PINCTRL_NONE
+ AT91_PIOC 1 AT91_PERIPH_C AT91_PINCTRL_NONE>;
+ };
+ };
+
tcb0 {
pinctrl_tcb0_tclk0: tcb0_tclk0-0 {
atmel,pins = <AT91_PIOA 24 AT91_PERIPH_A AT91_PINCTRL_NONE>;
@@ -471,6 +487,8 @@
dma-names = "tx", "rx";
#address-cells = <1>;
#size-cells = <0>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&pinctrl_i2c0>;
status = "disabled";
};
@@ -483,6 +501,8 @@
dma-names = "tx", "rx";
#address-cells = <1>;
#size-cells = <0>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&pinctrl_i2c1>;
status = "disabled";
};
--
1.7.9.5
correct pin number of gpio-key for at91sam9n12ek board
the pioB4 is connect to LED, the pioB3 use as gpio-key
Signed-off-by: Bo Shen <[email protected]>
---
Changes in v2: None
arch/arm/boot/dts/at91sam9n12ek.dts | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm/boot/dts/at91sam9n12ek.dts b/arch/arm/boot/dts/at91sam9n12ek.dts
index 7a95a28..3e86b05 100644
--- a/arch/arm/boot/dts/at91sam9n12ek.dts
+++ b/arch/arm/boot/dts/at91sam9n12ek.dts
@@ -137,7 +137,7 @@
enter {
label = "Enter";
- gpios = <&pioB 4 GPIO_ACTIVE_LOW>;
+ gpios = <&pioB 3 GPIO_ACTIVE_LOW>;
linux,code = <28>;
gpio-key,wakeup;
};
--
1.7.9.5
add qt1070 support on at91sam9n12ek board
Signed-off-by: Bo Shen <[email protected]>
---
Changes in v2:
- using micro for interrupt trigger mode
arch/arm/boot/dts/at91sam9n12ek.dts | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
diff --git a/arch/arm/boot/dts/at91sam9n12ek.dts b/arch/arm/boot/dts/at91sam9n12ek.dts
index d59b70c..7a95a28 100644
--- a/arch/arm/boot/dts/at91sam9n12ek.dts
+++ b/arch/arm/boot/dts/at91sam9n12ek.dts
@@ -40,6 +40,15 @@
i2c0: i2c@f8010000 {
status = "okay";
+
+ qt1070: keyboard@1b {
+ compatible = "qt1070";
+ reg = <0x1b>;
+ interrupt-parent = <&pioA>;
+ interrupts = <2 IRQ_TYPE_EDGE_FALLING>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&pinctrl_qt1070_irq>;
+ };
};
i2c1: i2c@f8014000 {
@@ -66,6 +75,13 @@
<AT91_PIOA 7 AT91_PERIPH_GPIO AT91_PINCTRL_PULL_UP_DEGLITCH>; /* PA7 gpio CD pin pull up and deglitch */
};
};
+
+ qt1070 {
+ pinctrl_qt1070_irq: qt1070_irq {
+ atmel,pins =
+ <AT91_PIOA 2 AT91_PERIPH_GPIO AT91_PINCTRL_PULL_UP_DEGLITCH>;
+ };
+ };
};
spi0: spi@f0000000 {
--
1.7.9.5
On 11/07/2013 05:30, Bo Shen :
> this patch is based on linux master branch, implementation as following:
> - add the i2c pinctrl which needed for using at91sam9n12 TWI
> - enable qt1070
> - trival fix for the gpio-key pin number
Acked-by: Nicolas Ferre <[email protected]>
On the whole series.
>
> Changes in v2:
> - remove comments as use micro
> - using micro for interrupt trigger mode
>
> Bo Shen (3):
> arm: atmel: at91sam9n12: add pinctrl of TWI
Beware:
1/ "arm" in upper case
2/ not "atmel" as second identifier but "at91" (lower case)
> arm: atmel: at91sam9n12: add qt1070 support
> arm: atmel: at91sam9n12: correct pin number of gpio-key
>
> arch/arm/boot/dts/at91sam9n12.dtsi | 20 ++++++++++++++++++++
> arch/arm/boot/dts/at91sam9n12ek.dts | 18 +++++++++++++++++-
> 2 files changed, 37 insertions(+), 1 deletion(-)
>
--
Nicolas Ferre