linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/6] ARM: pxa168: add keypad support
@ 2010-08-26 15:27 Mark F. Brown
  2010-08-26 15:27 ` [PATCH v2 1/6] ARM: pxa27x/pxa3xx: moved pxa27x_keypad.h to platform pxa directory Mark F. Brown
                   ` (8 more replies)
  0 siblings, 9 replies; 13+ messages in thread
From: Mark F. Brown @ 2010-08-26 15:27 UTC (permalink / raw)
  To: Eric Miao, Haojian Zhuang, linux-arm-kernel; +Cc: Mark F. Brown

Version 1
1) Make pxa27x_keypad.h accessible to mach-mmp
2) Add a wakeup handler for pxa27x_keypad interrupts
The wakeup callback fixes an issue on the pxa168 that prevents the keypad
driver from being able to clear the keypad interrupt after reading KPC_PC
3) Add initial board level support

Version 2
1) Clean up for wakeup handler moved from pxa168-irq to pxa27x_keypad
2) Reduced the number of rows to 5 for Aspenite

Mark F. Brown (6):
  ARM: pxa27x/pxa3xx: moved pxa27x_keypad.h to platform pxa directory
  ARM: pxa168: added keypad support
  ARM: pxa168: added wake clear register support for APMU
  ARM: pxa27x_keypad: added wakeup event handler for keypad interrupts
  ARM: pxa168: added keypad wake clear event support for platform
  ARM: pxa168: aspenite: add board support for keypad

 arch/arm/mach-mmp/aspenite.c                       |   27 ++++++++++++++++++++
 arch/arm/mach-mmp/include/mach/mfp-pxa168.h        |    7 +++++
 arch/arm/mach-mmp/include/mach/pxa168.h            |   12 +++++++++
 arch/arm/mach-mmp/include/mach/regs-apmu.h         |   12 +++++++++
 arch/arm/mach-mmp/pxa168.c                         |   13 +++++++++
 arch/arm/mach-pxa/devices.c                        |    2 +-
 arch/arm/mach-pxa/em-x270.c                        |    2 +-
 arch/arm/mach-pxa/ezx.c                            |    2 +-
 arch/arm/mach-pxa/littleton.c                      |    2 +-
 arch/arm/mach-pxa/mainstone.c                      |    4 +-
 arch/arm/mach-pxa/mioa701.c                        |    2 +-
 arch/arm/mach-pxa/palmld.c                         |    2 +-
 arch/arm/mach-pxa/palmt5.c                         |    2 +-
 arch/arm/mach-pxa/palmtreo.c                       |    2 +-
 arch/arm/mach-pxa/palmtx.c                         |    2 +-
 arch/arm/mach-pxa/palmz72.c                        |    2 +-
 arch/arm/mach-pxa/tavorevb.c                       |    2 +-
 arch/arm/mach-pxa/z2.c                             |    2 +-
 arch/arm/mach-pxa/zylonite.c                       |    2 +-
 .../mach => plat-pxa/include/plat}/pxa27x_keypad.h |    1 +
 drivers/input/keyboard/Kconfig                     |    2 +-
 drivers/input/keyboard/pxa27x_keypad.c             |   12 ++++++++-
 22 files changed, 99 insertions(+), 17 deletions(-)
 rename arch/arm/{mach-pxa/include/mach => plat-pxa/include/plat}/pxa27x_keypad.h (97%)


^ permalink raw reply	[flat|nested] 13+ messages in thread

* [PATCH v2 1/6] ARM: pxa27x/pxa3xx: moved pxa27x_keypad.h to platform pxa directory
  2010-08-26 15:27 [PATCH v2 0/6] ARM: pxa168: add keypad support Mark F. Brown
