mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-01 05:39:11 +00:00
Kernel: Move CPU feature detection to Arch/x86/CPU.{cpp.h}
We now refuse to boot on machines that don't support PAE since all of our paging code depends on it. Also let's only enable SSE and PGE support if the CPU advertises it.
This commit is contained in:
parent
3d59db4be4
commit
5aeaab601e
Notes:
sideshowbarker
2024-07-19 10:29:46 +09:00
Author: https://github.com/awesomekling
Commit: 5aeaab601e
6 changed files with 70 additions and 44 deletions
|
@ -223,7 +223,7 @@ void Region::remap_page(size_t index)
|
|||
pte.set_writable(false);
|
||||
else
|
||||
pte.set_writable(is_writable());
|
||||
if (MM.has_nx_support())
|
||||
if (g_cpu_supports_nx)
|
||||
pte.set_execute_disabled(!is_executable());
|
||||
pte.set_user_allowed(is_user_accessible());
|
||||
m_page_directory->flush(page_vaddr);
|
||||
|
@ -273,7 +273,7 @@ void Region::map(PageDirectory& page_directory)
|
|||
pte.set_writable(false);
|
||||
else
|
||||
pte.set_writable(is_writable());
|
||||
if (MM.has_nx_support())
|
||||
if (g_cpu_supports_nx)
|
||||
pte.set_execute_disabled(!is_executable());
|
||||
} else {
|
||||
pte.set_physical_page_base(0);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue