diff options
author | Sukadev Bhattiprolu <sukadev@us.ibm.com> | 2007-05-11 01:22:58 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-11 11:29:35 -0400 |
commit | e713d0dab21a68500720e222fa02567fc7dfb14b (patch) | |
tree | a56f90ce94d9287b73da6db72ed0e73542a70a07 /include/linux/pid.h | |
parent | 4ac24b3ba9016881b11646114bb5cd12cf23edd9 (diff) |
attach_pid() with struct pid parameter
attach_pid() currently takes a pid_t and then uses find_pid() to find the
corresponding struct pid. Sometimes we already have the struct pid. We can
then skip find_pid() if attach_pid() were to take a struct pid parameter.
Signed-off-by: Sukadev Bhattiprolu <sukadev@us.ibm.com>
Cc: Cedric Le Goater <clg@fr.ibm.com>
Cc: Dave Hansen <haveblue@us.ibm.com>
Cc: Serge Hallyn <serue@us.ibm.com>
Cc: <containers@lists.osdl.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/pid.h')
-rw-r--r-- | include/linux/pid.h | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/include/linux/pid.h b/include/linux/pid.h index 2ac27f9997dd..33d343880d89 100644 --- a/include/linux/pid.h +++ b/include/linux/pid.h | |||
@@ -76,8 +76,7 @@ extern struct pid *get_task_pid(struct task_struct *task, enum pid_type type); | |||
76 | * write-held. | 76 | * write-held. |
77 | */ | 77 | */ |
78 | extern int FASTCALL(attach_pid(struct task_struct *task, | 78 | extern int FASTCALL(attach_pid(struct task_struct *task, |
79 | enum pid_type type, int nr)); | 79 | enum pid_type type, struct pid *pid)); |
80 | |||
81 | extern void FASTCALL(detach_pid(struct task_struct *task, enum pid_type)); | 80 | extern void FASTCALL(detach_pid(struct task_struct *task, enum pid_type)); |
82 | extern void FASTCALL(transfer_pid(struct task_struct *old, | 81 | extern void FASTCALL(transfer_pid(struct task_struct *old, |
83 | struct task_struct *new, enum pid_type)); | 82 | struct task_struct *new, enum pid_type)); |