Home
last modified time | relevance | path

Searched refs:pid (Results 76 - 100 of 4853) sorted by relevance

12345678910>>...195

/kernel/liteos_a/testsuites/unittest/process/basic/process/smoke/
H A Dprocess_test_019.cpp56 pid_t pid, pid1, pid2; in ProcessTest() local
59 pid = fork(); in ProcessTest()
60 ICUNIT_GOTO_WITHIN_EQUAL(pid, 0, 100000, pid, EXIT); // 100000, assert pid equal to this. in ProcessTest()
61 if (pid == 0) { in ProcessTest()
69 g_waitPid = pid; in ProcessTest()
71 ICUNIT_GOTO_WITHIN_EQUAL(pid1, 0, 100000, pid, EXIT); // 100000, assert pid1 equal to this. in ProcessTest()
102 pid_t pid = fork(); in TestCase() local
103 ICUNIT_GOTO_WITHIN_EQUAL(pid, in TestCase()
[all...]
H A Dprocess_test_018.cpp56 pid_t pid, pid1, pid2; in ProcessTest() local
62 pid = fork(); in ProcessTest()
63 ICUNIT_GOTO_WITHIN_EQUAL(pid, 0, 100000, pid, EXIT); // 100000, assert pid equal to this. in ProcessTest()
64 g_waitPid = pid; in ProcessTest()
66 if (pid == 0) { in ProcessTest()
79 ICUNIT_GOTO_WITHIN_EQUAL(pid1, 0, 100000, pid, EXIT); // 100000, assert pid1 equal to this. in ProcessTest()
105 pid_t pid = fork(); in TestCase() local
106 ICUNIT_GOTO_WITHIN_EQUAL(pid, in TestCase()
[all...]
H A Dprocess_test_016.cpp56 pid_t pid; in ProcessTest() local
61 pid = fork(); in ProcessTest()
62 ICUNIT_GOTO_WITHIN_EQUAL(pid, 0, 100000, pid, EXIT); // 100000, assert pid equal to this. in ProcessTest()
65 if (pid == 0) { in ProcessTest()
78 ret = waitpid(pid, &status, 0); in ProcessTest()
79 ICUNIT_GOTO_EQUAL(ret, pid, ret, EXIT); in ProcessTest()
95 pid_t pid = fork(); in TestCase() local
96 ICUNIT_GOTO_WITHIN_EQUAL(pid, in TestCase()
[all...]
H A Dprocess_test_015.cpp56 pid_t pid; in ProcessTest() local
62 pid = fork(); in ProcessTest()
63 ICUNIT_GOTO_WITHIN_EQUAL(pid, 0, 100000, pid, EXIT); // 100000, assert pid equal to this. in ProcessTest()
66 if (pid == 0) { in ProcessTest()
76 ret = waitpid(pid, &status, 0); in ProcessTest()
77 ICUNIT_GOTO_EQUAL(ret, pid, ret, EXIT); in ProcessTest()
93 pid_t pid = fork(); in TestCase() local
94 ICUNIT_GOTO_WITHIN_EQUAL(pid, in TestCase()
[all...]
H A Dprocess_test_006.cpp37 pid_t pid = *((pid_t *)arg); in ThreadFunc2() local
40 ret = waitpid(pid, &status, 0); in ThreadFunc2()
42 ICUNIT_ASSERT_EQUAL_NULL(ret, pid, ret); in ThreadFunc2()
50 int pid, pid1; in ProcessTest001() local
63 pid = fork(); in ProcessTest001()
64 if (pid == 0) { in ProcessTest001()
69 ICUNIT_ASSERT_WITHIN_EQUAL(pid, 0, 100000, pid); // 100000, assert that function Result is equal to this. in ProcessTest001()
77 data = pid; in ProcessTest001()
96 int pid; in TestCase() local
[all...]
/kernel/linux/linux-6.6/kernel/bpf/
H A Dtask_iter.c22 u32 pid; member
39 struct pid *pid; in task_group_seq_get_next() local
44 pid = find_pid_ns(common->pid, common->ns); in task_group_seq_get_next()
45 if (!pid) in task_group_seq_get_next()
48 task = get_pid_task(pid, PIDTYPE_TGID); in task_group_seq_get_next()
52 *tid = common->pid; in task_group_seq_get_next()
53 common->pid_visiting = common->pid; in task_group_seq_get_next()
63 pid in task_group_seq_get_next()
114 struct pid *pid; task_seq_get_next() local
231 struct pid *pid; bpf_iter_attach_task() local
[all...]
/kernel/linux/linux-5.10/tools/testing/selftests/pidfd/
H A Dpidfd_wait.c34 static int sys_waitid(int which, pid_t pid, siginfo_t *info, int options, in sys_waitid() argument
37 return syscall(__NR_waitid, which, pid, info, options, ru); in sys_waitid()
50 pid_t pid; in TEST() local
58 pid = sys_waitid(P_PIDFD, pidfd, &info, WEXITED, NULL); in TEST()
59 ASSERT_NE(pid, 0); in TEST()
66 pid = sys_waitid(P_PIDFD, pidfd, &info, WEXITED, NULL); in TEST()
67 ASSERT_NE(pid, 0); in TEST()
71 pid = sys_clone3(&args); in TEST()
72 ASSERT_GE(pid, 0); in TEST()
74 if (pid in TEST()
99 pid_t pid; TEST() local
151 pid_t pid; TEST() local
[all...]
/kernel/linux/linux-6.6/tools/testing/selftests/proc/
H A Dproc-empty-vm.c21 * /proc/${pid}/maps
22 * /proc/${pid}/numa_maps
23 * /proc/${pid}/smaps
24 * /proc/${pid}/smaps_rollup
138 pid_t pid; in vsyscall() local
141 pid = fork(); in vsyscall()
142 if (pid < 0) { in vsyscall()
146 if (pid == 0) { in vsyscall()
171 waitpid(pid, &wstatus, 0); in vsyscall()
181 static int test_proc_pid_maps(pid_t pid) in test_proc_pid_maps() argument
203 test_proc_pid_numa_maps(pid_t pid) test_proc_pid_numa_maps() argument
226 test_proc_pid_smaps(pid_t pid) test_proc_pid_smaps() argument
282 test_proc_pid_smaps_rollup(pid_t pid) test_proc_pid_smaps_rollup() argument
331 pid_t pid = fork(); main() local
[all...]
/kernel/linux/linux-5.10/tools/testing/selftests/cgroup/
H A Dtest_freezer.c116 static int cg_enter_and_wait_for_frozen(const char *cgroup, int pid, in cg_enter_and_wait_for_frozen() argument
126 ret = cg_enter(cgroup, pid); in cg_enter_and_wait_for_frozen()
460 int pid; in test_cgfreezer_mkdir() local
479 pid = cg_run_nowait(child, child_fn, NULL); in test_cgfreezer_mkdir()
480 if (pid < 0) in test_cgfreezer_mkdir()
569 int pid; in test_cgfreezer_migrate() local
585 pid = cg_run_nowait(cgroup[0], child_fn, NULL); in test_cgfreezer_migrate()
586 if (pid < 0) in test_cgfreezer_migrate()
598 if (cg_enter_and_wait_for_frozen(cgroup[1], pid, true)) in test_cgfreezer_migrate()
607 if (cg_enter_and_wait_for_frozen(cgroup[0], pid, fals in test_cgfreezer_migrate()
645 int pid; test_cgfreezer_ptrace() local
700 proc_check_stopped(int pid) proc_check_stopped() argument
724 int pid, ret = KSFT_FAIL; test_cgfreezer_stopped() local
768 int pid, ret = KSFT_FAIL; test_cgfreezer_ptraced() local
822 int pid = vfork(); vfork_fn() local
[all...]
/kernel/linux/linux-6.6/tools/testing/selftests/cgroup/
H A Dtest_freezer.c59 static int cg_enter_and_wait_for_frozen(const char *cgroup, int pid, in cg_enter_and_wait_for_frozen() argument
69 ret = cg_enter(cgroup, pid); in cg_enter_and_wait_for_frozen()
403 int pid; in test_cgfreezer_mkdir() local
422 pid = cg_run_nowait(child, child_fn, NULL); in test_cgfreezer_mkdir()
423 if (pid < 0) in test_cgfreezer_mkdir()
512 int pid; in test_cgfreezer_migrate() local
528 pid = cg_run_nowait(cgroup[0], child_fn, NULL); in test_cgfreezer_migrate()
529 if (pid < 0) in test_cgfreezer_migrate()
541 if (cg_enter_and_wait_for_frozen(cgroup[1], pid, true)) in test_cgfreezer_migrate()
550 if (cg_enter_and_wait_for_frozen(cgroup[0], pid, fals in test_cgfreezer_migrate()
588 int pid; test_cgfreezer_ptrace() local
643 proc_check_stopped(int pid) proc_check_stopped() argument
667 int pid, ret = KSFT_FAIL; test_cgfreezer_stopped() local
711 int pid, ret = KSFT_FAIL; test_cgfreezer_ptraced() local
765 int pid = vfork(); vfork_fn() local
[all...]
/kernel/liteos_a/testsuites/unittest/process/basic/process/full/
H A Dprocess_test_042.cpp80 pid_t pid, pid1; in GroupProcess() local
99 pid = fork(); in GroupProcess()
100 ICUNIT_GOTO_WITHIN_EQUAL(pid, 0, 100000, pid, EXIT); // 100000, assert pid equal to this. in GroupProcess()
101 if (pid == 0) { in GroupProcess()
108 ICUNIT_GOTO_WITHIN_EQUAL(pid1, 0, 100000, pid1, EXIT); // 100000, assert pid equal to this. in GroupProcess()
128 ret = sched_setscheduler(pid, SCHED_RR, &param); in GroupProcess()
133 ret = waitpid(pid, &status, 0); in GroupProcess()
134 ICUNIT_ASSERT_EQUAL(ret, pid, re in GroupProcess()
152 pid_t pid, pid1; TestCase() local
[all...]
H A Dprocess_test_031.cpp57 pid_t pid, pid1; in TestCase() local
59 pid = fork(); in TestCase()
60 ICUNIT_GOTO_WITHIN_EQUAL(pid, 0, 100000, pid, EXIT); // 100000, assert pid equal to this. in TestCase()
62 if (pid == 0) { in TestCase()
69 ret = setpgid(pid, pid); in TestCase()
77 Child2(currGid, pid); in TestCase()
83 ret = setpgid(pid1, pid); in TestCase()
[all...]
H A Dprocess_test_033.cpp57 pid_t pid, pid1; in TestCase() local
59 pid = fork(); in TestCase()
60 ICUNIT_GOTO_WITHIN_EQUAL(pid, 0, 100000, pid, EXIT); // 100000, assert pid equal to this. in TestCase()
62 if (pid == 0) { in TestCase()
68 ret = setpgid(pid, pid); in TestCase()
71 ret = waitpid(pid, &status, 0); in TestCase()
72 ICUNIT_ASSERT_EQUAL(ret, pid, re in TestCase()
[all...]
H A Dprocess_test_041.cpp44 pid_t pid, pid1; in GroupProcess() local
66 pid = fork(); in GroupProcess()
67 if (pid == 0) { in GroupProcess()
73 } else if (pid < 0) { in GroupProcess()
84 testPid = pid; in GroupProcess()
108 pid_t pid, pid1; in TestCase() local
109 pid = fork(); in TestCase()
110 ICUNIT_GOTO_WITHIN_EQUAL(pid, 0, 100000, pid, EXIT); // 100000, assert pid equa in TestCase()
[all...]
/third_party/libunwind/libunwind/src/ptrace/
H A D_UPT_access_reg.c44 pid_t pid = ui->pid; in _UPT_access_reg() local
66 if (ptrace (PTRACE_GETREGSET, pid, NT_PRSTATUS, &loc) == -1) in _UPT_access_reg()
70 if (ptrace(PTRACE_SETREGSET, pid, NT_PRSTATUS, &loc) == -1) in _UPT_access_reg()
86 pid_t pid = ui->pid; in _UPT_access_reg() local
106 nat_bits = ptrace (PTRACE_PEEKUSER, pid, PT_NAT_BITS, 0); in _UPT_access_reg()
121 ptrace (PTRACE_POKEUSER, pid, PT_NAT_BITS, nat_bits); in _UPT_access_reg()
146 psr = ptrace (PTRACE_PEEKUSER, pid, PT_CR_IPSR, 0); in _UPT_access_reg()
158 ptrace (PTRACE_POKEUSER, pid, PT_CR_II in _UPT_access_reg()
330 pid_t pid = ui->pid; _UPT_access_reg() local
[all...]
/third_party/pulseaudio/src/pulsecore/
H A Dpid.c47 #include "pid.h"
50 * pid could be read, return 0, on failure (pid_t) -1 */
54 uint32_t pid; in read_pid() local
71 if (pa_atou(t, &pid) < 0) { in read_pid()
77 return (pid_t) pid; in read_pid()
136 static int proc_name_ours(pid_t pid, const char *procname) { in proc_name_ours() argument
141 pa_snprintf(bn, sizeof(bn), "/proc/%lu/stat", (unsigned long) pid); in proc_name_ours()
162 expected = pa_sprintf_malloc("%lu (%s)", (unsigned long) pid, procname); in proc_name_ours()
169 expected = pa_sprintf_malloc("%lu (lt-%s)", (unsigned long) pid, procname); in proc_name_ours()
189 pid_t pid; local
268 pid_t pid; global() local
324 pa_pid_file_check_running(pid_t *pid, const char *procname) global() argument
333 pa_pid_file_kill(int sig, pid_t *pid, const char *procname) global() argument
394 pa_pid_file_kill(int sig, pid_t *pid, const char *exe_name) global() argument
[all...]
/kernel/linux/linux-5.10/arch/um/os-Linux/
H A Dhelper.c41 /* Returns either the pid of the child process we run or -E* on failure. */
46 int pid, fds[2], ret, n; in run_helper() local
74 pid = clone(helper_child, (void *) sp, CLONE_VM, &data); in run_helper()
75 if (pid < 0) { in run_helper()
91 ret = pid; in run_helper()
99 CATCH_EINTR(waitpid(pid, NULL, __WALL)); in run_helper()
117 int pid, status, err; in run_helper_thread() local
124 pid = clone(proc, (void *) sp, flags, arg); in run_helper_thread()
125 if (pid < 0) { in run_helper_thread()
132 CATCH_EINTR(pid in run_helper_thread()
148 helper_wait(int pid) helper_wait() argument
[all...]
/kernel/linux/linux-6.6/arch/um/os-Linux/
H A Dhelper.c42 /* Returns either the pid of the child process we run or -E* on failure. */
47 int pid, fds[2], ret, n; in run_helper() local
75 pid = clone(helper_child, (void *) sp, CLONE_VM, &data); in run_helper()
76 if (pid < 0) { in run_helper()
92 ret = pid; in run_helper()
100 CATCH_EINTR(waitpid(pid, NULL, __WALL)); in run_helper()
122 int pid, status, err; in run_helper_thread() local
129 pid = clone(proc, (void *) sp, flags, arg); in run_helper_thread()
130 if (pid < 0) { in run_helper_thread()
137 CATCH_EINTR(pid in run_helper_thread()
153 helper_wait(int pid) helper_wait() argument
[all...]
/third_party/musl/libc-test/src/functionalext/supplement/linux/
H A Dwait3.c34 pid_t pid = fork(); in wait3_0100() local
35 if (pid > 0) { in wait3_0100()
40 if (wait3_for_pind != pid) { in wait3_0100()
41 t_error("%s wait3 get pid is %d are not want %d\n", __func__, wait3_for_pind, pid); in wait3_0100()
46 } else if (pid == 0) { in wait3_0100()
61 pid_t pid = fork(); in wait3_0200() local
62 if (pid > 0) { in wait3_0200()
67 if (wait3_for_pind != pid) { in wait3_0200()
68 t_error("%s wait3 get pid i in wait3_0200()
[all...]
/third_party/musl/libc-test/src/functionalext/supplement/process/
H A Dwait.c32 pid_t pid = fork(); in wait_0100() local
33 if (pid > 0) { in wait_0100()
36 if (wait_for_pind != pid) { in wait_0100()
37 t_error("%s wait get pid is %d are not want %d\n", __func__, wait_for_pind, pid); in wait_0100()
42 } else if (pid == 0) { in wait_0100()
57 pid_t pid = fork(); in wait_0200() local
58 if (pid > 0) { in wait_0200()
61 if (wait_for_pind != pid) { in wait_0200()
62 t_error("%s wait get pid i in wait_0200()
[all...]
/kernel/linux/linux-5.10/tools/testing/selftests/ptrace/
H A Dvmaccess.c6 * Check whether /proc/$pid/mem can be accessed without causing deadlocks
26 int f, pid = fork(); in TEST() local
29 if (!pid) { in TEST()
38 sprintf(mm, "/proc/%d/mem", pid); in TEST()
42 f = kill(pid, SIGCONT); in TEST()
48 int s, k, pid = fork(); in TEST() local
50 if (!pid) { in TEST()
59 k = ptrace(PTRACE_ATTACH, pid, 0L, 0L); in TEST()
65 ASSERT_NE(k, pid); in TEST()
69 k = ptrace(PTRACE_ATTACH, pid, in TEST()
[all...]
/kernel/linux/linux-6.6/tools/testing/selftests/ptrace/
H A Dvmaccess.c6 * Check whether /proc/$pid/mem can be accessed without causing deadlocks
26 int f, pid = fork(); in TEST() local
29 if (!pid) { in TEST()
38 sprintf(mm, "/proc/%d/mem", pid); in TEST()
42 f = kill(pid, SIGCONT); in TEST()
48 int s, k, pid = fork(); in TEST() local
50 if (!pid) { in TEST()
59 k = ptrace(PTRACE_ATTACH, pid, 0L, 0L); in TEST()
65 ASSERT_NE(k, pid); in TEST()
69 k = ptrace(PTRACE_ATTACH, pid, in TEST()
[all...]
/kernel/liteos_a/kernel/extended/cpup/
H A Dcpup_shellcmd.c56 VOID OsCmdCpupOperateTwoParam(UINT32 mode, UINT32 pid) in OsCmdCpupOperateTwoParam() argument
61 PRINTK("\npid %u CpuUsage in 10s: ", pid); in OsCmdCpupOperateTwoParam()
63 PRINTK("\npid %u CpuUsage in 1s: ", pid); in OsCmdCpupOperateTwoParam()
65 PRINTK("\npid %u CpuUsage in all time: ", pid); in OsCmdCpupOperateTwoParam()
67 ret = LOS_HistoryProcessCpuUsage(pid, mode); in OsCmdCpupOperateTwoParam()
85 size_t mode, pid; in OsShellCmdCpup() local
117 pid = strtoul(argv[1], &bufID, 0); in OsShellCmdCpup()
118 if (OsProcessIDUserCheckInvalid(pid) || (*bufID != 0)) { in OsShellCmdCpup()
119 PRINTK("\nUnknown pid: %s\n", argv[1]); in OsShellCmdCpup()
123 if (OsProcessIsUnused(OS_PCB_FROM_PID(pid)) || OsProcessIsDea in OsShellCmdCpup()
[all...]
/kernel/liteos_a/testsuites/unittest/basic/mem/vm/smoke/
H A Dmmap_test_009.cpp44 pid_t pid = fork(); in Testcase() local
45 ICUNIT_ASSERT_WITHIN_EQUAL(pid, 0, INVALID_PROCESS_ID, pid); in Testcase()
46 if (pid == 0) { in Testcase()
53 ret = waitpid(pid, &status, 0); in Testcase()
54 ICUNIT_ASSERT_EQUAL(ret, pid, ret); in Testcase()
62 pid = fork(); in Testcase()
63 ICUNIT_ASSERT_WITHIN_EQUAL(pid, 0, INVALID_PROCESS_ID, pid); in Testcase()
64 if (pid in Testcase()
[all...]
/third_party/ltp/testcases/kernel/controllers/cgroup_fj/
H A Dcgroup_fj_stress.sh74 pid=$!
75 collected_pids="$collected_pids $pid"
77 pid="$ppid"
81 if ! attach_and_check "$pid" "$cur_path"; then
93 if ! attach_and_check "$pid" "$cur_path"; then
140 pid=$!
143 attach_task "$start_path" 0 "$pid"
144 ROD kill -9 "$pid"
145 wait "$pid"
150 for pid i
[all...]

Completed in 12 milliseconds

12345678910>>...195