• Home
  • Raw
  • Download

Lines Matching +full:in +full:- +full:process

26             /// The calling process and the child process run in the same
29 /// The caller and the child process share the same filesystem
32 /// The calling process and the child process share the same file
35 /// The calling process and the child process share the same table
38 /// If the calling process is being traced, then trace the child
41 /// The execution of the calling process is suspended until the
46 /// will be the same as that of the calling process.
48 /// The child is placed in the same thread group as the calling
49 /// process.
51 /// The cloned child is started in a new mount namespace.
53 /// The child and the calling process share a single list of System
56 // Not supported by Nix due to lack of varargs support in Rust FFI
58 // Not supported by Nix due to lack of varargs support in Rust FFI
60 // Not supported by Nix due to lack of varargs support in Rust FFI
65 /// A tracing process cannot force `CLONE_PTRACE` on this child
66 /// process.
68 // Not supported by Nix due to lack of varargs support in Rust FFI
70 /// Create the process in a new cgroup namespace.
72 /// Create the process in a new UTS namespace.
74 /// Create the process in a new IPC namespace.
76 /// Create the process in a new user namespace.
78 /// Create the process in a new PID namespace.
80 /// Create the process in a new network namespace.
82 /// The new process shares an I/O context with the calling process.
88 pub type CloneCb<'a> = Box<dyn FnMut() -> isize + 'a>;
90 /// `clone` create a child process
91 /// ([`clone(2)`](https://man7.org/linux/man-pages/man2/clone.2.html))
94 /// process. Unlike when calling `clone(2)` from C, the provided stack
103 ) -> Result<Pid> { in clone()
104 extern "C" fn callback(data: *mut CloneCb) -> c_int { in clone()
116 as extern "C" fn(*mut Box<dyn FnMut() -> isize>) -> i32, in clone()
127 /// disassociate parts of the process execution context
129 /// See also [unshare(2)](https://man7.org/linux/man-pages/man2/unshare.2.html)
130 pub fn unshare(flags: CloneFlags) -> Result<()> { in unshare()
138 /// See also [setns(2)](https://man7.org/linux/man-pages/man2/setns.2.html)
139 pub fn setns(fd: RawFd, nstype: CloneFlags) -> Result<()> { in setns()
166 /// CpuSet represent a bit-mask of CPUs.
182 pub fn new() -> CpuSet { in new()
188 /// Test to see if a CPU is in the CpuSet.
190 pub fn is_set(&self, field: usize) -> Result<bool> { in is_set()
200 pub fn set(&mut self, field: usize) -> Result<()> { in set()
213 pub fn unset(&mut self, field: usize) -> Result<()> { in unset()
224 /// Return the maximum number of CPU in CpuSet
225 pub const fn count() -> usize { in count()
236 fn default() -> Self { in default()
242 /// ([`sched_setaffinity(2)`](https://man7.org/linux/man-pages/man2/sched_setaffinity.2.html))
262 pub fn sched_setaffinity(pid: Pid, cpuset: &CpuSet) -> Result<()> { in sched_setaffinity()
275 /// ([`sched_getaffinity(2)`](https://man7.org/linux/man-pages/man2/sched_getaffinity.2.html))
296 pub fn sched_getaffinity(pid: Pid) -> Result<CpuSet> { in sched_getaffinity()
310 pub fn sched_getcpu() -> Result<usize> { in sched_getcpu()
320 pub fn sched_yield() -> Result<()> { in sched_yield()