diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/cpufreq/intel_pstate.c | 14 | ||||
-rw-r--r-- | drivers/powercap/intel_rapl.c | 1 |
2 files changed, 8 insertions, 7 deletions
diff --git a/drivers/cpufreq/intel_pstate.c b/drivers/cpufreq/intel_pstate.c index c5b81beccc8e..6414661ac1c4 100644 --- a/drivers/cpufreq/intel_pstate.c +++ b/drivers/cpufreq/intel_pstate.c | |||
@@ -31,6 +31,7 @@ | |||
31 | #include <asm/div64.h> | 31 | #include <asm/div64.h> |
32 | #include <asm/msr.h> | 32 | #include <asm/msr.h> |
33 | #include <asm/cpu_device_id.h> | 33 | #include <asm/cpu_device_id.h> |
34 | #include <asm/cpufeature.h> | ||
34 | 35 | ||
35 | #define BYT_RATIOS 0x66a | 36 | #define BYT_RATIOS 0x66a |
36 | #define BYT_VIDS 0x66b | 37 | #define BYT_VIDS 0x66b |
@@ -649,7 +650,7 @@ static struct cpu_defaults byt_params = { | |||
649 | .pid_policy = { | 650 | .pid_policy = { |
650 | .sample_rate_ms = 10, | 651 | .sample_rate_ms = 10, |
651 | .deadband = 0, | 652 | .deadband = 0, |
652 | .setpoint = 97, | 653 | .setpoint = 60, |
653 | .p_gain_pct = 14, | 654 | .p_gain_pct = 14, |
654 | .d_gain_pct = 0, | 655 | .d_gain_pct = 0, |
655 | .i_gain_pct = 4, | 656 | .i_gain_pct = 4, |
@@ -1200,8 +1201,7 @@ static int __init intel_pstate_init(void) | |||
1200 | { | 1201 | { |
1201 | int cpu, rc = 0; | 1202 | int cpu, rc = 0; |
1202 | const struct x86_cpu_id *id; | 1203 | const struct x86_cpu_id *id; |
1203 | struct cpu_defaults *cpu_info; | 1204 | struct cpu_defaults *cpu_def; |
1204 | struct cpuinfo_x86 *c = &boot_cpu_data; | ||
1205 | 1205 | ||
1206 | if (no_load) | 1206 | if (no_load) |
1207 | return -ENODEV; | 1207 | return -ENODEV; |
@@ -1217,10 +1217,10 @@ static int __init intel_pstate_init(void) | |||
1217 | if (intel_pstate_platform_pwr_mgmt_exists()) | 1217 | if (intel_pstate_platform_pwr_mgmt_exists()) |
1218 | return -ENODEV; | 1218 | return -ENODEV; |
1219 | 1219 | ||
1220 | cpu_info = (struct cpu_defaults *)id->driver_data; | 1220 | cpu_def = (struct cpu_defaults *)id->driver_data; |
1221 | 1221 | ||
1222 | copy_pid_params(&cpu_info->pid_policy); | 1222 | copy_pid_params(&cpu_def->pid_policy); |
1223 | copy_cpu_funcs(&cpu_info->funcs); | 1223 | copy_cpu_funcs(&cpu_def->funcs); |
1224 | 1224 | ||
1225 | if (intel_pstate_msrs_not_valid()) | 1225 | if (intel_pstate_msrs_not_valid()) |
1226 | return -ENODEV; | 1226 | return -ENODEV; |
@@ -1231,7 +1231,7 @@ static int __init intel_pstate_init(void) | |||
1231 | if (!all_cpu_data) | 1231 | if (!all_cpu_data) |
1232 | return -ENOMEM; | 1232 | return -ENOMEM; |
1233 | 1233 | ||
1234 | if (cpu_has(c,X86_FEATURE_HWP) && !no_hwp) | 1234 | if (static_cpu_has_safe(X86_FEATURE_HWP) && !no_hwp) |
1235 | intel_pstate_hwp_enable(); | 1235 | intel_pstate_hwp_enable(); |
1236 | 1236 | ||
1237 | if (!hwp_active && hwp_only) | 1237 | if (!hwp_active && hwp_only) |
diff --git a/drivers/powercap/intel_rapl.c b/drivers/powercap/intel_rapl.c index e03877c4b195..fd243231620a 100644 --- a/drivers/powercap/intel_rapl.c +++ b/drivers/powercap/intel_rapl.c | |||
@@ -1064,6 +1064,7 @@ static const struct x86_cpu_id rapl_ids[] __initconst = { | |||
1064 | RAPL_CPU(0x3f, rapl_defaults_hsw_server),/* Haswell servers */ | 1064 | RAPL_CPU(0x3f, rapl_defaults_hsw_server),/* Haswell servers */ |
1065 | RAPL_CPU(0x4f, rapl_defaults_hsw_server),/* Broadwell servers */ | 1065 | RAPL_CPU(0x4f, rapl_defaults_hsw_server),/* Broadwell servers */ |
1066 | RAPL_CPU(0x45, rapl_defaults_core),/* Haswell ULT */ | 1066 | RAPL_CPU(0x45, rapl_defaults_core),/* Haswell ULT */ |
1067 | RAPL_CPU(0x4E, rapl_defaults_core),/* Skylake */ | ||
1067 | RAPL_CPU(0x4C, rapl_defaults_atom),/* Braswell */ | 1068 | RAPL_CPU(0x4C, rapl_defaults_atom),/* Braswell */ |
1068 | RAPL_CPU(0x4A, rapl_defaults_atom),/* Tangier */ | 1069 | RAPL_CPU(0x4A, rapl_defaults_atom),/* Tangier */ |
1069 | RAPL_CPU(0x56, rapl_defaults_core),/* Future Xeon */ | 1070 | RAPL_CPU(0x56, rapl_defaults_core),/* Future Xeon */ |