mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 14:18:12 +00:00
Kernel: Add mapping from page directory base (PDB) to PageDirectory
This allows the page fault code to find the owning PageDirectory and corresponding process for faulting regions. The mapping is implemented as a global hash map right now, which is definitely not optimal. We can come up with something better when it becomes necessary.
This commit is contained in:
parent
8d07bce12a
commit
2ad963d261
5 changed files with 60 additions and 16 deletions
|
@ -108,6 +108,8 @@ private:
|
|||
static Region* user_region_from_vaddr(Process&, VirtualAddress);
|
||||
static Region* kernel_region_from_vaddr(VirtualAddress);
|
||||
|
||||
static Region* region_from_vaddr(VirtualAddress);
|
||||
|
||||
bool copy_on_write(Region&, unsigned page_index_in_region);
|
||||
bool page_in_from_inode(Region&, unsigned page_index_in_region);
|
||||
bool zero_page(Region& region, unsigned page_index_in_region);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue