diff options
Diffstat (limited to 'arch/arm/mach-shmobile/clock.c')
-rw-r--r-- | arch/arm/mach-shmobile/clock.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/arch/arm/mach-shmobile/clock.c b/arch/arm/mach-shmobile/clock.c index e816ca9bd213..ad7df629d995 100644 --- a/arch/arm/mach-shmobile/clock.c +++ b/arch/arm/mach-shmobile/clock.c @@ -23,6 +23,19 @@ #include <linux/init.h> #include <linux/sh_clk.h> #include <linux/export.h> +#include <mach/clock.h> +#include <mach/common.h> + +unsigned long shmobile_fixed_ratio_clk_recalc(struct clk *clk) +{ + struct clk_ratio *p = clk->priv; + + return clk->parent->rate / p->div * p->mul; +}; + +struct sh_clk_ops shmobile_fixed_ratio_clk_ops = { + .recalc = shmobile_fixed_ratio_clk_recalc, +}; int __init shmobile_clk_init(void) { |