Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 184628
b: refs/heads/master
c: e9b98f6
h: refs/heads/master
v: v3
  • Loading branch information
Paul Walmsley committed Jan 27, 2010
1 parent cdd3171 commit 559a06e
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 19 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ced825293ac34d4f250775c40f13cc6330653309
refs/heads/master: e9b98f6040f5a7a04d659759d83ea28d9c528800
11 changes: 0 additions & 11 deletions trunk/arch/arm/mach-omap2/clock.c
Original file line number Diff line number Diff line change
Expand Up @@ -300,17 +300,6 @@ u32 omap2_get_dpll_rate(struct clk *clk)
return dpll_clk;
}

/*
* Used for clocks that have the same value as the parent clock,
* divided by some factor
*/
unsigned long omap2_fixed_divisor_recalc(struct clk *clk)
{
WARN_ON(!clk->fixed_div);

return clk->parent->rate / clk->fixed_div;
}

/**
* omap2_clk_dflt_find_companion - find companion clock to @clk
* @clk: struct clk * to find the companion clock of
Expand Down
1 change: 0 additions & 1 deletion trunk/arch/arm/mach-omap2/clock.h
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ u32 omap2_clksel_round_rate_div(struct clk *clk, unsigned long target_rate,
u32 *new_div);
u32 omap2_clksel_to_divisor(struct clk *clk, u32 field_val);
u32 omap2_divisor_to_clksel(struct clk *clk, u32 div);
unsigned long omap2_fixed_divisor_recalc(struct clk *clk);
long omap2_clksel_round_rate(struct clk *clk, unsigned long target_rate);
int omap2_clksel_set_rate(struct clk *clk, unsigned long rate);
u32 omap2_get_dpll_rate(struct clk *clk);
Expand Down
4 changes: 2 additions & 2 deletions trunk/arch/arm/mach-omap2/clock2xxx_data.c
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ static struct clk func_12m_ck = {
.parent = &func_48m_ck,
.fixed_div = 4,
.clkdm_name = "wkup_clkdm",
.recalc = &omap2_fixed_divisor_recalc,
.recalc = &omap_fixed_divisor_recalc,
};

/* Secure timer, only available in secure mode */
Expand Down Expand Up @@ -557,7 +557,7 @@ static struct clk iva1_mpu_int_ifck = {
.enable_reg = OMAP_CM_REGADDR(OMAP24XX_DSP_MOD, CM_FCLKEN),
.enable_bit = OMAP2420_EN_IVA_MPU_SHIFT,
.fixed_div = 2,
.recalc = &omap2_fixed_divisor_recalc,
.recalc = &omap_fixed_divisor_recalc,
};

/*
Expand Down
6 changes: 3 additions & 3 deletions trunk/arch/arm/mach-omap2/clock34xx_data.c
Original file line number Diff line number Diff line change
Expand Up @@ -735,7 +735,7 @@ static struct clk omap_12m_fck = {
.ops = &clkops_null,
.parent = &omap_48m_fck,
.fixed_div = 4,
.recalc = &omap2_fixed_divisor_recalc,
.recalc = &omap_fixed_divisor_recalc,
};

/* This virstual clock is the source for dpll4_m4x2_ck */
Expand Down Expand Up @@ -1588,15 +1588,15 @@ static struct clk ssi_sst_fck_3430es1 = {
.ops = &clkops_null,
.parent = &ssi_ssr_fck_3430es1,
.fixed_div = 2,
.recalc = &omap2_fixed_divisor_recalc,
.recalc = &omap_fixed_divisor_recalc,
};

static struct clk ssi_sst_fck_3430es2 = {
.name = "ssi_sst_fck",
.ops = &clkops_null,
.parent = &ssi_ssr_fck_3430es2,
.fixed_div = 2,
.recalc = &omap2_fixed_divisor_recalc,
.recalc = &omap_fixed_divisor_recalc,
};


Expand Down
11 changes: 11 additions & 0 deletions trunk/arch/arm/plat-omap/clock.c
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,17 @@ unsigned long followparent_recalc(struct clk *clk)
return clk->parent->rate;
}

/*
* Used for clocks that have the same value as the parent clock,
* divided by some factor
*/
unsigned long omap_fixed_divisor_recalc(struct clk *clk)
{
WARN_ON(!clk->fixed_div);

return clk->parent->rate / clk->fixed_div;
}

void clk_reparent(struct clk *child, struct clk *parent)
{
list_del_init(&child->sibling);
Expand Down
3 changes: 2 additions & 1 deletion trunk/arch/arm/plat-omap/include/plat/clock.h
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,9 @@ struct clk {
void (*init)(struct clk *);
__u8 enable_bit;
__s8 usecount;
u8 fixed_div;
#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3) || \
defined(CONFIG_ARCH_OMAP4)
u8 fixed_div;
void __iomem *clksel_reg;
u32 clksel_mask;
const struct clksel *clksel;
Expand Down Expand Up @@ -134,6 +134,7 @@ extern void propagate_rate(struct clk *clk);
extern void recalculate_root_clocks(void);
extern unsigned long followparent_recalc(struct clk *clk);
extern void clk_enable_init_clocks(void);
unsigned long omap_fixed_divisor_recalc(struct clk *clk);
#ifdef CONFIG_CPU_FREQ
extern void clk_init_cpufreq_table(struct cpufreq_frequency_table **table);
extern void clk_exit_cpufreq_table(struct cpufreq_frequency_table **table);
Expand Down

0 comments on commit 559a06e

Please sign in to comment.