mirror of https://github.com/0Nera/BMOSP.git
Вынос инициализации FPU из кода ядра в
This commit is contained in:
parent
f4d7b3e4e9
commit
5236f156e6
|
@ -94,12 +94,6 @@ void cpu_idle( ) {
|
|||
void cpu_init( ) {
|
||||
uint32_t eax, ebx, ecx, edx;
|
||||
cpuid(1, &eax, &ebx, &ecx, &edx);
|
||||
|
||||
if ((edx >> 0) & 1) {
|
||||
asm volatile("finit");
|
||||
LOG("FPU(x87) поддерживается!\n");
|
||||
}
|
||||
|
||||
if ((edx >> 22) & 1) {
|
||||
acpi_msrs_support = true;
|
||||
LOG("Встроенный терморегулятор MSRS для ACPI\n");
|
||||
|
|
|
@ -12,6 +12,11 @@ module_info_t __attribute__((section(".minit"))) init(env_t *env) {
|
|||
uint32_t eax, ebx, ecx, edx;
|
||||
cpuid(1, &eax, &ebx, &ecx, &edx);
|
||||
|
||||
if ((edx >> 0) & 1) {
|
||||
asm volatile("finit");
|
||||
fb_printf("FPU(x87) поддерживается!\n");
|
||||
}
|
||||
|
||||
if ((edx >> 23) & 1) { fb_printf("MMX поддерживается!\n"); }
|
||||
|
||||
if ((edx >> 25) & 1) {
|
||||
|
|
Loading…
Reference in New Issue