Thermal limit warnings are too scary and cause unnecessary concern
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iQIcBAABAgAGBQJRzhAdAAoJEKurIx+X31iByQEP/1eAEHNiSCrrKUm/ovGCiVBZ w+ZRJkcKYBj+/3cQUeMds7OevmM8fSU5t+4zGpikobQ75xCjz7vJ6nQNLrSylqQG Z4weVme6a529szRwv6H9an+psj5wP0yWAbCgBSw4/O3cogDS0eMD8T6ZhEi8mWJ9 PRSdqOLdxl7AZpJpJpP3GF7VQLJLDbVv56FcKgAZ3mtFM6qr7HFiTtnTc+Jl33V5 bM7v23HXyoyRk+JOUMtO+4BlrkKzbtL4Zh8aGw4s71QX3zZbP0BIw9sKffNMD+2k oYXOcJjTwbtxQqXKoSKOtvLUQzf/SDqzlFf7yU38Spw+nRECPhVVRO0aAXKOmFKD 74qyNuW6ZXMw7xH4M7iG6MuM/cZIvueDtp0RSZVc6Gmb5CGb1aXz4GeotvKF5Bev nVL65UVo6XwfB4m77ayPYqfD6KX0BsWHdCzWABNl8WbgyCY5dXRJJs/c9iLCl05I EXRgWLJK/H/wOY9mj3NGcvRicYJigZP2luJEdwn8mVlpZl+3wstDcgq9Ijxr0LGi bj2H9ro3vSaXpAnJw3FR9QbXgH/8Nbb8sV7yBddy9zntrnfEfvrYtrhOKR+fPrQL C5zXeaXGEnqCEcYNESSjyhDCa1az49BlJC5ebEHHqdviHzRpVVi/EG920GViWw+D z+z25N5hi4yoUF/+1vc/ =Dm06 -----END PGP SIGNATURE----- Merge tag 'please-pull-mce-therm' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux Pull thermal power-limit update from Tony Luck: "Thermal limit warnings are too scary and cause unnecessary concern" * tag 'please-pull-mce-therm' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux: x86 thermal: Disable power limit notification interrupt by default x86 thermal: Delete power-limit-notification console messages
This commit is contained in:
commit
a9f4a7005f
2 changed files with 28 additions and 17 deletions
|
@ -1158,6 +1158,8 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
|
|||
inport.irq= [HW] Inport (ATI XL and Microsoft) busmouse driver
|
||||
Format: <irq>
|
||||
|
||||
int_pln_enable [x86] Enable power limit notification interrupt
|
||||
|
||||
intel_iommu= [DMAR] Intel IOMMU driver (DMAR) option
|
||||
on
|
||||
Enable intel iommu driver.
|
||||
|
|
|
@ -182,11 +182,6 @@ static int therm_throt_process(bool new_event, int event, int level)
|
|||
this_cpu,
|
||||
level == CORE_LEVEL ? "Core" : "Package",
|
||||
state->count);
|
||||
else
|
||||
printk(KERN_CRIT "CPU%d: %s power limit notification (total events = %lu)\n",
|
||||
this_cpu,
|
||||
level == CORE_LEVEL ? "Core" : "Package",
|
||||
state->count);
|
||||
return 1;
|
||||
}
|
||||
if (old_event) {
|
||||
|
@ -194,10 +189,6 @@ static int therm_throt_process(bool new_event, int event, int level)
|
|||
printk(KERN_INFO "CPU%d: %s temperature/speed normal\n",
|
||||
this_cpu,
|
||||
level == CORE_LEVEL ? "Core" : "Package");
|
||||
else
|
||||
printk(KERN_INFO "CPU%d: %s power limit normal\n",
|
||||
this_cpu,
|
||||
level == CORE_LEVEL ? "Core" : "Package");
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
@ -220,6 +211,15 @@ static int thresh_event_valid(int event)
|
|||
return 1;
|
||||
}
|
||||
|
||||
static bool int_pln_enable;
|
||||
static int __init int_pln_enable_setup(char *s)
|
||||
{
|
||||
int_pln_enable = true;
|
||||
|
||||
return 1;
|
||||
}
|
||||
__setup("int_pln_enable", int_pln_enable_setup);
|
||||
|
||||
#ifdef CONFIG_SYSFS
|
||||
/* Add/Remove thermal_throttle interface for CPU device: */
|
||||
static __cpuinit int thermal_throttle_add_dev(struct device *dev,
|
||||
|
@ -232,7 +232,7 @@ static __cpuinit int thermal_throttle_add_dev(struct device *dev,
|
|||
if (err)
|
||||
return err;
|
||||
|
||||
if (cpu_has(c, X86_FEATURE_PLN))
|
||||
if (cpu_has(c, X86_FEATURE_PLN) && int_pln_enable)
|
||||
err = sysfs_add_file_to_group(&dev->kobj,
|
||||
&dev_attr_core_power_limit_count.attr,
|
||||
thermal_attr_group.name);
|
||||
|
@ -240,7 +240,7 @@ static __cpuinit int thermal_throttle_add_dev(struct device *dev,
|
|||
err = sysfs_add_file_to_group(&dev->kobj,
|
||||
&dev_attr_package_throttle_count.attr,
|
||||
thermal_attr_group.name);
|
||||
if (cpu_has(c, X86_FEATURE_PLN))
|
||||
if (cpu_has(c, X86_FEATURE_PLN) && int_pln_enable)
|
||||
err = sysfs_add_file_to_group(&dev->kobj,
|
||||
&dev_attr_package_power_limit_count.attr,
|
||||
thermal_attr_group.name);
|
||||
|
@ -353,7 +353,7 @@ static void intel_thermal_interrupt(void)
|
|||
CORE_LEVEL) != 0)
|
||||
mce_log_therm_throt_event(msr_val);
|
||||
|
||||
if (this_cpu_has(X86_FEATURE_PLN))
|
||||
if (this_cpu_has(X86_FEATURE_PLN) && int_pln_enable)
|
||||
therm_throt_process(msr_val & THERM_STATUS_POWER_LIMIT,
|
||||
POWER_LIMIT_EVENT,
|
||||
CORE_LEVEL);
|
||||
|
@ -363,7 +363,7 @@ static void intel_thermal_interrupt(void)
|
|||
therm_throt_process(msr_val & PACKAGE_THERM_STATUS_PROCHOT,
|
||||
THERMAL_THROTTLING_EVENT,
|
||||
PACKAGE_LEVEL);
|
||||
if (this_cpu_has(X86_FEATURE_PLN))
|
||||
if (this_cpu_has(X86_FEATURE_PLN) && int_pln_enable)
|
||||
therm_throt_process(msr_val &
|
||||
PACKAGE_THERM_STATUS_POWER_LIMIT,
|
||||
POWER_LIMIT_EVENT,
|
||||
|
@ -482,9 +482,13 @@ void intel_init_thermal(struct cpuinfo_x86 *c)
|
|||
apic_write(APIC_LVTTHMR, h);
|
||||
|
||||
rdmsr(MSR_IA32_THERM_INTERRUPT, l, h);
|
||||
if (cpu_has(c, X86_FEATURE_PLN))
|
||||
if (cpu_has(c, X86_FEATURE_PLN) && !int_pln_enable)
|
||||
wrmsr(MSR_IA32_THERM_INTERRUPT,
|
||||
l | (THERM_INT_LOW_ENABLE
|
||||
(l | (THERM_INT_LOW_ENABLE
|
||||
| THERM_INT_HIGH_ENABLE)) & ~THERM_INT_PLN_ENABLE, h);
|
||||
else if (cpu_has(c, X86_FEATURE_PLN) && int_pln_enable)
|
||||
wrmsr(MSR_IA32_THERM_INTERRUPT,
|
||||
l | (THERM_INT_LOW_ENABLE
|
||||
| THERM_INT_HIGH_ENABLE | THERM_INT_PLN_ENABLE), h);
|
||||
else
|
||||
wrmsr(MSR_IA32_THERM_INTERRUPT,
|
||||
|
@ -492,9 +496,14 @@ void intel_init_thermal(struct cpuinfo_x86 *c)
|
|||
|
||||
if (cpu_has(c, X86_FEATURE_PTS)) {
|
||||
rdmsr(MSR_IA32_PACKAGE_THERM_INTERRUPT, l, h);
|
||||
if (cpu_has(c, X86_FEATURE_PLN))
|
||||
if (cpu_has(c, X86_FEATURE_PLN) && !int_pln_enable)
|
||||
wrmsr(MSR_IA32_PACKAGE_THERM_INTERRUPT,
|
||||
l | (PACKAGE_THERM_INT_LOW_ENABLE
|
||||
(l | (PACKAGE_THERM_INT_LOW_ENABLE
|
||||
| PACKAGE_THERM_INT_HIGH_ENABLE))
|
||||
& ~PACKAGE_THERM_INT_PLN_ENABLE, h);
|
||||
else if (cpu_has(c, X86_FEATURE_PLN) && int_pln_enable)
|
||||
wrmsr(MSR_IA32_PACKAGE_THERM_INTERRUPT,
|
||||
l | (PACKAGE_THERM_INT_LOW_ENABLE
|
||||
| PACKAGE_THERM_INT_HIGH_ENABLE
|
||||
| PACKAGE_THERM_INT_PLN_ENABLE), h);
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue