summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLiav A <liavalb@gmail.com>2021-09-18 14:44:27 +0300
committerIdan Horowitz <idan.horowitz@gmail.com>2021-09-18 17:49:24 +0300
commit86fa5d71c06134b5d0a23ec2d9a8eb495bd771f9 (patch)
tree8ffcd08d5090b9362d5cf329ec8b8fb6f6483879
parenta27716846f14766a4a0f2b1495164021fd793ee3 (diff)
downloadserenity-86fa5d71c06134b5d0a23ec2d9a8eb495bd771f9.zip
Kernel/Memory: Add more super pages to satisfy contiguous allocations
When testing the RTL8168 driver, it seems we can't allocate super pages anymore. Either we expand the super pages range, or find a solution to dynamically expand the range (or let drivers utilize other ranges).
-rw-r--r--Kernel/Memory/MemoryManager.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/Kernel/Memory/MemoryManager.cpp b/Kernel/Memory/MemoryManager.cpp
index dcbb9be71e..dcf90d571b 100644
--- a/Kernel/Memory/MemoryManager.cpp
+++ b/Kernel/Memory/MemoryManager.cpp
@@ -38,7 +38,9 @@ extern multiboot_module_entry_t multiboot_copy_boot_modules_array[16];
extern size_t multiboot_copy_boot_modules_count;
// Treat the super pages as logically separate from .bss
-__attribute__((section(".super_pages"))) static u8 super_pages[1 * MiB];
+// FIXME: Find a solution so we don't need to expand this range each time
+// we are in a situation too many drivers try to allocate super pages.
+__attribute__((section(".super_pages"))) static u8 super_pages[4 * MiB];
namespace Kernel::Memory {