diff options
author | jkim <jkim@FreeBSD.org> | 2010-12-03 21:06:30 +0000 |
---|---|---|
committer | jkim <jkim@FreeBSD.org> | 2010-12-03 21:06:30 +0000 |
commit | 27a9a04e8570c6d0eddb40b6857bbb1376a4a923 (patch) | |
tree | 2d4950430b674ff1af637d106dc187083407881c /sys | |
parent | 1ffd755b88155bbf5b6a24803f1c24805e37f340 (diff) | |
download | FreeBSD-src-27a9a04e8570c6d0eddb40b6857bbb1376a4a923.zip FreeBSD-src-27a9a04e8570c6d0eddb40b6857bbb1376a4a923.tar.gz |
Do not change CPU ticker frequency if TSC is P-state invariant. Note this
change was meant to be committed with r184102 (and its subsequent MFCs) but
it fell off somehow.
Pointyhat to: jkim
MFC after: 3 days
Diffstat (limited to 'sys')
-rw-r--r-- | sys/amd64/amd64/tsc.c | 3 | ||||
-rw-r--r-- | sys/i386/i386/tsc.c | 3 |
2 files changed, 6 insertions, 0 deletions
diff --git a/sys/amd64/amd64/tsc.c b/sys/amd64/amd64/tsc.c index 847c1eb..9ed36eb 100644 --- a/sys/amd64/amd64/tsc.c +++ b/sys/amd64/amd64/tsc.c @@ -146,6 +146,9 @@ tsc_levels_changed(void *arg, int unit) int count, error; uint64_t max_freq; + if (tsc_is_invariant) + return; + /* Only use values from the first CPU, assuming all are equal. */ if (unit != 0) return; diff --git a/sys/i386/i386/tsc.c b/sys/i386/i386/tsc.c index 882b442..185f240 100644 --- a/sys/i386/i386/tsc.c +++ b/sys/i386/i386/tsc.c @@ -174,6 +174,9 @@ tsc_levels_changed(void *arg, int unit) int count, error; uint64_t max_freq; + if (tsc_is_invariant) + return; + /* Only use values from the first CPU, assuming all are equal. */ if (unit != 0) return; |