diff options
Diffstat (limited to 'include/asm-x86/processor.h')
-rw-r--r-- | include/asm-x86/processor.h | 62 |
1 files changed, 21 insertions, 41 deletions
diff --git a/include/asm-x86/processor.h b/include/asm-x86/processor.h index 5eaf9bf0a623..ee7cbb30773a 100644 --- a/include/asm-x86/processor.h +++ b/include/asm-x86/processor.h | |||
@@ -76,11 +76,11 @@ struct cpuinfo_x86 { | |||
76 | int x86_tlbsize; | 76 | int x86_tlbsize; |
77 | __u8 x86_virt_bits; | 77 | __u8 x86_virt_bits; |
78 | __u8 x86_phys_bits; | 78 | __u8 x86_phys_bits; |
79 | #endif | ||
79 | /* CPUID returned core id bits: */ | 80 | /* CPUID returned core id bits: */ |
80 | __u8 x86_coreid_bits; | 81 | __u8 x86_coreid_bits; |
81 | /* Max extended CPUID function supported: */ | 82 | /* Max extended CPUID function supported: */ |
82 | __u32 extended_cpuid_level; | 83 | __u32 extended_cpuid_level; |
83 | #endif | ||
84 | /* Maximum supported CPUID level, -1=no CPUID: */ | 84 | /* Maximum supported CPUID level, -1=no CPUID: */ |
85 | int cpuid_level; | 85 | int cpuid_level; |
86 | __u32 x86_capability[NCAPINTS]; | 86 | __u32 x86_capability[NCAPINTS]; |
@@ -166,11 +166,8 @@ extern void init_scattered_cpuid_features(struct cpuinfo_x86 *c); | |||
166 | extern unsigned int init_intel_cacheinfo(struct cpuinfo_x86 *c); | 166 | extern unsigned int init_intel_cacheinfo(struct cpuinfo_x86 *c); |
167 | extern unsigned short num_cache_leaves; | 167 | extern unsigned short num_cache_leaves; |
168 | 168 | ||
169 | #if defined(CONFIG_X86_HT) || defined(CONFIG_X86_64) | 169 | extern void detect_extended_topology(struct cpuinfo_x86 *c); |
170 | extern void detect_ht(struct cpuinfo_x86 *c); | 170 | extern void detect_ht(struct cpuinfo_x86 *c); |
171 | #else | ||
172 | static inline void detect_ht(struct cpuinfo_x86 *c) {} | ||
173 | #endif | ||
174 | 171 | ||
175 | static inline void native_cpuid(unsigned int *eax, unsigned int *ebx, | 172 | static inline void native_cpuid(unsigned int *eax, unsigned int *ebx, |
176 | unsigned int *ecx, unsigned int *edx) | 173 | unsigned int *ecx, unsigned int *edx) |
@@ -327,7 +324,12 @@ struct i387_fxsave_struct { | |||
327 | /* 16*16 bytes for each XMM-reg = 256 bytes: */ | 324 | /* 16*16 bytes for each XMM-reg = 256 bytes: */ |
328 | u32 xmm_space[64]; | 325 | u32 xmm_space[64]; |
329 | 326 | ||
330 | u32 padding[24]; | 327 | u32 padding[12]; |
328 | |||
329 | union { | ||
330 | u32 padding1[12]; | ||
331 | u32 sw_reserved[12]; | ||
332 | }; | ||
331 | 333 | ||
332 | } __attribute__((aligned(16))); | 334 | } __attribute__((aligned(16))); |
333 | 335 | ||
@@ -351,10 +353,23 @@ struct i387_soft_struct { | |||
351 | u32 entry_eip; | 353 | u32 entry_eip; |
352 | }; | 354 | }; |
353 | 355 | ||
356 | struct xsave_hdr_struct { | ||
357 | u64 xstate_bv; | ||
358 | u64 reserved1[2]; | ||
359 | u64 reserved2[5]; | ||
360 | } __attribute__((packed)); | ||
361 | |||
362 | struct xsave_struct { | ||
363 | struct i387_fxsave_struct i387; | ||
364 | struct xsave_hdr_struct xsave_hdr; | ||
365 | /* new processor state extensions will go here */ | ||
366 | } __attribute__ ((packed, aligned (64))); | ||
367 | |||
354 | union thread_xstate { | 368 | union thread_xstate { |
355 | struct i387_fsave_struct fsave; | 369 | struct i387_fsave_struct fsave; |
356 | struct i387_fxsave_struct fxsave; | 370 | struct i387_fxsave_struct fxsave; |
357 | struct i387_soft_struct soft; | 371 | struct i387_soft_struct soft; |
372 | struct xsave_struct xsave; | ||
358 | }; | 373 | }; |
359 | 374 | ||
360 | #ifdef CONFIG_X86_64 | 375 | #ifdef CONFIG_X86_64 |
@@ -571,41 +586,6 @@ static inline void clear_in_cr4(unsigned long mask) | |||
571 | write_cr4(cr4); | 586 | write_cr4(cr4); |
572 | } | 587 | } |
573 | 588 | ||
574 | struct microcode_header { | ||
575 | unsigned int hdrver; | ||
576 | unsigned int rev; | ||
577 | unsigned int date; | ||
578 | unsigned int sig; | ||
579 | unsigned int cksum; | ||
580 | unsigned int ldrver; | ||
581 | unsigned int pf; | ||
582 | unsigned int datasize; | ||
583 | unsigned int totalsize; | ||
584 | unsigned int reserved[3]; | ||
585 | }; | ||
586 | |||
587 | struct microcode { | ||
588 | struct microcode_header hdr; | ||
589 | unsigned int bits[0]; | ||
590 | }; | ||
591 | |||
592 | typedef struct microcode microcode_t; | ||
593 | typedef struct microcode_header microcode_header_t; | ||
594 | |||
595 | /* microcode format is extended from prescott processors */ | ||
596 | struct extended_signature { | ||
597 | unsigned int sig; | ||
598 | unsigned int pf; | ||
599 | unsigned int cksum; | ||
600 | }; | ||
601 | |||
602 | struct extended_sigtable { | ||
603 | unsigned int count; | ||
604 | unsigned int cksum; | ||
605 | unsigned int reserved[3]; | ||
606 | struct extended_signature sigs[0]; | ||
607 | }; | ||
608 | |||
609 | typedef struct { | 589 | typedef struct { |
610 | unsigned long seg; | 590 | unsigned long seg; |
611 | } mm_segment_t; | 591 | } mm_segment_t; |