提交 4973b22a 编写于 作者: Z Zhang Rui 提交者: Len Brown

ACPI processor: reset the throttling state once it's invalid

If the BIOS hands us an invalid throttling state,
write a valid state.

http://bugzilla.kernel.org/show_bug.cgi?id=13259Signed-off-by: NZhang Rui <rui.zhang@intel.com>
Tested-by: NJames Ettle <theholyettlz@googlemail.com>
Signed-off-by: NLen Brown <len.brown@intel.com>
上级 56c213fa
......@@ -838,6 +838,14 @@ static int acpi_processor_get_throttling_ptc(struct acpi_processor *pr)
ret = acpi_read_throttling_status(pr, &value);
if (ret >= 0) {
state = acpi_get_throttling_state(pr, value);
if (state == -1) {
ACPI_WARNING((AE_INFO,
"Invalid throttling state, reset\n"));
state = 0;
ret = acpi_processor_set_throttling(pr, state);
if (ret)
return ret;
}
pr->throttling.state = state;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册