Home
last modified time | relevance | path

Searched refs:pid (Results 751 - 775 of 5070) sorted by relevance

1...<<31323334353637383940>>...203

/kernel/linux/linux-5.10/tools/testing/selftests/pidfd/
H A Dpidfd_getfd_test.c123 /* pid points to the child which we are fetching FDs from */ in FIXTURE()
124 pid_t pid; in FIXTURE() local
143 self->pid = fork(); in FIXTURE_SETUP()
144 ASSERT_GE(self->pid, 0); in FIXTURE_SETUP()
146 if (self->pid == 0) { in FIXTURE_SETUP()
155 self->pidfd = sys_pidfd_open(self->pid, 0); in FIXTURE_SETUP()
171 EXPECT_EQ(0, wait_for_pid(self->pid)); in FIXTURE_TEARDOWN()
207 ret = sys_kcmp(getpid(), self->pid, KCMP_FILE, fd, self->remote_fd); in TEST_F()
/kernel/linux/linux-5.10/tools/testing/selftests/bpf/prog_tests/
H A Dsend_signal.c23 pid_t pid; in test_send_signal_common() local
36 pid = fork(); in test_send_signal_common()
37 if (CHECK(pid < 0, test_name, "fork error: %s\n", strerror(errno))) { in test_send_signal_common()
45 if (pid == 0) { in test_send_signal_common()
100 pmu_fd = syscall(__NR_perf_event_open, attr, pid, -1, in test_send_signal_common()
119 skel->bss->pid = pid; in test_send_signal_common()
178 pmu_fd = syscall(__NR_perf_event_open, &attr, 0 /* pid */, in test_send_signal_nmi()
H A Dtest_bpffs.c82 pid_t pid; in test_test_bpffs() local
84 pid = fork(); in test_test_bpffs()
85 if (CHECK(pid == -1, "clone", "clone failed %d", errno)) in test_test_bpffs()
87 if (pid == 0) in test_test_bpffs()
89 err = waitpid(pid, &status, 0); in test_test_bpffs()
/kernel/linux/linux-6.6/arch/um/os-Linux/skas/
H A Dmem.c23 extern void wait_stub_done(int pid);
56 int err, pid = mm_idp->u.pid; in do_syscall_stub() local
58 n = ptrace_setregs(pid, syscall_regs); in do_syscall_stub()
67 err = ptrace(PTRACE_CONT, pid, 0, 0); in do_syscall_stub()
69 panic("Failed to continue stub, pid = %d, errno = %d\n", pid, in do_syscall_stub()
72 wait_stub_done(pid); in do_syscall_stub()
/kernel/linux/linux-6.6/tools/testing/selftests/bpf/progs/
H A Dtask_kfunc_success.c12 int err, pid; variable
35 return pid == cur_pid; in is_test_kfunc_task()
235 acquired = bpf_task_from_pid(p->pid); in lookup_compare_pid()
241 if (acquired->pid != p->pid) in lookup_compare_pid()
266 static int is_pid_lookup_valid(s32 pid) in is_pid_lookup_valid() argument
270 acquired = bpf_task_from_pid(pid); in is_pid_lookup_valid()
/kernel/linux/linux-6.6/tools/testing/selftests/net/
H A Dipv6_flowlabel_mgr.c77 pid_t pid; in run_tests() local
131 pid = fork(); in run_tests()
132 if (pid == -1) in run_tests()
134 if (!pid) { in run_tests()
152 pid = fork(); in run_tests()
153 if (pid == -1) in run_tests()
155 if (!pid) { in run_tests()
/kernel/linux/linux-6.6/tools/testing/selftests/pidfd/
H A Dpidfd_getfd_test.c123 /* pid points to the child which we are fetching FDs from */ in FIXTURE()
124 pid_t pid; in FIXTURE() local
143 self->pid = fork(); in FIXTURE_SETUP()
144 ASSERT_GE(self->pid, 0); in FIXTURE_SETUP()
146 if (self->pid == 0) { in FIXTURE_SETUP()
155 self->pidfd = sys_pidfd_open(self->pid, 0); in FIXTURE_SETUP()
171 EXPECT_EQ(0, wait_for_pid(self->pid)); in FIXTURE_TEARDOWN()
207 ret = sys_kcmp(getpid(), self->pid, KCMP_FILE, fd, self->remote_fd); in TEST_F()
/third_party/node/test/internet/
H A Dtest-dgram-broadcast-multi-process.js82 workers[worker.pid] = worker;
97 worker.pid,
128 worker.pid,
137 Object.keys(workers).forEach((pid) => {
138 const worker = workers[pid];
152 worker.pid,
230 process.pid,
H A Dtest-dgram-multicast-multi-process.js47 workers[worker.pid] = worker;
61 worker.pid,
89 worker.pid,
97 Object.keys(workers).forEach(function(pid) {
98 const worker = workers[pid];
112 worker.pid, count);
207 console.error('[CHILD] %s received "%s" from %j', process.pid,
H A Dtest-dgram-multicast-ssmv6-multi-process.js41 workers[worker.pid] = worker;
55 worker.pid,
83 worker.pid,
91 Object.keys(workers).forEach(function(pid) {
92 const worker = workers[pid];
106 worker.pid, count);
202 console.error('[CHILD] %s received "%s" from %j', process.pid,
H A Dtest-dgram-multicast-ssm-multi-process.js41 workers[worker.pid] = worker;
55 worker.pid,
83 worker.pid,
91 Object.keys(workers).forEach(function(pid) {
92 const worker = workers[pid];
106 worker.pid, count);
202 console.error('[CHILD] %s received "%s" from %j', process.pid,
/third_party/ltp/testcases/kernel/io/ltp-aiodio/
H A Daiodio_sparse.c191 int i, pid; in run() local
202 pid = SAFE_FORK(); in run()
203 if (!pid) { in run()
208 tst_res(TINFO, "Child %i creates a sparse file", pid); in run()
211 if (SAFE_WAITPID(pid, NULL, WNOHANG)) in run()
218 kill(pid, SIGKILL); in run()
219 SAFE_WAITPID(pid, NULL, 0); in run()
H A Daiodio_append.c144 int i, pid; in run() local
155 pid = SAFE_FORK(); in run()
156 if (!pid) { in run()
161 tst_res(TINFO, "Child %i appends to a file", pid); in run()
164 if (SAFE_WAITPID(pid, NULL, WNOHANG)) in run()
171 kill(pid, SIGKILL); in run()
172 SAFE_WAITPID(pid, NULL, 0); in run()
/third_party/ltp/testcases/kernel/syscalls/futex/
H A Dfutex_cmp_requeue01.c59 int pid = getpid(); in do_child() local
68 pid); in do_child()
89 int pid[tc->num_waiters]; in verify_futex_cmp_requeue() local
95 pid[i] = SAFE_FORK(); in verify_futex_cmp_requeue()
96 if (!pid[i]) in verify_futex_cmp_requeue()
101 TST_PROCESS_STATE_WAIT(pid[i], 'S', 0); in verify_futex_cmp_requeue()
134 SAFE_WAITPID(pid[i], &status, 0); in verify_futex_cmp_requeue()
/third_party/ltp/testcases/kernel/syscalls/ipc/shmctl/
H A Dshmctl01.c68 pid_t pid = SAFE_FORK(); in fork_children() local
70 if (!pid) in fork_children()
73 children[i] = pid; in fork_children()
169 pid_t pid = getpid(); in check_ds() local
178 if (ds->shm_cpid != pid) { in check_ds()
180 desc, ds->shm_cpid, pid); in check_ds()
182 tst_res(TPASS, "%s: shm_cpid=%i", desc, pid); in check_ds()
/third_party/rust/crates/rustix/src/backend/libc/process/
H A Dsyscalls.rs134 let pid = c::getpid();
135 debug_assert_ne!(pid, 0);
136 Pid::from_raw_nonzero(RawNonZeroPid::new_unchecked(pid))
145 let pid: i32 = c::getppid();
146 Pid::from_raw(pid)
152 pub(crate) fn getpgid(pid: Option<Pid>) -> io::Result<Pid> {
154 let pgid = ret_pid_t(c::getpgid(Pid::as_raw(pid) as _))?;
178 pub(crate) fn sched_getaffinity(pid: Option<Pid>, cpuset: &mut RawCpuSet) -> io::Result<()> {
181 Pid::as_raw(pid) as _,
195 pub(crate) fn sched_setaffinity(pid
[all...]
/kernel/linux/linux-5.10/tools/testing/selftests/powerpc/pmu/ebb/
H A Dcpu_event_pinned_vs_ebb_test.c44 pid_t pid; in cpu_event_pinned_vs_ebb() local
55 pid = fork(); in cpu_event_pinned_vs_ebb()
56 if (pid == 0) { in cpu_event_pinned_vs_ebb()
64 kill_child_and_wait(pid); in cpu_event_pinned_vs_ebb()
78 FAIL_IF(wait_for_child(pid) != 2); in cpu_event_pinned_vs_ebb()
/kernel/linux/linux-5.10/tools/testing/selftests/powerpc/mm/
H A Dstack_expansion_signal.c75 pid_t pid; in test_one_size() local
80 pid = fork(); in test_one_size()
81 if (pid == 0) { in test_one_size()
91 kill(pid, SIGUSR1); in test_one_size()
93 FAIL_IF(wait_for_child(pid)); in test_one_size()
/kernel/linux/linux-5.10/tools/testing/selftests/nsfs/
H A Dpidns.c43 char *ns_strs[] = {"pid", "user"}; in main()
44 char path[] = "/proc/0123456789/ns/pid"; in main()
48 pid_t pid; in main() local
50 pid = clone(child, ca.stack_ptr, CLONE_NEWUSER | CLONE_NEWPID | SIGCHLD, NULL); in main()
51 if (pid < 0) in main()
55 snprintf(path, sizeof(path), "/proc/%d/ns/%s", pid, ns_strs[i]); in main()
76 kill(pid, SIGKILL); in main()
/kernel/linux/linux-5.10/tools/testing/selftests/cgroup/
H A Dcgroup_util.h38 extern int cg_enter(const char *cgroup, int pid);
48 extern int set_oom_adj_score(int pid, int score);
51 extern ssize_t proc_read_text(int pid, bool thread, const char *item, char *buf, size_t size);
52 extern int proc_read_strstr(int pid, bool thread, const char *item, const char *needle);
54 extern int clone_reap(pid_t pid, int options);
/kernel/linux/linux-5.10/tools/perf/scripts/python/
H A Dfailed-syscalls-by-pid.py1 # failed system call counts, by pid
5 # Displays system-wide failed system call totals, broken down by pid.
20 usage = "perf script -s syscall-counts-by-pid.py [comm|pid]\n";
66 print("%-30s %10s" % ("comm [pid]", "count"))
72 for pid in pid_keys:
73 print("\n%s [%d]" % (comm, pid))
74 id_keys = syscalls[comm][pid].keys()
77 ret_keys = syscalls[comm][pid][id].keys()
78 for ret, val in sorted(syscalls[comm][pid][i
[all...]
/kernel/linux/linux-6.6/tools/perf/scripts/python/
H A Dfailed-syscalls-by-pid.py1 # failed system call counts, by pid
5 # Displays system-wide failed system call totals, broken down by pid.
20 usage = "perf script -s syscall-counts-by-pid.py [comm|pid]\n";
66 print("%-30s %10s" % ("comm [pid]", "count"))
72 for pid in pid_keys:
73 print("\n%s [%d]" % (comm, pid))
74 id_keys = syscalls[comm][pid].keys()
77 ret_keys = syscalls[comm][pid][id].keys()
78 for ret, val in sorted(syscalls[comm][pid][i
[all...]
/kernel/linux/linux-6.6/tools/testing/selftests/nsfs/
H A Dpidns.c43 char *ns_strs[] = {"pid", "user"}; in main()
44 char path[] = "/proc/0123456789/ns/pid"; in main()
48 pid_t pid; in main() local
50 pid = clone(child, ca.stack_ptr, CLONE_NEWUSER | CLONE_NEWPID | SIGCHLD, NULL); in main()
51 if (pid < 0) in main()
55 snprintf(path, sizeof(path), "/proc/%d/ns/%s", pid, ns_strs[i]); in main()
76 kill(pid, SIGKILL); in main()
/kernel/linux/linux-6.6/tools/testing/selftests/cgroup/
H A Dcgroup_util.h44 extern int cg_enter(const char *cgroup, int pid);
54 extern int set_oom_adj_score(int pid, int score);
58 extern ssize_t proc_read_text(int pid, bool thread, const char *item, char *buf, size_t size);
59 extern int proc_read_strstr(int pid, bool thread, const char *item, const char *needle);
61 extern int clone_reap(pid_t pid, int options);
/kernel/linux/linux-6.6/tools/testing/selftests/powerpc/mm/
H A Dstack_expansion_signal.c75 pid_t pid; in test_one_size() local
80 pid = fork(); in test_one_size()
81 if (pid == 0) { in test_one_size()
91 kill(pid, SIGUSR1); in test_one_size()
93 FAIL_IF(wait_for_child(pid)); in test_one_size()

Completed in 11 milliseconds

1...<<31323334353637383940>>...203