3 * Routines to indentify additional cpu features that are scattered in
9 #include <asm/processor.h>
25 void __cpuinit
init_scattered_cpuid_features(struct cpuinfo_x86
*c
)
29 const struct cpuid_bit
*cb
;
31 static const struct cpuid_bit cpuid_bits
[] = {
32 { X86_FEATURE_IDA
, CR_EAX
, 1, 0x00000006 },
36 for (cb
= cpuid_bits
; cb
->feature
; cb
++) {
38 /* Verify that the level is valid */
39 max_level
= cpuid_eax(cb
->level
& 0xffff0000);
40 if (max_level
< cb
->level
||
41 max_level
> (cb
->level
| 0xffff))
44 cpuid(cb
->level
, ®s
[CR_EAX
], ®s
[CR_EBX
],
45 ®s
[CR_ECX
], ®s
[CR_EDX
]);
47 if (regs
[cb
->reg
] & (1 << cb
->bit
))
48 set_cpu_cap(c
, cb
->feature
);