Home
last modified time | relevance | path

Searched refs:i_mode (Results 1 – 25 of 455) sorted by relevance

12345678910>>...19

/linux-6.6.21/fs/hpfs/
Dinode.c21 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 …]
/linux-6.6.21/fs/squashfs/
Dinode.c65 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 …]
/linux-6.6.21/fs/sysv/
Dinode.c154 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()
216 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode)) in sysv_iget()
251 raw_inode->i_mode = cpu_to_fs16(sbi, inode->i_mode); in __sysv_write_inode()
261 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode)) in __sysv_write_inode()
/linux-6.6.21/fs/f2fs/
Dinode.c68 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode) || in __get_inode_rdev()
69 S_ISFIFO(inode->i_mode) || S_ISSOCK(inode->i_mode)) { in __get_inode_rdev()
97 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode)) { in __set_inode_rdev()
366 __func__, inode->i_ino, inode->i_mode); in sanity_check_inode()
370 if (f2fs_has_inline_dentry(inode) && !S_ISDIR(inode->i_mode)) { in sanity_check_inode()
372 __func__, inode->i_ino, inode->i_mode); in sanity_check_inode()
413 inode->i_mode = le16_to_cpu(ri->i_mode); in do_read_inode()
427 if (S_ISDIR(inode->i_mode)) in do_read_inode()
429 else if (S_ISREG(inode->i_mode)) in do_read_inode()
434 if (S_ISREG(inode->i_mode)) in do_read_inode()
[all …]
/linux-6.6.21/fs/affs/
Dinode.c55 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.6.21/fs/minix/
Dinode.c461 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()
536 inode->i_mode = raw_inode->i_mode; in V2_minix_iget()
587 raw_inode->i_mode = inode->i_mode; in V1_minix_update_inode()
593 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode)) in V1_minix_update_inode()
614 raw_inode->i_mode = inode->i_mode; in V2_minix_update_inode()
622 if (S_ISCHR(inode->i_mode) || S_ISBLK(inode->i_mode)) in V2_minix_update_inode()
[all …]
/linux-6.6.21/fs/ocfs2/
Dacl.c193 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.6.21/fs/coda/
Dcnode.c30 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.6.21/fs/hfs/
Dinode.c199 inode->i_mode = mode; in hfs_new_inode()
214 inode->i_mode |= S_IRWXUGO; in hfs_new_inode()
215 inode->i_mode &= ~HFS_SB(inode->i_sb)->s_dir_umask; in hfs_new_inode()
224 inode->i_mode |= S_IRUGO|S_IXUGO; in hfs_new_inode()
226 inode->i_mode |= S_IWUGO; in hfs_new_inode()
227 inode->i_mode &= ~HFS_SB(inode->i_sb)->s_file_umask; in hfs_new_inode()
249 if (S_ISDIR(inode->i_mode)) { in hfs_delete_inode()
260 if (S_ISREG(inode->i_mode)) { in hfs_delete_inode()
353 inode->i_mode = S_IRUGO | S_IXUGO; in hfs_read_inode()
355 inode->i_mode |= S_IWUGO; in hfs_read_inode()
[all …]
/linux-6.6.21/fs/jffs2/
Dfs.c53 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.6.21/fs/
Dsync.c234 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()
Dattr.c40 umode_t mode = inode->i_mode; in setattr_should_drop_sgid()
70 umode_t mode = inode->i_mode; in setattr_should_drop_suidgid()
321 inode->i_mode = mode; in setattr_copy()
385 umode_t mode = inode->i_mode; in notify_change()
411 if (S_ISLNK(inode->i_mode)) in notify_change()
453 attr->ia_mode = (inode->i_mode & ~S_ISUID); in notify_change()
460 attr->ia_mode = inode->i_mode; in notify_change()
/linux-6.6.21/fs/jfs/
Dacl.c104 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()
Dinode.c41 if (S_ISREG(inode->i_mode)) { in jfs_iget()
45 } else if (S_ISDIR(inode->i_mode)) { in jfs_iget()
48 } else if (S_ISLNK(inode->i_mode)) { in jfs_iget()
64 init_special_inode(inode, inode->i_mode, inode->i_rdev); in jfs_iget()
92 if (!special_file(inode->i_mode) && noisy) { in jfs_commit_inode()
185 if (!special_file(inode->i_mode) && noisy) { in jfs_dirty_inode()
/linux-6.6.21/fs/erofs/
Dinode.c84 inode->i_mode = le16_to_cpu(die->i_mode); in erofs_read_inode()
85 switch (inode->i_mode & S_IFMT) { in erofs_read_inode()
127 inode->i_mode = le16_to_cpu(dic->i_mode); in erofs_read_inode()
128 switch (inode->i_mode & S_IFMT) { in erofs_read_inode()
181 if (test_opt(&sbi->opt, DAX_ALWAYS) && S_ISREG(inode->i_mode) && in erofs_read_inode()
195 inode->i_mode, vi->nid); in erofs_read_inode()
256 switch (inode->i_mode & S_IFMT) { in erofs_fill_inode()
280 init_special_inode(inode, inode->i_mode, inode->i_rdev); in erofs_fill_inode()
/linux-6.6.21/fs/btrfs/
Dacl.c70 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()
/linux-6.6.21/fs/ext2/
Dinode.c53 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()
1255 if (!(S_ISREG(inode->i_mode) || S_ISDIR(inode->i_mode) || in ext2_truncate_blocks()
1256 S_ISLNK(inode->i_mode))) in ext2_truncate_blocks()
1270 if (!(S_ISREG(inode->i_mode) || S_ISDIR(inode->i_mode) || in ext2_setsize()
1271 S_ISLNK(inode->i_mode))) in ext2_setsize()
1364 if (test_opt(inode->i_sb, DAX) && S_ISREG(inode->i_mode)) in ext2_set_inode_flags()
1404 inode->i_mode = le16_to_cpu(raw_inode->i_mode); in ext2_iget()
1425 if (inode->i_nlink == 0 && (inode->i_mode == 0 || ei->i_dtime)) { in ext2_iget()
[all …]
/linux-6.6.21/fs/crypto/
Dkeysetup.c87 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()
671 S_ISDIR(inode->i_mode)); in fscrypt_get_encryption_info()
713 if (WARN_ON_ONCE(inode->i_mode == 0)) in fscrypt_prepare_new_inode()
720 if (!S_ISREG(inode->i_mode) && in fscrypt_prepare_new_inode()
721 !S_ISDIR(inode->i_mode) && in fscrypt_prepare_new_inode()
722 !S_ISLNK(inode->i_mode)) in fscrypt_prepare_new_inode()
730 S_ISDIR(inode->i_mode)); in fscrypt_prepare_new_inode()
757 if (IS_ENCRYPTED(inode) && S_ISLNK(inode->i_mode)) { in fscrypt_free_inode()
/linux-6.6.21/fs/reiserfs/
Dxattr_acl.c30 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.6.21/fs/proc/
Dfd.c128 if (S_ISLNK(inode->i_mode)) { in tid_fd_update_inode()
129 unsigned i_mode = S_IFLNK; in tid_fd_update_inode() local
131 i_mode |= S_IRUSR | S_IXUSR; in tid_fd_update_inode()
133 i_mode |= S_IWUSR | S_IXUSR; in tid_fd_update_inode()
134 inode->i_mode = i_mode; in tid_fd_update_inode()
358 if (S_ISDIR(inode->i_mode)) { in proc_fd_getattr()
/linux-6.6.21/fs/ntfs3/
Dxattr.c599 if (S_ISLNK(inode->i_mode)) in ntfs_set_acl_ex()
602 mode = inode->i_mode; in ntfs_set_acl_ex()
616 if (!S_ISDIR(inode->i_mode)) in ntfs_set_acl_ex()
647 inode->i_mode = mode; in ntfs_set_acl_ex()
678 err = posix_acl_create(dir, &inode->i_mode, &default_acl, &acl); in ntfs_init_acl()
714 if (S_ISLNK(inode->i_mode)) in ntfs_acl_chmod()
717 return posix_acl_chmod(idmap, dentry, inode->i_mode); in ntfs_acl_chmod()
858 if (S_ISREG(inode->i_mode)) { in ntfs_setxattr()
871 if (S_ISDIR(inode->i_mode)) in ntfs_setxattr()
879 inode->i_mode &= ~0222; in ntfs_setxattr()
[all …]
/linux-6.6.21/fs/nfs/
Dinode.c227 int mode = inode->i_mode; in nfs_zap_caches_locked()
339 inode->i_mode = fattr->mode; in nfs_init_locked()
481 inode->i_mode = fattr->mode; in nfs_fhget()
490 if (S_ISREG(inode->i_mode)) { in nfs_fhget()
494 } else if (S_ISDIR(inode->i_mode)) { in nfs_fhget()
509 } else if (S_ISLNK(inode->i_mode)) { in nfs_fhget()
513 init_special_inode(inode, inode->i_mode, fattr->rdev); in nfs_fhget()
624 BUG_ON(!S_ISREG(inode->i_mode)); in nfs_setattr()
641 if (S_ISREG(inode->i_mode)) in nfs_setattr()
720 inode->i_mode & S_ISUID) in nfs_setattr_update_inode()
[all …]
/linux-6.6.21/fs/adfs/
Dinode.c140 if (S_ISLNK(inode->i_mode)) in adfs_mode2atts()
144 if (S_ISDIR(inode->i_mode)) in adfs_mode2atts()
270 inode->i_mode = adfs_atts2mode(sb, inode); in adfs_iget()
275 if (S_ISDIR(inode->i_mode)) { in adfs_iget()
278 } else if (S_ISREG(inode->i_mode)) { in adfs_iget()
337 inode->i_mode = adfs_atts2mode(sb, inode); in adfs_notify_change()
/linux-6.6.21/fs/ext4/
Dacl.c204 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()
/linux-6.6.21/fs/exfat/
Dfile.c62 mode_t i_mode, mask, perm; in exfat_sanitize_mode() local
64 i_mode = inode->i_mode; in exfat_sanitize_mode()
66 mask = (S_ISREG(i_mode) || S_ISLNK(i_mode)) ? in exfat_sanitize_mode()
71 if ((perm & 0555) != (i_mode & 0555)) in exfat_sanitize_mode()

12345678910>>...19