diff options
author | Borislav Petkov <bp@suse.de> | 2015-12-07 04:39:39 -0500 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2015-12-19 05:49:53 -0500 |
commit | 2ccd71f1b278d450a6f8c8c737c7fe237ca06dc6 (patch) | |
tree | 2365ca28c6bfd32d2a0527539317db5eddb6ebde /arch/x86/include | |
parent | 0fa85119cd480c1ded7a81ed64f723fe16a15355 (diff) |
x86/cpufeature: Move some of the scattered feature bits to x86_capability
Turn the CPUID leafs which are proper CPUID feature bit leafs into
separate ->x86_capability words.
Signed-off-by: Borislav Petkov <bp@suse.de>
Link: http://lkml.kernel.org/r/1449481182-27541-2-git-send-email-bp@alien8.de
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'arch/x86/include')
-rw-r--r-- | arch/x86/include/asm/cpufeature.h | 54 |
1 files changed, 32 insertions, 22 deletions
diff --git a/arch/x86/include/asm/cpufeature.h b/arch/x86/include/asm/cpufeature.h index e4f8010f22e0..13d78e0e6ae0 100644 --- a/arch/x86/include/asm/cpufeature.h +++ b/arch/x86/include/asm/cpufeature.h | |||
@@ -12,7 +12,7 @@ | |||
12 | #include <asm/disabled-features.h> | 12 | #include <asm/disabled-features.h> |
13 | #endif | 13 | #endif |
14 | 14 | ||
15 | #define NCAPINTS 14 /* N 32-bit words worth of info */ | 15 | #define NCAPINTS 16 /* N 32-bit words worth of info */ |
16 | #define NBUGINTS 1 /* N 32-bit bug flags */ | 16 | #define NBUGINTS 1 /* N 32-bit bug flags */ |
17 | 17 | ||
18 | /* | 18 | /* |
@@ -181,22 +181,17 @@ | |||
181 | 181 | ||
182 | /* | 182 | /* |
183 | * Auxiliary flags: Linux defined - For features scattered in various | 183 | * Auxiliary flags: Linux defined - For features scattered in various |
184 | * CPUID levels like 0x6, 0xA etc, word 7 | 184 | * CPUID levels like 0x6, 0xA etc, word 7. |
185 | * | ||
186 | * Reuse free bits when adding new feature flags! | ||
185 | */ | 187 | */ |
186 | #define X86_FEATURE_IDA ( 7*32+ 0) /* Intel Dynamic Acceleration */ | 188 | |
187 | #define X86_FEATURE_ARAT ( 7*32+ 1) /* Always Running APIC Timer */ | ||
188 | #define X86_FEATURE_CPB ( 7*32+ 2) /* AMD Core Performance Boost */ | 189 | #define X86_FEATURE_CPB ( 7*32+ 2) /* AMD Core Performance Boost */ |
189 | #define X86_FEATURE_EPB ( 7*32+ 3) /* IA32_ENERGY_PERF_BIAS support */ | 190 | #define X86_FEATURE_EPB ( 7*32+ 3) /* IA32_ENERGY_PERF_BIAS support */ |
190 | #define X86_FEATURE_PLN ( 7*32+ 5) /* Intel Power Limit Notification */ | 191 | |
191 | #define X86_FEATURE_PTS ( 7*32+ 6) /* Intel Package Thermal Status */ | ||
192 | #define X86_FEATURE_DTHERM ( 7*32+ 7) /* Digital Thermal Sensor */ | ||
193 | #define X86_FEATURE_HW_PSTATE ( 7*32+ 8) /* AMD HW-PState */ | 192 | #define X86_FEATURE_HW_PSTATE ( 7*32+ 8) /* AMD HW-PState */ |
194 | #define X86_FEATURE_PROC_FEEDBACK ( 7*32+ 9) /* AMD ProcFeedbackInterface */ | 193 | #define X86_FEATURE_PROC_FEEDBACK ( 7*32+ 9) /* AMD ProcFeedbackInterface */ |
195 | #define X86_FEATURE_HWP ( 7*32+ 10) /* "hwp" Intel HWP */ | 194 | |
196 | #define X86_FEATURE_HWP_NOTIFY ( 7*32+ 11) /* Intel HWP_NOTIFY */ | ||
197 | #define X86_FEATURE_HWP_ACT_WINDOW ( 7*32+ 12) /* Intel HWP_ACT_WINDOW */ | ||
198 | #define X86_FEATURE_HWP_EPP ( 7*32+13) /* Intel HWP_EPP */ | ||
199 | #define X86_FEATURE_HWP_PKG_REQ ( 7*32+14) /* Intel HWP_PKG_REQ */ | ||
200 | #define X86_FEATURE_INTEL_PT ( 7*32+15) /* Intel Processor Trace */ | 195 | #define X86_FEATURE_INTEL_PT ( 7*32+15) /* Intel Processor Trace */ |
201 | 196 | ||
202 | /* Virtualization flags: Linux defined, word 8 */ | 197 | /* Virtualization flags: Linux defined, word 8 */ |
@@ -205,16 +200,7 @@ | |||
205 | #define X86_FEATURE_FLEXPRIORITY ( 8*32+ 2) /* Intel FlexPriority */ | 200 | #define X86_FEATURE_FLEXPRIORITY ( 8*32+ 2) /* Intel FlexPriority */ |
206 | #define X86_FEATURE_EPT ( 8*32+ 3) /* Intel Extended Page Table */ | 201 | #define X86_FEATURE_EPT ( 8*32+ 3) /* Intel Extended Page Table */ |
207 | #define X86_FEATURE_VPID ( 8*32+ 4) /* Intel Virtual Processor ID */ | 202 | #define X86_FEATURE_VPID ( 8*32+ 4) /* Intel Virtual Processor ID */ |
208 | #define X86_FEATURE_NPT ( 8*32+ 5) /* AMD Nested Page Table support */ | 203 | |
209 | #define X86_FEATURE_LBRV ( 8*32+ 6) /* AMD LBR Virtualization support */ | ||
210 | #define X86_FEATURE_SVML ( 8*32+ 7) /* "svm_lock" AMD SVM locking MSR */ | ||
211 | #define X86_FEATURE_NRIPS ( 8*32+ 8) /* "nrip_save" AMD SVM next_rip save */ | ||
212 | #define X86_FEATURE_TSCRATEMSR ( 8*32+ 9) /* "tsc_scale" AMD TSC scaling support */ | ||
213 | #define X86_FEATURE_VMCBCLEAN ( 8*32+10) /* "vmcb_clean" AMD VMCB clean bits support */ | ||
214 | #define X86_FEATURE_FLUSHBYASID ( 8*32+11) /* AMD flush-by-ASID support */ | ||
215 | #define X86_FEATURE_DECODEASSISTS ( 8*32+12) /* AMD Decode Assists support */ | ||
216 | #define X86_FEATURE_PAUSEFILTER ( 8*32+13) /* AMD filtered pause intercept */ | ||
217 | #define X86_FEATURE_PFTHRESHOLD ( 8*32+14) /* AMD pause filter threshold */ | ||
218 | #define X86_FEATURE_VMMCALL ( 8*32+15) /* Prefer vmmcall to vmcall */ | 204 | #define X86_FEATURE_VMMCALL ( 8*32+15) /* Prefer vmmcall to vmcall */ |
219 | 205 | ||
220 | 206 | ||
@@ -258,6 +244,30 @@ | |||
258 | /* AMD-defined CPU features, CPUID level 0x80000008 (ebx), word 13 */ | 244 | /* AMD-defined CPU features, CPUID level 0x80000008 (ebx), word 13 */ |
259 | #define X86_FEATURE_CLZERO (13*32+0) /* CLZERO instruction */ | 245 | #define X86_FEATURE_CLZERO (13*32+0) /* CLZERO instruction */ |
260 | 246 | ||
247 | /* Thermal and Power Management Leaf, CPUID level 0x00000006 (eax), word 14 */ | ||
248 | #define X86_FEATURE_DTHERM (14*32+ 0) /* Digital Thermal Sensor */ | ||
249 | #define X86_FEATURE_IDA (14*32+ 1) /* Intel Dynamic Acceleration */ | ||
250 | #define X86_FEATURE_ARAT (14*32+ 2) /* Always Running APIC Timer */ | ||
251 | #define X86_FEATURE_PLN (14*32+ 4) /* Intel Power Limit Notification */ | ||
252 | #define X86_FEATURE_PTS (14*32+ 6) /* Intel Package Thermal Status */ | ||
253 | #define X86_FEATURE_HWP (14*32+ 7) /* Intel Hardware P-states */ | ||
254 | #define X86_FEATURE_HWP_NOTIFY (14*32+ 8) /* HWP Notification */ | ||
255 | #define X86_FEATURE_HWP_ACT_WINDOW (14*32+ 9) /* HWP Activity Window */ | ||
256 | #define X86_FEATURE_HWP_EPP (14*32+10) /* HWP Energy Perf. Preference */ | ||
257 | #define X86_FEATURE_HWP_PKG_REQ (14*32+11) /* HWP Package Level Request */ | ||
258 | |||
259 | /* AMD SVM Feature Identification, CPUID level 0x8000000a (edx), word 15 */ | ||
260 | #define X86_FEATURE_NPT (15*32+ 0) /* Nested Page Table support */ | ||
261 | #define X86_FEATURE_LBRV (15*32+ 1) /* LBR Virtualization support */ | ||
262 | #define X86_FEATURE_SVML (15*32+ 2) /* "svm_lock" SVM locking MSR */ | ||
263 | #define X86_FEATURE_NRIPS (15*32+ 3) /* "nrip_save" SVM next_rip save */ | ||
264 | #define X86_FEATURE_TSCRATEMSR (15*32+ 4) /* "tsc_scale" TSC scaling support */ | ||
265 | #define X86_FEATURE_VMCBCLEAN (15*32+ 5) /* "vmcb_clean" VMCB clean bits support */ | ||
266 | #define X86_FEATURE_FLUSHBYASID (15*32+ 6) /* flush-by-ASID support */ | ||
267 | #define X86_FEATURE_DECODEASSISTS (15*32+ 7) /* Decode Assists support */ | ||
268 | #define X86_FEATURE_PAUSEFILTER (15*32+10) /* filtered pause intercept */ | ||
269 | #define X86_FEATURE_PFTHRESHOLD (15*32+12) /* pause filter threshold */ | ||
270 | |||
261 | /* | 271 | /* |
262 | * BUG word(s) | 272 | * BUG word(s) |
263 | */ | 273 | */ |