Home
last modified time | relevance | path

Searched refs:S_IFMT (Results 1 – 25 of 99) sorted by relevance

1234

/Linux-v5.4/include/uapi/linux/
Dstat.h9 #define S_IFMT 00170000 macro
21 #define S_ISLNK(m) (((m) & S_IFMT) == S_IFLNK)
22 #define S_ISREG(m) (((m) & S_IFMT) == S_IFREG)
23 #define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
24 #define S_ISCHR(m) (((m) & S_IFMT) == S_IFCHR)
25 #define S_ISBLK(m) (((m) & S_IFMT) == S_IFBLK)
26 #define S_ISFIFO(m) (((m) & S_IFMT) == S_IFIFO)
27 #define S_ISSOCK(m) (((m) & S_IFMT) == S_IFSOCK)
Dgfs2_ondisk.h223 #define DT2IF(dt) (((dt) << 12) & S_IFMT)
224 #define IF2DT(sif) (((sif) & S_IFMT) >> 12)
/Linux-v5.4/tools/include/uapi/linux/
Dstat.h9 #define S_IFMT 00170000 macro
21 #define S_ISLNK(m) (((m) & S_IFMT) == S_IFLNK)
22 #define S_ISREG(m) (((m) & S_IFMT) == S_IFREG)
23 #define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
24 #define S_ISCHR(m) (((m) & S_IFMT) == S_IFCHR)
25 #define S_ISBLK(m) (((m) & S_IFMT) == S_IFBLK)
26 #define S_ISFIFO(m) (((m) & S_IFMT) == S_IFIFO)
27 #define S_ISSOCK(m) (((m) & S_IFMT) == S_IFSOCK)
/Linux-v5.4/include/linux/
Dfs_types.h30 #define S_DT(mode) (((mode) & S_IFMT) >> S_DT_SHIFT)
31 #define S_DT_MASK (S_IFMT >> S_DT_SHIFT)
/Linux-v5.4/samples/vfs/
Dtest-statx.c88 switch (stx->stx_mode & S_IFMT) { in dump_statx()
97 printf(" unknown type (%o)\n", stx->stx_mode & S_IFMT); in dump_statx()
111 switch (stx->stx_mode & S_IFMT) { in dump_statx()
/Linux-v5.4/fs/overlayfs/
Dnamei.c340 ((d_inode(origin)->i_mode ^ d_inode(upperdentry)->i_mode) & S_IFMT)) in ovl_check_origin_fh()
358 upperdentry, d_inode(upperdentry)->i_mode & S_IFMT, in ovl_check_origin_fh()
359 d_inode(origin)->i_mode & S_IFMT); in ovl_check_origin_fh()
587 index, d_inode(index)->i_mode & S_IFMT, err); in ovl_verify_index()
592 index, d_inode(index)->i_mode & S_IFMT, in ovl_verify_index()
716 ((inode->i_mode ^ d_inode(origin)->i_mode) & S_IFMT)) { in ovl_lookup_index()
725 index, d_inode(index)->i_mode & S_IFMT, in ovl_lookup_index()
726 d_inode(origin)->i_mode & S_IFMT); in ovl_lookup_index()
/Linux-v5.4/fs/erofs/
Dinode.c39 switch (inode->i_mode & S_IFMT) { in erofs_read_inode()
78 switch (inode->i_mode & S_IFMT) { in erofs_read_inode()
203 switch (inode->i_mode & S_IFMT) { in erofs_fill_inode()
/Linux-v5.4/fs/nfsd/
Dnfsproc.c303 type = attr->ia_mode & S_IFMT; in nfsd_proc_create()
304 mode = attr->ia_mode & ~S_IFMT; in nfsd_proc_create()
309 type = inode->i_mode & S_IFMT; in nfsd_proc_create()
335 type = inode->i_mode & S_IFMT; in nfsd_proc_create()
336 mode = inode->i_mode & ~S_IFMT; in nfsd_proc_create()
365 if (inode && type != (inode->i_mode & S_IFMT)) in nfsd_proc_create()
/Linux-v5.4/fs/9p/
Dvfs_inode.c261 switch (mode & S_IFMT) { in v9fs_init_inode()
333 mode, mode & S_IFMT); in v9fs_init_inode()
455 if ((inode->i_mode & S_IFMT) != (umode & S_IFMT)) in v9fs_test_inode()
1412 if ((inode->i_mode & S_IFMT) != (umode & S_IFMT)) in v9fs_refresh_inode()
Dvfs_inode_dotl.c62 if ((inode->i_mode & S_IFMT) != (st->st_mode & S_IFMT)) in v9fs_test_inode_dotl()
931 if ((inode->i_mode & S_IFMT) != (st->st_mode & S_IFMT)) in v9fs_refresh_inode_dotl()
/Linux-v5.4/fs/efivarfs/
Dinode.c26 switch (mode & S_IFMT) { in efivarfs_get_inode()
/Linux-v5.4/security/tomoyo/
Dtomoyo.c226 switch (mode & S_IFMT) { in tomoyo_path_mknod()
238 switch (mode & S_IFMT) { in tomoyo_path_mknod()
/Linux-v5.4/fs/xfs/
Dxfs_symlink.c238 error = xfs_dir_ialloc(&tp, dp, S_IFLNK | (mode & ~S_IFMT), 1, 0, in xfs_symlink()
420 VFS_I(ip)->i_mode = (VFS_I(ip)->i_mode & ~S_IFMT) | S_IFREG; in xfs_inactive_symlink_rmt()
Dxfs_iops.c539 switch (inode->i_mode & S_IFMT) { in xfs_vn_getattr()
573 inode->i_mode &= S_IFMT; in xfs_setattr_mode()
574 inode->i_mode |= mode & ~S_IFMT; in xfs_setattr_mode()
1323 switch (inode->i_mode & S_IFMT) { in xfs_setup_iops()
/Linux-v5.4/fs/cifs/
Dinode.c44 switch (inode->i_mode & S_IFMT) {
249 fattr->cf_mode &= ~S_IFMT;
423 if (unlikely(((*pinode)->i_mode & S_IFMT) !=
424 (fattr.cf_mode & S_IFMT))) {
455 fattr->cf_mode &= ~S_IFMT;
944 if (unlikely(((*inode)->i_mode & S_IFMT) !=
945 (fattr.cf_mode & S_IFMT))) {
981 if ((inode->i_mode & S_IFMT) != (fattr->cf_mode & S_IFMT))
Dreaddir.c120 (inode->i_mode & S_IFMT) == in cifs_prime_dcache()
121 (fattr->cf_mode & S_IFMT)) { in cifs_prime_dcache()
183 fattr->cf_mode &= ~S_IFMT; in cifs_fill_common_info()
/Linux-v5.4/fs/nfs/
Dexport.c54 p[FILE_I_TYPE_OFF] = inode->i_mode & S_IFMT; in nfs_encode_fh()
Dinode.c313 if ((S_IFMT & inode->i_mode) != (S_IFMT & fattr->mode)) in nfs_find_actor()
1418 if ((fattr->valid & NFS_ATTR_FATTR_TYPE) && (inode->i_mode & S_IFMT) != (fattr->mode & S_IFMT)) in nfs_check_inode_attributes()
1832 if ((fattr->valid & NFS_ATTR_FATTR_TYPE) && (inode->i_mode & S_IFMT) != (fattr->mode & S_IFMT)) { in nfs_update_inode()
1959 umode_t newmode = inode->i_mode & S_IFMT; in nfs_update_inode()
/Linux-v5.4/fs/tracefs/
Dinode.c397 if (!(mode & S_IFMT)) in tracefs_create_file()
509 switch (dentry->d_inode->i_mode & S_IFMT) { in __tracefs_remove()
/Linux-v5.4/security/
Dinode.c116 if (!(mode & S_IFMT)) in securityfs_create_dentry()
/Linux-v5.4/fs/coda/
Ddir.c543 if ((old_mode & S_IFMT) != (inode->i_mode & S_IFMT)) { in coda_revalidate_inode()
/Linux-v5.4/fs/fuse/
Ddir.c251 if (ret || (outarg.attr.mode ^ inode->i_mode) & S_IFMT) in fuse_dentry_revalidate()
440 BUG_ON((mode & S_IFMT) != S_IFREG); in fuse_create_open()
589 if ((outarg.attr.mode ^ mode) & S_IFMT) in create_new_entry()
892 stat->mode = (inode->i_mode & S_IFMT) | (attr->mode & 07777); in fuse_fillattr()
945 if ((inode->i_mode ^ outarg.attr.mode) & S_IFMT) { in fuse_do_getattr()
1566 if ((inode->i_mode ^ outarg.attr.mode) & S_IFMT) { in fuse_do_setattr()
/Linux-v5.4/fs/fat/
Dfile.c438 perm = *mode_ptr & ~(S_IFMT | mask); in fat_sanitize_mode()
456 *mode_ptr &= S_IFMT | perm; in fat_sanitize_mode()
/Linux-v5.4/fs/ramfs/
Dinode.c75 switch (mode & S_IFMT) { in ramfs_get_inode()
/Linux-v5.4/fs/jffs2/
Ddir.c260 type = (d_inode(old_dentry)->i_mode & S_IFMT) >> 12; in jffs2_link()
719 rd->type = (mode & S_IFMT) >> 12; in jffs2_mknod()
797 type = (d_inode(old_dentry)->i_mode & S_IFMT) >> 12; in jffs2_rename()

1234