| 79 | #endif |
| 80 | |
| 81 | static void InitHardwareRand() |
| 82 | { |
| 83 | uint32_t eax, ebx, ecx, edx; |
| 84 | GetCPUID(1, 0, eax, ebx, ecx, edx); |
| 85 | if (ecx & CPUID_F1_ECX_RDRAND) { |
| 86 | g_rdrand_supported = true; |
| 87 | } |
| 88 | GetCPUID(7, 0, eax, ebx, ecx, edx); |
| 89 | if (ebx & CPUID_F7_EBX_RDSEED) { |
| 90 | g_rdseed_supported = true; |
| 91 | } |
| 92 | } |
| 93 | |
| 94 | static void ReportHardwareRand() |
| 95 | { |