diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/boot/amd64-desktop.make | 4 | ||||
| -rw-r--r-- | src/boot/src/HEL/AMD64/BootEFI.cpp | 2 | ||||
| -rw-r--r-- | src/boot/src/HEL/ARM64/BootEFI.cpp | 2 | ||||
| -rw-r--r-- | src/kernel/FirmwareKit/Handover.h | 5 | ||||
| -rw-r--r-- | src/kernel/HALKit/AMD64/HalKernelMain.cpp | 8 |
5 files changed, 14 insertions, 7 deletions
diff --git a/src/boot/amd64-desktop.make b/src/boot/amd64-desktop.make index 0854db60..9379dc60 100644 --- a/src/boot/amd64-desktop.make +++ b/src/boot/amd64-desktop.make @@ -49,12 +49,12 @@ DEBUG_MACRO = -D__DEBUG__ endif ifeq ($(KVM_SUPPORT),) -EMU_FLAGS=-M q35 -smp 4 -m 8G \ +EMU_FLAGS=-M q35 -smp 8 -m 8G \ -bios $(BIOS) -cdrom $(BOOT) -boot d endif ifneq ($(KVM_SUPPORT),) -EMU_FLAGS=-M q35 -smp 4 -m 8G \ +EMU_FLAGS=-M q35 -smp 8 -m 8G \ -bios $(BIOS) -M q35 -cdrom $(BOOT) -boot d -accel kvm endif diff --git a/src/boot/src/HEL/AMD64/BootEFI.cpp b/src/boot/src/HEL/AMD64/BootEFI.cpp index 4d004e54..51cdf8e9 100644 --- a/src/boot/src/HEL/AMD64/BootEFI.cpp +++ b/src/boot/src/HEL/AMD64/BootEFI.cpp @@ -120,8 +120,10 @@ EFI_EXTERN_C EFI_API Int32 BootloaderMain(EfiHandlePtr image_handle, EfiSystemTa if (mp) { mp->GetNumberOfProcessors(mp, &cnt_disabled, &cnt_enabled); + kHandoverHeader->f_NumberOfProcessors = cnt_enabled;; handover_hdr->f_HardwareTables.f_MultiProcessingEnabled = cnt_enabled > 1; } else { + handover_hdr->f_NumberOfProcessors = 1; handover_hdr->f_HardwareTables.f_MultiProcessingEnabled = NO; } diff --git a/src/boot/src/HEL/ARM64/BootEFI.cpp b/src/boot/src/HEL/ARM64/BootEFI.cpp index 936f5dfb..a92b9a62 100644 --- a/src/boot/src/HEL/ARM64/BootEFI.cpp +++ b/src/boot/src/HEL/ARM64/BootEFI.cpp @@ -94,8 +94,10 @@ EFI_EXTERN_C EFI_API Int32 BootloaderMain(EfiHandlePtr image_handle, EfiSystemTa if (mp) { mp->GetNumberOfProcessors(mp, &cnt_disabled, &cnt_enabled); + kHandoverHeader->f_NumberOfProcessors = cnt_enabled; kHandoverHeader->f_HardwareTables.f_MultiProcessingEnabled = cnt_enabled > 1; } else { + kHandoverHeader->f_NumberOfProcessors = 1; kHandoverHeader->f_HardwareTables.f_MultiProcessingEnabled = NO; } diff --git a/src/kernel/FirmwareKit/Handover.h b/src/kernel/FirmwareKit/Handover.h index 8515cfa6..f3382f75 100644 --- a/src/kernel/FirmwareKit/Handover.h +++ b/src/kernel/FirmwareKit/Handover.h @@ -10,7 +10,7 @@ #include <NeKit/Config.h> #define kHandoverMagic (0xBADCC) -#define kHandoverVersion (0x0117) +#define kHandoverVersion (0x0118) /* Initial bitmap pointer location and size. */ #define kHandoverStructSz sizeof(HEL::BootInfoHeader) @@ -79,7 +79,8 @@ struct BootInfoHeader final { UInt32 f_PixelPerLine; } f_GOP; - UInt64 f_FirmwareSpecific[8]; + UInt64 f_NumberOfProcessors; + UInt64 f_FirmwareSpecific[7]; }; enum { diff --git a/src/kernel/HALKit/AMD64/HalKernelMain.cpp b/src/kernel/HALKit/AMD64/HalKernelMain.cpp index 4c527572..97102865 100644 --- a/src/kernel/HALKit/AMD64/HalKernelMain.cpp +++ b/src/kernel/HALKit/AMD64/HalKernelMain.cpp @@ -157,9 +157,11 @@ EXTERN_C Kernel::Void hal_real_init(Kernel::Void) { NeFileSystemMgr::Mount(new NeFileSystemMgr()); #endif - cg_init(); - FBDrawBitMapInRegion(kBootLogo, BOOT_LOGO_WIDTH, BOOT_LOGO_HEIGHT, 10, 10); - cg_clear(); + for (SizeT idxCore{0}; idxCore < kHandoverHeader->f_NumberOfProcessors; ++idxCore) { + cg_init(); + FBDrawBitMapInRegion(kBootLogo, BOOT_LOGO_WIDTH, BOOT_LOGO_HEIGHT, 10, 12 + BOOT_LOGO_WIDTH * idxCore); + cg_clear(); + } UserProcessScheduler::The().SwitchTeam(kRTUserTeam); |
