函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:Check whether we can create an object with dentry child in directory* dir.* 1. We can't do it if child already exists (open has special treatment for* this case, but since we are inlined it's OK)* 2

函数原型:static inline int may_create(struct inode *dir, struct dentry *child)

返回类型:int

参数:

类型参数名称
struct inode *dir
struct dentry *child
2786  audit_inode_child(dir, child, a child being created )
2787  如果 Where the name belongs to - NULL is * negative 则返回:负EEXIST
2789  如果IS_DEADDIR(dir)则返回:负ENOENT
2791  s_user_ns等于s_user_ns
2792  如果非kuid_has_mapping(s_user_ns, current_fsuid())或非kgid_has_mapping(s_user_ns, current_fsgid())则返回:负EOVERFLOW
2795  返回: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
调用者
名称描述
vfs_create
vfs_mkobj
vfs_mknod
vfs_mkdir
vfs_symlink
vfs_linkvfs_link - create a new link*@old_dentry: object to be linked*@dir: new parent*@new_dentry: where to create the new link*@delegated_inode: returns inode needing a delegation break* The caller must hold dir->i_mutex* If vfs_link discovers a delegation on
vfs_renamevfs_rename - rename a filesystem object*@old_dir: parent of source*@old_dentry: source*@new_dir: parent of destination*@new_dentry: destination*@delegated_inode: returns an inode needing a delegation break*@flags: rename flags
vfs_whiteout