mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 19:57:35 +00:00
Kernel: Remove unused syscall sys$minherit()
This is no longer used. We can bring it back the day we need it.
This commit is contained in:
parent
de31e82f97
commit
43109f9614
8 changed files with 0 additions and 60 deletions
|
@ -306,32 +306,6 @@ int Process::sys$madvise(void* address, size_t size, int advice)
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
int Process::sys$minherit(void* address, size_t size, int inherit)
|
||||
{
|
||||
REQUIRE_PROMISE(stdio);
|
||||
|
||||
auto* region = find_region_from_range({ VirtualAddress(address), size });
|
||||
if (!region)
|
||||
return -EINVAL;
|
||||
|
||||
if (!region->is_mmap())
|
||||
return -EINVAL;
|
||||
|
||||
if (region->is_shared())
|
||||
return -EINVAL;
|
||||
|
||||
if (!region->vmobject().is_anonymous())
|
||||
return -EINVAL;
|
||||
|
||||
switch (inherit) {
|
||||
case MAP_INHERIT_ZERO:
|
||||
region->set_inherit_mode(Region::InheritMode::ZeroedOnFork);
|
||||
return 0;
|
||||
}
|
||||
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
int Process::sys$set_mmap_name(Userspace<const Syscall::SC_set_mmap_name_params*> user_params)
|
||||
{
|
||||
REQUIRE_PROMISE(stdio);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue