summaryrefslogtreecommitdiff
path: root/arch/arm
diff options
context:
space:
mode:
authorAvik Sil <avik.sil@linaro.org>2011-03-31 17:12:38 +0530
committerAvik Sil <avik.sil@linaro.org>2011-03-31 17:12:38 +0530
commitf6950887f5a6ea73b9037cdd8346deb7fdfe6ae2 (patch)
tree14d7d781561a4328152bff5587b711b5231d7e8b /arch/arm
parentebb688e3183bd5891312bdb8f4e2f520d70b36b6 (diff)
lttng: fix cpu_hz initialization issue for omap4
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/mach-omap2/opp4xxx_data.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/opp4xxx_data.c b/arch/arm/mach-omap2/opp4xxx_data.c
index 2293ba27101..895f4d0f720 100644
--- a/arch/arm/mach-omap2/opp4xxx_data.c
+++ b/arch/arm/mach-omap2/opp4xxx_data.c
@@ -19,8 +19,11 @@
* GNU General Public License for more details.
*/
#include <linux/module.h>
+#include <linux/opp.h>
#include <plat/cpu.h>
+#include <plat/common.h>
+#include <asm/trace-clock.h>
#include "control.h"
#include "omap_opp_data.h"
@@ -93,6 +96,7 @@ static struct omap_opp_def __initdata omap44xx_opp_def_list[] = {
int __init omap4_opp_init(void)
{
int r = -ENODEV;
+ struct device *dev;
if (!cpu_is_omap44xx())
return r;
@@ -100,6 +104,13 @@ int __init omap4_opp_init(void)
r = omap_init_opp_table(omap44xx_opp_def_list,
ARRAY_SIZE(omap44xx_opp_def_list));
+ dev = omap2_get_mpuss_device();
+ cpu_hz = ULONG_MAX;
+ if (IS_ERR(opp_find_freq_floor(dev,&cpu_hz))) {
+ dev_err(dev, "%s: Unable to find highest opp\n", __func__);
+ return -ENODEV;
+ }
+
return r;
}
device_initcall(omap4_opp_init);