diff options
author | Andreas Kling <kling@serenityos.org> | 2021-02-14 01:25:22 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-02-14 01:34:23 +0100 |
commit | 8415866c0371eae16e3c1221720efaa6c3cec3e2 (patch) | |
tree | 069ac36c07e125f946a1369eb34746e427ba3eb0 /Kernel/FileSystem/ProcFS.cpp | |
parent | 1593219a41bdb9d8efa62abf5fca462b38563878 (diff) | |
download | serenity-8415866c0371eae16e3c1221720efaa6c3cec3e2.zip |
Kernel: Remove user/kernel flags from Region
Now that we no longer need to support the signal trampolines being
user-accessible inside the kernel memory range, we can get rid of the
"kernel" and "user-accessible" flags on Region and simply use the
address of the region to determine whether it's kernel or user.
This also tightens the page table mapping code, since it can now set
user-accessibility based solely on the virtual address of a page.
Diffstat (limited to 'Kernel/FileSystem/ProcFS.cpp')
-rw-r--r-- | Kernel/FileSystem/ProcFS.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/Kernel/FileSystem/ProcFS.cpp b/Kernel/FileSystem/ProcFS.cpp index 4a32d89983..ec07b6a4fa 100644 --- a/Kernel/FileSystem/ProcFS.cpp +++ b/Kernel/FileSystem/ProcFS.cpp @@ -319,7 +319,7 @@ static bool procfs$pid_vm(InodeIdentifier identifier, KBufferBuilder& builder) { ScopedSpinLock lock(process->space().get_lock()); for (auto& region : process->space().regions()) { - if (!region.is_user_accessible() && !Process::current()->is_superuser()) + if (!region.is_user() && !Process::current()->is_superuser()) continue; auto region_object = array.add_object(); region_object.add("readable", region.is_readable()); @@ -328,13 +328,11 @@ static bool procfs$pid_vm(InodeIdentifier identifier, KBufferBuilder& builder) region_object.add("stack", region.is_stack()); region_object.add("shared", region.is_shared()); region_object.add("syscall", region.is_syscall_region()); - region_object.add("user_accessible", region.is_user_accessible()); region_object.add("purgeable", region.vmobject().is_anonymous()); if (region.vmobject().is_anonymous()) { region_object.add("volatile", static_cast<const AnonymousVMObject&>(region.vmobject()).is_any_volatile()); } region_object.add("cacheable", region.is_cacheable()); - region_object.add("kernel", region.is_kernel()); region_object.add("address", region.vaddr().get()); region_object.add("size", region.size()); region_object.add("amount_resident", region.amount_resident()); |