Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\inode.c Create Date:2022-07-28 20:07:59
Last Modify:2020-03-18 19:19:59 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:de_init_owner - Init uid,gid,mode for new inode according to posix standards*@inode: New inode*@dir: Directory inode*@mode: mode of the new inode

Proto:void inode_init_owner(struct inode *inode, const struct inode *dir, umode_t mode)

Type:void

Parameter:

TypeParameterName
struct inode *inode
const struct inode *dir
umode_tmode
2054  i_uid = current_fsuid()
2055  If dir && i_mode & S_ISGID Then
2056  i_gid = i_gid
2059  If S_ISDIR(mode) Then mode |= S_ISGID
2061  Else if (mode & (S_ISGID | S_IXGRP)) == (S_ISGID | S_IXGRP) && Not Check whether we're fsgid/egid or in the supplemental group.. && Not apable_wrt_inode_uidgid - Check nsown_capable and uid and gid mapped*@inode: The inode in question*@cap: The capability in question* Return true if the current task has the given capability targeted at* its own user namespace and that the given inode's Then mode &= ~S_ISGID
2065  Else i_gid = current_fsgid()
2067  i_mode = mode
Caller
NameDescribe
ramfs_get_inode
bpf_get_inode