提交 8e37e1a2 编写于 作者: A Alex Shi 提交者: Rafael J. Wysocki

cpuidle/menu: stop seeking deeper idle if current state is deep enough

Obsolete commit 71abbbf8 (cpuidle: extend cpuidle and menu governor
to handle dynamic states) wanted to introduce dynamic C-states, but that
idea was dropped long ago.  The nonsense deeper C-state checking
remained, though.

Since both target_residency and exit_latency are longer for deeper
idle state, there's no need to waste CPU time on useless checks.
Signed-off-by: NAlex Shi <alex.shi@linaro.org>
Acked-by: NRik van Riel <riel@redhat.com>
[ rjw: Subject & changelog ]
Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
上级 2dc8ffad
......@@ -357,9 +357,9 @@ static int menu_select(struct cpuidle_driver *drv, struct cpuidle_device *dev)
if (s->disabled || su->disable)
continue;
if (s->target_residency > data->predicted_us)
continue;
break;
if (s->exit_latency > latency_req)
continue;
break;
data->last_state_idx = i;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册