| 56 | } |
| 57 | |
| 58 | static int isCPUGenuineIntel(void) |
| 59 | { |
| 60 | regs_t regs; |
| 61 | unsigned int level = 0; |
| 62 | unsigned int eax = 0; |
| 63 | |
| 64 | __get_cpuid(level, &eax, ®s.ebx, ®s.ecx, ®s.edx); |
| 65 | |
| 66 | return !strncmp((char *)®s, "GenuineIntel", CPU_ID_SIZE-1); |
| 67 | } |
| 68 | |
| 69 | /* You need >4GB total ram, in kernel cmdline, use 'mem=1000m' |
| 70 | * then this code will clone to absolute memory address 0xe0000000 |