From: srinivas <[email protected]>
---
arch/arm/plat-omap/cpu-omap.c | 2 ++
drivers/cpuidle/cpuidle.c | 3 ++-
2 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/arch/arm/plat-omap/cpu-omap.c b/arch/arm/plat-omap/cpu-omap.c
index f9b480d..afa03aa 100644
--- a/arch/arm/plat-omap/cpu-omap.c
+++ b/arch/arm/plat-omap/cpu-omap.c
@@ -25,6 +25,7 @@
#include <linux/err.h>
#include <linux/clk.h>
#include <linux/io.h>
+#include <trace/events/power.h>
#include <mach/hardware.h>
#include <plat/clock.h>
@@ -119,6 +120,7 @@ static int omap_target(struct cpufreq_policy *policy,
break;
}
}
+ trace_power_frequency(POWER_PSTATE, ind);
}
#endif
return ret;
diff --git a/drivers/cpuidle/cpuidle.c b/drivers/cpuidle/cpuidle.c
index 12fdd39..15dc70a 100644
--- a/drivers/cpuidle/cpuidle.c
+++ b/drivers/cpuidle/cpuidle.c
@@ -85,7 +85,9 @@ static void cpuidle_idle_call(void)
/* enter the state and update stats */
dev->last_state = target_state;
+ trace_power_start(POWER_CSTATE,next_state);
dev->last_residency = target_state->enter(dev, target_state);
+ trace_power_end(0);
if (dev->last_state)
target_state = dev->last_state;
@@ -95,7 +97,6 @@ static void cpuidle_idle_call(void)
/* give the governor an opportunity to reflect on the outcome */
if (cpuidle_curr_governor->reflect)
cpuidle_curr_governor->reflect(dev);
- trace_power_end(0);
}
/**
--
1.6.0.4
_______________________________________________
linaro-dev mailing list
[email protected]
http://lists.linaro.org/mailman/listinfo/linaro-dev