summaryrefslogtreecommitdiffstats
path: root/arch/x86/include/asm/msr-index.h
diff options
context:
space:
mode:
authorLen Brown <len.brown@intel.com>2015-12-01 07:36:39 +0100
committerLen Brown <len.brown@intel.com>2016-02-17 07:42:26 +0100
commit670e27d809a9a29943e1d2e45823fa4fc16c29f0 (patch)
tree37bca9b2a52d484751814a028f208ed9aa5738a9 /arch/x86/include/asm/msr-index.h
parenttools/power turbostat: CPUID(0x16) leaf shows base, max, and bus frequency (diff)
downloadlinux-670e27d809a9a29943e1d2e45823fa4fc16c29f0.tar.xz
linux-670e27d809a9a29943e1d2e45823fa4fc16c29f0.zip
x86 msr-index: Simplify syntax for HWP fields
syntax only, no functional change Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'arch/x86/include/asm/msr-index.h')
-rw-r--r--arch/x86/include/asm/msr-index.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/arch/x86/include/asm/msr-index.h b/arch/x86/include/asm/msr-index.h
index 690b4027e17c..5c5e7e53d824 100644
--- a/arch/x86/include/asm/msr-index.h
+++ b/arch/x86/include/asm/msr-index.h
@@ -230,10 +230,10 @@
#define HWP_PACKAGE_LEVEL_REQUEST_BIT (1<<11)
/* IA32_HWP_CAPABILITIES */
-#define HWP_HIGHEST_PERF(x) (x & 0xff)
-#define HWP_GUARANTEED_PERF(x) ((x & (0xff << 8)) >>8)
-#define HWP_MOSTEFFICIENT_PERF(x) ((x & (0xff << 16)) >>16)
-#define HWP_LOWEST_PERF(x) ((x & (0xff << 24)) >>24)
+#define HWP_HIGHEST_PERF(x) (((x) >> 0) & 0xff)
+#define HWP_GUARANTEED_PERF(x) (((x) >> 8) & 0xff)
+#define HWP_MOSTEFFICIENT_PERF(x) (((x) >> 16) & 0xff)
+#define HWP_LOWEST_PERF(x) (((x) >> 24) & 0xff)
/* IA32_HWP_REQUEST */
#define HWP_MIN_PERF(x) (x & 0xff)