summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortuukka.tikkanen@linaro.org <tuukka.tikkanen@linaro.org>2014-02-24 06:29:37 (GMT)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2014-03-07 11:55:17 (GMT)
commit4b2f0b033a294e6c19d57c5d0a66c000f6299559 (patch)
tree94f9b73ad4d9acbbdd073c6becd6881857599b0b
parent96e95182e95fd4e0069ff4d6ee1888fe9031d154 (diff)
downloadlinux-4b2f0b033a294e6c19d57c5d0a66c000f6299559.tar.xz
cpuidle: poll state can measure residency
For some platforms, a poll state is inserted in the cpuidle driver states. The flags for the state do not indicate that timekeeping is not affected. As the state does not do anything apart from calling cpu_relax(), the times returned by ktime_get should remain valid. Add the missing flag. Signed-off-by: Tuukka Tikkanen <tuukka.tikkanen@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
-rw-r--r--drivers/cpuidle/driver.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/cpuidle/driver.c b/drivers/cpuidle/driver.c
index 06dbe7c..136d6a2 100644
--- a/drivers/cpuidle/driver.c
+++ b/drivers/cpuidle/driver.c
@@ -209,7 +209,7 @@ static void poll_idle_init(struct cpuidle_driver *drv)
state->exit_latency = 0;
state->target_residency = 0;
state->power_usage = -1;
- state->flags = 0;
+ state->flags = CPUIDLE_FLAG_TIME_VALID;
state->enter = poll_idle;
state->disabled = false;
}