From 4a188916a3cb2420d221f5f3866c64e74d1f9681 Mon Sep 17 00:00:00 2001 From: Anson Huang Date: Tue, 3 Sep 2013 21:43:48 -0400 Subject: [PATCH] ENGR00277955-1 keyboard: gpio_keys: support wakeup system from freeze mode To support wakeup system from freeze mode of suspend, device's irq can NOT be disabled during devices suspend, so we need to add IRQF_NO_SUSPEND flag to irqflags. Signed-off-by: Anson Huang [shawn.guo: cherry-pick commit 1eb907e9e5d9 from imx_3.10.y] Signed-off-by: Shawn Guo --- drivers/input/keyboard/gpio_keys.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/input/keyboard/gpio_keys.c b/drivers/input/keyboard/gpio_keys.c index 2db13246eb8e..7135631d1e04 100644 --- a/drivers/input/keyboard/gpio_keys.c +++ b/drivers/input/keyboard/gpio_keys.c @@ -3,6 +3,7 @@ * * Copyright 2005 Phil Blundell * Copyright 2010, 2011 David Jander + * Copyright (C) 2013 Freescale Semiconductor, Inc. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 as @@ -473,6 +474,8 @@ static int gpio_keys_setup_key(struct platform_device *pdev, isr = gpio_keys_gpio_isr; irqflags = IRQF_TRIGGER_RISING | IRQF_TRIGGER_FALLING; + if (bdata->button->wakeup) + irqflags |= IRQF_NO_SUSPEND; } else { if (!button->irq) { -- 2.39.5