Changeset View
Changeset View
Standalone View
Standalone View
head/sys/x86/cpufreq/hwpstate_intel.c
Show First 20 Lines • Show All 455 Lines • ▼ Show 20 Lines | set_autonomous_hwp(struct hwp_softc *sc) | ||||
if (sc->hwp_pkg_ctrl_en) { | if (sc->hwp_pkg_ctrl_en) { | ||||
/* | /* | ||||
* "The structure of the IA32_HWP_REQUEST_PKG MSR | * "The structure of the IA32_HWP_REQUEST_PKG MSR | ||||
* (package-level) is identical to the IA32_HWP_REQUEST MSR | * (package-level) is identical to the IA32_HWP_REQUEST MSR | ||||
* with the exception of the Package Control field, which does | * with the exception of the Package Control field, which does | ||||
* not exist." (Intel SDM §14.4.4) | * not exist." (Intel SDM §14.4.4) | ||||
*/ | */ | ||||
ret = wrmsr_safe(MSR_IA32_HWP_REQUEST_PKG, sc->req); | ret = wrmsr_safe(MSR_IA32_HWP_REQUEST_PKG, sc->req); | ||||
if (ret) { | |||||
device_printf(dev, | device_printf(dev, | ||||
"Failed to set autonomous HWP for package\n"); | "Failed to set autonomous HWP for package\n"); | ||||
} | |||||
} | } | ||||
out: | out: | ||||
thread_lock(curthread); | thread_lock(curthread); | ||||
sched_unbind(curthread); | sched_unbind(curthread); | ||||
thread_unlock(curthread); | thread_unlock(curthread); | ||||
return (ret); | return (ret); | ||||
▲ Show 20 Lines • Show All 164 Lines • Show Last 20 Lines |