@ 2010-08-26 15:27 ` Mark F. Brown
  2010-08-26 15:27 ` [PATCH v2 2/6] ARM: pxa168: added keypad support Mark F. Brown
                   ` (7 subsequent siblings)
  8 siblings, 0 replies; 13+ messages in thread
From: Mark F. Brown @ 2010-08-26 15:27 UTC (permalink / raw)
  To: Eric Miao, Haojian Zhuang, linux-arm-kernel; +Cc: Mark F. Brown

mach-mmp utilizes pxa27x_keypad code so we need to move header to
platform pxa directory.

Signed-off-by: Mark F. Brown <mark.brown314@gmail.com>
---
 arch/arm/mach-pxa/devices.c                        |    2 +-
 arch/arm/mach-pxa/em-x270.c                        |    2 +-
 arch/arm/mach-pxa/ezx.c                            |    2 +-
 arch/arm/mach-pxa/littleton.c                      |    2 +-
 arch/arm/mach-pxa/mainstone.c                      |    4 ++--
 arch/arm/mach-pxa/mioa701.c                        |    2 +-
 arch/arm/mach-pxa/palmld.c                         |    2 +-
 arch/arm/mach-pxa/palmt5.c                         |    2 +-
 arch/arm/mach-pxa/palmtreo.c                       |    2 +-
 arch/arm/mach-pxa/palmtx.c                         |    2 +-
 arch/arm/mach-pxa/palmz72.c                        |    2 +-
 arch/arm/mach-pxa/tavorevb.c                       |    2 +-
 arch/arm/mach-pxa/z2.c                             |    2 +-
 arch/arm/mach-pxa/zylonite.c                       |    2 +-
 .../mach => plat-pxa/include/plat}/pxa27x_keypad.h |    0
 drivers/input/keyboard/pxa27x_keypad.c             |    2 +-
 16 files changed, 16 insertions(+), 16 deletions(-)
 rename arch/arm/{mach-pxa/include/mach => plat-pxa/include/plat}/pxa27x_keypad.h (100%)

diff --git a/arch/arm/mach-pxa/devices.c b/arch/arm/mach-pxa/devices.c
index a2fc859..08b4103 100644
--- a/arch/arm/mach-pxa/devices.c
+++ b/arch/arm/mach-pxa/devices.c
@@ -11,7 +11,7 @@
 #include <mach/mmc.h>
 #include <mach/irda.h>
 #include <mach/ohci.h>
-#include <mach/pxa27x_keypad.h>
+#include <plat/pxa27x_keypad.h>
 #include <mach/pxa2xx_spi.h>
 #include <mach/camera.h>
 #include <mach/audio.h>
diff --git a/arch/arm/mach-pxa/em-x270.c b/arch/arm/mach-pxa/em-x270.c
index 0517c17..51286a7 100644
--- a/arch/arm/mach-pxa/em-x270.c
+++ b/arch/arm/mach-pxa/em-x270.c
@@ -43,7 +43,7 @@
 #include <mach/pxafb.h>
 #include <mach/ohci.h>
 #include <mach/mmc.h>
-#include <mach/pxa27x_keypad.h>
+#include <plat/pxa27x_keypad.h>
 #include <plat/i2c.h>
 #include <mach/camera.h>
 #include <mach/pxa2xx_spi.h>
diff --git a/arch/arm/mach-pxa/ezx.c b/arch/arm/mach-pxa/ezx.c
index 3fe61f4..f997e84 100644
--- a/arch/arm/mach-pxa/ezx.c
+++ b/arch/arm/mach-pxa/ezx.c
@@ -32,7 +32,7 @@
 #include <mach/ohci.h>
 #include <plat/i2c.h>
 #include <mach/hardware.h>
-#include <mach/pxa27x_keypad.h>
+#include <plat/pxa27x_keypad.h>
 #include <mach/camera.h>
 
 #include "devices.h"
diff --git a/arch/arm/mach-pxa/littleton.c b/arch/arm/mach-pxa/littleton.c
index 83f3236..eb58506 100644
--- a/arch/arm/mach-pxa/littleton.c
+++ b/arch/arm/mach-pxa/littleton.c
@@ -43,7 +43,7 @@
 #include <mach/pxafb.h>
 #include <mach/mmc.h>
 #include <mach/pxa2xx_spi.h>
-#include <mach/pxa27x_keypad.h>
+#include <plat/pxa27x_keypad.h>
 #include <mach/littleton.h>
 #include <plat/i2c.h>
 #include <plat/pxa3xx_nand.h>
diff --git a/arch/arm/mach-pxa/mainstone.c b/arch/arm/mach-pxa/mainstone.c
index c2a8717..126dca1 100644
--- a/arch/arm/mach-pxa/mainstone.c
+++ b/arch/arm/mach-pxa/mainstone.c
@@ -41,7 +41,7 @@
 #include <asm/mach/irq.h>
 #include <asm/mach/flash.h>
 
-#include <mach/pxa27x.h>
+#include <plat/pxa27x.h>
 #include <mach/gpio.h>
 #include <mach/mainstone.h>
 #include <mach/audio.h>
@@ -50,7 +50,7 @@
 #include <mach/mmc.h>
 #include <mach/irda.h>
 #include <mach/ohci.h>
-#include <mach/pxa27x_keypad.h>
+#include <plat/pxa27x_keypad.h>
 
 #include "generic.h"
 #include "devices.h"
diff --git a/arch/arm/mach-pxa/mioa701.c b/arch/arm/mach-pxa/mioa701.c
index dc66942..ffb3f5a 100644
--- a/arch/arm/mach-pxa/mioa701.c
+++ b/arch/arm/mach-pxa/mioa701.c
@@ -45,7 +45,7 @@
 
 #include <mach/pxa27x.h>
 #include <mach/regs-rtc.h>
-#include <mach/pxa27x_keypad.h>
+#include <plat/pxa27x_keypad.h>
 #include <mach/pxafb.h>
 #include <mach/mmc.h>
 #include <mach/udc.h>
diff --git a/arch/arm/mach-pxa/palmld.c b/arch/arm/mach-pxa/palmld.c
index 91038ee..3ff0c4a 100644
--- a/arch/arm/mach-pxa/palmld.c
+++ b/arch/arm/mach-pxa/palmld.c
@@ -39,7 +39,7 @@
 #include <mach/mmc.h>
 #include <mach/pxafb.h>
 #include <mach/irda.h>
-#include <mach/pxa27x_keypad.h>
+#include <plat/pxa27x_keypad.h>
 #include <mach/palmasoc.h>
 #include <mach/palm27x.h>
 
diff --git a/arch/arm/mach-pxa/palmt5.c b/arch/arm/mach-pxa/palmt5.c
index 1c28199..5b9f766 100644
--- a/arch/arm/mach-pxa/palmt5.c
+++ b/arch/arm/mach-pxa/palmt5.c
@@ -39,7 +39,7 @@
 #include <mach/mmc.h>
 #include <mach/pxafb.h>
 #include <mach/irda.h>
-#include <mach/pxa27x_keypad.h>
+#include <plat/pxa27x_keypad.h>
 #include <mach/udc.h>
 #include <mach/palmasoc.h>
 #include <mach/palm27x.h>
diff --git a/arch/arm/mach-pxa/palmtreo.c b/arch/arm/mach-pxa/palmtreo.c
index 52defd5..f685a60 100644
--- a/arch/arm/mach-pxa/palmtreo.c
+++ b/arch/arm/mach-pxa/palmtreo.c
@@ -39,7 +39,7 @@
 #include <mach/mmc.h>
 #include <mach/pxafb.h>
 #include <mach/irda.h>
-#include <mach/pxa27x_keypad.h>
+#include <plat/pxa27x_keypad.h>
 #include <mach/udc.h>
 #include <mach/ohci.h>
 #include <mach/pxa2xx-regs.h>
diff --git a/arch/arm/mach-pxa/palmtx.c b/arch/arm/mach-pxa/palmtx.c
index 144dc2b..89a3792 100644
--- a/arch/arm/mach-pxa/palmtx.c
+++ b/arch/arm/mach-pxa/palmtx.c
@@ -43,7 +43,7 @@
 #include <mach/mmc.h>
 #include <mach/pxafb.h>
 #include <mach/irda.h>
-#include <mach/pxa27x_keypad.h>
+#include <plat/pxa27x_keypad.h>
 #include <mach/udc.h>
 #include <mach/palmasoc.h>
 #include <mach/palm27x.h>
diff --git a/arch/arm/mach-pxa/palmz72.c b/arch/arm/mach-pxa/palmz72.c
index 87e4b10..38f4425 100644
--- a/arch/arm/mach-pxa/palmz72.c
+++ b/arch/arm/mach-pxa/palmz72.c
@@ -41,7 +41,7 @@
 #include <mach/mmc.h>
 #include <mach/pxafb.h>
 #include <mach/irda.h>
-#include <mach/pxa27x_keypad.h>
+#include <plat/pxa27x_keypad.h>
 #include <mach/udc.h>
 #include <mach/palmasoc.h>
 #include <mach/palm27x.h>
diff --git a/arch/arm/mach-pxa/tavorevb.c b/arch/arm/mach-pxa/tavorevb.c
index f02dcb5..0f440c9 100644
--- a/arch/arm/mach-pxa/tavorevb.c
+++ b/arch/arm/mach-pxa/tavorevb.c
@@ -25,7 +25,7 @@
 
 #include <mach/pxa930.h>
 #include <mach/pxafb.h>
-#include <mach/pxa27x_keypad.h>
+#include <plat/pxa27x_keypad.h>
 
 #include "devices.h"
 #include "generic.h"
diff --git a/arch/arm/mach-pxa/z2.c b/arch/arm/mach-pxa/z2.c
index f0d0228..8c44bc4 100644
--- a/arch/arm/mach-pxa/z2.c
+++ b/arch/arm/mach-pxa/z2.c
@@ -37,7 +37,7 @@
 #include <mach/z2.h>
 #include <mach/pxafb.h>
 #include <mach/mmc.h>
-#include <mach/pxa27x_keypad.h>
+#include <plat/pxa27x_keypad.h>
 #include <mach/pxa2xx_spi.h>
 
 #include <plat/i2c.h>
diff --git a/arch/arm/mach-pxa/zylonite.c b/arch/arm/mach-pxa/zylonite.c
index 2edad61..69df3ed 100644
--- a/arch/arm/mach-pxa/zylonite.c
+++ b/arch/arm/mach-pxa/zylonite.c
@@ -30,7 +30,7 @@
 #include <mach/zylonite.h>
 #include <mach/mmc.h>
 #include <mach/ohci.h>
-#include <mach/pxa27x_keypad.h>
+#include <plat/pxa27x_keypad.h>
 #include <plat/pxa3xx_nand.h>
 
 #include "devices.h"
diff --git a/arch/arm/mach-pxa/include/mach/pxa27x_keypad.h b/arch/arm/plat-pxa/include/plat/pxa27x_keypad.h
similarity index 100%
rename from arch/arm/mach-pxa/include/mach/pxa27x_keypad.h
rename to arch/arm/plat-pxa/include/plat/pxa27x_keypad.h
diff --git a/drivers/input/keyboard/pxa27x_keypad.c b/drivers/input/keyboard/pxa27x_keypad.c
index 0e53b3b..0610d10 100644
--- a/drivers/input/keyboard/pxa27x_keypad.c
+++ b/drivers/input/keyboard/pxa27x_keypad.c
@@ -32,7 +32,7 @@
 #include <asm/mach/map.h>
 
 #include <mach/hardware.h>
-#include <mach/pxa27x_keypad.h>
+#include <plat/pxa27x_keypad.h>
 /*
  * Keypad Controller registers
  */
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 13+ messages in thread

* [PATCH v2 2/6] ARM: pxa168: added keypad support
  2010-08-26 15:27 [PATCH v2 0/6] ARM: pxa168: add keypad support Mark F. Brown
  2010-08-26 15:27 ` [PATCH v2 1/6] ARM: pxa27x/pxa3xx: moved pxa27x_keypad.h to platform pxa directory Mark F. Brown
