mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-09 17:49:40 +00:00
Kernel: Add mechanism to identity map the lowest 2MB
This commit is contained in:
parent
19190267a6
commit
841364b609
Notes:
sideshowbarker
2024-07-19 05:50:08 +09:00
Author: https://github.com/tomuta
Commit: 841364b609
Pull-request: https://github.com/SerenityOS/serenity/pull/2475
Reviewed-by: https://github.com/awesomekling
Reviewed-by: https://github.com/bugaevc
7 changed files with 40 additions and 12 deletions
|
@ -107,6 +107,7 @@ public:
|
|||
OwnPtr<Region> allocate_contiguous_kernel_region(size_t, const StringView& name, u8 access, bool user_accessible = false, bool cacheable = true);
|
||||
OwnPtr<Region> allocate_kernel_region(size_t, const StringView& name, u8 access, bool user_accessible = false, bool should_commit = true, bool cacheable = true);
|
||||
OwnPtr<Region> allocate_kernel_region(PhysicalAddress, size_t, const StringView& name, u8 access, bool user_accessible = false, bool cacheable = true);
|
||||
OwnPtr<Region> allocate_kernel_region_identity(PhysicalAddress, size_t, const StringView& name, u8 access, bool user_accessible = false, bool cacheable = true);
|
||||
OwnPtr<Region> allocate_kernel_region_with_vmobject(VMObject&, size_t, const StringView& name, u8 access, bool user_accessible = false, bool cacheable = true);
|
||||
OwnPtr<Region> allocate_kernel_region_with_vmobject(const Range&, VMObject&, const StringView& name, u8 access, bool user_accessible = false, bool cacheable = true);
|
||||
OwnPtr<Region> allocate_user_accessible_kernel_region(size_t, const StringView& name, u8 access, bool cacheable = true);
|
||||
|
@ -143,6 +144,8 @@ public:
|
|||
|
||||
PhysicalPage& shared_zero_page() { return *m_shared_zero_page; }
|
||||
|
||||
PageDirectory& kernel_page_directory() { return *m_kernel_page_directory; }
|
||||
|
||||
private:
|
||||
MemoryManager();
|
||||
~MemoryManager();
|
||||
|
@ -177,8 +180,6 @@ private:
|
|||
PageDirectoryEntry* quickmap_pd(PageDirectory&, size_t pdpt_index);
|
||||
PageTableEntry* quickmap_pt(PhysicalAddress);
|
||||
|
||||
PageDirectory& kernel_page_directory() { return *m_kernel_page_directory; }
|
||||
|
||||
const PageTableEntry* pte(const PageDirectory&, VirtualAddress);
|
||||
PageTableEntry& ensure_pte(PageDirectory&, VirtualAddress);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue