>>> >
>>> > diff --git a/arch/x86/platform/mrst/mrst.c b/arch/x86/platform/mrst/mrst.c
>>> > index f289118..82c37e7 100644
>>> > --- a/arch/x86/platform/mrst/mrst.c
>>> > +++ b/arch/x86/platform/mrst/mrst.c
>>> > @@ -1102,7 +1102,7 @@ static struct gpio_keys_button gpio_button[] = {
>>> > {KEY_LEFTMETA, -1, 1, "KEY_LEFTMETA", EV_KEY, 0, 20},
>>> > {SW_ROTATE_LOCK, -1, 1, "SW_ROTATE_LOCK",EV_SW, 0, 20},
>>> > {KEY_POWER, -1, 1, "KEY_POWER", EV_KEY, 0, 20},
>>> > - {SW_FRONT_PROXIMITY, -1, 1, "SW_FRONT_PROXIMITY", EV_SW, 0, 20},
>>> > + {SW_FRONT_PROXIMITY, -1, 1, "SW_PROXIMITY", EV_SW, 0, 20},
>>> > };
We found that a patch from upstream should be applied in order to
solve request_irq problem in gpio-keys. Please also pick up this
patch.
Jekyll
From: Philippe Langlais <[email protected]>
Date: Fri, 21 Jan 2011 07:09:30 +0000 (-0800)
Subject: Input: gpio_keys - switch to using request_any_context_irq
X-Git-Tag: v2.6.38-rc3~12^2~9
X-Git-Url:
http://git.kernel.org/?p=linux%2Fkernel%2Fgit%2Ftorvalds%2Flinux-2.6.git;a=commitdiff_plain;h=94a8cab8caaa56824981c17b6898b73627e8382f;hp=48c27016e18f8608c12b7516515ad773093198d8
Input: gpio_keys - switch to using request_any_context_irq
The driver does not require hardirq context and can work with threaded
interrupts as well, so let's switch to request_any_context_irq which
will select the context that is available for us.
Signed-off-by: Philippe Langlais <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
---
diff --git a/drivers/input/keyboard/gpio_keys.c
b/drivers/input/keyboard/gpio_keys.c
index 6069abe..eb30063 100644
--- a/drivers/input/keyboard/gpio_keys.c
+++ b/drivers/input/keyboard/gpio_keys.c
@@ -322,7 +322,7 @@ static void gpio_keys_report_event(struct
gpio_button_data *bdata)
struct gpio_keys_button *button = bdata->button;
struct input_dev *input = bdata->input;
unsigned int type = button->type ?: EV_KEY;
- int state = (gpio_get_value(button->gpio) ? 1 : 0) ^ button->active_low;
+ int state = (gpio_get_value_cansleep(button->gpio) ? 1 : 0) ^
button->active_low;
input_event(input, type, button->code, !!state);
input_sync(input);
@@ -410,8 +410,8 @@ static int __devinit gpio_keys_setup_key(struct
platform_device *pdev,
if (!button->can_disable)
irqflags |= IRQF_SHARED;
- error = request_irq(irq, gpio_keys_isr, irqflags, desc, bdata);
- if (error) {
+ error = request_any_context_irq(irq, gpio_keys_isr, irqflags, desc,
bdata);
+ if (error < 0) {
dev_err(dev, "Unable to claim irq %d; error %d\n",
irq, error);
goto fail3;
_______________________________________________
MeeGo-kernel mailing list
[email protected]
http://lists.meego.com/listinfo/meego-kernel