@ 2010-08-26 15:27 ` Mark F. Brown
  2010-08-26 15:27 ` [PATCH v2 3/6] ARM: pxa168: added wake clear register support for APMU Mark F. Brown
                   ` (6 subsequent siblings)
  8 siblings, 0 replies; 13+ messages in thread
From: Mark F. Brown @ 2010-08-26 15:27 UTC (permalink / raw)
  To: Eric Miao, Haojian Zhuang, linux-arm-kernel; +Cc: Mark F. Brown

Signed-off-by: Mark F. Brown <mark.brown314@gmail.com>
---
 arch/arm/mach-mmp/include/mach/mfp-pxa168.h |    7 +++++++
 arch/arm/mach-mmp/include/mach/pxa168.h     |    7 +++++++
 arch/arm/mach-mmp/pxa168.c                  |    3 +++
 drivers/input/keyboard/Kconfig              |    2 +-
 4 files changed, 18 insertions(+), 1 deletions(-)

diff --git a/arch/arm/mach-mmp/include/mach/mfp-pxa168.h b/arch/arm/mach-mmp/include/mach/mfp-pxa168.h
index ded43c4..4621067 100644
--- a/arch/arm/mach-mmp/include/mach/mfp-pxa168.h
+++ b/arch/arm/mach-mmp/include/mach/mfp-pxa168.h
@@ -289,4 +289,11 @@
 #define GPIO86_PWM1_OUT		MFP_CFG(GPIO86, AF2)
 #define GPIO86_PWM2_OUT		MFP_CFG(GPIO86, AF3)
 
+/* Keypad */
+#define GPIO109_KP_MKIN1        MFP_CFG(GPIO109, AF7)
+#define GPIO110_KP_MKIN0        MFP_CFG(GPIO110, AF7)
+#define GPIO111_KP_MKOUT7       MFP_CFG(GPIO111, AF7)
+#define GPIO112_KP_MKOUT6       MFP_CFG(GPIO112, AF7)
+#define GPIO121_KP_MKIN4        MFP_CFG(GPIO121, AF7)
+
 #endif /* __ASM_MACH_MFP_PXA168_H */
diff --git a/arch/arm/mach-mmp/include/mach/pxa168.h b/arch/arm/mach-mmp/include/mach/pxa168.h
index 220738f..f34e663 100644
--- a/arch/arm/mach-mmp/include/mach/pxa168.h
+++ b/arch/arm/mach-mmp/include/mach/pxa168.h
@@ -11,6 +11,7 @@ extern void __init pxa168_init_irq(void);
 #include <plat/i2c.h>
 #include <plat/pxa3xx_nand.h>
 #include <video/pxa168fb.h>
+#include <plat/pxa27x_keypad.h>
 
 extern struct pxa_device_desc pxa168_device_uart1;
 extern struct pxa_device_desc pxa168_device_uart2;
@@ -27,6 +28,7 @@ extern struct pxa_device_desc pxa168_device_ssp4;
 extern struct pxa_device_desc pxa168_device_ssp5;
 extern struct pxa_device_desc pxa168_device_nand;
 extern struct pxa_device_desc pxa168_device_fb;
+extern struct pxa_device_desc pxa168_device_keypad;
 
 static inline int pxa168_add_uart(int id)
 {
@@ -105,4 +107,9 @@ static inline int pxa168_add_fb(struct pxa168fb_mach_info *mi)
 	return pxa_register_device(&pxa168_device_fb, mi, sizeof(*mi));
 }
 
+static inline int pxa168_add_keypad(struct pxa27x_keypad_platform_data *data)
+{
+	return pxa_register_device(&pxa168_device_keypad, data, sizeof(*data));
+}
+
 #endif /* __ASM_MACH_PXA168_H */
diff --git a/arch/arm/mach-mmp/pxa168.c b/arch/arm/mach-mmp/pxa168.c
index eaebf66..2fa16fb 100644
--- a/arch/arm/mach-mmp/pxa168.c
+++ b/arch/arm/mach-mmp/pxa168.c
@@ -77,6 +77,7 @@ static APBC_CLK(ssp2, PXA168_SSP2, 4, 0);
 static APBC_CLK(ssp3, PXA168_SSP3, 4, 0);
 static APBC_CLK(ssp4, PXA168_SSP4, 4, 0);
 static APBC_CLK(ssp5, PXA168_SSP5, 4, 0);
+static APBC_CLK(keypad, PXA168_KPC, 0, 32000);
 
 static APMU_CLK(nand, NAND, 0x01db, 208000000);
 static APMU_CLK(lcd, LCD, 0x7f, 312000000);
@@ -98,6 +99,7 @@ static struct clk_lookup pxa168_clkregs[] = {
 	INIT_CLKREG(&clk_ssp5, "pxa168-ssp.4", NULL),
 	INIT_CLKREG(&clk_nand, "pxa3xx-nand", NULL),
 	INIT_CLKREG(&clk_lcd, "pxa168-fb", NULL),
+	INIT_CLKREG(&clk_keypad, "pxa27x-keypad", NULL),
 };
 
 static int __init pxa168_init(void)
@@ -150,3 +152,4 @@ PXA168_DEVICE(ssp3, "pxa168-ssp", 2, SSP3, 0xd401f000, 0x40, 56, 57);
 PXA168_DEVICE(ssp4, "pxa168-ssp", 3, SSP4, 0xd4020000, 0x40, 58, 59);
 PXA168_DEVICE(ssp5, "pxa168-ssp", 4, SSP5, 0xd4021000, 0x40, 60, 61);
 PXA168_DEVICE(fb, "pxa168-fb", -1, LCD, 0xd420b000, 0x1c8);
+PXA168_DEVICE(keypad, "pxa27x-keypad", -1, KEYPAD, 0xd4012000, 0x4c);
diff --git a/drivers/input/keyboard/Kconfig b/drivers/input/keyboard/Kconfig
index 9cc488d..aa037fe 100644
--- a/drivers/input/keyboard/Kconfig
+++ b/drivers/input/keyboard/Kconfig
@@ -338,7 +338,7 @@ config KEYBOARD_OPENCORES
 
 config KEYBOARD_PXA27x
 	tristate "PXA27x/PXA3xx keypad support"
-	depends on PXA27x || PXA3xx
+	depends on PXA27x || PXA3xx || ARCH_MMP
 	help
 	  Enable support for PXA27x/PXA3xx keypad controller.
 
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 13+ messages in thread

* [PATCH v2 3/6] ARM: pxa168: added wake clear register support for APMU
  2010-08-26 15:27 [PATCH v2 0/6] ARM: pxa168: add keypad support Mark F. Brown
  2010-08-26 15:27 ` [PATCH v2 1/6] ARM: pxa27x/pxa3xx: moved pxa27x_keypad.h to platform pxa directory Mark F. Brown
  2010-08-26 15:27 ` [PATCH v2 2/6] ARM: pxa168: added keypad support Mark F. Brown
@ 2010-08-26 15:27 ` Mark F. Brown
  2010-08-26 15:27 ` [PATCH v2 4/6] ARM: pxa27x_keypad: added wakeup event handler for keypad interrupts Mark F. Brown
                   ` (5 subsequent siblings)
  8 siblings, 0 replies; 13+ messages in thread
From: Mark F. Brown @ 2010-08-26 15:27 UTC (permalink / raw)
  To: Eric Miao, Haojian Zhuang, linux-arm-kernel; +Cc: Mark F. Brown

Signed-off-by: Mark F. Brown <mark.brown314@gmail.com>
---
 arch/arm/mach-mmp/include/mach/regs-apmu.h |   12 ++++++++++++
 1 files changed, 12 insertions(+), 0 deletions(-)

diff --git a/arch/arm/mach-mmp/include/mach/regs-apmu.h b/arch/arm/mach-mmp/include/mach/regs-apmu.h
index 9190305..ac47023 100644
--- a/arch/arm/mach-mmp/include/mach/regs-apmu.h
+++ b/arch/arm/mach-mmp/include/mach/regs-apmu.h
@@ -33,4 +33,16 @@
 #define APMU_FNRST_DIS	(1 << 1)
 #define APMU_AXIRST_DIS	(1 << 0)
 
