mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-30 12:49:36 +00:00
ARM: OMAP5 / DRA7: PM: Set MPUSS-EMIF clock-domain static dependency
With EMIF clock-domain put under hardware supervised control, memory corruption and untraceable crashes are observed on OMAP5. Further investigation revealed that there is a weakness in the PRCM on this specific dynamic depedency. The recommendation is to set MPUSS static dependency towards EMIF clock-domain to avoid issues. This recommendation holds good for DRA7 family of devices as well. Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com> [rnayak@ti.com: DRA7] Signed-off-by: Rajendra Nayak <rnayak@ti.com> [nm@ti.com: conflict resolution, dra7] Signed-off-by: Nishanth Menon <nm@ti.com> Reviewed-by: Kevin Hilman <khilman@linaro.org> Tested-by: Kevin Hilman <khilman@linaro.org>
This commit is contained in:
parent
a89726d3b4
commit
d2136bce9d
1 changed files with 33 additions and 3 deletions
|
@ -202,6 +202,32 @@ static inline int omap4_init_static_deps(void)
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* omap5_dra7_init_static_deps - Init static clkdm dependencies on OMAP5 and
|
||||||
|
* DRA7
|
||||||
|
*
|
||||||
|
* The dynamic dependency between MPUSS -> EMIF is broken and has
|
||||||
|
* not worked as expected. The hardware recommendation is to
|
||||||
|
* enable static dependencies for these to avoid system
|
||||||
|
* lock ups or random crashes.
|
||||||
|
*/
|
||||||
|
static inline int omap5_dra7_init_static_deps(void)
|
||||||
|
{
|
||||||
|
struct clockdomain *mpuss_clkdm, *emif_clkdm;
|
||||||
|
int ret;
|
||||||
|
|
||||||
|
mpuss_clkdm = clkdm_lookup("mpu_clkdm");
|
||||||
|
emif_clkdm = clkdm_lookup("emif_clkdm");
|
||||||
|
if (!mpuss_clkdm || !emif_clkdm)
|
||||||
|
return -EINVAL;
|
||||||
|
|
||||||
|
ret = clkdm_add_wkdep(mpuss_clkdm, emif_clkdm);
|
||||||
|
if (ret)
|
||||||
|
pr_err("Failed to add MPUSS -> EMIF wakeup dependency\n");
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* omap4_pm_init_early - Does early initialization necessary for OMAP4+ devices
|
* omap4_pm_init_early - Does early initialization necessary for OMAP4+ devices
|
||||||
*
|
*
|
||||||
|
@ -239,10 +265,14 @@ int __init omap4_pm_init(void)
|
||||||
goto err2;
|
goto err2;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (cpu_is_omap44xx()) {
|
if (cpu_is_omap44xx())
|
||||||
ret = omap4_init_static_deps();
|
ret = omap4_init_static_deps();
|
||||||
if (ret)
|
else if (soc_is_omap54xx() || soc_is_dra7xx())
|
||||||
goto err2;
|
ret = omap5_dra7_init_static_deps();
|
||||||
|
|
||||||
|
if (ret) {
|
||||||
|
pr_err("Failed to initialise static dependencies.\n");
|
||||||
|
goto err2;
|
||||||
}
|
}
|
||||||
|
|
||||||
ret = omap4_mpuss_init();
|
ret = omap4_mpuss_init();
|
||||||
|
|
Loading…
Reference in a new issue