/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 | 67 result->i_mode |= S_IFDIR; in hpfs_mkdir() 74 result->i_mode &= ~0222; in hpfs_mkdir() 109 result->i_mode != (mode | S_IFDIR)) { in hpfs_mkdir() 112 result->i_mode = mode | S_IFDIR; in hpfs_mkdir() 164 result->i_mode |= S_IFREG; in hpfs_create() 165 result->i_mode &= ~0111; in hpfs_create() 176 result->i_mode &= ~0222; in hpfs_create() 199 result->i_mode != (mode | S_IFREG)) { in hpfs_create() 202 result->i_mode = mode | S_IFREG; in hpfs_create() 334 result->i_mode = S_IFLNK | 0777; in hpfs_symlink() [all …]
|
/fs/squashfs/ |
D | inode.c | 65 inode->i_mode = le16_to_cpu(sqsh_ino->mode); in squashfs_new_inode() 157 inode->i_mode |= S_IFREG; in squashfs_read_inode() 202 inode->i_mode |= S_IFREG; in squashfs_read_inode() 231 inode->i_mode |= S_IFDIR; in squashfs_read_inode() 256 inode->i_mode |= S_IFDIR; in squashfs_read_inode() 284 inode->i_mode |= S_IFLNK; in squashfs_read_inode() 318 inode->i_mode |= S_IFCHR; in squashfs_read_inode() 320 inode->i_mode |= S_IFBLK; in squashfs_read_inode() 323 init_special_inode(inode, inode->i_mode, new_decode_dev(rdev)); in squashfs_read_inode() 340 inode->i_mode |= S_IFCHR; in squashfs_read_inode() [all …]
|
/fs/f2fs/ |
D | inode.c | 66 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode) || in __get_inode_rdev() 67 S_ISFIFO(inode->i_mode) || S_ISSOCK(inode->i_mode)) { in __get_inode_rdev() 95 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode)) { in __set_inode_rdev() 268 __func__, inode->i_ino, inode->i_mode); in sanity_check_inode() 272 if (f2fs_has_inline_dentry(inode) && !S_ISDIR(inode->i_mode)) { in sanity_check_inode() 275 __func__, inode->i_ino, inode->i_mode); in sanity_check_inode() 350 inode->i_mode = le16_to_cpu(ri->i_mode); in do_read_inode() 364 if (S_ISDIR(inode->i_mode)) in do_read_inode() 366 else if (S_ISREG(inode->i_mode)) in do_read_inode() 371 if (S_ISREG(inode->i_mode)) in do_read_inode() [all …]
|
/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() 217 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode)) in sysv_iget() 252 raw_inode->i_mode = cpu_to_fs16(sbi, inode->i_mode); in __sysv_write_inode() 262 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode)) in __sysv_write_inode()
|
/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 …]
|
/fs/minix/ |
D | inode.c | 461 if (S_ISREG(inode->i_mode)) { in minix_set_inode() 465 } else if (S_ISDIR(inode->i_mode)) { in minix_set_inode() 469 } else if (S_ISLNK(inode->i_mode)) { in minix_set_inode() 474 init_special_inode(inode, inode->i_mode, rdev); in minix_set_inode() 499 inode->i_mode = raw_inode->i_mode; in V1_minix_iget() 539 inode->i_mode = raw_inode->i_mode; in V2_minix_iget() 591 raw_inode->i_mode = inode->i_mode; in V1_minix_update_inode() 597 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode)) in V1_minix_update_inode() 618 raw_inode->i_mode = inode->i_mode; in V2_minix_update_inode() 626 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode)) in V2_minix_update_inode() [all …]
|
/fs/hfs/ |
D | inode.c | 197 inode->i_mode = mode; in hfs_new_inode() 212 inode->i_mode |= S_IRWXUGO; in hfs_new_inode() 213 inode->i_mode &= ~HFS_SB(inode->i_sb)->s_dir_umask; in hfs_new_inode() 222 inode->i_mode |= S_IRUGO|S_IXUGO; in hfs_new_inode() 224 inode->i_mode |= S_IWUGO; in hfs_new_inode() 225 inode->i_mode &= ~HFS_SB(inode->i_sb)->s_file_umask; in hfs_new_inode() 247 if (S_ISDIR(inode->i_mode)) { in hfs_delete_inode() 258 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 …]
|
/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() 326 if (S_ISLNK(inode->i_mode)) in ocfs2_acl_chmod() 337 ret = __posix_acl_chmod(&acl, GFP_KERNEL, inode->i_mode); in ocfs2_acl_chmod() 363 if (!S_ISLNK(inode->i_mode)) { in ocfs2_init_acl() 373 mode = inode->i_mode & ~current_umask(); in ocfs2_init_acl() 382 if (S_ISDIR(inode->i_mode)) { in ocfs2_init_acl() 389 mode = inode->i_mode; in ocfs2_init_acl()
|
/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(&init_user_ns, inode, 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 …]
|
/fs/ |
D | sync.c | 235 umode_t i_mode; in sync_file_range() local 272 i_mode = file_inode(file)->i_mode; in sync_file_range() 274 if (!S_ISREG(i_mode) && !S_ISBLK(i_mode) && !S_ISDIR(i_mode) && in sync_file_range() 275 !S_ISLNK(i_mode)) in sync_file_range()
|
D | attr.c | 39 umode_t mode = inode->i_mode; in setattr_should_drop_sgid() 70 umode_t mode = inode->i_mode; in setattr_should_drop_suidgid() 326 inode->i_mode = mode; in setattr_copy() 393 umode_t mode = inode->i_mode; in notify_change() 419 if (S_ISLNK(inode->i_mode)) in notify_change() 461 attr->ia_mode = (inode->i_mode & ~S_ISUID); in notify_change() 468 attr->ia_mode = inode->i_mode; in notify_change()
|
/fs/erofs/ |
D | inode.c | 94 inode->i_mode = le16_to_cpu(die->i_mode); in erofs_read_inode() 95 switch (inode->i_mode & S_IFMT) { in erofs_read_inode() 137 inode->i_mode = le16_to_cpu(dic->i_mode); in erofs_read_inode() 138 switch (inode->i_mode & S_IFMT) { in erofs_read_inode() 195 if (test_opt(&sbi->opt, DAX_ALWAYS) && S_ISREG(inode->i_mode) && in erofs_read_inode() 208 inode->i_mode, vi->nid); in erofs_read_inode() 269 switch (inode->i_mode & S_IFMT) { in erofs_fill_inode() 292 init_special_inode(inode, inode->i_mode, inode->i_rdev); in erofs_fill_inode()
|
/fs/nfs/ |
D | inode.c | 231 int mode = inode->i_mode; in nfs_zap_caches_locked() 345 inode->i_mode = fattr->mode; in nfs_init_locked() 493 inode->i_mode = fattr->mode; in nfs_fhget() 502 if (S_ISREG(inode->i_mode)) { in nfs_fhget() 506 } else if (S_ISDIR(inode->i_mode)) { in nfs_fhget() 521 } else if (S_ISLNK(inode->i_mode)) { in nfs_fhget() 525 init_special_inode(inode, inode->i_mode, fattr->rdev); in nfs_fhget() 638 BUG_ON(!S_ISREG(inode->i_mode)); in nfs_setattr() 655 if (S_ISREG(inode->i_mode)) in nfs_setattr() 732 inode->i_mode & S_ISUID) in nfs_setattr_update_inode() [all …]
|
/fs/btrfs/ |
D | acl.c | 71 if (!S_ISDIR(inode->i_mode)) in __btrfs_set_acl() 118 umode_t old_mode = inode->i_mode; in btrfs_set_acl() 122 &inode->i_mode, &acl); in btrfs_set_acl() 128 inode->i_mode = old_mode; in btrfs_set_acl() 142 ret = posix_acl_create(dir, &inode->i_mode, &default_acl, &acl); in btrfs_init_acl()
|
/fs/jfs/ |
D | acl.c | 103 umode_t mode = inode->i_mode; in jfs_set_acl() 111 if (mode != inode->i_mode) in jfs_set_acl() 117 inode->i_mode = mode; in jfs_set_acl() 134 rc = posix_acl_create(dir, &inode->i_mode, &default_acl, &acl); in jfs_init_acl() 154 inode->i_mode; in jfs_init_acl()
|
/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() 208 if (mk->mk_secret.is_hw_wrapped && S_ISREG(inode->i_mode)) { in setup_per_mode_enc_key() 723 S_ISDIR(inode->i_mode)); in fscrypt_get_encryption_info() 765 if (WARN_ON_ONCE(inode->i_mode == 0)) in fscrypt_prepare_new_inode() 772 if (!S_ISREG(inode->i_mode) && in fscrypt_prepare_new_inode() 773 !S_ISDIR(inode->i_mode) && in fscrypt_prepare_new_inode() 774 !S_ISLNK(inode->i_mode)) in fscrypt_prepare_new_inode() 782 S_ISDIR(inode->i_mode)); in fscrypt_prepare_new_inode() [all …]
|
/fs/ext2/ |
D | inode.c | 53 return (S_ISLNK(inode->i_mode) && in ext2_inode_is_fast_symlink() 530 if (S_ISDIR(inode->i_mode) && IS_DIRSYNC(inode)) in ext2_alloc_branch() 714 if (S_ISREG(inode->i_mode) && (!ei->i_block_alloc_info)) in ext2_get_blocks() 1274 if (!(S_ISREG(inode->i_mode) || S_ISDIR(inode->i_mode) || in ext2_truncate_blocks() 1275 S_ISLNK(inode->i_mode))) in ext2_truncate_blocks() 1289 if (!(S_ISREG(inode->i_mode) || S_ISDIR(inode->i_mode) || in ext2_setsize() 1290 S_ISLNK(inode->i_mode))) in ext2_setsize() 1387 if (test_opt(inode->i_sb, DAX) && S_ISREG(inode->i_mode)) in ext2_set_inode_flags() 1429 inode->i_mode = le16_to_cpu(raw_inode->i_mode); in ext2_iget() 1450 if (inode->i_nlink == 0 && (inode->i_mode == 0 || ei->i_dtime)) { in ext2_iget() [all …]
|
/fs/ntfs3/ |
D | xattr.c | 600 if (S_ISLNK(inode->i_mode)) in ntfs_set_acl_ex() 603 mode = inode->i_mode; in ntfs_set_acl_ex() 618 if (!S_ISDIR(inode->i_mode)) in ntfs_set_acl_ex() 649 if (inode->i_mode != mode) { in ntfs_set_acl_ex() 650 inode->i_mode = mode; in ntfs_set_acl_ex() 681 err = posix_acl_create(dir, &inode->i_mode, &default_acl, &acl); in ntfs_init_acl() 716 if (S_ISLNK(inode->i_mode)) in ntfs_acl_chmod() 719 return posix_acl_chmod(mnt_userns, inode, inode->i_mode); in ntfs_acl_chmod() 872 if (S_ISREG(inode->i_mode)) { in ntfs_setxattr() 885 if (S_ISDIR(inode->i_mode)) in ntfs_setxattr() [all …]
|
/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() 169 inode->i_mode = 0444; in coda_cnode_makectl()
|
/fs/reiserfs/ |
D | xattr_acl.c | 29 umode_t mode = inode->i_mode; in reiserfs_set_acl() 52 inode->i_mode = mode; in reiserfs_set_acl() 263 if (!S_ISDIR(inode->i_mode)) in __reiserfs_set_acl() 313 if (S_ISLNK(inode->i_mode)) in reiserfs_inherit_default_acl() 331 err = posix_acl_create(dir, &inode->i_mode, &default_acl, &acl); in reiserfs_inherit_default_acl() 351 inode->i_mode &= ~current_umask(); in reiserfs_inherit_default_acl() 407 return posix_acl_chmod(&init_user_ns, inode, inode->i_mode); in reiserfs_acl_chmod()
|
/fs/udf/ |
D | inode.c | 152 inode->i_ino, inode->i_mode, in udf_evict_inode() 879 if (S_ISREG(inode->i_mode)) in inode_getblk() 1225 if (!(S_ISREG(inode->i_mode) || S_ISDIR(inode->i_mode) || in udf_setsize() 1226 S_ISLNK(inode->i_mode))) in udf_setsize() 1456 inode->i_mode = sbi->s_fmode; in udf_read_inode() 1459 inode->i_mode = sbi->s_dmode; in udf_read_inode() 1461 inode->i_mode = udf_convert_permissions(fe); in udf_read_inode() 1462 inode->i_mode &= ~sbi->s_umask; in udf_read_inode() 1546 inode->i_mode |= S_IFDIR; in udf_read_inode() 1559 inode->i_mode |= S_IFREG; in udf_read_inode() [all …]
|
/fs/adfs/ |
D | inode.c | 139 if (S_ISLNK(inode->i_mode)) in adfs_mode2atts() 143 if (S_ISDIR(inode->i_mode)) in adfs_mode2atts() 269 inode->i_mode = adfs_atts2mode(sb, inode); in adfs_iget() 274 if (S_ISDIR(inode->i_mode)) { in adfs_iget() 277 } else if (S_ISREG(inode->i_mode)) { in adfs_iget() 336 inode->i_mode = adfs_atts2mode(sb, inode); in adfs_notify_change()
|
/fs/proc/ |
D | fd.c | 126 if (S_ISLNK(inode->i_mode)) { in tid_fd_update_inode() 127 unsigned i_mode = S_IFLNK; in tid_fd_update_inode() local 129 i_mode |= S_IRUSR | S_IXUSR; in tid_fd_update_inode() 131 i_mode |= S_IWUSR | S_IXUSR; in tid_fd_update_inode() 132 inode->i_mode = i_mode; in tid_fd_update_inode()
|
/fs/gfs2/ |
D | inode.c | 85 umode_t mode = inode->i_mode; in gfs2_set_iop() 103 init_special_inode(inode, inode->i_mode, inode->i_rdev); in gfs2_set_iop() 204 inode->i_mode = DT2IF(type); in gfs2_inode_lookup() 378 (dip->i_inode.i_mode & S_ISUID) && in munge_mode_uid_gid() 380 if (S_ISDIR(inode->i_mode)) in munge_mode_uid_gid() 381 inode->i_mode |= S_ISUID; in munge_mode_uid_gid() 383 inode->i_mode &= ~07111; in munge_mode_uid_gid() 388 if (dip->i_inode.i_mode & S_ISGID) { in munge_mode_uid_gid() 389 if (S_ISDIR(inode->i_mode)) in munge_mode_uid_gid() 390 inode->i_mode |= S_ISGID; in munge_mode_uid_gid() [all …]
|