mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 14:28:12 +00:00
Fix dumb-but-hard-to-find bug in paging.
This was the fix: -process.m_page_directory[0] = m_kernel_page_directory[0]; -process.m_page_directory[1] = m_kernel_page_directory[1]; +process.m_page_directory->entries[0] = m_kernel_page_directory->entries[0]; +process.m_page_directory->entries[1] = m_kernel_page_directory->entries[1]; I spent a good two hours scratching my head, not being able to figure out why user process page directories felt they had ownership of page tables in the kernel page directory. It was because I was copying the entire damn kernel page directory into the process instead of only sharing the two first PDE's. Dang!
This commit is contained in:
parent
8accc92c3c
commit
b59ce22fc5
5 changed files with 113 additions and 38 deletions
|
@ -108,10 +108,13 @@ private:
|
|||
void flushEntireTLB();
|
||||
void flushTLB(LinearAddress);
|
||||
|
||||
void* allocate_page_table();
|
||||
PhysicalAddress allocate_page_table();
|
||||
void deallocate_page_table(PhysicalAddress);
|
||||
|
||||
void protectMap(LinearAddress, size_t length);
|
||||
void identityMap(LinearAddress, size_t length);
|
||||
|
||||
void create_identity_mapping(LinearAddress, size_t length);
|
||||
void remove_identity_mapping(LinearAddress, size_t);
|
||||
|
||||
Vector<PhysicalAddress> allocatePhysicalPages(size_t count);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue