aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-msm/include
diff options
context:
space:
mode:
authorStephen Boyd <sboyd@codeaurora.org>2011-02-23 12:37:42 -0500
committerDavid Brown <davidb@codeaurora.org>2011-02-28 15:40:17 -0500
commitbd32344a6baa8baac9c2b3e9c6c649cc4ed53920 (patch)
tree0b272cc0ea1e7dae1d86fd5ea43de78264000eac /arch/arm/mach-msm/include
parent2a52220c89e02423aa23e6b9fb6dc0c706465a82 (diff)
msm: clock: Migrate to clkdev
Migrating to clkdev has several advantages: * Less code in mach-msm/clock.c * A more robust clk_get() implementation * clk_add_alias() support * clk_get_sys() support In general, this will help board authors setup clock aliases and break the dependency on device pointers in the clock tables. Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Signed-off-by: David Brown <davidb@codeaurora.org>
Diffstat (limited to 'arch/arm/mach-msm/include')
-rw-r--r--arch/arm/mach-msm/include/mach/board.h4
-rw-r--r--arch/arm/mach-msm/include/mach/clkdev.h19
2 files changed, 21 insertions, 2 deletions
diff --git a/arch/arm/mach-msm/include/mach/board.h b/arch/arm/mach-msm/include/mach/board.h
index 6abf4a6eadc1..2ce8f1f2fc4d 100644
--- a/arch/arm/mach-msm/include/mach/board.h
+++ b/arch/arm/mach-msm/include/mach/board.h
@@ -31,7 +31,7 @@ struct msm_acpu_clock_platform_data
31 unsigned long wait_for_irq_khz; 31 unsigned long wait_for_irq_khz;
32}; 32};
33 33
34struct clk; 34struct clk_lookup;
35 35
36extern struct sys_timer msm_timer; 36extern struct sys_timer msm_timer;
37 37
@@ -41,7 +41,7 @@ void __init msm_add_devices(void);
41void __init msm_map_common_io(void); 41void __init msm_map_common_io(void);
42void __init msm_init_irq(void); 42void __init msm_init_irq(void);
43void __init msm_init_gpio(void); 43void __init msm_init_gpio(void);
44void __init msm_clock_init(struct clk *clock_tbl, unsigned num_clocks); 44void __init msm_clock_init(struct clk_lookup *clock_tbl, unsigned num_clocks);
45void __init msm_acpu_clock_init(struct msm_acpu_clock_platform_data *); 45void __init msm_acpu_clock_init(struct msm_acpu_clock_platform_data *);
46int __init msm_add_sdcc(unsigned int controller, 46int __init msm_add_sdcc(unsigned int controller,
47 struct msm_mmc_platform_data *plat, 47 struct msm_mmc_platform_data *plat,
diff --git a/arch/arm/mach-msm/include/mach/clkdev.h b/arch/arm/mach-msm/include/mach/clkdev.h
new file mode 100644
index 000000000000..f87a57b59534
--- /dev/null
+++ b/arch/arm/mach-msm/include/mach/clkdev.h
@@ -0,0 +1,19 @@
1/* Copyright (c) 2011, Code Aurora Forum. All rights reserved.
2 *
3 * This program is free software; you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License version 2 and
5 * only version 2 as published by the Free Software Foundation.
6 *
7 * This program is distributed in the hope that it will be useful,
8 * but WITHOUT ANY WARRANTY; without even the implied warranty of
9 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10 * GNU General Public License for more details.
11 */
12#ifndef __ASM_ARCH_MSM_CLKDEV_H
13#define __ASM_ARCH_MSM_CLKDEV_H
14
15struct clk;
16
17static inline int __clk_get(struct clk *clk) { return 1; }
18static inline void __clk_put(struct clk *clk) { }
19#endif