提交 c9a81e68 编写于 作者: A Akshay Adiga 提交者: Rafael J. Wysocki

cpufreq: powernv: Fix uninitialized lpstate_idx in gpstates_timer_handler()

lpstate_idx remains uninitialized in the case when elapsed_time
is greater than MAX_RAMP_DOWN_TIME.  At the end of rampdown the
global pstate should be equal to the local pstate.

Fixes: 20b15b76 (cpufreq: powernv: Use PMCR to verify global and localpstate)
Reported-by: NStephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: NAkshay Adiga <akshay.adiga@linux.vnet.ibm.com>
Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
上级 7f7a516e
......@@ -624,6 +624,7 @@ void gpstate_timer_handler(unsigned long data)
if (gpstates->elapsed_time > MAX_RAMP_DOWN_TIME) {
gpstate_idx = pstate_to_idx(freq_data.pstate_id);
lpstate_idx = gpstate_idx;
reset_gpstates(policy);
gpstates->highest_lpstate_idx = gpstate_idx;
} else {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册