+/* Wake Clear Register */
+#define APMU_WAKE_CLR	APMU_REG(0x07c)
+
+#define APMU_PXA168_KP_WAKE_CLR		(1 << 7)
+#define APMU_PXA168_CFI_WAKE_CLR	(1 << 6)
+#define APMU_PXA168_XD_WAKE_CLR		(1 << 5)
+#define APMU_PXA168_MSP_WAKE_CLR	(1 << 4)
+#define APMU_PXA168_SD4_WAKE_CLR	(1 << 3)
+#define APMU_PXA168_SD3_WAKE_CLR	(1 << 2)
+#define APMU_PXA168_SD2_WAKE_CLR	(1 << 1)
+#define APMU_PXA168_SD1_WAKE_CLR	(1 << 0)
+
 #endif /* __ASM_MACH_REGS_APMU_H */
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 13+ messages in thread

* [PATCH v2 4/6] ARM: pxa27x_keypad: added wakeup event handler for keypad interrupts
  2010-08-26 15:27 [PATCH v2 0/6] ARM: pxa168: add keypad support Mark F. Brown
                   ` (2 preceding siblings ...)
  2010-08-26 15:27 ` [PATCH v2 3/6] ARM: pxa168: added wake clear register support for APMU Mark F. Brown
@ 2010-08-26 15:27 ` Mark F. Brown
  2010-08-26 15:27 ` [PATCH v2 5/6] ARM: pxa168: added keypad wake clear event support for platform Mark F. Brown
                   ` (4 subsequent siblings)
  8 siblings, 0 replies; 13+ messages in thread
From: Mark F. Brown @ 2010-08-26 15:27 UTC (permalink / raw)
  To: Eric Miao, Haojian Zhuang, linux-arm-kernel; +Cc: Mark F. Brown

mach-mmp needs to clear wake event in order to clear the keypad interrupt

Signed-off-by: Mark F. Brown <mark.brown314@gmail.com>
---
 arch/arm/plat-pxa/include/plat/pxa27x_keypad.h |    1 +
 drivers/input/keyboard/pxa27x_keypad.c         |   10 ++++++++++
 2 files changed, 11 insertions(+), 0 deletions(-)

diff --git a/arch/arm/plat-pxa/include/plat/pxa27x_keypad.h b/arch/arm/plat-pxa/include/plat/pxa27x_keypad.h
index 7b4eadc..73dacda 100644
--- a/arch/arm/plat-pxa/include/plat/pxa27x_keypad.h
+++ b/arch/arm/plat-pxa/include/plat/pxa27x_keypad.h
@@ -52,6 +52,7 @@ struct pxa27x_keypad_platform_data {
 
 	/* key debounce interval */
 	unsigned int	debounce_interval;
+	void		(*clear_wakeup_event)(void);
 };
 
 extern void pxa_set_keypad_info(struct pxa27x_keypad_platform_data *info);
diff --git a/drivers/input/keyboard/pxa27x_keypad.c b/drivers/input/keyboard/pxa27x_keypad.c
index 0610d10..b36d2be 100644
--- a/drivers/input/keyboard/pxa27x_keypad.c
+++ b/drivers/input/keyboard/pxa27x_keypad.c
@@ -330,11 +330,21 @@ static void pxa27x_keypad_scan_direct(struct pxa27x_keypad *keypad)
 	keypad->direct_key_state = new_state;
 }
 
+static void clear_wakeup_event(struct pxa27x_keypad *keypad)
+{
+	struct pxa27x_keypad_platform_data *pdata = keypad->pdata;
+
+	if (pdata->clear_wakeup_event)
+		(pdata->clear_wakeup_event)();
+}
+
 static irqreturn_t pxa27x_keypad_irq_handler(int irq, void *dev_id)
 {
 	struct pxa27x_keypad *keypad = dev_id;
 	unsigned long kpc = keypad_readl(KPC);
 
+	clear_wakeup_event(keypad);
+
 	if (kpc & KPC_DI)
 		pxa27x_keypad_scan_direct(keypad);
 
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 13+ messages in thread

* [PATCH v2 5/6] ARM: pxa168: added keypad wake clear event support for platform
  2010-08-26 15:27 [PATCH v2 0/6] ARM: pxa168: add keypad support Mark F. Brown
                   ` (3 preceding siblings ...)
  2010-08-26 15:27 ` [PATCH v2 4/6] ARM: pxa27x_keypad: added wakeup event handler for keypad interrupts Mark F. Brown
@ 2010-08-26 15:27 ` Mark F. Brown
  2010-08-26 15:27 ` [PATCH v2 6/6] ARM: pxa168: aspenite: add board support for keypad Mark F. Brown
                   ` (3 subsequent siblings)
  8 siblings, 0 replies; 13+ messages in thread
From: Mark F. Brown @ 2010-08-26 15:27 UTC (permalink / raw)
  To: Eric Miao, Haojian Zhuang, linux-arm-kernel; +Cc: Mark F. Brown

Signed-off-by: Mark F. Brown <mark.brown314@gmail.com>
---
 arch/arm/mach-mmp/include/mach/pxa168.h |    5 +++++
 arch/arm/mach-mmp/pxa168.c              |   10 ++++++++++
 2 files changed, 15 insertions(+), 0 deletions(-)

diff --git a/arch/arm/mach-mmp/include/mach/pxa168.h b/arch/arm/mach-mmp/include/mach/pxa168.h
index f34e663..1801e42 100644
--- a/arch/arm/mach-mmp/include/mach/pxa168.h
+++ b/arch/arm/mach-mmp/include/mach/pxa168.h
@@ -5,6 +5,7 @@ struct sys_timer;
 
 extern struct sys_timer pxa168_timer;
 extern void __init pxa168_init_irq(void);
+extern void pxa168_clear_keypad_wakeup(void);
 
 #include <linux/i2c.h>
 #include <mach/devices.h>
@@ -12,6 +13,7 @@ extern void __init pxa168_init_irq(void);
 #include <plat/pxa3xx_nand.h>
 #include <video/pxa168fb.h>
 #include <plat/pxa27x_keypad.h>
+#include <mach/cputype.h>
 
 extern struct pxa_device_desc pxa168_device_uart1;
 extern struct pxa_device_desc pxa168_device_uart2;
@@ -109,6 +111,9 @@ static inline int pxa168_add_fb(struct pxa168fb_mach_info *mi)
 
 static inline int pxa168_add_keypad(struct pxa27x_keypad_platform_data *data)
 {
+	if (cpu_is_pxa168())
+		data->clear_wakeup_event = pxa168_clear_keypad_wakeup;
+
 	return pxa_register_device(&pxa168_device_keypad, data, sizeof(*data));
 }
 
diff --git a/arch/arm/mach-mmp/pxa168.c b/arch/arm/mach-mmp/pxa168.c
index 2fa16fb..72b4e76 100644
--- a/arch/arm/mach-mmp/pxa168.c
+++ b/arch/arm/mach-mmp/pxa168.c
@@ -136,6 +136,16 @@ struct sys_timer pxa168_timer = {
 	.init	= pxa168_timer_init,
 };
 
+void pxa168_clear_keypad_wakeup(void)
+{
+	uint32_t val;
+	uint32_t mask = APMU_PXA168_KP_WAKE_CLR;
+
+	/* wake event clear is needed in order to clear keypad interrupt */
+	val = __raw_readl(APMU_WAKE_CLR);
+	__raw_writel(val |  mask, APMU_WAKE_CLR);
+}
+
 /* on-chip devices */
 PXA168_DEVICE(uart1, "pxa2xx-uart", 0, UART1, 0xd4017000, 0x30, 21, 22);
 PXA168_DEVICE(uart2, "pxa2xx-uart", 1, UART2, 0xd4018000, 0x30, 23, 24);
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 13+ messages in thread

* [PATCH v2 6/6] ARM: pxa168: aspenite: add board support for keypad
  2010-08-26 15:27 [PATCH v2 0/6] ARM: pxa168: add keypad support Mark F. Brown
                   ` (4 preceding siblings ...)
  2010-08-26 15:27 ` [PATCH v2 5/6] ARM: pxa168: added keypad wake clear event support for platform Mark F. Brown
