/linux-6.12.1/fs/hpfs/ |
D | inode.c | 21 i->i_mode = hpfs_sb(sb)->sb_mode; in hpfs_init_inode() 79 i->i_mode = S_IFLNK | 0777; in hpfs_read_inode() 97 i->i_mode = mode; in hpfs_read_inode() 118 i->i_mode |= S_IFDIR; in hpfs_read_inode() 133 i->i_mode |= S_IFREG; in hpfs_read_inode() 134 if (!hpfs_inode->i_ea_mode) i->i_mode &= ~0111; in hpfs_read_inode() 165 if (!S_ISLNK(i->i_mode)) in hpfs_write_inode_ea() 166 if ((i->i_mode != ((hpfs_sb(i->i_sb)->sb_mode & ~(S_ISDIR(i->i_mode) ? 0 : 0111)) in hpfs_write_inode_ea() 167 | (S_ISDIR(i->i_mode) ? S_IFDIR : S_IFREG)) in hpfs_write_inode_ea() 168 && i->i_mode != ((hpfs_sb(i->i_sb)->sb_mode & ~(S_ISDIR(i->i_mode) ? 0222 : 0333)) in hpfs_write_inode_ea() [all …]
|
D | namei.c | 64 result->i_mode |= S_IFDIR; in hpfs_mkdir() 71 result->i_mode &= ~0222; in hpfs_mkdir() 106 result->i_mode != (mode | S_IFDIR)) { in hpfs_mkdir() 109 result->i_mode = mode | S_IFDIR; in hpfs_mkdir() 161 result->i_mode |= S_IFREG; in hpfs_create() 162 result->i_mode &= ~0111; in hpfs_create() 171 result->i_mode &= ~0222; in hpfs_create() 194 result->i_mode != (mode | S_IFREG)) { in hpfs_create() 197 result->i_mode = mode | S_IFREG; in hpfs_create() 325 result->i_mode = S_IFLNK | 0777; in hpfs_symlink() [all …]
|
/linux-6.12.1/fs/squashfs/ |
D | inode.c | 68 inode->i_mode = le16_to_cpu(sqsh_ino->mode); in squashfs_new_inode() 160 inode->i_mode |= S_IFREG; in squashfs_read_inode() 205 inode->i_mode |= S_IFREG; in squashfs_read_inode() 234 inode->i_mode |= S_IFDIR; in squashfs_read_inode() 259 inode->i_mode |= S_IFDIR; in squashfs_read_inode() 292 inode->i_mode |= S_IFLNK; in squashfs_read_inode() 326 inode->i_mode |= S_IFCHR; in squashfs_read_inode() 328 inode->i_mode |= S_IFBLK; in squashfs_read_inode() 331 init_special_inode(inode, inode->i_mode, new_decode_dev(rdev)); in squashfs_read_inode() 348 inode->i_mode |= S_IFCHR; in squashfs_read_inode() [all …]
|
/linux-6.12.1/fs/sysv/ |
D | inode.c | 154 if (S_ISREG(inode->i_mode)) { in sysv_set_inode() 158 } else if (S_ISDIR(inode->i_mode)) { in sysv_set_inode() 162 } else if (S_ISLNK(inode->i_mode)) { in sysv_set_inode() 167 init_special_inode(inode, inode->i_mode, rdev); in sysv_set_inode() 198 inode->i_mode = fs16_to_cpu(sbi, raw_inode->i_mode); in sysv_iget() 214 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode)) in sysv_iget() 249 raw_inode->i_mode = cpu_to_fs16(sbi, inode->i_mode); in __sysv_write_inode() 259 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode)) in __sysv_write_inode()
|
/linux-6.12.1/fs/f2fs/ |
D | inode.c | 75 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode) || in __get_inode_rdev() 76 S_ISFIFO(inode->i_mode) || S_ISSOCK(inode->i_mode)) { in __get_inode_rdev() 88 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode)) { in __set_inode_rdev() 353 __func__, inode->i_ino, inode->i_mode); in sanity_check_inode() 357 if (f2fs_has_inline_dentry(inode) && !S_ISDIR(inode->i_mode)) { in sanity_check_inode() 359 __func__, inode->i_ino, inode->i_mode); in sanity_check_inode() 405 inode->i_mode = le16_to_cpu(ri->i_mode); in do_read_inode() 419 if (S_ISDIR(inode->i_mode)) in do_read_inode() 421 else if (S_ISREG(inode->i_mode)) in do_read_inode() 425 if (S_ISREG(inode->i_mode)) in do_read_inode() [all …]
|
/linux-6.12.1/fs/affs/ |
D | inode.c | 55 inode->i_mode = 0; in affs_iget() 72 inode->i_mode = sbi->s_mode; in affs_iget() 74 inode->i_mode = affs_prot_to_mode(prot); in affs_iget() 100 if (inode->i_mode & S_IRUSR) in affs_iget() 101 inode->i_mode |= S_IXUSR; in affs_iget() 102 if (inode->i_mode & S_IRGRP) in affs_iget() 103 inode->i_mode |= S_IXGRP; in affs_iget() 104 if (inode->i_mode & S_IROTH) in affs_iget() 105 inode->i_mode |= S_IXOTH; in affs_iget() 106 inode->i_mode |= S_IFDIR; in affs_iget() [all …]
|
/linux-6.12.1/fs/minix/ |
D | inode.c | 482 if (S_ISREG(inode->i_mode)) { in minix_set_inode() 486 } else if (S_ISDIR(inode->i_mode)) { in minix_set_inode() 490 } else if (S_ISLNK(inode->i_mode)) { in minix_set_inode() 495 init_special_inode(inode, inode->i_mode, rdev); in minix_set_inode() 520 inode->i_mode = raw_inode->i_mode; in V1_minix_iget() 558 inode->i_mode = raw_inode->i_mode; in V2_minix_iget() 607 raw_inode->i_mode = inode->i_mode; in V1_minix_update_inode() 613 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode)) in V1_minix_update_inode() 634 raw_inode->i_mode = inode->i_mode; in V2_minix_update_inode() 642 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode)) in V2_minix_update_inode() [all …]
|
/linux-6.12.1/fs/ocfs2/ |
D | acl.c | 193 inode->i_mode = new_mode; in ocfs2_acl_set_mode() 195 di->i_mode = cpu_to_le16(inode->i_mode); in ocfs2_acl_set_mode() 227 if (S_ISLNK(inode->i_mode)) in ocfs2_set_acl() 236 if (!S_ISDIR(inode->i_mode)) in ocfs2_set_acl() 327 if (S_ISLNK(inode->i_mode)) in ocfs2_acl_chmod() 338 ret = __posix_acl_chmod(&acl, GFP_KERNEL, inode->i_mode); in ocfs2_acl_chmod() 364 if (!S_ISLNK(inode->i_mode)) { in ocfs2_init_acl() 374 mode = inode->i_mode & ~current_umask(); in ocfs2_init_acl() 383 if (S_ISDIR(inode->i_mode)) { in ocfs2_init_acl() 390 mode = inode->i_mode; in ocfs2_init_acl()
|
/linux-6.12.1/fs/erofs/ |
D | inode.c | 99 inode->i_mode = le16_to_cpu(die->i_mode); in erofs_read_inode() 116 inode->i_mode = le16_to_cpu(dic->i_mode); in erofs_read_inode() 138 switch (inode->i_mode & S_IFMT) { in erofs_read_inode() 143 if(S_ISLNK(inode->i_mode)) { in erofs_read_inode() 158 erofs_err(sb, "bogus i_mode (%o) @ nid %llu", inode->i_mode, in erofs_read_inode() 183 if (test_opt(&sbi->opt, DAX_ALWAYS) && S_ISREG(inode->i_mode) && in erofs_read_inode() 212 switch (inode->i_mode & S_IFMT) { in erofs_fill_inode() 237 init_special_inode(inode, inode->i_mode, inode->i_rdev); in erofs_fill_inode() 336 if ((request_mask & STATX_DIOALIGN) && S_ISREG(inode->i_mode)) { in erofs_getattr()
|
/linux-6.12.1/fs/coda/ |
D | cnode.c | 30 if (S_ISREG(inode->i_mode)) { in coda_fill_inode() 33 } else if (S_ISDIR(inode->i_mode)) { in coda_fill_inode() 36 } else if (S_ISLNK(inode->i_mode)) { in coda_fill_inode() 42 init_special_inode(inode, inode->i_mode, huge_decode_dev(attr->va_rdev)); in coda_fill_inode() 81 } else if ((inode->i_mode & S_IFMT) != inode_type) { in coda_iget() 174 inode->i_mode = 0444; in coda_cnode_makectl()
|
/linux-6.12.1/fs/hfs/ |
D | inode.c | 194 inode->i_mode = mode; in hfs_new_inode() 210 inode->i_mode |= S_IRWXUGO; in hfs_new_inode() 211 inode->i_mode &= ~HFS_SB(inode->i_sb)->s_dir_umask; in hfs_new_inode() 220 inode->i_mode |= S_IRUGO|S_IXUGO; in hfs_new_inode() 222 inode->i_mode |= S_IWUGO; in hfs_new_inode() 223 inode->i_mode &= ~HFS_SB(inode->i_sb)->s_file_umask; in hfs_new_inode() 245 if (S_ISDIR(inode->i_mode)) { in hfs_delete_inode() 256 if (S_ISREG(inode->i_mode)) { in hfs_delete_inode() 351 inode->i_mode = S_IRUGO | S_IXUGO; in hfs_read_inode() 353 inode->i_mode |= S_IWUGO; in hfs_read_inode() [all …]
|
/linux-6.12.1/fs/jffs2/ |
D | fs.c | 53 if (S_ISBLK(inode->i_mode) || S_ISCHR(inode->i_mode)) { in jffs2_do_setattr() 59 } else if (S_ISLNK(inode->i_mode)) { in jffs2_do_setattr() 80 if (S_ISLNK(inode->i_mode)) in jffs2_do_setattr() 89 if (S_ISLNK(inode->i_mode)) in jffs2_do_setattr() 112 ri->mode = cpu_to_jemode(inode->i_mode); in jffs2_do_setattr() 140 if (S_ISLNK(inode->i_mode)) in jffs2_do_setattr() 153 inode->i_mode = jemode_to_cpu(ri->mode); in jffs2_do_setattr() 205 rc = posix_acl_chmod(&nop_mnt_idmap, dentry, inode->i_mode); in jffs2_setattr() 247 __func__, inode->i_ino, inode->i_mode); in jffs2_evict_inode() 281 inode->i_mode = jemode_to_cpu(latest_node.mode); in jffs2_iget() [all …]
|
/linux-6.12.1/fs/ |
D | sync.c | 234 umode_t i_mode; in sync_file_range() local 271 i_mode = file_inode(file)->i_mode; in sync_file_range() 273 if (!S_ISREG(i_mode) && !S_ISBLK(i_mode) && !S_ISDIR(i_mode) && in sync_file_range() 274 !S_ISLNK(i_mode)) in sync_file_range()
|
D | attr.c | 36 umode_t mode = inode->i_mode; in setattr_should_drop_sgid() 66 umode_t mode = inode->i_mode; in setattr_should_drop_suidgid() 317 inode->i_mode = mode; in setattr_copy() 381 umode_t mode = inode->i_mode; in notify_change() 407 if (S_ISLNK(inode->i_mode)) in notify_change() 449 attr->ia_mode = (inode->i_mode & ~S_ISUID); in notify_change() 456 attr->ia_mode = inode->i_mode; in notify_change()
|
/linux-6.12.1/fs/jfs/ |
D | acl.c | 104 umode_t mode = inode->i_mode; in jfs_set_acl() 112 if (mode != inode->i_mode) in jfs_set_acl() 118 inode->i_mode = mode; in jfs_set_acl() 135 rc = posix_acl_create(dir, &inode->i_mode, &default_acl, &acl); in jfs_init_acl() 155 inode->i_mode; in jfs_init_acl()
|
/linux-6.12.1/fs/btrfs/ |
D | acl.c | 69 if (!S_ISDIR(inode->i_mode)) in __btrfs_set_acl() 117 umode_t old_mode = inode->i_mode; in btrfs_set_acl() 121 &inode->i_mode, &acl); in btrfs_set_acl() 127 inode->i_mode = old_mode; in btrfs_set_acl()
|
/linux-6.12.1/fs/xfs/libxfs/ |
D | xfs_inode_util.c | 50 if (S_ISDIR(VFS_I(ip)->i_mode)) { in xfs_flags2diflags() 59 } else if (S_ISREG(VFS_I(ip)->i_mode)) { in xfs_flags2diflags() 154 umode_t mode = VFS_I(ip)->i_mode; in xfs_inode_inherit_flags() 205 VFS_I(ip)->i_mode, ip->i_diflags); in xfs_inode_inherit_flags() 230 VFS_I(ip)->i_mode, ip->i_diflags, ip->i_diflags2); in xfs_inode_inherit_flags2() 290 inode->i_mode = args->mode; in xfs_inode_init() 293 if (dir && !(dir->i_mode & S_ISGID) && xfs_has_grpid(mp)) { in xfs_inode_init() 296 inode->i_mode = args->mode; in xfs_inode_init() 307 if (irix_sgid_inherit && (inode->i_mode & S_ISGID) && in xfs_inode_init() 309 inode->i_mode &= ~S_ISGID; in xfs_inode_init() [all …]
|
/linux-6.12.1/fs/ext2/ |
D | inode.c | 53 return (S_ISLNK(inode->i_mode) && in ext2_inode_is_fast_symlink() 534 if (S_ISDIR(inode->i_mode) && IS_DIRSYNC(inode)) in ext2_alloc_branch() 718 if (S_ISREG(inode->i_mode) && (!ei->i_block_alloc_info)) in ext2_get_blocks() 1253 if (!(S_ISREG(inode->i_mode) || S_ISDIR(inode->i_mode) || in ext2_truncate_blocks() 1254 S_ISLNK(inode->i_mode))) in ext2_truncate_blocks() 1268 if (!(S_ISREG(inode->i_mode) || S_ISDIR(inode->i_mode) || in ext2_setsize() 1269 S_ISLNK(inode->i_mode))) in ext2_setsize() 1362 if (test_opt(inode->i_sb, DAX) && S_ISREG(inode->i_mode)) in ext2_set_inode_flags() 1402 inode->i_mode = le16_to_cpu(raw_inode->i_mode); in ext2_iget() 1422 if (inode->i_nlink == 0 && (inode->i_mode == 0 || ei->i_dtime)) { in ext2_iget() [all …]
|
/linux-6.12.1/fs/reiserfs/ |
D | xattr_acl.c | 30 umode_t mode = inode->i_mode; in reiserfs_set_acl() 53 inode->i_mode = mode; in reiserfs_set_acl() 264 if (!S_ISDIR(inode->i_mode)) in __reiserfs_set_acl() 314 if (S_ISLNK(inode->i_mode)) in reiserfs_inherit_default_acl() 332 err = posix_acl_create(dir, &inode->i_mode, &default_acl, &acl); in reiserfs_inherit_default_acl() 352 inode->i_mode &= ~current_umask(); in reiserfs_inherit_default_acl() 410 return posix_acl_chmod(&nop_mnt_idmap, dentry, inode->i_mode); in reiserfs_acl_chmod()
|
/linux-6.12.1/fs/crypto/ |
D | keysetup.c | 87 if (S_ISREG(inode->i_mode)) in select_encryption_mode() 90 if (S_ISDIR(inode->i_mode) || S_ISLNK(inode->i_mode)) in select_encryption_mode() 94 inode->i_ino, (inode->i_mode & S_IFMT)); in select_encryption_mode() 678 S_ISDIR(inode->i_mode)); in fscrypt_get_encryption_info() 723 if (WARN_ON_ONCE(inode->i_mode == 0)) in fscrypt_prepare_new_inode() 730 if (!S_ISREG(inode->i_mode) && in fscrypt_prepare_new_inode() 731 !S_ISDIR(inode->i_mode) && in fscrypt_prepare_new_inode() 732 !S_ISLNK(inode->i_mode)) in fscrypt_prepare_new_inode() 740 S_ISDIR(inode->i_mode)); in fscrypt_prepare_new_inode() 767 if (IS_ENCRYPTED(inode) && S_ISLNK(inode->i_mode)) { in fscrypt_free_inode()
|
/linux-6.12.1/fs/proc/ |
D | fd.c | 134 if (S_ISLNK(inode->i_mode)) { in tid_fd_update_inode() 135 unsigned i_mode = S_IFLNK; in tid_fd_update_inode() local 137 i_mode |= S_IRUSR | S_IXUSR; in tid_fd_update_inode() 139 i_mode |= S_IWUSR | S_IXUSR; in tid_fd_update_inode() 140 inode->i_mode = i_mode; in tid_fd_update_inode() 365 if (S_ISDIR(inode->i_mode)) { in proc_fd_getattr()
|
/linux-6.12.1/fs/ntfs3/ |
D | xattr.c | 603 if (S_ISLNK(inode->i_mode)) in ntfs_set_acl_ex() 606 mode = inode->i_mode; in ntfs_set_acl_ex() 620 if (!S_ISDIR(inode->i_mode)) in ntfs_set_acl_ex() 651 inode->i_mode = mode; in ntfs_set_acl_ex() 682 err = posix_acl_create(dir, &inode->i_mode, &default_acl, &acl); in ntfs_init_acl() 718 if (S_ISLNK(inode->i_mode)) in ntfs_acl_chmod() 721 return posix_acl_chmod(idmap, dentry, inode->i_mode); in ntfs_acl_chmod() 862 if (S_ISREG(inode->i_mode)) { in ntfs_setxattr() 875 if (S_ISDIR(inode->i_mode)) in ntfs_setxattr() 883 inode->i_mode &= ~0222; in ntfs_setxattr() [all …]
|
/linux-6.12.1/fs/nfs/ |
D | inode.c | 229 int mode = inode->i_mode; in nfs_zap_caches_locked() 343 inode->i_mode = fattr->mode; in nfs_init_locked() 485 inode->i_mode = fattr->mode; in nfs_fhget() 494 if (S_ISREG(inode->i_mode)) { in nfs_fhget() 499 } else if (S_ISDIR(inode->i_mode)) { in nfs_fhget() 514 } else if (S_ISLNK(inode->i_mode)) { in nfs_fhget() 518 init_special_inode(inode, inode->i_mode, fattr->rdev); in nfs_fhget() 690 BUG_ON(!S_ISREG(inode->i_mode)); in nfs_setattr() 719 if (S_ISREG(inode->i_mode)) in nfs_setattr() 800 inode->i_mode & S_ISUID) in nfs_setattr_update_inode() [all …]
|
/linux-6.12.1/fs/adfs/ |
D | inode.c | 142 if (S_ISLNK(inode->i_mode)) in adfs_mode2atts() 146 if (S_ISDIR(inode->i_mode)) in adfs_mode2atts() 273 inode->i_mode = adfs_atts2mode(sb, inode); in adfs_iget() 279 if (S_ISDIR(inode->i_mode)) { in adfs_iget() 282 } else if (S_ISREG(inode->i_mode)) { in adfs_iget() 342 inode->i_mode = adfs_atts2mode(sb, inode); in adfs_notify_change()
|
/linux-6.12.1/fs/ext4/ |
D | acl.c | 204 if (!S_ISDIR(inode->i_mode)) in __ext4_set_acl() 235 umode_t mode = inode->i_mode; in ext4_set_acl() 255 if (mode != inode->i_mode) in ext4_set_acl() 261 inode->i_mode = mode; in ext4_set_acl() 284 error = posix_acl_create(dir, &inode->i_mode, &default_acl, &acl); in ext4_init_acl()
|