函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\groups.c Create Date:2022-07-27 10:35:39
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:ll a group_info from a user-space array - it must be allocated already

函数原型:static int groups_from_user(struct group_info *group_info, gid_t __user *grouplist)

返回类型:int

参数:

类型参数名称
struct group_info *group_info
gid_t __user *grouplist
62  user_ns等于current_user_ns()
64  count等于ngroups
66 i小于count循环
69  如果Careful: we have to cast the result to the type of the pointer* for sign reasons(gid, grouplist + i)则返回:负EFAULT
72  kgid等于make_kgid(user_ns, gid)
73  如果非gid_valid(kgid)则返回:负EINVAL
76  gid[i]等于kgid
78  返回:0
调用者
名称描述
SYSCALL_DEFINE2SMP: Our groups are copy-on-write. We can set them safely* without another task interfering.