@ 2010-08-26 15:27 ` Mark F. Brown
  2010-09-03 21:52 ` [PATCH v2 0/6] ARM: pxa168: add keypad support David Miller
                   ` (2 subsequent siblings)
  8 siblings, 0 replies; 13+ messages in thread
From: Mark F. Brown @ 2010-08-26 15:27 UTC (permalink / raw)
  To: Eric Miao, Haojian Zhuang, linux-arm-kernel; +Cc: Mark F. Brown

Signed-off-by: Mark F. Brown <mark.brown314@gmail.com>
---
 arch/arm/mach-mmp/aspenite.c |   27 +++++++++++++++++++++++++++
 1 files changed, 27 insertions(+), 0 deletions(-)

diff --git a/arch/arm/mach-mmp/aspenite.c b/arch/arm/mach-mmp/aspenite.c
index 9e1bd6b..f04bae6 100644
--- a/arch/arm/mach-mmp/aspenite.c
+++ b/arch/arm/mach-mmp/aspenite.c
@@ -24,6 +24,8 @@
 #include <mach/pxa168.h>
 #include <mach/gpio.h>
 #include <video/pxa168fb.h>
+#include <linux/input.h>
+#include <plat/pxa27x_keypad.h>
 
 #include "common.h"
 
@@ -97,6 +99,13 @@ static unsigned long common_pin_config[] __initdata = {
 	GPIO81_LCD_DD21,
 	GPIO82_LCD_DD22,
 	GPIO83_LCD_DD23,
+
+	/* Keypad */
+	GPIO109_KP_MKIN1,
+	GPIO110_KP_MKIN0,
+	GPIO111_KP_MKOUT7,
+	GPIO112_KP_MKOUT6,
+	GPIO121_KP_MKIN4,
 };
 
 static struct smc91x_platdata smc91x_info = {
@@ -193,6 +202,23 @@ struct pxa168fb_mach_info aspenite_lcd_info = {
 	.invert_pixclock	= 0,
 };
 
+static unsigned int aspenite_matrix_key_map[] = {
+	KEY(0, 6, KEY_UP),	/* SW 4 */
+	KEY(0, 7, KEY_DOWN),	/* SW 5 */
+	KEY(1, 6, KEY_LEFT),	/* SW 6 */
+	KEY(1, 7, KEY_RIGHT),	/* SW 7 */
+	KEY(4, 6, KEY_ENTER),	/* SW 8 */
+	KEY(4, 7, KEY_ESC),	/* SW 9 */
+};
+
+static struct pxa27x_keypad_platform_data aspenite_keypad_info __initdata = {
+	.matrix_key_rows	= 5,
+	.matrix_key_cols	= 8,
+	.matrix_key_map		= aspenite_matrix_key_map,
+	.matrix_key_map_size	= ARRAY_SIZE(aspenite_matrix_key_map),
+	.debounce_interval	= 30,
+};
+
 static void __init common_init(void)
 {
 	mfp_config(ARRAY_AND_SIZE(common_pin_config));
@@ -203,6 +229,7 @@ static void __init common_init(void)
 	pxa168_add_ssp(1);
 	pxa168_add_nand(&aspenite_nand_info);
 	pxa168_add_fb(&aspenite_lcd_info);
+	pxa168_add_keypad(&aspenite_keypad_info);
 
 	/* off-chip devices */
 	platform_device_register(&smc91x_device);
-- 
1.7.0.4


^ permalink raw reply related	[flat|nested] 13+ messages in thread

* Re: [PATCH v2 0/6] ARM: pxa168: add keypad support
  2010-08-26 15:27 [PATCH v2 0/6] ARM: pxa168: add keypad support Mark F. Brown
                   ` (5 preceding siblings ...)
  2010-08-26 15:27 ` [PATCH v2 6/6] ARM: pxa168: aspenite: add board support for keypad Mark F. Brown
@ 2010-09-03 21:52 ` David Miller
  2010-09-03 22:06   ` Mark F. Brown
       [not found] ` <1282836457-5651-2-git-send-email-mark.brown314@gmail.com>
       [not found] ` <1282836457-5651-7-git-send-email-mark.brown314@gmail.com>
  8 siblings, 1 reply; 13+ messages in thread
From: David Miller @ 2010-09-03 21:52 UTC (permalink / raw)
  To: mark.brown314
  Cc: eric.y.miao, haojian.zhuang, linux-arm-kernel, linux-kernel,
	linux-input


Please fix the date on your email postings, they says it's August
26th.

That's several days in the past, and every time someone posts
with a date that far in the past I get flooded with bounce
messages because many mail systems outright reject such postings.

Thanks.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH v2 0/6] ARM: pxa168: add keypad support
  2010-09-03 21:52 ` [PATCH v2 0/6] ARM: pxa168: add keypad support David Miller
@ 2010-09-03 22:06   ` Mark F. Brown
  0 siblings, 0 replies; 13+ messages in thread
From: Mark F. Brown @ 2010-09-03 22:06 UTC (permalink / raw)
  To: David Miller
  Cc: eric.y.miao, haojian.zhuang, linux-arm-kernel, linux-kernel,
	linux-input

On Fri, Sep 3, 2010 at 5:52 PM, David Miller <davem@davemloft.net> wrote:
>
> Please fix the date on your email postings, they says it's August
> 26th.
>
> That's several days in the past, and every time someone posts
> with a date that far in the past I get flooded with bounce
> messages because many mail systems outright reject such postings.
>
> Thanks.
>

Sorry about that! When my laptop resumed it failed to update the
system time properly. Will resubmit!

Regards,
-- Mark

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH v2 1/6] ARM: pxa27x/pxa3xx: moved pxa27x_keypad.h to platform pxa directory
       [not found] ` <1282836457-5651-2-git-send-email-mark.brown314@gmail.com>
