Home
last modified time | relevance | path

Searched refs:mode (Results 1 – 25 of 347) sorted by relevance

12345678910>>...14

/fs/xfs/scrub/
Dinode.c73 uint16_t mode, in xchk_inode_extsize() argument
79 mode, flags); in xchk_inode_extsize()
95 uint16_t mode, in xchk_inode_cowextsize() argument
102 be32_to_cpu(dip->di_cowextsize), mode, flags, in xchk_inode_cowextsize()
114 uint16_t mode, in xchk_inode_flags() argument
137 !S_ISDIR(mode)) in xchk_inode_flags()
142 !S_ISREG(mode)) in xchk_inode_flags()
160 uint16_t mode, in xchk_inode_flags2() argument
178 if ((flags2 & XFS_DIFLAG2_DAX) && !(S_ISREG(mode) || S_ISDIR(mode))) in xchk_inode_flags2()
182 if ((flags2 & XFS_DIFLAG2_REFLINK) && !S_ISREG(mode)) in xchk_inode_flags2()
[all …]
/fs/
Dopen.c238 int vfs_fallocate(struct file *file, int mode, loff_t offset, loff_t len) in vfs_fallocate() argument
247 if (mode & ~FALLOC_FL_SUPPORTED_MASK) in vfs_fallocate()
251 if ((mode & (FALLOC_FL_PUNCH_HOLE | FALLOC_FL_ZERO_RANGE)) == in vfs_fallocate()
256 if ((mode & FALLOC_FL_PUNCH_HOLE) && in vfs_fallocate()
257 !(mode & FALLOC_FL_KEEP_SIZE)) in vfs_fallocate()
261 if ((mode & FALLOC_FL_COLLAPSE_RANGE) && in vfs_fallocate()
262 (mode & ~FALLOC_FL_COLLAPSE_RANGE)) in vfs_fallocate()
266 if ((mode & FALLOC_FL_INSERT_RANGE) && in vfs_fallocate()
267 (mode & ~FALLOC_FL_INSERT_RANGE)) in vfs_fallocate()
271 if ((mode & FALLOC_FL_UNSHARE_RANGE) && in vfs_fallocate()
[all …]
Dposix_acl.c282 umode_t mode = 0; in posix_acl_equiv_mode() local
294 mode |= (pa->e_perm & S_IRWXO) << 6; in posix_acl_equiv_mode()
297 mode |= (pa->e_perm & S_IRWXO) << 3; in posix_acl_equiv_mode()
300 mode |= pa->e_perm & S_IRWXO; in posix_acl_equiv_mode()
303 mode = (mode & ~S_IRWXG) | in posix_acl_equiv_mode()
316 *mode_p = (*mode_p & ~S_IRWXUGO) | mode; in posix_acl_equiv_mode()
325 posix_acl_from_mode(umode_t mode, gfp_t flags) in posix_acl_from_mode() argument
332 acl->a_entries[0].e_perm = (mode & S_IRWXU) >> 6; in posix_acl_from_mode()
335 acl->a_entries[1].e_perm = (mode & S_IRWXG) >> 3; in posix_acl_from_mode()
338 acl->a_entries[2].e_perm = (mode & S_IRWXO); in posix_acl_from_mode()
[all …]
/fs/xfs/
Dxfs_sysctl.c58 .mode = 0644,
67 .mode = 0644,
76 .mode = 0644,
86 .mode = 0644,
95 .mode = 0644,
104 .mode = 0644,
113 .mode = 0644,
122 .mode = 0644,
131 .mode = 0644,
140 .mode = 0644,
[all …]
Dxfs_iops.c91 int mode) in xfs_dentry_mode_to_name() argument
95 namep->type = xfs_mode_to_ftype(mode); in xfs_dentry_mode_to_name()
125 umode_t mode, in xfs_generic_create() argument
139 if (S_ISCHR(mode) || S_ISBLK(mode)) { in xfs_generic_create()
146 error = posix_acl_create(dir, &mode, &default_acl, &acl); in xfs_generic_create()
151 error = xfs_dentry_mode_to_name(&name, dentry, mode); in xfs_generic_create()
156 error = xfs_create(XFS_I(dir), &name, mode, rdev, &ip); in xfs_generic_create()
158 error = xfs_create_tmpfile(XFS_I(dir), mode, &ip); in xfs_generic_create()
219 umode_t mode, in xfs_vn_mknod() argument
222 return xfs_generic_create(dir, dentry, mode, rdev, false); in xfs_vn_mknod()
[all …]
/fs/dlm/
Dast.c28 lkb->lkb_last_bast.mode, in dlm_dump_lkb_callbacks()
36 lkb->lkb_last_cast.mode, in dlm_dump_lkb_callbacks()
45 lkb->lkb_callbacks[i].mode, in dlm_dump_lkb_callbacks()
51 int dlm_add_lkb_callback(struct dlm_lkb *lkb, uint32_t flags, int mode, in dlm_add_lkb_callback() argument
74 prev_mode = lkb->lkb_callbacks[i-1].mode; in dlm_add_lkb_callback()
76 if ((prev_mode == mode) || in dlm_add_lkb_callback()
77 (prev_mode > mode && prev_mode > DLM_LOCK_PR)) { in dlm_add_lkb_callback()
83 mode, in dlm_add_lkb_callback()
93 lkb->lkb_callbacks[i].mode = mode; in dlm_add_lkb_callback()
103 flags, mode, status, sbflags); in dlm_add_lkb_callback()
[all …]
/fs/ramfs/
Dinode.c44 umode_t mode; member
64 const struct inode *dir, umode_t mode, dev_t dev) in ramfs_get_inode() argument
70 inode_init_owner(inode, dir, mode); in ramfs_get_inode()
75 switch (mode & S_IFMT) { in ramfs_get_inode()
77 init_special_inode(inode, mode, dev); in ramfs_get_inode()
104 ramfs_mknod(struct inode *dir, struct dentry *dentry, umode_t mode, dev_t dev) in ramfs_mknod() argument
106 struct inode * inode = ramfs_get_inode(dir->i_sb, dir, mode, dev); in ramfs_mknod()
118 static int ramfs_mkdir(struct inode * dir, struct dentry * dentry, umode_t mode) in ramfs_mkdir() argument
120 int retval = ramfs_mknod(dir, dentry, mode | S_IFDIR, 0); in ramfs_mkdir()
126 static int ramfs_create(struct inode *dir, struct dentry *dentry, umode_t mode, bool excl) in ramfs_create() argument
[all …]
/fs/9p/
Dvfs_inode.c49 static u32 unixmode2p9mode(struct v9fs_session_info *v9ses, umode_t mode) in unixmode2p9mode() argument
52 res = mode & 0777; in unixmode2p9mode()
53 if (S_ISDIR(mode)) in unixmode2p9mode()
57 if (S_ISSOCK(mode)) in unixmode2p9mode()
59 if (S_ISFIFO(mode)) in unixmode2p9mode()
61 if (S_ISBLK(mode)) in unixmode2p9mode()
63 if (S_ISCHR(mode)) in unixmode2p9mode()
67 if ((mode & S_ISUID) == S_ISUID) in unixmode2p9mode()
69 if ((mode & S_ISGID) == S_ISGID) in unixmode2p9mode()
71 if ((mode & S_ISVTX) == S_ISVTX) in unixmode2p9mode()
[all …]
/fs/hostfs/
Dhostfs_user.c24 p->mode = buf->st_mode; in stat64_to_hostfs()
57 int mode = 0; in access_file() local
60 mode = R_OK; in access_file()
62 mode |= W_OK; in access_file()
64 mode |= X_OK; in access_file()
65 if (access(path, mode) != 0) in access_file()
72 int mode = 0, fd; in open_file() local
75 mode = O_RDONLY; in open_file()
77 mode = O_WRONLY; in open_file()
79 mode = O_RDWR; in open_file()
[all …]
Dhostfs_kern.c25 fmode_t mode; member
230 hi->mode = 0; in hostfs_alloc_inode()
302 fmode_t mode; in hostfs_open() local
306 mode = file->f_mode & (FMODE_READ | FMODE_WRITE); in hostfs_open()
307 if ((mode & HOSTFS_I(ino)->mode) == mode) in hostfs_open()
310 mode |= HOSTFS_I(ino)->mode; in hostfs_open()
315 if (mode & FMODE_READ) in hostfs_open()
317 if (mode & FMODE_WRITE) in hostfs_open()
331 if ((mode & HOSTFS_I(ino)->mode) == mode) { in hostfs_open()
336 if ((mode | HOSTFS_I(ino)->mode) != mode) { in hostfs_open()
[all …]
/fs/proc/
Dgeneric.c39 if (S_ISLNK(pde->mode)) in pde_free()
132 de->mode = inode->i_mode; in proc_notify_change()
309 de->low_ino, de->mode >> 12)) { in proc_readdir_de()
377 umode_t mode, in __proc_create() argument
425 ent->mode = mode; in __proc_create()
462 struct proc_dir_entry *proc_mkdir_data(const char *name, umode_t mode, in proc_mkdir_data() argument
467 if (mode == 0) in proc_mkdir_data()
468 mode = S_IRUGO | S_IXUGO; in proc_mkdir_data()
470 ent = __proc_create(&parent, name, S_IFDIR | mode, 2); in proc_mkdir_data()
484 struct proc_dir_entry *proc_mkdir_mode(const char *name, umode_t mode, in proc_mkdir_mode() argument
[all …]
/fs/debugfs/
Dfile.c381 static struct dentry *debugfs_create_mode_unsafe(const char *name, umode_t mode, in debugfs_create_mode_unsafe() argument
388 if (!(mode & S_IWUGO)) in debugfs_create_mode_unsafe()
389 return debugfs_create_file_unsafe(name, mode, parent, value, in debugfs_create_mode_unsafe()
392 if (!(mode & S_IRUGO)) in debugfs_create_mode_unsafe()
393 return debugfs_create_file_unsafe(name, mode, parent, value, in debugfs_create_mode_unsafe()
396 return debugfs_create_file_unsafe(name, mode, parent, value, fops); in debugfs_create_mode_unsafe()
436 struct dentry *debugfs_create_u8(const char *name, umode_t mode, in debugfs_create_u8() argument
439 return debugfs_create_mode_unsafe(name, mode, parent, value, &fops_u8, in debugfs_create_u8()
481 struct dentry *debugfs_create_u16(const char *name, umode_t mode, in debugfs_create_u16() argument
484 return debugfs_create_mode_unsafe(name, mode, parent, value, &fops_u16, in debugfs_create_u16()
[all …]
Dinode.c79 umode_t mode; member
109 opts->mode = DEBUGFS_DEFAULT_MODE; in debugfs_parse_options()
136 opts->mode = option & S_IALLUGO; in debugfs_parse_options()
155 inode->i_mode |= opts->mode; in debugfs_apply_options()
190 if (opts->mode != DEBUGFS_DEFAULT_MODE) in debugfs_show_options()
191 seq_printf(m, ",mode=%o", opts->mode); in debugfs_show_options()
373 static struct dentry *__debugfs_create_file(const char *name, umode_t mode, in __debugfs_create_file() argument
381 if (!(mode & S_IFMT)) in __debugfs_create_file()
382 mode |= S_IFREG; in __debugfs_create_file()
383 BUG_ON(!S_ISREG(mode)); in __debugfs_create_file()
[all …]
/fs/sysfs/
Dgroup.c43 umode_t mode = (*attr)->mode; in create_files() local
53 mode = grp->is_visible(kobj, *attr, i); in create_files()
54 if (!mode) in create_files()
58 WARN(mode & ~(SYSFS_PREALLOC | 0664), in create_files()
60 (*attr)->name, mode); in create_files()
62 mode &= SYSFS_PREALLOC | 0664; in create_files()
64 mode, uid, gid, NULL); in create_files()
76 umode_t mode = (*bin_attr)->attr.mode; in create_files() local
82 mode = grp->is_bin_visible(kobj, *bin_attr, i); in create_files()
83 if (!mode) in create_files()
[all …]
/fs/adfs/
Dinode.c89 umode_t mode, rmask; in adfs_atts2mode() local
93 mode = S_IRUGO & asb->s_owner_mask; in adfs_atts2mode()
94 return S_IFDIR | S_IXUGO | mode; in adfs_atts2mode()
109 mode = S_IFREG; in adfs_atts2mode()
112 mode |= rmask & asb->s_owner_mask; in adfs_atts2mode()
115 mode |= S_IWUGO & asb->s_owner_mask; in adfs_atts2mode()
118 mode |= rmask & asb->s_other_mask; in adfs_atts2mode()
121 mode |= S_IWUGO & asb->s_other_mask; in adfs_atts2mode()
122 return mode; in adfs_atts2mode()
132 umode_t mode; in adfs_mode2atts() local
[all …]
/fs/f2fs/
Dacl.c210 umode_t mode = inode->i_mode; in __f2fs_set_acl() local
216 error = posix_acl_update_mode(inode, &mode, &acl); in __f2fs_set_acl()
219 set_acl_inode(inode, mode); in __f2fs_set_acl()
282 umode_t mode = *mode_p; in f2fs_acl_create_masq() local
290 pa->e_perm &= (mode >> 6) | ~S_IRWXO; in f2fs_acl_create_masq()
291 mode &= (pa->e_perm << 6) | ~S_IRWXU; in f2fs_acl_create_masq()
304 pa->e_perm &= mode | ~S_IRWXO; in f2fs_acl_create_masq()
305 mode &= pa->e_perm | ~S_IRWXO; in f2fs_acl_create_masq()
319 mask_obj->e_perm &= (mode >> 3) | ~S_IRWXO; in f2fs_acl_create_masq()
320 mode &= (mask_obj->e_perm << 3) | ~S_IRWXG; in f2fs_acl_create_masq()
[all …]
/fs/affs/
Damigaffs.c393 umode_t mode = 0; in affs_prot_to_mode() local
396 mode |= 0200; in affs_prot_to_mode()
398 mode |= 0400; in affs_prot_to_mode()
400 mode |= 0100; in affs_prot_to_mode()
402 mode |= 0020; in affs_prot_to_mode()
404 mode |= 0040; in affs_prot_to_mode()
406 mode |= 0010; in affs_prot_to_mode()
408 mode |= 0002; in affs_prot_to_mode()
410 mode |= 0004; in affs_prot_to_mode()
412 mode |= 0001; in affs_prot_to_mode()
[all …]
/fs/crypto/
Dkeysetup.c69 fscrypt_allocate_skcipher(struct fscrypt_mode *mode, const u8 *raw_key, in fscrypt_allocate_skcipher() argument
75 tfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0); in fscrypt_allocate_skcipher()
80 mode->friendly_name, mode->cipher_str); in fscrypt_allocate_skcipher()
84 mode->cipher_str, PTR_ERR(tfm)); in fscrypt_allocate_skcipher()
87 if (!xchg(&mode->logged_impl_name, 1)) { in fscrypt_allocate_skcipher()
95 mode->friendly_name, in fscrypt_allocate_skcipher()
99 err = crypto_skcipher_setkey(tfm, raw_key, mode->keysize); in fscrypt_allocate_skcipher()
162 struct fscrypt_mode *mode = ci->ci_mode; in setup_per_mode_key() local
163 const u8 mode_num = mode - fscrypt_modes; in setup_per_mode_key()
217 mode_key, mode->keysize); in setup_per_mode_key()
[all …]
/fs/hfsplus/
Ddir.c225 u16 mode; in hfsplus_readdir() local
234 mode = be16_to_cpu(entry.file.permissions.mode); in hfsplus_readdir()
235 if (S_ISREG(mode)) in hfsplus_readdir()
237 else if (S_ISLNK(mode)) in hfsplus_readdir()
239 else if (S_ISFIFO(mode)) in hfsplus_readdir()
241 else if (S_ISCHR(mode)) in hfsplus_readdir()
243 else if (S_ISBLK(mode)) in hfsplus_readdir()
245 else if (S_ISSOCK(mode)) in hfsplus_readdir()
480 umode_t mode, dev_t rdev) in hfsplus_mknod() argument
487 inode = hfsplus_new_inode(dir->i_sb, dir, mode); in hfsplus_mknod()
[all …]
/fs/xfs/libxfs/
Dxfs_inode_buf.c448 uint16_t mode; in xfs_dinode_verify() local
474 mode = be16_to_cpu(dip->di_mode); in xfs_dinode_verify()
475 if (mode && xfs_mode_to_ftype(mode) == XFS_DIR3_FT_UNKNOWN) in xfs_dinode_verify()
479 if ((S_ISLNK(mode) || S_ISDIR(mode)) && di_size == 0) in xfs_dinode_verify()
483 if (mode && in xfs_dinode_verify()
488 if (mode && XFS_DFORK_BOFF(dip) > mp->m_sb.sb_inodesize) in xfs_dinode_verify()
493 if (mode && (flags & XFS_DIFLAG_REALTIME) && !mp->m_rtdev_targp) in xfs_dinode_verify()
502 switch (mode & S_IFMT) { in xfs_dinode_verify()
548 mode, flags); in xfs_dinode_verify()
564 if ((flags2 & XFS_DIFLAG2_REFLINK) && (mode & S_IFMT) != S_IFREG) in xfs_dinode_verify()
[all …]
/fs/configfs/
Dinode.c88 umode_t mode = iattr->ia_mode; in configfs_setattr() local
91 mode &= ~S_ISGID; in configfs_setattr()
92 sd_iattr->ia_mode = sd->s_mode = mode; in configfs_setattr()
98 static inline void set_default_inode_attr(struct inode * inode, umode_t mode) in set_default_inode_attr() argument
100 inode->i_mode = mode; in set_default_inode_attr()
115 struct inode *configfs_new_inode(umode_t mode, struct configfs_dirent *sd, in configfs_new_inode() argument
131 set_default_inode_attr(inode, mode); in configfs_new_inode()
167 struct inode *configfs_create(struct dentry *dentry, umode_t mode) in configfs_create() argument
180 inode = configfs_new_inode(mode, sd, dentry->d_sb); in configfs_create()
/fs/devpts/
Dinode.c52 .mode = 0644,
60 .mode = 0644,
68 .mode = 0444,
78 .mode = 0555,
87 .mode = 0555,
98 umode_t mode; member
256 opts->mode = DEVPTS_DEFAULT_MODE; in parse_mount_options()
298 opts->mode = option & S_IALLUGO; in parse_mount_options()
324 int mode; in mknod_ptmx() local
361 mode = S_IFCHR|opts->ptmxmode; in mknod_ptmx()
[all …]
/fs/squashfs/
Dsquashfs_fs.h270 __le16 mode; member
279 __le16 mode; member
289 __le16 mode; member
300 __le16 mode; member
311 __le16 mode; member
323 __le16 mode; member
335 __le16 mode; member
349 __le16 mode; member
366 __le16 mode; member
380 __le16 mode; member
/fs/overlayfs/
Ddir.c117 umode_t mode) in ovl_mkdir_real() argument
122 err = ovl_do_mkdir(dir, dentry, mode); in ovl_mkdir_real()
162 switch (attr->mode & S_IFMT) { in ovl_create_real()
164 err = ovl_do_create(dir, newdentry, attr->mode); in ovl_create_real()
169 err = ovl_mkdir_real(dir, &newdentry, attr->mode); in ovl_create_real()
176 err = ovl_do_mknod(dir, newdentry, attr->mode, in ovl_create_real()
300 attr->mode &= ~current_umask(); in ovl_create_upper()
357 if (!S_ISDIR(stat.mode)) in ovl_clear_empty()
363 opaquedir = ovl_create_temp(workdir, OVL_CATTR(stat.mode)); in ovl_clear_empty()
447 &cattr->mode, &default_acl, &acl); in ovl_create_over_whiteout()
[all …]
Doverlayfs.h114 umode_t mode) in ovl_do_create() argument
116 int err = vfs_create(dir, dentry, mode, true); in ovl_do_create()
118 pr_debug("create(%pd2, 0%o) = %i\n", dentry, mode, err); in ovl_do_create()
123 umode_t mode) in ovl_do_mkdir() argument
125 int err = vfs_mkdir(dir, dentry, mode); in ovl_do_mkdir()
126 pr_debug("mkdir(%pd2, 0%o) = %i\n", dentry, mode, err); in ovl_do_mkdir()
131 umode_t mode, dev_t dev) in ovl_do_mknod() argument
133 int err = vfs_mknod(dir, dentry, mode, dev); in ovl_do_mknod()
135 pr_debug("mknod(%pd2, 0%o, 0%o) = %i\n", dentry, mode, dev, err); in ovl_do_mknod()
186 static inline struct dentry *ovl_do_tmpfile(struct dentry *dentry, umode_t mode) in ovl_do_tmpfile() argument
[all …]

12345678910>>...14