- Initial checkin of the freebios2 tree
[coreboot.git] / src / include / cpu / p5 / cpuid.h
1 #ifndef CPU_P5_CPUID_H
2 #define CPU_P5_CPUID_H
3
4 int mtrr_check(void);
5 void display_cpuid(void);
6
7 /*
8  *      Generic CPUID function. copied from Linux kernel headers
9  */
10
11 static inline void cpuid(int op, int *eax, int *ebx, int *ecx, int *edx)
12 {
13         __asm__("pushl %%ebx\n\t"
14                 "cpuid\n\t"
15                 "movl   %%ebx, %%esi\n\t"
16                 "popl   %%ebx\n\t"
17                 : "=a" (*eax),
18                   "=S" (*ebx),
19                   "=c" (*ecx),
20                   "=d" (*edx)
21                 : "a" (op)
22                 : "cc");
23 }
24
25 #endif /* CPU_P5_CPUID_H */