intel_idle: Build fix
commit4d916140bf
upstream. Because CONFIG_ soup. Fixes:6e1d2bc675
("intel_idle: Fix intel_idle() vs tracing") Reported-by: Randy Dunlap <rdunlap@infradead.org> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Link: https://lkml.kernel.org/r/20201130115402.GO3040@hirez.programming.kicks-ass.net Signed-off-by: Chen Zhuo <sagazchen@tencent.com> Signed-off-by: Xinghui Li <korantli@tencent.com>
This commit is contained in:
parent
69a0944244
commit
91d50bd49f
|
@ -1142,6 +1142,20 @@ static bool __init intel_idle_max_cstate_reached(int cstate)
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static bool __init intel_idle_state_needs_timer_stop(struct cpuidle_state *state)
|
||||||
|
{
|
||||||
|
unsigned long eax = flg2MWAIT(state->flags);
|
||||||
|
|
||||||
|
if (boot_cpu_has(X86_FEATURE_ARAT))
|
||||||
|
return false;
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Switch over to one-shot tick broadcast if the target C-state
|
||||||
|
* is deeper than C1.
|
||||||
|
*/
|
||||||
|
return !!((eax >> MWAIT_SUBSTATE_SIZE) & MWAIT_CSTATE_MASK);
|
||||||
|
}
|
||||||
|
|
||||||
#ifdef CONFIG_ACPI_PROCESSOR_CSTATE
|
#ifdef CONFIG_ACPI_PROCESSOR_CSTATE
|
||||||
#include <acpi/processor.h>
|
#include <acpi/processor.h>
|
||||||
|
|
||||||
|
@ -1212,20 +1226,6 @@ static bool __init intel_idle_acpi_cst_extract(void)
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
static bool __init intel_idle_state_needs_timer_stop(struct cpuidle_state *state)
|
|
||||||
{
|
|
||||||
unsigned long eax = flg2MWAIT(state->flags);
|
|
||||||
|
|
||||||
if (boot_cpu_has(X86_FEATURE_ARAT))
|
|
||||||
return false;
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Switch over to one-shot tick broadcast if the target C-state
|
|
||||||
* is deeper than C1.
|
|
||||||
*/
|
|
||||||
return !!((eax >> MWAIT_SUBSTATE_SIZE) & MWAIT_CSTATE_MASK);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void __init intel_idle_init_cstates_acpi(struct cpuidle_driver *drv)
|
static void __init intel_idle_init_cstates_acpi(struct cpuidle_driver *drv)
|
||||||
{
|
{
|
||||||
int cstate, limit = min_t(int, CPUIDLE_STATE_MAX, acpi_state_table.count);
|
int cstate, limit = min_t(int, CPUIDLE_STATE_MAX, acpi_state_table.count);
|
||||||
|
|
Loading…
Reference in New Issue