函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:Locate the user_struct for the passed UID. If found, take a ref on it. The* caller must undo that ref with free_uid().* If the user_struct could not be found, return NULL.

函数原型:struct user_struct *find_user(kuid_t uid)

返回类型:struct user_struct

参数:

类型参数名称
kuid_tuid
158  spin_lock_irqsave( & The uidhash_lock is mostly taken from process context, but it is* occasionally also taken from softirq/tasklet context, when* task-structs get RCU-freed, flags)
159  ret等于uid_hash_find(uid, uidhashentry(uid))
160  spin_unlock_irqrestore( & The uidhash_lock is mostly taken from process context, but it is* occasionally also taken from softirq/tasklet context, when* task-structs get RCU-freed, flags)
161  返回:ret
调用者
名称描述
SYSCALL_DEFINE3
SYSCALL_DEFINE2Ugh. To avoid negative return values, "getpriority()" will* not return the normal nice-value, but a negated value that* has been offset by 20 (ie it returns 40..1 instead of -20..19)* to stay compatible.
SYSCALL_DEFINE2
SYSCALL_DEFINE3