input: gpio_keys: Add IRQF_NO_SUSPEND flag to wake-up from freeze state
authorChanwoo Choi <cw00.choi@samsung.com>
Thu, 10 Jul 2014 11:10:17 +0000 (20:10 +0900)
committerChanho Park <chanho61.park@samsung.com>
Thu, 7 Aug 2014 06:17:50 +0000 (15:17 +0900)
This patch add IRQF_NO_SUSPEND flag before requesting interrupt handler
if button->wakeup is true. If ther interrupt of gpio-keys hasn't included
IRQF_NO_SUSPEND, wouldn't wake-up from freeze state when pressing button.

Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
drivers/input/keyboard/gpio_keys.c

index b29ca65..0b8ae51 100644 (file)
@@ -502,6 +502,9 @@ static int gpio_keys_setup_key(struct platform_device *pdev,
        if (!button->can_disable)
                irqflags |= IRQF_SHARED;
 
+       if (button->wakeup)
+               irqflags |= IRQF_NO_SUSPEND;
+
        error = request_any_context_irq(bdata->irq, isr, irqflags, desc, bdata);
        if (error < 0) {
                dev_err(dev, "Unable to claim irq %d; error %d\n",