@ 2010-09-04  2:11   ` Marek Vasut
  0 siblings, 0 replies; 13+ messages in thread
From: Marek Vasut @ 2010-09-04  2:11 UTC (permalink / raw)
  To: Mark F. Brown
  Cc: Eric Miao, Haojian Zhuang, linux-arm-kernel, linux-kernel,
	linux-input

Dne Čt 26. srpna 2010 17:27:32 Mark F. Brown napsal(a):
> mach-mmp utilizes pxa27x_keypad code so we need to move header to
> platform pxa directory.
> 
Hey, so what's so V2-ish on this one? Isn't this just a resubmission ?

Cheers
> Signed-off-by: Mark F. Brown <mark.brown314@gmail.com>
> ---
>  arch/arm/mach-pxa/devices.c                        |    2 +-
>  arch/arm/mach-pxa/em-x270.c                        |    2 +-
>  arch/arm/mach-pxa/ezx.c                            |    2 +-
>  arch/arm/mach-pxa/littleton.c                      |    2 +-
>  arch/arm/mach-pxa/mainstone.c                      |    4 ++--
>  arch/arm/mach-pxa/mioa701.c                        |    2 +-
>  arch/arm/mach-pxa/palmld.c                         |    2 +-
>  arch/arm/mach-pxa/palmt5.c                         |    2 +-
>  arch/arm/mach-pxa/palmtreo.c                       |    2 +-
>  arch/arm/mach-pxa/palmtx.c                         |    2 +-
>  arch/arm/mach-pxa/palmz72.c                        |    2 +-
>  arch/arm/mach-pxa/tavorevb.c                       |    2 +-
>  arch/arm/mach-pxa/z2.c                             |    2 +-
>  arch/arm/mach-pxa/zylonite.c                       |    2 +-
>  .../mach => plat-pxa/include/plat}/pxa27x_keypad.h |    0
>  drivers/input/keyboard/pxa27x_keypad.c             |    2 +-
>  16 files changed, 16 insertions(+), 16 deletions(-)
>  rename arch/arm/{mach-pxa/include/mach =>
> plat-pxa/include/plat}/pxa27x_keypad.h (100%)
> 
> diff --git a/arch/arm/mach-pxa/devices.c b/arch/arm/mach-pxa/devices.c
> index a2fc859..08b4103 100644
> --- a/arch/arm/mach-pxa/devices.c
> +++ b/arch/arm/mach-pxa/devices.c
> @@ -11,7 +11,7 @@
>  #include <mach/mmc.h>
>  #include <mach/irda.h>
>  #include <mach/ohci.h>
> -#include <mach/pxa27x_keypad.h>
> +#include <plat/pxa27x_keypad.h>
>  #include <mach/pxa2xx_spi.h>
>  #include <mach/camera.h>
>  #include <mach/audio.h>
> diff --git a/arch/arm/mach-pxa/em-x270.c b/arch/arm/mach-pxa/em-x270.c
> index 0517c17..51286a7 100644
> --- a/arch/arm/mach-pxa/em-x270.c
> +++ b/arch/arm/mach-pxa/em-x270.c
> @@ -43,7 +43,7 @@
>  #include <mach/pxafb.h>
>  #include <mach/ohci.h>
>  #include <mach/mmc.h>
> -#include <mach/pxa27x_keypad.h>
> +#include <plat/pxa27x_keypad.h>
>  #include <plat/i2c.h>
>  #include <mach/camera.h>
>  #include <mach/pxa2xx_spi.h>
> diff --git a/arch/arm/mach-pxa/ezx.c b/arch/arm/mach-pxa/ezx.c
> index 3fe61f4..f997e84 100644
> --- a/arch/arm/mach-pxa/ezx.c
> +++ b/arch/arm/mach-pxa/ezx.c
> @@ -32,7 +32,7 @@
>  #include <mach/ohci.h>
>  #include <plat/i2c.h>
>  #include <mach/hardware.h>
> -#include <mach/pxa27x_keypad.h>
> +#include <plat/pxa27x_keypad.h>
>  #include <mach/camera.h>
> 
>  #include "devices.h"
> diff --git a/arch/arm/mach-pxa/littleton.c b/arch/arm/mach-pxa/littleton.c
> index 83f3236..eb58506 100644
> --- a/arch/arm/mach-pxa/littleton.c
> +++ b/arch/arm/mach-pxa/littleton.c
> @@ -43,7 +43,7 @@
>  #include <mach/pxafb.h>
>  #include <mach/mmc.h>
>  #include <mach/pxa2xx_spi.h>
> -#include <mach/pxa27x_keypad.h>
> +#include <plat/pxa27x_keypad.h>
>  #include <mach/littleton.h>
>  #include <plat/i2c.h>
>  #include <plat/pxa3xx_nand.h>
> diff --git a/arch/arm/mach-pxa/mainstone.c b/arch/arm/mach-pxa/mainstone.c
> index c2a8717..126dca1 100644
> --- a/arch/arm/mach-pxa/mainstone.c
> +++ b/arch/arm/mach-pxa/mainstone.c
> @@ -41,7 +41,7 @@
>  #include <asm/mach/irq.h>
>  #include <asm/mach/flash.h>
> 
> -#include <mach/pxa27x.h>
> +#include <plat/pxa27x.h>
>  #include <mach/gpio.h>
>  #include <mach/mainstone.h>
>  #include <mach/audio.h>
> @@ -50,7 +50,7 @@
>  #include <mach/mmc.h>
>  #include <mach/irda.h>
>  #include <mach/ohci.h>
> -#include <mach/pxa27x_keypad.h>
> +#include <plat/pxa27x_keypad.h>
> 
>  #include "generic.h"
>  #include "devices.h"
> diff --git a/arch/arm/mach-pxa/mioa701.c b/arch/arm/mach-pxa/mioa701.c
> index dc66942..ffb3f5a 100644
> --- a/arch/arm/mach-pxa/mioa701.c
> +++ b/arch/arm/mach-pxa/mioa701.c
> @@ -45,7 +45,7 @@
> 
>  #include <mach/pxa27x.h>
>  #include <mach/regs-rtc.h>
> -#include <mach/pxa27x_keypad.h>
> +#include <plat/pxa27x_keypad.h>
>  #include <mach/pxafb.h>
>  #include <mach/mmc.h>
>  #include <mach/udc.h>
> diff --git a/arch/arm/mach-pxa/palmld.c b/arch/arm/mach-pxa/palmld.c
> index 91038ee..3ff0c4a 100644
> --- a/arch/arm/mach-pxa/palmld.c
> +++ b/arch/arm/mach-pxa/palmld.c
> @@ -39,7 +39,7 @@
>  #include <mach/mmc.h>
>  #include <mach/pxafb.h>
>  #include <mach/irda.h>
> -#include <mach/pxa27x_keypad.h>
> +#include <plat/pxa27x_keypad.h>
>  #include <mach/palmasoc.h>
>  #include <mach/palm27x.h>
> 
> diff --git a/arch/arm/mach-pxa/palmt5.c b/arch/arm/mach-pxa/palmt5.c
> index 1c28199..5b9f766 100644
> --- a/arch/arm/mach-pxa/palmt5.c
> +++ b/arch/arm/mach-pxa/palmt5.c
> @@ -39,7 +39,7 @@
>  #include <mach/mmc.h>
>  #include <mach/pxafb.h>
>  #include <mach/irda.h>
> -#include <mach/pxa27x_keypad.h>
> +#include <plat/pxa27x_keypad.h>
>  #include <mach/udc.h>
>  #include <mach/palmasoc.h>
>  #include <mach/palm27x.h>
> diff --git a/arch/arm/mach-pxa/palmtreo.c b/arch/arm/mach-pxa/palmtreo.c
> index 52defd5..f685a60 100644
> --- a/arch/arm/mach-pxa/palmtreo.c
> +++ b/arch/arm/mach-pxa/palmtreo.c
> @@ -39,7 +39,7 @@
>  #include <mach/mmc.h>
>  #include <mach/pxafb.h>
>  #include <mach/irda.h>
> -#include <mach/pxa27x_keypad.h>
> +#include <plat/pxa27x_keypad.h>
>  #include <mach/udc.h>
>  #include <mach/ohci.h>
>  #include <mach/pxa2xx-regs.h>
> diff --git a/arch/arm/mach-pxa/palmtx.c b/arch/arm/mach-pxa/palmtx.c
> index 144dc2b..89a3792 100644
> --- a/arch/arm/mach-pxa/palmtx.c
> +++ b/arch/arm/mach-pxa/palmtx.c
> @@ -43,7 +43,7 @@
>  #include <mach/mmc.h>
>  #include <mach/pxafb.h>
>  #include <mach/irda.h>
> -#include <mach/pxa27x_keypad.h>
> +#include <plat/pxa27x_keypad.h>
>  #include <mach/udc.h>
>  #include <mach/palmasoc.h>
>  #include <mach/palm27x.h>
> diff --git a/arch/arm/mach-pxa/palmz72.c b/arch/arm/mach-pxa/palmz72.c
> index 87e4b10..38f4425 100644
> --- a/arch/arm/mach-pxa/palmz72.c
> +++ b/arch/arm/mach-pxa/palmz72.c
> @@ -41,7 +41,7 @@
>  #include <mach/mmc.h>
>  #include <mach/pxafb.h>
>  #include <mach/irda.h>
> -#include <mach/pxa27x_keypad.h>
> +#include <plat/pxa27x_keypad.h>
>  #include <mach/udc.h>
>  #include <mach/palmasoc.h>
>  #include <mach/palm27x.h>
> diff --git a/arch/arm/mach-pxa/tavorevb.c b/arch/arm/mach-pxa/tavorevb.c
> index f02dcb5..0f440c9 100644
> --- a/arch/arm/mach-pxa/tavorevb.c
> +++ b/arch/arm/mach-pxa/tavorevb.c
> @@ -25,7 +25,7 @@
> 
>  #include <mach/pxa930.h>
>  #include <mach/pxafb.h>
> -#include <mach/pxa27x_keypad.h>
> +#include <plat/pxa27x_keypad.h>
> 
>  #include "devices.h"
>  #include "generic.h"
> diff --git a/arch/arm/mach-pxa/z2.c b/arch/arm/mach-pxa/z2.c
> index f0d0228..8c44bc4 100644
> --- a/arch/arm/mach-pxa/z2.c
> +++ b/arch/arm/mach-pxa/z2.c
> @@ -37,7 +37,7 @@
>  #include <mach/z2.h>
>  #include <mach/pxafb.h>
>  #include <mach/mmc.h>
> -#include <mach/pxa27x_keypad.h>
> +#include <plat/pxa27x_keypad.h>
>  #include <mach/pxa2xx_spi.h>
> 
>  #include <plat/i2c.h>
> diff --git a/arch/arm/mach-pxa/zylonite.c b/arch/arm/mach-pxa/zylonite.c
> index 2edad61..69df3ed 100644
> --- a/arch/arm/mach-pxa/zylonite.c
> +++ b/arch/arm/mach-pxa/zylonite.c
> @@ -30,7 +30,7 @@
>  #include <mach/zylonite.h>
>  #include <mach/mmc.h>
>  #include <mach/ohci.h>
> -#include <mach/pxa27x_keypad.h>
> +#include <plat/pxa27x_keypad.h>
>  #include <plat/pxa3xx_nand.h>
> 
>  #include "devices.h"
> diff --git a/arch/arm/mach-pxa/include/mach/pxa27x_keypad.h
> b/arch/arm/plat-pxa/include/plat/pxa27x_keypad.h similarity index 100%
> rename from arch/arm/mach-pxa/include/mach/pxa27x_keypad.h
> rename to arch/arm/plat-pxa/include/plat/pxa27x_keypad.h
> diff --git a/drivers/input/keyboard/pxa27x_keypad.c
> b/drivers/input/keyboard/pxa27x_keypad.c index 0e53b3b..0610d10 100644
> --- a/drivers/input/keyboard/pxa27x_keypad.c
> +++ b/drivers/input/keyboard/pxa27x_keypad.c
> @@ -32,7 +32,7 @@
>  #include <asm/mach/map.h>
> 
>  #include <mach/hardware.h>
> -#include <mach/pxa27x_keypad.h>
> +#include <plat/pxa27x_keypad.h>
>  /*
>   * Keypad Controller registers
>   */
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH v2 6/6] ARM: pxa168: aspenite: add board support for keypad
       [not found] ` <1282836457-5651-7-git-send-email-mark.brown314@gmail.com>
