diff options
author | Paul Mundt <lethal@linux-sh.org> | 2009-05-11 15:27:43 -0400 |
---|---|---|
committer | Paul Mundt <lethal@linux-sh.org> | 2009-05-11 15:27:43 -0400 |
commit | b1f6cfe48c3cb1dfa77db3d2f42f765febaef9bc (patch) | |
tree | e5f2722c8ebd6dd64809a283133f60cbc50794df /arch/sh/include/asm/clock.h | |
parent | a02cb230bb4fca04f091746c593de720a0e3a94a (diff) |
sh: clkfwk: refactor rate propagation.
This resyncs the rate propagation strategy with the scheme used by the
OMAP clock framework. Child clocks are tracked on a list under each
parent and propagation happens there specifically rather than constantly
iterating over the global clock list.
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh/include/asm/clock.h')
-rw-r--r-- | arch/sh/include/asm/clock.h | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/arch/sh/include/asm/clock.h b/arch/sh/include/asm/clock.h index 241f1c1d9ce1..5dc8b73a2bd5 100644 --- a/arch/sh/include/asm/clock.h +++ b/arch/sh/include/asm/clock.h | |||
@@ -27,6 +27,9 @@ struct clk { | |||
27 | struct clk *parent; | 27 | struct clk *parent; |
28 | struct clk_ops *ops; | 28 | struct clk_ops *ops; |
29 | 29 | ||
30 | struct list_head children; | ||
31 | struct list_head sibling; /* node for children */ | ||
32 | |||
30 | int usecount; | 33 | int usecount; |
31 | 34 | ||
32 | unsigned long rate; | 35 | unsigned long rate; |
@@ -35,7 +38,6 @@ struct clk { | |||
35 | }; | 38 | }; |
36 | 39 | ||
37 | #define CLK_ALWAYS_ENABLED (1 << 0) | 40 | #define CLK_ALWAYS_ENABLED (1 << 0) |
38 | #define CLK_RATE_PROPAGATES (1 << 1) | ||
39 | #define CLK_NEEDS_INIT (1 << 2) | 41 | #define CLK_NEEDS_INIT (1 << 2) |
40 | 42 | ||
41 | /* Should be defined by processor-specific code */ | 43 | /* Should be defined by processor-specific code */ |
@@ -44,9 +46,10 @@ int __init arch_clk_init(void); | |||
44 | 46 | ||
45 | /* arch/sh/kernel/cpu/clock.c */ | 47 | /* arch/sh/kernel/cpu/clock.c */ |
46 | int clk_init(void); | 48 | int clk_init(void); |
47 | unsigned long followparent_recalc(struct clk *clk); | 49 | unsigned long followparent_recalc(struct clk *); |
50 | void recalculate_root_clocks(void); | ||
51 | void propagate_rate(struct clk *); | ||
48 | void clk_recalc_rate(struct clk *); | 52 | void clk_recalc_rate(struct clk *); |
49 | |||
50 | int clk_register(struct clk *); | 53 | int clk_register(struct clk *); |
51 | void clk_unregister(struct clk *); | 54 | void clk_unregister(struct clk *); |
52 | 55 | ||