Lines Matching full:target
8 static int collect_syscall(struct task_struct *target, struct syscall_info *info) in collect_syscall() argument
13 if (!try_get_task_stack(target)) { in collect_syscall()
20 regs = task_pt_regs(target); in collect_syscall()
22 put_task_stack(target); in collect_syscall()
29 info->data.nr = syscall_get_nr(target, regs); in collect_syscall()
31 syscall_get_arguments(target, regs, args); in collect_syscall()
40 put_task_stack(target); in collect_syscall()
46 * @target: thread to examine
53 * If @target is blocked in a system call, returns zero with @info.data.nr
57 * call is still in progress. Note we may get this result if @target
61 * If @target is blocked in the kernel during a fault or exception,
63 * @info.data.args. If so, it's now safe to examine @target using
64 * &struct user_regset get() calls as long as we're sure @target won't return
67 * Returns -%EAGAIN if @target does not remain blocked.
69 int task_current_syscall(struct task_struct *target, struct syscall_info *info) in task_current_syscall() argument
74 if (target == current) in task_current_syscall()
75 return collect_syscall(target, info); in task_current_syscall()
77 state = READ_ONCE(target->__state); in task_current_syscall()
81 ncsw = wait_task_inactive(target, state); in task_current_syscall()
83 unlikely(collect_syscall(target, info)) || in task_current_syscall()
84 unlikely(wait_task_inactive(target, state) != ncsw)) in task_current_syscall()