mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 05:27:43 +00:00
Kernel: Make sure the kernel info page is read-only for userspace
To enforce this, we create two separate mappings of the same underlying physical page. A writable mapping for the kernel, and a read-only one for userspace (the one returned by sys$get_kernel_info_page.)
This commit is contained in:
parent
77cf607cda
commit
0a75a46501
3 changed files with 26 additions and 7 deletions
|
@ -63,6 +63,7 @@ public:
|
|||
void map_for_kernel(VirtualAddress, PhysicalAddress, bool cache_disabled = false);
|
||||
|
||||
OwnPtr<Region> allocate_kernel_region(size_t, const StringView& name, bool user_accessible = false, bool should_commit = true);
|
||||
OwnPtr<Region> allocate_kernel_region_with_vmobject(VMObject&, size_t, const StringView& name);
|
||||
OwnPtr<Region> allocate_user_accessible_kernel_region(size_t, const StringView& name);
|
||||
|
||||
unsigned user_physical_pages() const { return m_user_physical_pages; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue