PM debug: allow configurable wakeup from suspend on OMAP GPtimer
Using debugfs, export a configurable wakeup timer to be used to wakeup system from suspend. If a non-zero value is written to /debug/pm_debug/wakeup_timer_seconds, A timer wakeup event will wake the system and resume after the configured number of seconds. Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
This commit is contained in:
@ -47,6 +47,7 @@ static struct omap_dm_timer *gptimer;
|
||||
static struct clock_event_device clockevent_gpt;
|
||||
static u8 __initdata gptimer_id = 1;
|
||||
static u8 __initdata inited;
|
||||
struct omap_dm_timer *gptimer_wakeup;
|
||||
|
||||
static irqreturn_t omap2_gp_timer_interrupt(int irq, void *dev_id)
|
||||
{
|
||||
@ -134,6 +135,7 @@ static void __init omap2_gp_clockevent_init(void)
|
||||
|
||||
gptimer = omap_dm_timer_request_specific(gptimer_id);
|
||||
BUG_ON(gptimer == NULL);
|
||||
gptimer_wakeup = gptimer;
|
||||
|
||||
#if defined(CONFIG_OMAP_32K_TIMER)
|
||||
src = OMAP_TIMER_SRC_32_KHZ;
|
||||
|
Reference in New Issue
Block a user