| /kernel/ |
| A D | pid.c | 94 void put_pid(struct pid *pid) in put_pid() argument 112 struct pid *pid = container_of(rhp, struct pid, rcu); in delayed_put_pid() local 116 void free_pid(struct pid *pid) in free_pid() argument 165 struct pid *pid; in alloc_pid() local 341 struct pid *pid; in attach_pid() local 377 struct pid *pid) in change_pid() argument 457 struct pid *pid; in get_task_pid() local 479 struct pid *pid; in find_get_pid() local 544 struct pid *pid; in pidfd_get_pid() local 572 struct pid *pid; in pidfd_get_task() local [all …]
|
| A D | capability.c | 105 static inline int cap_get_target_pid(pid_t pid, kernel_cap_t *pEp, in cap_get_target_pid() argument 110 if (pid && (pid != task_pid_vnr(current))) { in cap_get_target_pid() 115 target = find_task_by_vpid(pid); in cap_get_target_pid() 140 pid_t pid; in SYSCALL_DEFINE2() local 149 if (get_user(pid, &header->pid)) in SYSCALL_DEFINE2() 152 if (pid < 0) in SYSCALL_DEFINE2() 155 ret = cap_get_target_pid(pid, &pE, &pI, &pP); in SYSCALL_DEFINE2() 223 pid_t pid; in SYSCALL_DEFINE2() local 229 if (get_user(pid, &header->pid)) in SYSCALL_DEFINE2() 233 if (pid != 0 && pid != task_pid_vnr(current)) in SYSCALL_DEFINE2()
|
| A D | exit.c | 137 struct pid *pid = task_pid(p); in __unhash_process() local 1276 infop->pid = pid; in wait_task_zombie() 1280 return pid; in wait_task_zombie() 1319 pid_t pid; in wait_task_stopped() local 1373 infop->pid = pid; in wait_task_stopped() 1376 return pid; in wait_task_stopped() 1388 pid_t pid; in wait_task_continued() local 1421 infop->pid = pid; in wait_task_continued() 1425 return pid; in wait_task_continued() 1724 struct pid *pid = NULL; in kernel_waitid_prepare() local [all …]
|
| A D | taskstats.c | 50 pid_t pid; member 131 rc = genlmsg_unicast(&init_net, skb_cur, s->pid); in send_cpu_listeners() 205 tsk = find_get_task_by_vpid(pid); in fill_stats_for_pid() 319 s->pid = pid; in add_del_listener() 325 if (s2->pid == pid && s2->valid) in add_del_listener() 343 if (s->pid == pid) { in add_del_listener() 389 if (nla_put(skb, type, sizeof(pid), &pid) < 0) { in mk_reply() 498 u32 pid; in cmd_attr_pid() local 508 pid = nla_get_u32(info->attrs[TASKSTATS_CMD_ATTR_PID]); in cmd_attr_pid() 509 stats = mk_reply(rep_skb, TASKSTATS_TYPE_PID, pid); in cmd_attr_pid() [all …]
|
| A D | hung_task.c | 141 task->comm, task->pid); in debug_show_blocker() 145 task->comm, task->pid); in debug_show_blocker() 150 task->comm, task->pid); in debug_show_blocker() 164 task->comm, task->pid, t->comm, t->pid); in debug_show_blocker() 168 task->comm, task->pid, t->comm, t->pid); in debug_show_blocker() 173 task->comm, task->pid, rwsem_blocked_as, t->comm, in debug_show_blocker() 174 t->pid, rwsem_blocked_by); in debug_show_blocker() 236 t->comm, t->pid, (jiffies - t->last_switch_time) / HZ); in check_hung_task()
|
| A D | signal.c | 1450 struct pid *pid, enum pid_type type) in kill_pid_info_type() argument 1522 struct pid *pid, const struct cred *cred) in kill_pid_usb_asyncio() argument 1576 if (pid > 0) in kill_something_info() 1586 pid ? find_vpid(-pid) : task_pgrp(current)); in kill_something_info() 1883 int kill_pgrp(struct pid *pid, int sig, int priv) in kill_pgrp() argument 1889 int kill_pid(struct pid *pid, int sig, int priv) in kill_pid() argument 2153 struct pid *pid = task_pid(task); in do_notify_pidfd() local 3963 static bool access_pidfd_pidns(struct pid *pid) in access_pidfd_pidns() argument 3997 struct pid *pid; in pidfd_to_pid() local 4001 return pid; in pidfd_to_pid() [all …]
|
| A D | umh.c | 128 pid_t pid; in call_usermodehelper_exec_sync() local 132 pid = user_mode_thread(call_usermodehelper_exec_async, sub_info, SIGCHLD); in call_usermodehelper_exec_sync() 133 if (pid < 0) in call_usermodehelper_exec_sync() 134 sub_info->retval = pid; in call_usermodehelper_exec_sync() 136 kernel_wait(pid, &sub_info->retval); in call_usermodehelper_exec_sync() 165 pid_t pid; in call_usermodehelper_exec_work() local 171 pid = user_mode_thread(call_usermodehelper_exec_async, sub_info, in call_usermodehelper_exec_work() 173 if (pid < 0) { in call_usermodehelper_exec_work() 174 sub_info->retval = pid; in call_usermodehelper_exec_work()
|
| A D | sys.c | 265 struct pid *pgrp; in SYSCALL_DEFINE3() 335 struct pid *pgrp; in SYSCALL_DEFINE2() 1018 int pid; in SYSCALL_DEFINE0() local 1024 return pid; in SYSCALL_DEFINE0() 1122 if (!pid) in SYSCALL_DEFINE2() 1125 pgid = pid; in SYSCALL_DEFINE2() 1190 struct pid *grp; in do_getpgid() 1194 if (!pid) in do_getpgid() 1236 if (!pid) in SYSCALL_DEFINE1() 1257 static void set_special_pids(struct pid **pids, struct pid *pid) in set_special_pids() argument [all …]
|
| A D | fork.c | 1759 init_task_pid(struct task_struct *task, enum pid_type type, struct pid *pid) in init_task_pid() argument 1816 int pidfd_prepare(struct pid *pid, unsigned int flags, struct file **ret_file) in pidfd_prepare() argument 1919 struct pid *pid, in copy_process() argument 2193 if (IS_ERR(pid)) { in copy_process() 2244 p->pid = pid_nr(pid); in copy_process() 2250 p->tgid = p->pid; in copy_process() 2368 if (likely(p->pid)) { in copy_process() 2443 free_pid(pid); in copy_process() 2568 struct pid *pid; in kernel_clone() local 2618 nr = pid_vnr(pid); in kernel_clone() [all …]
|
| A D | audit.c | 104 struct pid *pid; member 267 pid_t pid; in auditd_pid_vnr() local 272 if (!ac || !ac->pid) in auditd_pid_vnr() 273 pid = 0; in auditd_pid_vnr() 275 pid = pid_vnr(ac->pid); in auditd_pid_vnr() 278 return pid; in auditd_pid_vnr() 480 put_pid(ac->pid); in auditd_conn_free() 497 static int auditd_set(struct pid *pid, u32 portid, struct net *net, in auditd_set() argument 504 if (!pid || !net) in auditd_set() 510 ac_new->pid = get_pid(pid); in auditd_set() [all …]
|
| A D | compat.c | 124 COMPAT_SYSCALL_DEFINE3(sched_setaffinity, compat_pid_t, pid, in COMPAT_SYSCALL_DEFINE3() argument 138 retval = sched_setaffinity(pid, new_mask); in COMPAT_SYSCALL_DEFINE3() 144 COMPAT_SYSCALL_DEFINE3(sched_getaffinity, compat_pid_t, pid, unsigned int, len, in COMPAT_SYSCALL_DEFINE3() argument 158 ret = sched_getaffinity(pid, mask); in COMPAT_SYSCALL_DEFINE3()
|
| A D | pid_namespace.c | 52 len = struct_size_t(struct pid, numbers, level + 1); in create_pid_cachep() 197 struct pid *pid; in zap_pid_ns_processes() local 227 idr_for_each_entry_continue(&pid_ns->idr, pid, nr) { in zap_pid_ns_processes() 228 task = pid_task(pid, PIDTYPE_PID); in zap_pid_ns_processes()
|
| /kernel/bpf/ |
| A D | bpf_task_storage.c | 93 struct pid *pid; in bpf_pid_task_storage_lookup_elem() local 98 if (IS_ERR(pid)) in bpf_pid_task_storage_lookup_elem() 114 put_pid(pid); in bpf_pid_task_storage_lookup_elem() 117 put_pid(pid); in bpf_pid_task_storage_lookup_elem() 127 struct pid *pid; in bpf_pid_task_storage_update_elem() local 135 if (IS_ERR(pid)) in bpf_pid_task_storage_update_elem() 136 return PTR_ERR(pid); in bpf_pid_task_storage_update_elem() 156 put_pid(pid); in bpf_pid_task_storage_update_elem() 181 struct pid *pid; in bpf_pid_task_storage_delete_elem() local 186 if (IS_ERR(pid)) in bpf_pid_task_storage_delete_elem() [all …]
|
| A D | task_iter.c | 23 u32 pid; member 40 struct pid *pid; in task_group_seq_get_next() local 45 pid = find_pid_ns(common->pid, common->ns); in task_group_seq_get_next() 93 struct pid *pid; in task_seq_get_next() local 99 pid = find_pid_ns(common->pid, common->ns); in task_seq_get_next() 100 if (pid) { in task_seq_get_next() 120 if (pid) { in task_seq_get_next() 210 struct pid *pid; in bpf_iter_attach_task() local 223 aux->task.pid = linfo->task.pid; in bpf_iter_attach_task() 387 common->pid = aux->task.pid; in init_seq_pidns() [all …]
|
| /kernel/trace/ |
| A D | trace_sched_switch.c | 248 if (!tsk->pid) in trace_save_cmdline() 287 if (!pid) { in __trace_find_cmdline() 292 if (WARN_ON_ONCE(pid < 0)) { in __trace_find_cmdline() 301 if (tpid == pid) { in __trace_find_cmdline() 332 return &map[pid]; in trace_find_tgid_ptr() 335 int trace_find_tgid(int pid) in trace_find_tgid() argument 347 if (!tsk->pid) in trace_save_tgid() 463 int pid = ++(*pos); in saved_tgids_next() local 470 int pid = *pos; in saved_tgids_start() local 482 int pid = entry - tgid_map; in saved_tgids_show() local [all …]
|
| A D | pid_list.c | 89 static inline int pid_split(unsigned int pid, unsigned int *upper1, in pid_split() argument 96 if (unlikely(pid >= MAX_PID)) in pid_split() 99 *upper1 = (pid >> UPPER1_SHIFT) & UPPER_MASK; in pid_split() 100 *upper2 = (pid >> UPPER2_SHIFT) & UPPER_MASK; in pid_split() 101 *lower = pid & LOWER_MASK; in pid_split() 138 if (pid_split(pid, &upper1, &upper2, &lower) < 0) in trace_pid_list_is_set() 164 int trace_pid_list_set(struct trace_pid_list *pid_list, unsigned int pid) in trace_pid_list_set() argument 177 if (pid_split(pid, &upper1, &upper2, &lower) < 0) in trace_pid_list_set() 229 if (pid_split(pid, &upper1, &upper2, &lower) < 0) in trace_pid_list_clear() 282 if (pid_split(pid, &upper1, &upper2, &lower) < 0) in trace_pid_list_next() [all …]
|
| A D | blktrace.c | 102 t->pid = pid; in trace_note() 186 pid_t pid) in act_log_check() argument 192 if (bt->pid && pid != bt->pid) in act_log_check() 226 pid_t pid; in __blk_add_trace() local 248 pid = tsk->pid; in __blk_add_trace() 291 t->pid = pid; in __blk_add_trace() 589 bt->pid = buts->pid; in do_blk_trace_setup() 645 .pid = cbuts.pid, in compat_blk_trace_setup() 1307 trace_find_cmdline(ent->pid, cmd); in blk_log_generic() 1632 static BLK_TRACE_DEVICE_ATTR(pid); [all …]
|
| A D | trace_functions_graph.c | 521 trace_find_cmdline(pid, comm); in print_graph_proc() 523 sprintf(pid_str, "%d", pid); in print_graph_proc() 562 if (*last_pid == pid) in verif_pid() 566 *last_pid = pid; in verif_pid() 582 print_graph_proc(s, pid); in verif_pid() 649 if (curr->ent.pid != next->ent.pid || in get_return_for_leaf() 711 print_graph_proc(s, pid); in print_graph_irq() 965 cpu, iter->ent->pid, flags); in print_graph_entry_leaf() 1244 pid_t pid = ent->pid; in print_graph_return() local 1312 cpu, pid, flags); in print_graph_return() [all …]
|
| /kernel/sched/ |
| A D | syscalls.c | 266 return pid ? find_task_by_vpid(pid) : current; in find_process_by_pid() 274 p = find_process_by_pid(pid); in find_get_task() 282 find_get_task(pid), pid_t pid) in DEFINE_CLASS() argument 879 CLASS(find_get_task, p)(pid); in do_sched_setscheduler() 995 CLASS(find_get_task, p)(pid); in SYSCALL_DEFINE3() 1017 if (pid < 0) in SYSCALL_DEFINE1() 1021 p = find_process_by_pid(pid); in SYSCALL_DEFINE1() 1052 p = find_process_by_pid(pid); in SYSCALL_DEFINE2() 1214 CLASS(find_get_task, p)(pid); in sched_setaffinity() 1295 p = find_process_by_pid(pid); in sched_getaffinity() [all …]
|
| A D | core_sched.c | 131 int sched_core_share_pid(unsigned int cmd, pid_t pid, enum pid_type type, in sched_core_share_pid() argument 136 struct pid *grp; in sched_core_share_pid() 146 if (type > PIDTYPE_PGID || cmd >= PR_SCHED_CORE_MAX || pid < 0 || in sched_core_share_pid() 151 if (pid == 0) { in sched_core_share_pid() 154 task = find_task_by_vpid(pid); in sched_core_share_pid()
|
| /kernel/trace/rv/ |
| A D | rv_trace.h | 141 __field(pid_t, pid) 149 __entry->pid = task->pid; 155 TP_printk("%s[%d]: (%s) x (%s) -> (%s)", __get_str(comm), __entry->pid, 167 __field(pid_t, pid) 172 __entry->pid = task->pid; 175 TP_printk("%s[%d]: violation detected", __get_str(comm), __entry->pid)
|
| /kernel/debug/kdb/ |
| A D | kdb_bt.c | 86 kdb_printf("Stack traceback for pid %d\n", p->pid); in kdb_bt1() 162 unsigned long pid; in kdb_bt() local 165 diag = kdbgetularg((char *)argv[1], &pid); in kdb_bt() 168 p = find_task_by_pid_ns(pid, &init_pid_ns); in kdb_bt() 171 kdb_printf("No process with pid == %ld found\n", pid); in kdb_bt()
|
| /kernel/time/ |
| A D | posix-cpu-timers.c | 61 struct pid *pid; in pid_for_clock() local 73 pid = find_vpid(upid); in pid_for_clock() 74 if (!pid) in pid_for_clock() 78 struct task_struct *tsk = pid_task(pid, PIDTYPE_PID); in pid_for_clock() 88 if (gettime && (pid == task_pid(current))) in pid_for_clock() 94 return pid_has_task(pid, PIDTYPE_TGID) ? pid : NULL; in pid_for_clock() 389 struct pid *pid; in posix_cpu_timer_create() local 392 pid = pid_for_clock(new_timer->it_clock, false); in posix_cpu_timer_create() 393 if (!pid) { in posix_cpu_timer_create() 411 new_timer->it.cpu.pid = get_pid(pid); in posix_cpu_timer_create() [all …]
|
| /kernel/futex/ |
| A D | syscalls.c | 48 SYSCALL_DEFINE3(get_robust_list, int, pid, in SYSCALL_DEFINE3() argument 59 if (!pid) in SYSCALL_DEFINE3() 62 p = find_task_by_vpid(pid); in SYSCALL_DEFINE3() 454 COMPAT_SYSCALL_DEFINE3(get_robust_list, int, pid, in COMPAT_SYSCALL_DEFINE3() argument 465 if (!pid) in COMPAT_SYSCALL_DEFINE3() 468 p = find_task_by_vpid(pid); in COMPAT_SYSCALL_DEFINE3()
|
| A D | pi.c | 207 pid_t pid = uval & FUTEX_TID_MASK; in attach_to_pi_state() local 263 if (pid) in attach_to_pi_state() 279 if (!pid) in attach_to_pi_state() 295 if (pid != task_pid_vnr(pi_state->owner)) in attach_to_pi_state() 415 pid_t pid = uval & FUTEX_TID_MASK; in attach_to_pi_owner() local 425 if (!pid) in attach_to_pi_owner() 427 p = find_get_task_by_vpid(pid); in attach_to_pi_owner()
|