Skip to content

Commit 1617971

Browse files
Doug Smythiesrafaeljw
authored andcommitted
cpuidle: poll_state: Fix default time limit
The default time is declared in units of microsecnds, but is used as nanoseconds, resulting in significant accounting errors for idle state 0 time when all idle states deeper than 0 are disabled. Under these unusual conditions, we don't really care about the poll time limit anyhow. Fixes: 800fb34 ("cpuidle: poll_state: Disregard disable idle states") Signed-off-by: Doug Smythies <dsmythies@telus.net> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
1 parent f17b5f0 commit 1617971

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/cpuidle/poll_state.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ static int __cpuidle poll_idle(struct cpuidle_device *dev,
2121
local_irq_enable();
2222
if (!current_set_polling_and_test()) {
2323
unsigned int loop_count = 0;
24-
u64 limit = TICK_USEC;
24+
u64 limit = TICK_NSEC;
2525
int i;
2626

2727
for (i = 1; i < drv->state_count; i++) {

0 commit comments

Comments
 (0)