summaryrefslogtreecommitdiff
path: root/Kernel/Memory/PageDirectory.h
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2021-09-05 15:13:20 +0200
committerAndreas Kling <kling@serenityos.org>2021-09-05 15:13:20 +0200
commit83fed5b2de58e7ad9dc2da1f15dd5cf0e052cadd (patch)
tree1c6d3d99d74f40387e78b9dc2e7a8318a6a58877 /Kernel/Memory/PageDirectory.h
parent0cf65cf7ec5513dc972f51e2bdc95ca7f983064b (diff)
downloadserenity-83fed5b2de58e7ad9dc2da1f15dd5cf0e052cadd.zip
Kernel: Tidy up Memory::AddressSpace construction
- Return KResultOr<T> in places - Propagate errors - Use TRY()
Diffstat (limited to 'Kernel/Memory/PageDirectory.h')
-rw-r--r--Kernel/Memory/PageDirectory.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/Kernel/Memory/PageDirectory.h b/Kernel/Memory/PageDirectory.h
index 6d6e8e9036..348f43857b 100644
--- a/Kernel/Memory/PageDirectory.h
+++ b/Kernel/Memory/PageDirectory.h
@@ -19,7 +19,7 @@ class PageDirectory : public RefCounted<PageDirectory> {
friend class MemoryManager;
public:
- static RefPtr<PageDirectory> try_create_for_userspace(VirtualRangeAllocator const* parent_range_allocator = nullptr);
+ static KResultOr<NonnullRefPtr<PageDirectory>> try_create_for_userspace(VirtualRangeAllocator const* parent_range_allocator = nullptr);
static NonnullRefPtr<PageDirectory> must_create_kernel_page_directory();
static RefPtr<PageDirectory> find_by_cr3(FlatPtr);