summaryrefslogtreecommitdiffstats
path: root/sys/x86
diff options
context:
space:
mode:
authormav <mav@FreeBSD.org>2010-09-16 02:59:25 +0000
committermav <mav@FreeBSD.org>2010-09-16 02:59:25 +0000
commite0d6e8068db893e66e2cacca8a3b1b800c40bc43 (patch)
treec5e7c345df3b681e99c1db43b898ba9505a76600 /sys/x86
parent489c1437aad80456391795b153ab87e37f44680d (diff)
downloadFreeBSD-src-e0d6e8068db893e66e2cacca8a3b1b800c40bc43.zip
FreeBSD-src-e0d6e8068db893e66e2cacca8a3b1b800c40bc43.tar.gz
Few whitespace cleanups and comments tunings.
Submitted by: arundel
Diffstat (limited to 'sys/x86')
-rw-r--r--sys/x86/cpufreq/est.c22
1 files changed, 12 insertions, 10 deletions
diff --git a/sys/x86/cpufreq/est.c b/sys/x86/cpufreq/est.c
index 144858c..ecca30c 100644
--- a/sys/x86/cpufreq/est.c
+++ b/sys/x86/cpufreq/est.c
@@ -110,14 +110,16 @@ CTASSERT(EST_MAX_SETTINGS <= MAX_SETTINGS);
#define EST_TRANS_LAT 1000
/*
- * Frequency (MHz) and voltage (mV) settings. Data from the
- * Intel Pentium M Processor Datasheet (Order Number 252612), Table 5.
+ * Frequency (MHz) and voltage (mV) settings.
*
* Dothan processors have multiple VID#s with different settings for
* each VID#. Since we can't uniquely identify this info
* without undisclosed methods from Intel, we can't support newer
* processors with this table method. If ACPI Px states are supported,
* we get info from them.
+ *
+ * Data from the "Intel Pentium M Processor Datasheet",
+ * Order Number 252612-003, Table 5.
*/
static freq_info PM17_130[] = {
/* 130nm 1.70GHz Pentium M */
@@ -217,7 +219,7 @@ static freq_info PM10_ULV_130[] = {
/*
* Data from "Intel Pentium M Processor on 90nm Process with
- * 2-MB L2 Cache Datasheet", Order Number 302189, Table 5.
+ * 2-MB L2 Cache Datasheet", Order Number 302189-008, Table 5.
*/
static freq_info PM_765A_90[] = {
/* 90 nm 2.10GHz Pentium M, VID #A */
@@ -985,7 +987,7 @@ est_probe(device_t dev)
device_t perf_dev;
uint64_t msr;
int error, type;
-
+
if (resource_disabled("est", 0))
return (ENXIO);
@@ -1125,7 +1127,7 @@ est_acpi_info(device_t dev, freq_info **freqs)
if (sets[i].freq > 0) {
error = est_set_id16(dev, sets[i].spec[0], strict);
if (error != 0) {
- if (bootverbose)
+ if (bootverbose)
device_printf(dev, "Invalid freq %u, "
"ignored.\n", sets[i].freq);
continue;
@@ -1221,7 +1223,7 @@ est_msr_info(device_t dev, uint64_t msr, freq_info **freqs)
device_printf(dev, "Guessed bus clock (low) of %d MHz\n", bus);
if (!bus_speed_ok(bus))
return (EOPNOTSUPP);
-
+
/* Calculate high frequency. */
id = msr >> 32;
freq = ((id >> 8) & 0xff) * bus;
@@ -1282,14 +1284,14 @@ est_set_id16(device_t dev, uint16_t id16, int need_check)
msr = rdmsr(MSR_PERF_CTL);
msr = (msr & ~0xffff) | id16;
wrmsr(MSR_PERF_CTL, msr);
-
+
/* Wait a short while for the new setting. XXX Is this necessary? */
DELAY(EST_TRANS_LAT);
-
+
if (need_check) {
- est_get_id16(&new_id16);
+ est_get_id16(&new_id16);
if (new_id16 != id16) {
- if (bootverbose)
+ if (bootverbose)
device_printf(dev, "Invalid id16 (set, cur) "
"= (%u, %u)\n", id16, new_id16);
ret = ENXIO;
OpenPOWER on IntegriCloud