Skip to content

Commit

Permalink
ARM: OMAP2+: hwmod: Invoke init_clkdm before other init functions
Browse files Browse the repository at this point in the history
Without this kernel would crash, since clkdm inside omap_hwmod
is accessed in some of the init functions like, _init_main_clk.

So call init_clkdm before _init_main_clk().

Signed-off-by: Vaibhav Hiremath <hvaibhav@ti.com>
Signed-off-by: Mike Turquette <mturquette@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
  • Loading branch information
Vaibhav Hiremath authored and Paul Walmsley committed Nov 13, 2012
1 parent 8577413 commit b797be1
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions arch/arm/mach-omap2/omap_hwmod.c
Original file line number Diff line number Diff line change
Expand Up @@ -1519,11 +1519,12 @@ static int _init_clocks(struct omap_hwmod *oh, void *data)

pr_debug("omap_hwmod: %s: looking up clocks\n", oh->name);

if (soc_ops.init_clkdm)
ret |= soc_ops.init_clkdm(oh);

ret |= _init_main_clk(oh);
ret |= _init_interface_clks(oh);
ret |= _init_opt_clks(oh);
if (soc_ops.init_clkdm)
ret |= soc_ops.init_clkdm(oh);

if (!ret)
oh->_state = _HWMOD_STATE_CLKS_INITED;
Expand Down

0 comments on commit b797be1

Please sign in to comment.