diff options
author | Andreas Kling <kling@serenityos.org> | 2022-04-03 17:12:39 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2022-04-03 21:51:58 +0200 |
commit | 07f3d09c55226bd3f2e1ad7139521268a347d136 (patch) | |
tree | 26e9e4b3f4bea1fd317004e83f9063bd8d315141 /Kernel/Memory/Region.h | |
parent | e852a69a069de6176cd6ff3534d5a606d383f396 (diff) | |
download | serenity-07f3d09c55226bd3f2e1ad7139521268a347d136.zip |
Kernel: Make VM allocation atomic for userspace regions
This patch move AddressSpace (the per-process memory manager) to using
the new atomic "place" APIs in RegionTree as well, just like we did for
MemoryManager in the previous commit.
This required updating quite a few places where VM allocation and
actually committing a Region object to the AddressSpace were separated
by other code.
All you have to do now is call into AddressSpace once and it'll take
care of everything for you.
Diffstat (limited to 'Kernel/Memory/Region.h')
-rw-r--r-- | Kernel/Memory/Region.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Kernel/Memory/Region.h b/Kernel/Memory/Region.h index b3aff78d6e..1e2eb64766 100644 --- a/Kernel/Memory/Region.h +++ b/Kernel/Memory/Region.h @@ -57,7 +57,7 @@ public: static ErrorOr<NonnullOwnPtr<Region>> try_create_user_accessible(VirtualRange const&, NonnullRefPtr<VMObject>, size_t offset_in_vmobject, OwnPtr<KString> name, Region::Access access, Cacheable, bool shared); static ErrorOr<NonnullOwnPtr<Region>> try_create_kernel_only(VirtualRange const&, NonnullRefPtr<VMObject>, size_t offset_in_vmobject, OwnPtr<KString> name, Region::Access access, Cacheable = Cacheable::Yes); static ErrorOr<NonnullOwnPtr<Region>> create_unbacked(); - static ErrorOr<NonnullOwnPtr<Region>> create_unplaced(NonnullRefPtr<VMObject>, size_t offset_in_vmobject, OwnPtr<KString> name, Region::Access access, Cacheable = Cacheable::Yes); + static ErrorOr<NonnullOwnPtr<Region>> create_unplaced(NonnullRefPtr<VMObject>, size_t offset_in_vmobject, OwnPtr<KString> name, Region::Access access, Cacheable = Cacheable::Yes, bool shared = false); ~Region(); |