mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-28 12:18:25 +00:00
Revert "Kernel/x86: Bake the Prekernel and the Kernel into one image"
Some hardware/software configurations crash KVM as soon as we try to
start Serenity. The exact cause is currently unknown, so just fully
revert it for now.
This reverts commit 897c4e5145.
This commit is contained in:
committed by
Jelle Raaijmakers
parent
a8d08357c9
commit
9ab598af49
@@ -38,6 +38,9 @@ extern u8 end_of_unmap_after_init[];
|
||||
extern u8 start_of_kernel_ksyms[];
|
||||
extern u8 end_of_kernel_ksyms[];
|
||||
|
||||
extern multiboot_module_entry_t multiboot_copy_boot_modules_array[16];
|
||||
extern size_t multiboot_copy_boot_modules_count;
|
||||
|
||||
namespace Kernel::Memory {
|
||||
|
||||
ErrorOr<FlatPtr> page_round_up(FlatPtr x)
|
||||
@@ -268,6 +271,15 @@ UNMAP_AFTER_INIT void MemoryManager::parse_memory_map()
|
||||
#endif
|
||||
global_data.used_memory_ranges.append(UsedMemoryRange { UsedMemoryRangeType::Kernel, PhysicalAddress(virtual_to_low_physical((FlatPtr)start_of_kernel_image)), PhysicalAddress(page_round_up(virtual_to_low_physical((FlatPtr)end_of_kernel_image)).release_value_but_fixme_should_propagate_errors()) });
|
||||
|
||||
if (multiboot_flags & 0x4) {
|
||||
auto* bootmods_start = multiboot_copy_boot_modules_array;
|
||||
auto* bootmods_end = bootmods_start + multiboot_copy_boot_modules_count;
|
||||
|
||||
for (auto* bootmod = bootmods_start; bootmod < bootmods_end; bootmod++) {
|
||||
global_data.used_memory_ranges.append(UsedMemoryRange { UsedMemoryRangeType::BootModule, PhysicalAddress(bootmod->start), PhysicalAddress(bootmod->end) });
|
||||
}
|
||||
}
|
||||
|
||||
auto* mmap_begin = multiboot_memory_map;
|
||||
auto* mmap_end = multiboot_memory_map + multiboot_memory_map_count;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user