From: NeilBrown Date: Mon, 30 Jul 2012 05:18:47 +0000 (-0700) Subject: Input: gpio_keys - report a wakeup_event for a button press X-Git-Tag: omap-for-v3.7-rc1/fixes-cpufreq-signed~43^2^2~25 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2fba26c6595e4c1c64a74dad30f71c09708ff59a;p=pandora-kernel.git Input: gpio_keys - report a wakeup_event for a button press In order to avoid races with suspend, a wakeup event must register as such by calling pm_wakeup_event() or pm_stay_awake(). This will ensure that the current suspend cycle aborts. When the user-space visible event is created in the interrupt handler (gpio_keys_irq_isr), a simple pm_wakeup_event() with no delay is sufficient as suspend will synchronise with all interrupt delivery. When the user-space visible event is created later (gpio_keys_gpio_isr), we need to bracket the event with pm_stay_awake() and pm_relax(). Signed-off-by: NeilBrown Signed-off-by: Dmitry Torokhov --- Reading git-diff-tree failed