cpuidle: we should exit when cStateCount is less than 3

If only C0, C1 are available, it doesn't make any sense to enable
cpuidle

Signed-off-by: Fredrik Holmqvist <[email protected]>
This commit is contained in:
Yongcong Du
2012-11-18 17:39:19 +01:00
committed by Fredrik Holmqvist
parent e467ba95b0
commit 69f69b003a
+1 -1
View File
@@ -86,7 +86,7 @@ std_ops(int32 op, ...)
} }
close_module_list(cookie); close_module_list(cookie);
if (sCpuidleModule->cStateCount < 2) { if (sCpuidleModule->cStateCount < 3) {
dprintf("no enough available cstates, exiting...\n"); dprintf("no enough available cstates, exiting...\n");
put_module(sCpuidleModule->info.name); put_module(sCpuidleModule->info.name);
return B_ERROR; return B_ERROR;