X-Git-Url: http://pileus.org/git/?a=blobdiff_plain;f=arch%2Farm%2Fmach-omap2%2Fpm.c;h=f4b3143a8b1d23f104419181c0d266b07e31ad78;hb=5031a2a7c12b837a0913c4139ebeb6bbff5e1aa5;hp=331478f9b86403cd73d770bc564602c6b912b01e;hpb=d408c5dcc524dfc8e687c443719a3d6be86e2ea0;p=~andy%2Flinux diff --git a/arch/arm/mach-omap2/pm.c b/arch/arm/mach-omap2/pm.c index 331478f9b86..f4b3143a8b1 100644 --- a/arch/arm/mach-omap2/pm.c +++ b/arch/arm/mach-omap2/pm.c @@ -40,6 +40,38 @@ static struct omap_device_pm_latency *pm_lats; */ int (*omap_pm_suspend)(void); +#ifdef CONFIG_PM +/** + * struct omap2_oscillator - Describe the board main oscillator latencies + * @startup_time: oscillator startup latency + * @shutdown_time: oscillator shutdown latency + */ +struct omap2_oscillator { + u32 startup_time; + u32 shutdown_time; +}; + +static struct omap2_oscillator oscillator = { + .startup_time = ULONG_MAX, + .shutdown_time = ULONG_MAX, +}; + +void omap_pm_setup_oscillator(u32 tstart, u32 tshut) +{ + oscillator.startup_time = tstart; + oscillator.shutdown_time = tshut; +} + +void omap_pm_get_oscillator(u32 *tstart, u32 *tshut) +{ + if (!tstart || !tshut) + return; + + *tstart = oscillator.startup_time; + *tshut = oscillator.shutdown_time; +} +#endif + static int __init _init_omap_device(char *name) { struct omap_hwmod *oh;