[MIPS] Use find_task_by_vpid in system calls

There are some places left in mips, that lookup task in initial namespace,
while the code doing so gets the pid from the user space and thus must
treat it as virtual.

Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
Cc: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
This commit is contained in:
Pavel Emelyanov 2008-02-04 23:44:24 -08:00 коммит произвёл Ralf Baechle
Родитель 9a4c8546f3
Коммит 0e568536d9
2 изменённых файлов: 2 добавлений и 2 удалений

Просмотреть файл

@ -36,7 +36,7 @@ unsigned long mt_fpemul_threshold = 0;
*/ */
static inline struct task_struct *find_process_by_pid(pid_t pid) static inline struct task_struct *find_process_by_pid(pid_t pid)
{ {
return pid ? find_task_by_pid(pid) : current; return pid ? find_task_by_vpid(pid) : current;
} }

Просмотреть файл

@ -111,7 +111,7 @@ asmlinkage int irix_prctl(unsigned option, ...)
printk("irix_prctl[%s:%d]: Wants PR_ISBLOCKED\n", printk("irix_prctl[%s:%d]: Wants PR_ISBLOCKED\n",
current->comm, current->pid); current->comm, current->pid);
read_lock(&tasklist_lock); read_lock(&tasklist_lock);
task = find_task_by_pid(va_arg(args, pid_t)); task = find_task_by_vpid(va_arg(args, pid_t));
error = -ESRCH; error = -ESRCH;
if (error) if (error)
error = (task->run_list.next != NULL); error = (task->run_list.next != NULL);