2 * Routines to indentify additional cpu features that are scattered in
8 #include <asm/processor.h>
24 void __cpuinit init_scattered_cpuid_features(struct cpuinfo_x86 *c)
28 const struct cpuid_bit *cb;
30 static const struct cpuid_bit cpuid_bits[] = {
31 { X86_FEATURE_IDA, CR_EAX, 1, 0x00000006 },
35 for (cb = cpuid_bits; cb->feature; cb++) {
37 /* Verify that the level is valid */
38 max_level = cpuid_eax(cb->level & 0xffff0000);
39 if (max_level < cb->level ||
40 max_level > (cb->level | 0xffff))
43 cpuid(cb->level, ®s[CR_EAX], ®s[CR_EBX],
44 ®s[CR_ECX], ®s[CR_EDX]);
46 if (regs[cb->reg] & (1 << cb->bit))
47 set_cpu_cap(c, cb->feature);
52 void __cpuinit validate_pat_support(struct cpuinfo_x86 *c)
55 pat_disable("PAT not supported by CPU.");
57 switch (c->x86_vendor) {
58 case X86_VENDOR_INTEL:
59 if (c->x86 == 0xF || (c->x86 == 6 && c->x86_model >= 15))
63 case X86_VENDOR_CENTAUR:
64 case X86_VENDOR_TRANSMETA:
68 pat_disable("PAT disabled. Not yet verified on this CPU type.");