Commit 9261c5b2 authored by Tony Lindgren's avatar Tony Lindgren

ARM: OMAP2+: Check for inited flag

If we have no hwmods configured and omap_hwmod_init() is not called,
we don't want to call omap_hwmod_setup_all() as it will fail with
checks for configured MPU at least.
Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
parent 4097c9a6
...@@ -627,6 +627,9 @@ static struct clockdomain *_get_clkdm(struct omap_hwmod *oh) ...@@ -627,6 +627,9 @@ static struct clockdomain *_get_clkdm(struct omap_hwmod *oh)
{ {
struct clk_hw_omap *clk; struct clk_hw_omap *clk;
if (!oh)
return NULL;
if (oh->clkdm) { if (oh->clkdm) {
return oh->clkdm; return oh->clkdm;
} else if (oh->_clk) { } else if (oh->_clk) {
...@@ -3677,6 +3680,9 @@ static void __init omap_hwmod_setup_earlycon_flags(void) ...@@ -3677,6 +3680,9 @@ static void __init omap_hwmod_setup_earlycon_flags(void)
*/ */
static int __init omap_hwmod_setup_all(void) static int __init omap_hwmod_setup_all(void)
{ {
if (!inited)
return 0;
_ensure_mpu_hwmod_is_setup(NULL); _ensure_mpu_hwmod_is_setup(NULL);
omap_hwmod_for_each(_init, NULL); omap_hwmod_for_each(_init, NULL);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment