mirror of
https://github.com/RGBCube/serenity
synced 2025-06-30 10:22:13 +00:00
Kernel: Add convenience values to the Memory::Region::Access enum
Instead of `Memory::Region::Access::Read | Memory::Region::AccessWrite` you can now say `Memory::Region::Access::ReadWrite`.
This commit is contained in:
parent
47bdd7c3a0
commit
2cd8b21974
38 changed files with 68 additions and 65 deletions
|
@ -39,7 +39,7 @@ UNMAP_AFTER_INIT void Thread::initialize()
|
|||
|
||||
KResultOr<NonnullRefPtr<Thread>> Thread::try_create(NonnullRefPtr<Process> process)
|
||||
{
|
||||
auto kernel_stack_region = MM.allocate_kernel_region(default_kernel_stack_size, {}, Memory::Region::Access::Read | Memory::Region::Access::Write, AllocationStrategy::AllocateNow);
|
||||
auto kernel_stack_region = MM.allocate_kernel_region(default_kernel_stack_size, {}, Memory::Region::Access::ReadWrite, AllocationStrategy::AllocateNow);
|
||||
if (!kernel_stack_region)
|
||||
return ENOMEM;
|
||||
kernel_stack_region->set_stack(true);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue