]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
OMAP: Add clk_get_parent() for OMAP2/3
authorMans Rullgard <mans@mansr.com>
Mon, 20 Oct 2008 23:24:24 +0000 (00:24 +0100)
committerTony Lindgren <tony@atomide.com>
Sat, 6 Dec 2008 00:10:12 +0000 (16:10 -0800)
This makes clk_get_parent() work on OMAP2/3.

Signed-off-by: Mans Rullgard <mans@mansr.com>
Acked-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
arch/arm/mach-omap2/clock.c
arch/arm/mach-omap2/clock.h
arch/arm/mach-omap2/clock24xx.c
arch/arm/mach-omap2/clock34xx.c

index 42af2865cbdd689048f4dbca222451e71ff419fd..93a692fe05ba4a1ac5393e06f5f3bd1587374756 100644 (file)
@@ -872,6 +872,11 @@ int omap2_clk_set_parent(struct clk *clk, struct clk *new_parent)
        return 0;
 }
 
+struct clk *omap2_clk_get_parent(struct clk *clk)
+{
+       return clk->parent;
+}
+
 /* DPLL rate rounding code */
 
 /**
index bcb0c0362d027fa693bf9f1f8723b3e7ffe51349..a5183d0f971e9fa3512d3de4961bd2d122b7cd94 100644 (file)
@@ -29,6 +29,7 @@ int omap2_clk_set_rate(struct clk *clk, unsigned long rate);
 int omap2_clk_set_parent(struct clk *clk, struct clk *new_parent);
 int omap2_dpll_set_rate_tolerance(struct clk *clk, unsigned int tolerance);
 long omap2_dpll_round_rate(struct clk *clk, unsigned long target_rate);
+struct clk *omap2_clk_get_parent(struct clk *clk);
 
 #ifdef CONFIG_OMAP_RESET_CLOCKS
 void omap2_clk_disable_unused(struct clk *clk);
index 32f6632c15ed90514c4c9e0f00064dcddc44e940..d9a3cb3a1595529ceaf481912eff7bb53ddf2b56 100644 (file)
@@ -416,6 +416,7 @@ static struct clk_functions omap2_clk_functions = {
        .clk_round_rate         = omap2_clk_round_rate,
        .clk_set_rate           = omap2_clk_set_rate,
        .clk_set_parent         = omap2_clk_set_parent,
+       .clk_get_parent         = omap2_clk_get_parent,
        .clk_disable_unused     = omap2_clk_disable_unused,
 #ifdef CONFIG_CPU_FREQ
        .clk_init_cpufreq_table = omap2_clk_init_cpufreq_table,
index b8b44947b05eee83fc12db87698db0d4a89544a3..e15b60d1f951fb2ac9f31086f0cf0e104106c2ee 100644 (file)
@@ -630,6 +630,7 @@ static struct clk_functions omap2_clk_functions = {
        .clk_round_rate         = omap2_clk_round_rate,
        .clk_set_rate           = omap2_clk_set_rate,
        .clk_set_parent         = omap2_clk_set_parent,
+       .clk_get_parent         = omap2_clk_get_parent,
        .clk_disable_unused     = omap2_clk_disable_unused,
 };