diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2010-03-01 16:18:39 +0000 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2010-05-02 09:35:38 +0100 |
commit | 9bf5b2ef673237e0e43161c56f70ac8bf24e43f9 (patch) | |
tree | 6b75855102d54da6ff6d7023ae00e25610e44f92 /arch/arm/mach-versatile | |
parent | 3081e43b97cb50a80ebd98ce4b60e4853ad38424 (diff) |
ARM: Indirect round/set_rate operations through clk structure
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/mach-versatile')
-rw-r--r-- | arch/arm/mach-versatile/core.c | 8 | ||||
-rw-r--r-- | arch/arm/mach-versatile/include/mach/clkdev.h | 4 |
2 files changed, 9 insertions, 3 deletions
diff --git a/arch/arm/mach-versatile/core.c b/arch/arm/mach-versatile/core.c index 957bbde83d3..60baba65635 100644 --- a/arch/arm/mach-versatile/core.c +++ b/arch/arm/mach-versatile/core.c @@ -381,9 +381,15 @@ static void versatile_oscvco_set(struct clk *clk, struct icst_vco vco) writel(0, sys_lock); } +static const struct clk_ops osc4_clk_ops = { + .round = icst_clk_round, + .set = icst_clk_set, + .setvco = versatile_oscvco_set, +}; + static struct clk osc4_clk = { + .ops = &osc4_clk_ops, .params = &versatile_oscvco_params, - .setvco = versatile_oscvco_set, }; /* diff --git a/arch/arm/mach-versatile/include/mach/clkdev.h b/arch/arm/mach-versatile/include/mach/clkdev.h index baea03c9ad4..e58d0771b64 100644 --- a/arch/arm/mach-versatile/include/mach/clkdev.h +++ b/arch/arm/mach-versatile/include/mach/clkdev.h @@ -1,13 +1,13 @@ #ifndef __ASM_MACH_CLKDEV_H #define __ASM_MACH_CLKDEV_H -#include <asm/hardware/icst.h> +#include <plat/clock.h> struct clk { unsigned long rate; + const struct clk_ops *ops; const struct icst_params *params; void __iomem *vcoreg; - void (*setvco)(struct clk *, struct icst_vco vco); }; #define __clk_get(clk) ({ 1; }) |