summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorBryan Steele <brynet@cvs.openbsd.org>2013-10-05 18:47:06 +0000
committerBryan Steele <brynet@cvs.openbsd.org>2013-10-05 18:47:06 +0000
commitc29d06141fbdb9137c7bafd5adfd2b39ca799c44 (patch)
treea573f2c09818b910c74ebf3ec1f5f9330c0c7551 /sys
parent86de2de69abb3168f941d7ea3491cc8b6c039142 (diff)
Use K1X_FID macro on msr read.
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/amd64/amd64/k1x-pstate.c4
-rw-r--r--sys/arch/i386/i386/k1x-pstate.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/sys/arch/amd64/amd64/k1x-pstate.c b/sys/arch/amd64/amd64/k1x-pstate.c
index f377d30e067..ff43fc6a919 100644
--- a/sys/arch/amd64/amd64/k1x-pstate.c
+++ b/sys/arch/amd64/amd64/k1x-pstate.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: k1x-pstate.c,v 1.4 2012/01/31 01:59:20 jsg Exp $ */
+/* $OpenBSD: k1x-pstate.c,v 1.5 2013/10/05 18:47:05 brynet Exp $ */
/*
* Copyright (c) 2011 Bryan Steele <brynet@gmail.com>
*
@@ -110,7 +110,7 @@ k1x_transition(struct k1x_cpu_state *cstate, int level)
wrmsr(MSR_K1X_CONTROL, fid);
for (i = 0; i < 100; i++) {
msr = rdmsr(MSR_K1X_STATUS);
- if (msr == fid)
+ if (K1X_FID(msr) == fid)
break;
DELAY(100);
}
diff --git a/sys/arch/i386/i386/k1x-pstate.c b/sys/arch/i386/i386/k1x-pstate.c
index 50397bae85a..25d88d57866 100644
--- a/sys/arch/i386/i386/k1x-pstate.c
+++ b/sys/arch/i386/i386/k1x-pstate.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: k1x-pstate.c,v 1.4 2012/01/31 01:59:20 jsg Exp $ */
+/* $OpenBSD: k1x-pstate.c,v 1.5 2013/10/05 18:47:05 brynet Exp $ */
/*
* Copyright (c) 2011 Bryan Steele <brynet@gmail.com>
*
@@ -110,7 +110,7 @@ k1x_transition(struct k1x_cpu_state *cstate, int level)
wrmsr(MSR_K1X_CONTROL, fid);
for (i = 0; i < 100; i++) {
msr = rdmsr(MSR_K1X_STATUS);
- if (msr == fid)
+ if (K1X_FID(msr) == fid)
break;
DELAY(100);
}