Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\syscall.c Create Date:2022-07-28 07:12:35
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:collect_syscall

Proto:static int collect_syscall(struct task_struct *target, struct syscall_info *info)

Type:int

Parameter:

TypeParameterName
struct task_struct *target
struct syscall_info *info
12  If Not try_get_task_stack(target) Then
14  memset(info, 0, size of info )
15  nr = -1
16  Return 0
19  regs = task_pt_regs(target)
20  If Value for the false possibility is greater at compile time(!regs) Then
21  put_task_stack(target)
22  Return -EAGAIN
25  sp = user_stack_pointer(regs)
26  instruction_pointer = instruction_pointer(regs)
28  nr = Only the low 32 bits of orig_ax are meaningful, so we return int.* This importantly ignores the high bits on 64-bit, so comparisons* sign-extend the low 32 bits.
29  If nr != -1L Then syscall_get_arguments(target, regs, (unsignedlong * ) & args[0])
33  put_task_stack(target)
34  Return 0
Caller
NameDescribe
task_current_syscallask_current_syscall - Discover what a blocked task is doing.*@target: thread to examine*@info: structure with the following fields:* .sp - filled with user stack pointer* .data.nr - filled with system call number or -1*