mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-09 02:56:10 +00:00
Kernel: Propagate overflow errors from Memory::page_round_up
Fixes #11402.
This commit is contained in:
parent
11599a3342
commit
33b78915d3
Notes:
sideshowbarker
2024-07-17 22:09:47 +09:00
Author: https://github.com/eggpi 🔰
Commit: 33b78915d3
Pull-request: https://github.com/SerenityOS/serenity/pull/11433
Issue: https://github.com/SerenityOS/serenity/issues/11402
Reviewed-by: https://github.com/awesomekling
31 changed files with 112 additions and 100 deletions
|
@ -334,7 +334,7 @@ UNMAP_AFTER_INIT void APIC::setup_ap_boot_environment()
|
|||
// * aps_to_enable u32 values for ap_cpu_init_processor_info_array
|
||||
constexpr u64 apic_startup_region_base = 0x8000;
|
||||
VERIFY(apic_startup_region_base + apic_ap_start_size < USER_RANGE_BASE);
|
||||
auto apic_startup_region = create_identity_mapped_region(PhysicalAddress(apic_startup_region_base), Memory::page_round_up(apic_ap_start_size + (2 * aps_to_enable * sizeof(u32))));
|
||||
auto apic_startup_region = create_identity_mapped_region(PhysicalAddress(apic_startup_region_base), Memory::page_round_up(apic_ap_start_size + (2 * aps_to_enable * sizeof(u32))).release_value_but_fixme_should_propagate_errors());
|
||||
memcpy(apic_startup_region->vaddr().as_ptr(), reinterpret_cast<const void*>(apic_ap_start), apic_ap_start_size);
|
||||
|
||||
// Allocate enough stacks for all APs
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue