diff options
author | Tero Kristo <t-kristo@ti.com> | 2016-06-30 16:15:03 +0300 |
---|---|---|
committer | Tony Lindgren <tony@atomide.com> | 2016-07-04 07:15:47 -0700 |
commit | 183e2077d007aa4b697efba095ecfea7244a6107 (patch) | |
tree | 791f9f6bcbc4ee0ff9657c37a2cf1cc1d1afd39e /arch/arm/mach-omap2 | |
parent | 1d9a5425654de6bb141c7ca1d5dde120ee8c5430 (diff) | |
download | linux-183e2077d007aa4b697efba095ecfea7244a6107.tar.gz linux-183e2077d007aa4b697efba095ecfea7244a6107.tar.bz2 linux-183e2077d007aa4b697efba095ecfea7244a6107.zip |
ARM: AM33xx: fix module_wait_ready without clkctrl register
If the module has no clkctrl register defined, module_wait_ready should
not try to access this. This can potentially cause an illegal register
access, and result in bad idle reporting also.
Signed-off-by: Tero Kristo <t-kristo@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch/arm/mach-omap2')
-rw-r--r-- | arch/arm/mach-omap2/cm33xx.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/cm33xx.c b/arch/arm/mach-omap2/cm33xx.c index 7b181f929525..c073fb57dd13 100644 --- a/arch/arm/mach-omap2/cm33xx.c +++ b/arch/arm/mach-omap2/cm33xx.c @@ -220,6 +220,9 @@ static int am33xx_cm_wait_module_ready(u8 part, s16 inst, u16 clkctrl_offs, { int i = 0; + if (!clkctrl_offs) + return 0; + omap_test_timeout(_is_module_ready(inst, clkctrl_offs), MAX_MODULE_READY_TIME, i); |