Commit e49859e7 authored by Pavel Emelyanov's avatar Pavel Emelyanov Committed by Linus Torvalds

pidns: remove now unused find_pid function.

This one had the only users so far - the kill_proc, which is removed, so
drop this (invalid in namespaced world) call too.

And of course - erase all references on it from comments.
Signed-off-by: default avatarPavel Emelyanov <xemul@openvz.org>
Cc: Oleg Nesterov <oleg@tv-sign.ru>
Cc: "Eric W. Biederman" <ebiederm@xmission.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 19b0cfcc
...@@ -48,7 +48,7 @@ enum pid_type ...@@ -48,7 +48,7 @@ enum pid_type
*/ */
struct upid { struct upid {
/* Try to keep pid_chain in the same cacheline as nr for find_pid */ /* Try to keep pid_chain in the same cacheline as nr for find_vpid */
int nr; int nr;
struct pid_namespace *ns; struct pid_namespace *ns;
struct hlist_node pid_chain; struct hlist_node pid_chain;
...@@ -105,14 +105,12 @@ extern struct pid_namespace init_pid_ns; ...@@ -105,14 +105,12 @@ extern struct pid_namespace init_pid_ns;
* or rcu_read_lock() held. * or rcu_read_lock() held.
* *
* find_pid_ns() finds the pid in the namespace specified * find_pid_ns() finds the pid in the namespace specified
* find_pid() find the pid by its global id, i.e. in the init namespace
* find_vpid() finr the pid by its virtual id, i.e. in the current namespace * find_vpid() finr the pid by its virtual id, i.e. in the current namespace
* *
* see also find_task_by_pid() set in include/linux/sched.h * see also find_task_by_pid() set in include/linux/sched.h
*/ */
extern struct pid *find_pid_ns(int nr, struct pid_namespace *ns); extern struct pid *find_pid_ns(int nr, struct pid_namespace *ns);
extern struct pid *find_vpid(int nr); extern struct pid *find_vpid(int nr);
extern struct pid *find_pid(int nr);
/* /*
* Lookup a PID in the hash table, and return with it's count elevated. * Lookup a PID in the hash table, and return with it's count elevated.
......
...@@ -1718,7 +1718,7 @@ extern struct pid_namespace init_pid_ns; ...@@ -1718,7 +1718,7 @@ extern struct pid_namespace init_pid_ns;
* find_task_by_pid(): * find_task_by_pid():
* finds a task by its global pid * finds a task by its global pid
* *
* see also find_pid() etc in include/linux/pid.h * see also find_vpid() etc in include/linux/pid.h
*/ */
extern struct task_struct *find_task_by_pid_type_ns(int type, int pid, extern struct task_struct *find_task_by_pid_type_ns(int type, int pid,
......
...@@ -309,12 +309,6 @@ struct pid *find_vpid(int nr) ...@@ -309,12 +309,6 @@ struct pid *find_vpid(int nr)
} }
EXPORT_SYMBOL_GPL(find_vpid); EXPORT_SYMBOL_GPL(find_vpid);
struct pid *find_pid(int nr)
{
return find_pid_ns(nr, &init_pid_ns);
}
EXPORT_SYMBOL_GPL(find_pid);
/* /*
* attach_pid() must be called with the tasklist_lock write-held. * attach_pid() must be called with the tasklist_lock write-held.
*/ */
...@@ -483,7 +477,7 @@ EXPORT_SYMBOL(task_session_nr_ns); ...@@ -483,7 +477,7 @@ EXPORT_SYMBOL(task_session_nr_ns);
/* /*
* Used by proc to find the first pid that is greater then or equal to nr. * Used by proc to find the first pid that is greater then or equal to nr.
* *
* If there is a pid at nr this function is exactly the same as find_pid. * If there is a pid at nr this function is exactly the same as find_pid_ns.
*/ */
struct pid *find_ge_pid(int nr, struct pid_namespace *ns) struct pid *find_ge_pid(int nr, struct pid_namespace *ns)
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment