|
@@ -65,7 +65,7 @@ int cpuidle_play_dead(void)
|
|
|
return -ENODEV;
|
|
|
|
|
|
/* Find lowest-power state that supports long-term idle */
|
|
|
- for (i = drv->state_count - 1; i >= CPUIDLE_DRIVER_STATE_START; i--)
|
|
|
+ for (i = drv->state_count - 1; i >= 0; i--)
|
|
|
if (drv->states[i].enter_dead)
|
|
|
return drv->states[i].enter_dead(dev, i);
|
|
|
|
|
@@ -79,9 +79,9 @@ static int find_deepest_state(struct cpuidle_driver *drv,
|
|
|
bool freeze)
|
|
|
{
|
|
|
unsigned int latency_req = 0;
|
|
|
- int i, ret = freeze ? -1 : CPUIDLE_DRIVER_STATE_START - 1;
|
|
|
+ int i, ret = -ENXIO;
|
|
|
|
|
|
- for (i = CPUIDLE_DRIVER_STATE_START; i < drv->state_count; i++) {
|
|
|
+ for (i = 0; i < drv->state_count; i++) {
|
|
|
struct cpuidle_state *s = &drv->states[i];
|
|
|
struct cpuidle_state_usage *su = &dev->states_usage[i];
|
|
|
|