VM_MAP_INHERIT(9)
π VM_MAP_INHERIT(9) π
okay so bestie, welcome to VM_MAP_INHERIT(9) β yep, the Kernel Developer's Manual page, and it's literally about setting fork inheritance flags for a range inside a map. Very main-character kernel energy. π«Ά
β¨ NAME β¨
vm_map_inherit β set fork inheritance flags for a range within a map. no cap, that's the whole vibe. π
πΈ SYNOPSIS πΈ
#include <sys/param.h>
#include <vm/vm.h>
#include <vm/vm_map.h>
int
vm_map_inherit(vm_map_t map, vm_offset_t start, vm_offset_t end,
vm_inherit_t new_inheritance);
π¦ DESCRIPTION π¦
so the vm_map_inherit() function sets the inheritance flags for the range from start to end within the target map to the value new_inheritance. that's it, that's the assignment. π
the new_inheritance flag has to be one of these three icons π:
VM_INHERIT_NONEVM_INHERIT_COPYVM_INHERIT_SHARE
and this is what affects how the map will be shared with child maps when the associated process forks. yes, fork(2) behavior, we're in it. π₯
π IMPLEMENTATION NOTES π
the vm_map_inherit() function obtains a lock on the map using vm_map_lock(9) for the duration of the function. she locks in, literally. πβ¨
π RETURN VALUES π
vm_map_inherit() returns KERN_SUCCESS if the inheritance flags could be set. slay. β
otherwise, if the provided flags were invalid, KERN_INVALID_ARGUMENT will be returned. not slay, but important. π
π§ SEE ALSO π§
iykyk, go read that one too. π
π AUTHORS π
this manual page was written by Bruce M Simpson <bms@spc.org>. iconic behavior, honestly. π
and that's the whole page, bestie. source/version: Debian. date: July 19, 2003. mwah, kisses from the manual footer ππ
π¦ where this page comes from
- freebsd 14.5: base 14.5
- freebsd 15.1: base 15.1
- nixpkgs unstable: source
- Copyright (c) 2003 Bruce M Simpson <bms@spc.org>
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms