Skip to content

Commit 4152379

Browse files
dedekindrafaeljw
authored andcommitted
intel_idle: do not sprinkle module parameter definitions around
This is a cleanup which improves code consistency. Move the force_irq_on module parameter variable and definition to the same place where we have variables and definitions for other module parameters. Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com> Reviewed-by: Zhang Rui <rui.zhang@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
1 parent db1ae0c commit 4152379

1 file changed

Lines changed: 7 additions & 3 deletions

File tree

drivers/idle/intel_idle.c

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@ static struct cpuidle_driver intel_idle_driver = {
6868
static int max_cstate = CPUIDLE_STATE_MAX - 1;
6969
static unsigned int disabled_states_mask;
7070
static unsigned int preferred_states_mask;
71+
static bool force_irq_on __read_mostly;
7172

7273
static struct cpuidle_device __percpu *intel_idle_cpuidle_devices;
7374

@@ -1838,9 +1839,6 @@ static bool __init intel_idle_verify_cstate(unsigned int mwait_hint)
18381839
return true;
18391840
}
18401841

1841-
static bool force_irq_on __read_mostly;
1842-
module_param(force_irq_on, bool, 0444);
1843-
18441842
static void __init intel_idle_init_cstates_icpu(struct cpuidle_driver *drv)
18451843
{
18461844
int cstate;
@@ -2157,3 +2155,9 @@ MODULE_PARM_DESC(states_off, "Mask of disabled idle states");
21572155
*/
21582156
module_param_named(preferred_cstates, preferred_states_mask, uint, 0444);
21592157
MODULE_PARM_DESC(preferred_cstates, "Mask of preferred idle states");
2158+
/*
2159+
* Debugging option that forces the driver to enter all C-states with
2160+
* interrupts enabled. Does not apply to C-states with
2161+
* 'CPUIDLE_FLAG_INIT_XSTATE' and 'CPUIDLE_FLAG_IBRS' flags.
2162+
*/
2163+
module_param(force_irq_on, bool, 0444);

0 commit comments

Comments
 (0)