@ 2010-09-04  2:12   ` Marek Vasut
  2010-09-04  2:56     ` Mark F. Brown
  0 siblings, 1 reply; 13+ messages in thread
From: Marek Vasut @ 2010-09-04  2:12 UTC (permalink / raw)
  To: Mark F. Brown
  Cc: Eric Miao, Haojian Zhuang, linux-arm-kernel, linux-kernel,
	linux-input

Dne Čt 26. srpna 2010 17:27:37 Mark F. Brown napsal(a):
> Signed-off-by: Mark F. Brown <mark.brown314@gmail.com>

Ditto, which is V2 and which are just resubmissions please ?
> ---
>  arch/arm/mach-mmp/aspenite.c |   27 +++++++++++++++++++++++++++
>  1 files changed, 27 insertions(+), 0 deletions(-)
> 
> diff --git a/arch/arm/mach-mmp/aspenite.c b/arch/arm/mach-mmp/aspenite.c
> index 9e1bd6b..f04bae6 100644
> --- a/arch/arm/mach-mmp/aspenite.c
> +++ b/arch/arm/mach-mmp/aspenite.c
> @@ -24,6 +24,8 @@
>  #include <mach/pxa168.h>
>  #include <mach/gpio.h>
>  #include <video/pxa168fb.h>
> +#include <linux/input.h>
> +#include <plat/pxa27x_keypad.h>
> 
>  #include "common.h"
> 
> @@ -97,6 +99,13 @@ static unsigned long common_pin_config[] __initdata = {
>  	GPIO81_LCD_DD21,
>  	GPIO82_LCD_DD22,
>  	GPIO83_LCD_DD23,
> +
> +	/* Keypad */
> +	GPIO109_KP_MKIN1,
> +	GPIO110_KP_MKIN0,
> +	GPIO111_KP_MKOUT7,
> +	GPIO112_KP_MKOUT6,
> +	GPIO121_KP_MKIN4,
>  };
> 
>  static struct smc91x_platdata smc91x_info = {
> @@ -193,6 +202,23 @@ struct pxa168fb_mach_info aspenite_lcd_info = {
>  	.invert_pixclock	= 0,
>  };
> 
> +static unsigned int aspenite_matrix_key_map[] = {
> +	KEY(0, 6, KEY_UP),	/* SW 4 */
> +	KEY(0, 7, KEY_DOWN),	/* SW 5 */
> +	KEY(1, 6, KEY_LEFT),	/* SW 6 */
> +	KEY(1, 7, KEY_RIGHT),	/* SW 7 */
> +	KEY(4, 6, KEY_ENTER),	/* SW 8 */
> +	KEY(4, 7, KEY_ESC),	/* SW 9 */
> +};
> +
> +static struct pxa27x_keypad_platform_data aspenite_keypad_info __initdata
> = { +	.matrix_key_rows	= 5,
> +	.matrix_key_cols	= 8,
> +	.matrix_key_map		= aspenite_matrix_key_map,
> +	.matrix_key_map_size	= ARRAY_SIZE(aspenite_matrix_key_map),
> +	.debounce_interval	= 30,
> +};
> +
>  static void __init common_init(void)
>  {
>  	mfp_config(ARRAY_AND_SIZE(common_pin_config));
> @@ -203,6 +229,7 @@ static void __init common_init(void)
>  	pxa168_add_ssp(1);
>  	pxa168_add_nand(&aspenite_nand_info);
>  	pxa168_add_fb(&aspenite_lcd_info);
> +	pxa168_add_keypad(&aspenite_keypad_info);
> 
>  	/* off-chip devices */
>  	platform_device_register(&smc91x_device);
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH v2 6/6] ARM: pxa168: aspenite: add board support for keypad
  2010-09-04  2:12   ` [PATCH v2 6/6] ARM: pxa168: aspenite: add board support for keypad Marek Vasut
@ 2010-09-04  2:56     ` Mark F. Brown
  2010-09-04  5:23       ` Marek Vasut
  0 siblings, 1 reply; 13+ messages in thread
From: Mark F. Brown @ 2010-09-04  2:56 UTC (permalink / raw)
  To: Marek Vasut
  Cc: Eric Miao, Haojian Zhuang, linux-arm-kernel, linux-kernel,
	linux-input

On Fri, Sep 3, 2010 at 10:12 PM, Marek Vasut <marek.vasut@gmail.com> wrote:
> Dne Čt 26. srpna 2010 17:27:37 Mark F. Brown napsal(a):
>> Signed-off-by: Mark F. Brown <mark.brown314@gmail.com>
>
> Ditto, which is V2 and which are just resubmissions please ?
>> ---
>>  arch/arm/mach-mmp/aspenite.c |   27 +++++++++++++++++++++++++++
>>  1 files changed, 27 insertions(+), 0 deletions(-)
>>
>> diff --git a/arch/arm/mach-mmp/aspenite.c b/arch/arm/mach-mmp/aspenite.c
>> index 9e1bd6b..f04bae6 100644
>> --- a/arch/arm/mach-mmp/aspenite.c
>> +++ b/arch/arm/mach-mmp/aspenite.c
>> @@ -24,6 +24,8 @@
>>  #include <mach/pxa168.h>
>>  #include <mach/gpio.h>
>>  #include <video/pxa168fb.h>
>> +#include <linux/input.h>
>> +#include <plat/pxa27x_keypad.h>
>>
>>  #include "common.h"
>>
>> @@ -97,6 +99,13 @@ static unsigned long common_pin_config[] __initdata = {
>>       GPIO81_LCD_DD21,
>>       GPIO82_LCD_DD22,
>>       GPIO83_LCD_DD23,
>> +
>> +     /* Keypad */
>> +     GPIO109_KP_MKIN1,
>> +     GPIO110_KP_MKIN0,
>> +     GPIO111_KP_MKOUT7,
>> +     GPIO112_KP_MKOUT6,
>> +     GPIO121_KP_MKIN4,
>>  };
>>
>>  static struct smc91x_platdata smc91x_info = {
>> @@ -193,6 +202,23 @@ struct pxa168fb_mach_info aspenite_lcd_info = {
>>       .invert_pixclock        = 0,
>>  };
>>
>> +static unsigned int aspenite_matrix_key_map[] = {
>> +     KEY(0, 6, KEY_UP),      /* SW 4 */
>> +     KEY(0, 7, KEY_DOWN),    /* SW 5 */
>> +     KEY(1, 6, KEY_LEFT),    /* SW 6 */
>> +     KEY(1, 7, KEY_RIGHT),   /* SW 7 */
>> +     KEY(4, 6, KEY_ENTER),   /* SW 8 */
>> +     KEY(4, 7, KEY_ESC),     /* SW 9 */
>> +};
>> +
>> +static struct pxa27x_keypad_platform_data aspenite_keypad_info __initdata
>> = { + .matrix_key_rows        = 5,
>> +     .matrix_key_cols        = 8,
>> +     .matrix_key_map         = aspenite_matrix_key_map,
>> +     .matrix_key_map_size    = ARRAY_SIZE(aspenite_matrix_key_map),
>> +     .debounce_interval      = 30,
>> +};
>> +
>>  static void __init common_init(void)
>>  {
>>       mfp_config(ARRAY_AND_SIZE(common_pin_config));
>> @@ -203,6 +229,7 @@ static void __init common_init(void)
>>       pxa168_add_ssp(1);
>>       pxa168_add_nand(&aspenite_nand_info);
>>       pxa168_add_fb(&aspenite_lcd_info);
>> +     pxa168_add_keypad(&aspenite_keypad_info);
>>
>>       /* off-chip devices */
>>       platform_device_register(&smc91x_device);
>

Sorry I am new to this! If I am updating the patchset based on
community recommendations should I consider that the next version of
the patchset or something else? I think I am confused about the
distinction.

Thanks,
-- Mark
-- Mark
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH v2 6/6] ARM: pxa168: aspenite: add board support for keypad
  2010-09-04  2:56     ` Mark F. Brown
@ 2010-09-04  5:23       ` Marek Vasut
  0 siblings, 0 replies; 13+ messages in thread
From: Marek Vasut @ 2010-09-04  5:23 UTC (permalink / raw)
  To: Mark F. Brown
  Cc: Eric Miao, Haojian Zhuang, linux-arm-kernel, linux-kernel,
	linux-input

Dne So 4. září 2010 04:56:27 Mark F. Brown napsal(a):
> On Fri, Sep 3, 2010 at 10:12 PM, Marek Vasut <marek.vasut@gmail.com> wrote:
> > Dne Čt 26. srpna 2010 17:27:37 Mark F. Brown napsal(a):
> >> Signed-off-by: Mark F. Brown <mark.brown314@gmail.com>
> > 
> > Ditto, which is V2 and which are just resubmissions please ?
> > 
> >> ---
> >>  arch/arm/mach-mmp/aspenite.c |   27 +++++++++++++++++++++++++++
> >>  1 files changed, 27 insertions(+), 0 deletions(-)
> >> 
> >> diff --git a/arch/arm/mach-mmp/aspenite.c b/arch/arm/mach-mmp/aspenite.c
> >> index 9e1bd6b..f04bae6 100644
> >> --- a/arch/arm/mach-mmp/aspenite.c
> >> +++ b/arch/arm/mach-mmp/aspenite.c
> >> @@ -24,6 +24,8 @@
> >>  #include <mach/pxa168.h>
> >>  #include <mach/gpio.h>
> >>  #include <video/pxa168fb.h>
> >> +#include <linux/input.h>
> >> +#include <plat/pxa27x_keypad.h>
> >> 
> >>  #include "common.h"
> >> 
> >> @@ -97,6 +99,13 @@ static unsigned long common_pin_config[] __initdata =
> >> { GPIO81_LCD_DD21,
> >>       GPIO82_LCD_DD22,
> >>       GPIO83_LCD_DD23,
> >> +
> >> +     /* Keypad */
> >> +     GPIO109_KP_MKIN1,
> >> +     GPIO110_KP_MKIN0,
> >> +     GPIO111_KP_MKOUT7,
> >> +     GPIO112_KP_MKOUT6,
> >> +     GPIO121_KP_MKIN4,
> >>  };
> >> 
> >>  static struct smc91x_platdata smc91x_info = {
> >> @@ -193,6 +202,23 @@ struct pxa168fb_mach_info aspenite_lcd_info = {
> >>       .invert_pixclock        = 0,
> >>  };
> >> 
> >> +static unsigned int aspenite_matrix_key_map[] = {
> >> +     KEY(0, 6, KEY_UP),      /* SW 4 */
> >> +     KEY(0, 7, KEY_DOWN),    /* SW 5 */
> >> +     KEY(1, 6, KEY_LEFT),    /* SW 6 */
> >> +     KEY(1, 7, KEY_RIGHT),   /* SW 7 */
> >> +     KEY(4, 6, KEY_ENTER),   /* SW 8 */
> >> +     KEY(4, 7, KEY_ESC),     /* SW 9 */
> >> +};
> >> +
> >> +static struct pxa27x_keypad_platform_data aspenite_keypad_info
> >> __initdata = { + .matrix_key_rows        = 5,
> >> +     .matrix_key_cols        = 8,
> >> +     .matrix_key_map         = aspenite_matrix_key_map,
> >> +     .matrix_key_map_size    = ARRAY_SIZE(aspenite_matrix_key_map),
> >> +     .debounce_interval      = 30,
> >> +};
> >> +
> >>  static void __init common_init(void)
> >>  {
> >>       mfp_config(ARRAY_AND_SIZE(common_pin_config));
> >> @@ -203,6 +229,7 @@ static void __init common_init(void)
> >>       pxa168_add_ssp(1);
> >>       pxa168_add_nand(&aspenite_nand_info);
> >>       pxa168_add_fb(&aspenite_lcd_info);
> >> +     pxa168_add_keypad(&aspenite_keypad_info);
> >> 
> >>       /* off-chip devices */
> >>       platform_device_register(&smc91x_device);
> 
> Sorry I am new to this! If I am updating the patchset based on
> community recommendations should I consider that the next version of
> the patchset or something else? I think I am confused about the
> distinction.

Stick the description of the changes made from previous version to where 
diffstat is.

Also, mark "vN+1" only those patches, that are really changed in the patchset. 
Cheers
> 
> Thanks,
> -- Mark
> -- Mark
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2010-09-04  5:24 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-08-26 15:27 [PATCH v2 0/6] ARM: pxa168: add keypad support Mark F. Brown
2010-08-26 15:27 ` [PATCH v2 1/6] ARM: pxa27x/pxa3xx: moved pxa27x_keypad.h to platform pxa directory Mark F. Brown
2010-08-26 15:27 ` [PATCH v2 2/6] ARM: pxa168: added keypad support Mark F. Brown
2010-08-26 15:27 ` [PATCH v2 3/6] ARM: pxa168: added wake clear register support for APMU Mark F. Brown
2010-08-26 15:27 ` [PATCH v2 4/6] ARM: pxa27x_keypad: added wakeup event handler for keypad interrupts Mark F. Brown
2010-08-26 15:27 ` [PATCH v2 5/6] ARM: pxa168: added keypad wake clear event support for platform Mark F. Brown
2010-08-26 15:27 ` [PATCH v2 6/6] ARM: pxa168: aspenite: add board support for keypad Mark F. Brown
2010-09-03 21:52 ` [PATCH v2 0/6] ARM: pxa168: add keypad support David Miller
2010-09-03 22:06   ` Mark F. Brown
     [not found] ` <1282836457-5651-2-git-send-email-mark.brown314@gmail.com>
2010-09-04  2:11   ` [PATCH v2 1/6] ARM: pxa27x/pxa3xx: moved pxa27x_keypad.h to platform pxa directory Marek Vasut
     [not found] ` <1282836457-5651-7-git-send-email-mark.brown314@gmail.com>
2010-09-04  2:12   ` [PATCH v2 6/6] ARM: pxa168: aspenite: add board support for keypad Marek Vasut
2010-09-04  2:56     ` Mark F. Brown
2010-09-04  5:23       ` Marek Vasut

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).