diff options
author | Paul Walmsley <paul@pwsan.com> | 2011-09-15 02:01:20 +0400 |
---|---|---|
committer | Paul Walmsley <paul@pwsan.com> | 2011-09-15 02:01:20 +0400 |
commit | 08cb9703e2922db297d8f83ec110bde37823e021 (patch) | |
tree | c76df5dce71b7d8150e7c5c8a98073d5cf9542d2 /arch/arm/mach-omap2/clockdomain.h | |
parent | 057673d8bd4a223c72850d843458cf3d35340bd3 (diff) | |
download | linux-08cb9703e2922db297d8f83ec110bde37823e021.tar.xz |
OMAP: clockdomain: split clkdm_init()
In preparation for OMAP_CHIP() removal, split clkdm_init() into four
functions. This allows some of them to be called multiple times: for
example, clkdm_register_clkdms() can be called once to register
clockdomains that are common to a group of SoCs, and once to register
clockdomains that are specific to a single SoC.
The appropriate order to call these functions - which is enforced
by the code - is:
1. clkdm_register_platform_funcs()
2. clkdm_register_clkdms() (can be called multiple times)
3. clkdm_register_autodeps() (optional; deprecated)
4. clkdm_complete_init()
Convert the OMAP2, 3, and 4 clockdomain init code to use these new
functions.
While here, improve documentation, and increase CodingStyle
conformance by shortening some local variable names.
Signed-off-by: Paul Walmsley <paul@pwsan.com>
Diffstat (limited to 'arch/arm/mach-omap2/clockdomain.h')
-rw-r--r-- | arch/arm/mach-omap2/clockdomain.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/arch/arm/mach-omap2/clockdomain.h b/arch/arm/mach-omap2/clockdomain.h index 1e50c88b8a07..0d879ff490d1 100644 --- a/arch/arm/mach-omap2/clockdomain.h +++ b/arch/arm/mach-omap2/clockdomain.h @@ -166,8 +166,11 @@ struct clkdm_ops { int (*clkdm_clk_disable)(struct clockdomain *clkdm); }; -void clkdm_init(struct clockdomain **clkdms, struct clkdm_autodep *autodeps, - struct clkdm_ops *custom_funcs); +int clkdm_register_platform_funcs(struct clkdm_ops *co); +int clkdm_register_autodeps(struct clkdm_autodep *ia); +int clkdm_register_clkdms(struct clockdomain **c); +int clkdm_complete_init(void); + struct clockdomain *clkdm_lookup(const char *name); int clkdm_for_each(int (*fn)(struct clockdomain *clkdm, void *user), |