Lines Matching refs:nr

42 #define pid_hashfn(nr, ns)	\  argument
43 hash_long((unsigned long)nr + (unsigned long)ns, pidhash_shift)
107 int nr = upid->nr; in free_pidmap() local
108 struct pidmap *map = upid->ns->pidmap + nr / BITS_PER_PAGE; in free_pidmap()
109 int offset = nr & BITS_PER_PAGE_MASK; in free_pidmap()
301 int i, nr; in alloc_pid() local
313 nr = alloc_pidmap(tmp); in alloc_pid()
314 if (IS_ERR_VALUE(nr)) { in alloc_pid()
315 retval = nr; in alloc_pid()
319 pid->numbers[i].nr = nr; in alloc_pid()
340 &pid_hash[pid_hashfn(upid->nr, upid->ns)]); in alloc_pid()
366 struct pid *find_pid_ns(int nr, struct pid_namespace *ns) in find_pid_ns() argument
371 &pid_hash[pid_hashfn(nr, ns)], pid_chain) in find_pid_ns()
372 if (pnr->nr == nr && pnr->ns == ns) in find_pid_ns()
380 struct pid *find_vpid(int nr) in find_vpid() argument
382 return find_pid_ns(nr, task_active_pid_ns(current)); in find_vpid()
452 struct task_struct *find_task_by_pid_ns(pid_t nr, struct pid_namespace *ns) in find_task_by_pid_ns() argument
456 return pid_task(find_pid_ns(nr, ns), PIDTYPE_PID); in find_task_by_pid_ns()
488 struct pid *find_get_pid(pid_t nr) in find_get_pid() argument
493 pid = get_pid(find_vpid(nr)); in find_get_pid()
503 pid_t nr = 0; in pid_nr_ns() local
508 nr = upid->nr; in pid_nr_ns()
510 return nr; in pid_nr_ns()
523 pid_t nr = 0; in __task_pid_nr_ns() local
531 nr = pid_nr_ns(rcu_dereference(task->pids[type].pid), ns); in __task_pid_nr_ns()
535 return nr; in __task_pid_nr_ns()
556 struct pid *find_ge_pid(int nr, struct pid_namespace *ns) in find_ge_pid() argument
561 pid = find_pid_ns(nr, ns); in find_ge_pid()
564 nr = next_pidmap(ns, nr); in find_ge_pid()
565 } while (nr > 0); in find_ge_pid()