* [PATCH] ARM: pxa27x_keypad: clear pending interrupts on keypad config
@ 2012-02-26 13:50 Vasily Khoruzhick
0 siblings, 0 replies; only message in thread
From: Vasily Khoruzhick @ 2012-02-26 13:50 UTC (permalink / raw)
To: linux-arm-kernel
Bootloader can leave interrupt bit pending, and it confuses driver.
Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
---
drivers/input/keyboard/pxa27x_keypad.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/input/keyboard/pxa27x_keypad.c b/drivers/input/keyboard/pxa27x_keypad.c
index eca6ae6..a5f198f 100644
--- a/drivers/input/keyboard/pxa27x_keypad.c
+++ b/drivers/input/keyboard/pxa27x_keypad.c
@@ -360,6 +360,9 @@ static void pxa27x_keypad_config(struct pxa27x_keypad *keypad)
unsigned int mask = 0, direct_key_num = 0;
unsigned long kpc = 0;
+ /* clear pending interrupt bit */
+ keypad_readl(KPC);
+
/* enable matrix keys with automatic scan */
if (pdata->matrix_key_rows && pdata->matrix_key_cols) {
kpc |= KPC_ASACT | KPC_MIE | KPC_ME | KPC_MS_ALL;
--
1.7.9.2
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2012-02-26 13:50 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-26 13:50 [PATCH] ARM: pxa27x_keypad: clear pending interrupts on keypad config Vasily Khoruzhick
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).