From ed1ebc4948fdfe4c68865e5543b4a68e5a55973b Mon Sep 17 00:00:00 2001 From: Rajendra Nayak Date: Fri, 27 Apr 2012 15:59:32 +0530 Subject: ARM: OMAP2: clock: Convert to common clk Convert all OMAP2 specific platform files to use COMMON clk and keep all the changes under the CONFIG_COMMON_CLK macro check so it does not break any existing code. At a later point switch to COMMON clk and get rid of all old/legacy code. Signed-off-by: Rajendra Nayak Signed-off-by: Mike Turquette [paul@pwsan.com: updated to apply] Signed-off-by: Paul Walmsley --- arch/arm/mach-omap2/pm24xx.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'arch/arm/mach-omap2/pm24xx.c') diff --git a/arch/arm/mach-omap2/pm24xx.c b/arch/arm/mach-omap2/pm24xx.c index 83815ddc4786..87ae36c7e155 100644 --- a/arch/arm/mach-omap2/pm24xx.c +++ b/arch/arm/mach-omap2/pm24xx.c @@ -25,7 +25,11 @@ #include #include #include +#ifdef CONFIG_COMMON_CLK +#include +#else #include +#endif #include #include #include @@ -202,7 +206,11 @@ static int omap2_can_sleep(void) { if (omap2_fclks_active()) return 0; +#ifdef CONFIG_COMMON_CLK + if (__clk_is_enabled(osc_ck)) +#else if (osc_ck->usecount > 1) +#endif return 0; if (omap_dma_running()) return 0; -- cgit v1.2.3