Commit 7ae42954 authored by Len Brown's avatar Len Brown Committed by Len Brown

[ACPI] add "processor.nocst" parameter

which blocks _CST parsing and always uses FADT info instead.
Signed-off-by: default avatarDominik Brodowski <linux@brodo.de>
Signed-off-by: default avatarLen Brown <len.brown@intel.com>
parent ae00fd58
...@@ -55,7 +55,10 @@ ACPI_MODULE_NAME ("acpi_processor") ...@@ -55,7 +55,10 @@ ACPI_MODULE_NAME ("acpi_processor")
#define C3_OVERHEAD 4 /* 1us (3.579 ticks per us) */ #define C3_OVERHEAD 4 /* 1us (3.579 ticks per us) */
static void (*pm_idle_save)(void); static void (*pm_idle_save)(void);
module_param_named(max_cstate, max_cstate, uint, 0644); module_param(max_cstate, uint, 0644);
static unsigned int nocst = 0;
module_param(nocst, uint, 0000);
/* -------------------------------------------------------------------------- /* --------------------------------------------------------------------------
Power Management Power Management
...@@ -506,6 +509,10 @@ static int acpi_processor_get_power_info_cst (struct acpi_processor *pr) ...@@ -506,6 +509,10 @@ static int acpi_processor_get_power_info_cst (struct acpi_processor *pr)
if (errata.smp) if (errata.smp)
return_VALUE(-ENODEV); return_VALUE(-ENODEV);
if (nocst)
return_VALUE(-ENODEV);
pr->power.count = 0; pr->power.count = 0;
for (i = 0; i < ACPI_PROCESSOR_MAX_POWER; i++) for (i = 0; i < ACPI_PROCESSOR_MAX_POWER; i++)
memset(pr->power.states, 0, sizeof(struct acpi_processor_cx)); memset(pr->power.states, 0, sizeof(struct acpi_processor_cx));
...@@ -800,7 +807,7 @@ int acpi_processor_cst_has_changed (struct acpi_processor *pr) ...@@ -800,7 +807,7 @@ int acpi_processor_cst_has_changed (struct acpi_processor *pr)
if (!pr) if (!pr)
return_VALUE(-EINVAL); return_VALUE(-EINVAL);
if (errata.smp) { if (errata.smp || nocst) {
return_VALUE(-ENODEV); return_VALUE(-ENODEV);
} }
...@@ -917,7 +924,7 @@ int acpi_processor_power_init(struct acpi_processor *pr, struct acpi_device *dev ...@@ -917,7 +924,7 @@ int acpi_processor_power_init(struct acpi_processor *pr, struct acpi_device *dev
first_run++; first_run++;
} }
if (!errata.smp && (pr->id == 0) && acpi_fadt.cst_cnt) { if (!errata.smp && (pr->id == 0) && acpi_fadt.cst_cnt && !nocst) {
status = acpi_os_write_port(acpi_fadt.smi_cmd, acpi_fadt.cst_cnt, 8); status = acpi_os_write_port(acpi_fadt.smi_cmd, acpi_fadt.cst_cnt, 8);
if (ACPI_FAILURE(status)) { if (ACPI_FAILURE(status)) {
ACPI_DEBUG_PRINT((ACPI_DB_ERROR, ACPI_DEBUG_PRINT((ACPI_DB_ERROR,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment