mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 19:17:44 +00:00
Kernel: Never forcibly page in entire executables
We were doing this for the initial kernel-spawned userspace process(es) to work around instability in the page fault handler. Now that the page fault handler is more robust, we can stop worrying about this. Specifically, the page fault handler was previous not able to handle getting a page fault in anything but the currently executing task's page directory.
This commit is contained in:
parent
e29fd3cd20
commit
f5d779f47e
3 changed files with 0 additions and 27 deletions
|
@ -46,26 +46,6 @@ Region::~Region()
|
|||
MM.unregister_region(*this);
|
||||
}
|
||||
|
||||
bool Region::page_in()
|
||||
{
|
||||
ASSERT(m_page_directory);
|
||||
ASSERT(vmo().is_inode());
|
||||
#ifdef MM_DEBUG
|
||||
dbgprintf("MM: page_in %u pages\n", page_count());
|
||||
#endif
|
||||
for (size_t i = 0; i < page_count(); ++i) {
|
||||
auto& vmo_page = vmo().physical_pages()[first_page_index() + i];
|
||||
if (vmo_page.is_null()) {
|
||||
bool success = MM.page_in_from_inode(*this, i);
|
||||
if (!success)
|
||||
return false;
|
||||
continue;
|
||||
}
|
||||
MM.remap_region_page(*this, i);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
NonnullRefPtr<Region> Region::clone()
|
||||
{
|
||||
ASSERT(current);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue