mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-05-28 14:02:51 +00:00
Kernel: Use PAE to allow accessing all physical memory beyond 4GB
We already use PAE for the NX bit, but this changes the PhysicalAddress structure to be able to hold 64 bit physical addresses. This allows us to use all the available physical memory.
This commit is contained in:
parent
658b41a06c
commit
ad5d9d648b
Notes:
sideshowbarker
2024-07-18 10:05:10 +09:00
Author: https://github.com/tomuta
Commit: ad5d9d648b
Pull-request: https://github.com/SerenityOS/serenity/pull/8520
Reviewed-by: https://github.com/Hendiadyoin1
7 changed files with 87 additions and 86 deletions
|
@ -64,12 +64,12 @@ MemoryStatsWidget::~MemoryStatsWidget()
|
|||
{
|
||||
}
|
||||
|
||||
static inline size_t page_count_to_kb(size_t kb)
|
||||
static inline u64 page_count_to_kb(u64 kb)
|
||||
{
|
||||
return (kb * 4096) / 1024;
|
||||
}
|
||||
|
||||
static inline size_t bytes_to_kb(size_t bytes)
|
||||
static inline u64 bytes_to_kb(u64 bytes)
|
||||
{
|
||||
return bytes / 1024;
|
||||
}
|
||||
|
@ -88,12 +88,12 @@ void MemoryStatsWidget::refresh()
|
|||
[[maybe_unused]] unsigned kmalloc_eternal_allocated = json.get("kmalloc_eternal_allocated").to_u32();
|
||||
unsigned kmalloc_allocated = json.get("kmalloc_allocated").to_u32();
|
||||
unsigned kmalloc_available = json.get("kmalloc_available").to_u32();
|
||||
unsigned user_physical_allocated = json.get("user_physical_allocated").to_u32();
|
||||
unsigned user_physical_available = json.get("user_physical_available").to_u32();
|
||||
unsigned user_physical_committed = json.get("user_physical_committed").to_u32();
|
||||
unsigned user_physical_uncommitted = json.get("user_physical_uncommitted").to_u32();
|
||||
unsigned super_physical_alloc = json.get("super_physical_allocated").to_u32();
|
||||
unsigned super_physical_free = json.get("super_physical_available").to_u32();
|
||||
unsigned user_physical_allocated = json.get("user_physical_allocated").to_u64();
|
||||
unsigned user_physical_available = json.get("user_physical_available").to_u64();
|
||||
unsigned user_physical_committed = json.get("user_physical_committed").to_u64();
|
||||
unsigned user_physical_uncommitted = json.get("user_physical_uncommitted").to_u64();
|
||||
unsigned super_physical_alloc = json.get("super_physical_allocated").to_u64();
|
||||
unsigned super_physical_free = json.get("super_physical_available").to_u64();
|
||||
unsigned kmalloc_call_count = json.get("kmalloc_call_count").to_u32();
|
||||
unsigned kfree_call_count = json.get("kfree_call_count").to_u32();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue