函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:may_o_create

函数原型:static int may_o_create(const struct path *dir, struct dentry *dentry, umode_t mode)

返回类型:int

参数:

类型参数名称
const struct path *dir
struct dentry *dentry
umode_tmode
2970  error等于security_path_mknod(dir, dentry, mode, 0)
2971  如果error则返回:error
2974  s_user_ns等于s_user_ns
2975  如果非kuid_has_mapping(s_user_ns, current_fsuid())或非kgid_has_mapping(s_user_ns, current_fsgid())则返回:负EOVERFLOW
2979  error等于de_permission - Check for access rights to a given inode*@inode: Inode to check permission on*@mask: Right to check for (%MAY_READ, %MAY_WRITE, %MAY_EXEC)* Check for read/write/execute permissions on an inode
2980  如果error则返回:error
2983  返回:security_inode_create( Where the name belongs to - NULL is * negative , dentry, mode)
调用者
名称描述
lookup_openLook up and maybe create and open the last component