aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/coretemp
diff options
context:
space:
mode:
authorAttilio Rao <attilio@FreeBSD.org>2011-09-19 10:58:30 +0000
committerAttilio Rao <attilio@FreeBSD.org>2011-09-19 10:58:30 +0000
commitc839b5bbf75d4a5b79a9e7fd6fc3a76cf4206d4f (patch)
tree25883e54cacc5ebcd2fb30fd8142d49fffb1be5c /sys/dev/coretemp
parentc61f25617c9b4db4c627097bbd9cdead643c2058 (diff)
downloadsrc-c839b5bbf75d4a5b79a9e7fd6fc3a76cf4206d4f.tar.gz
src-c839b5bbf75d4a5b79a9e7fd6fc3a76cf4206d4f.zip
#PROCHOT assertion is sticky after reading the MSR (accordingly with
Intel manuals) it must be cleared by writing a 0. Fix that. Sponsored by: Sandvine Incorporated Reported by: rstone Reviewed by: delphij, emaste, rstone Approved by: re (kib) MFC after: 1 week
Notes
Notes: svn path=/head/; revision=225662
Diffstat (limited to 'sys/dev/coretemp')
-rw-r--r--sys/dev/coretemp/coretemp.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/dev/coretemp/coretemp.c b/sys/dev/coretemp/coretemp.c
index cb1cbff3100e..54e5a4365e87 100644
--- a/sys/dev/coretemp/coretemp.c
+++ b/sys/dev/coretemp/coretemp.c
@@ -384,6 +384,7 @@ coretemp_get_val_sysctl(SYSCTL_HANDLER_ARGS)
}
if (msr & THERM_STATUS_LOG) {
+ coretemp_clear_thermal_msr(device_get_unit(dev));
sc->sc_throttle_log = 1;
/*
@@ -424,8 +425,10 @@ coretemp_throttle_log_sysctl(SYSCTL_HANDLER_ARGS)
msr = coretemp_get_thermal_msr(device_get_unit(dev));
sc = device_get_softc(dev);
- if (msr & THERM_STATUS_LOG)
+ if (msr & THERM_STATUS_LOG) {
+ coretemp_clear_thermal_msr(device_get_unit(dev));
sc->sc_throttle_log = 1;
+ }
val = sc->sc_throttle_log;