Home
last modified time | relevance | path

Searched refs:dentry (Results 1 – 25 of 1394) sorted by relevance

12345678910>>...56

/linux/include/linux/
H A Ddcache.h92 struct dentry { struct
97 struct dentry *d_parent; /* parent directory */ argument
153 struct dentry *, unsigned int);
154 int (*d_weak_revalidate)(struct dentry *, unsigned int);
155 int (*d_hash)(const struct dentry *, struct qstr *);
156 int (*d_compare)(const struct dentry *,
158 int (*d_delete)(const struct dentry *);
159 int (*d_init)(struct dentry *);
160 void (*d_release)(struct dentry *);
161 void (*d_prune)(struct dentry *);
[all …]
H A Dfsnotify.h58 static inline void fsnotify_dirent(struct inode *dir, struct dentry *dentry, in fsnotify_dirent() argument
61 fsnotify_name(mask, dentry, FSNOTIFY_EVENT_DENTRY, dir, &dentry->d_name, 0); in fsnotify_dirent()
76 static inline int fsnotify_parent(struct dentry *dentry, __u32 mask, in fsnotify_parent() argument
79 struct inode *inode = d_inode(dentry); in fsnotify_parent()
88 if (!(dentry->d_flags & DCACHE_FSNOTIFY_PARENT_WATCHED)) in fsnotify_parent()
93 if (IS_ROOT(dentry)) in fsnotify_parent()
96 return __fsnotify_parent(dentry, mask, data, data_type); in fsnotify_parent()
106 static inline void fsnotify_dentry(struct dentry *dentry, __u32 mask) in fsnotify_dentry() argument
108 fsnotify_parent(dentry, mask, dentry, FSNOTIFY_EVENT_DENTRY); in fsnotify_dentry()
113 return fsnotify_parent(path->dentry, mask, path, FSNOTIFY_EVENT_PATH); in fsnotify_path()
[all …]
/linux/fs/
H A Ddcache.c126 static inline struct hlist_bl_head *in_lookup_hash(const struct dentry *parent, in in_lookup_hash()
302 static inline int dentry_cmp(const struct dentry *dentry, const unsigned char *ct, unsigned tcount) in dentry_cmp() argument
320 const unsigned char *cs = READ_ONCE(dentry->d_name.name); in dentry_cmp()
337 static inline struct external_name *external_name(struct dentry *dentry) in external_name() argument
339 return container_of(dentry->d_name.name, struct external_name, name[0]); in external_name()
344 struct dentry *dentry = container_of(head, struct dentry, d_u.d_rcu); in __d_free() local
346 kmem_cache_free(dentry_cache, dentry); in __d_free()
351 struct dentry *dentry = container_of(head, struct dentry, d_u.d_rcu); in __d_free_external() local
352 kfree(external_name(dentry)); in __d_free_external()
353 kmem_cache_free(dentry_cache, dentry); in __d_free_external()
[all …]
H A Dlibfs.c37 struct inode *inode = d_inode(path->dentry); in simple_getattr()
44 int simple_statfs(struct dentry *dentry, struct kstatfs *buf) in simple_statfs() argument
46 u64 id = huge_encode_dev(dentry->d_sb->s_dev); in simple_statfs()
49 buf->f_type = dentry->d_sb->s_magic; in simple_statfs()
60 int always_delete_dentry(const struct dentry *dentry) in always_delete_dentry() argument
70 struct dentry *simple_lookup(struct inode *dir, struct dentry *dentry, unsigned int flags) in simple_lookup() argument
72 if (dentry->d_name.len > NAME_MAX) in simple_lookup()
74 if (!dentry->d_op && !(dentry->d_flags & DCACHE_DONTCACHE)) { in simple_lookup()
75 spin_lock(&dentry->d_lock); in simple_lookup()
76 dentry->d_flags |= DCACHE_DONTCACHE; in simple_lookup()
[all …]
H A Dnamei.c705 dget(path->dentry); in path_get()
717 dput(path->dentry); in path_put()
761 p->path.dentry = NULL; in __set_nameidata()
810 static bool path_connected(struct vfsmount *mnt, struct dentry *dentry) in path_connected() argument
818 return is_subdir(dentry, mnt->mnt_root); in path_connected()
856 nd->path.dentry = NULL; in terminate_walk()
866 path->dentry = NULL; in __legitimize_path()
869 if (unlikely(!lockref_get_not_dead(&path->dentry->d_lockref))) { in __legitimize_path()
870 path->dentry = NULL; in __legitimize_path()
873 return !read_seqcount_retry(&path->dentry->d_seq, seq); in __legitimize_path()
[all …]
/linux/fs/overlayfs/
H A Doverlayfs.h206 struct dentry *upperdentry, in ovl_do_notify_change()
213 struct inode *dir, struct dentry *dentry) in ovl_do_rmdir() argument
215 int err = vfs_rmdir(ovl_upper_mnt_idmap(ofs), dir, dentry, NULL); in ovl_do_rmdir()
217 pr_debug("rmdir(%pd2) = %i\n", dentry, err); in ovl_do_rmdir()
222 struct dentry *dentry) in ovl_do_unlink() argument
224 int err = vfs_unlink(ovl_upper_mnt_idmap(ofs), dir, dentry, NULL); in ovl_do_unlink()
226 pr_debug("unlink(%pd2) = %i\n", dentry, err); in ovl_do_unlink()
230 static inline int ovl_do_link(struct ovl_fs *ofs, struct dentry *old_dentry, in ovl_do_link()
231 struct inode *dir, struct dentry *new_dentry) in ovl_do_link()
241 struct inode *dir, struct dentry *dentry, in ovl_do_create() argument
[all …]
H A Dutil.c22 int ovl_get_write_access(struct dentry *dentry) in ovl_get_write_access() argument
24 struct ovl_fs *ofs = OVL_FS(dentry->d_sb); in ovl_get_write_access()
29 void ovl_start_write(struct dentry *dentry) in ovl_start_write() argument
31 struct ovl_fs *ofs = OVL_FS(dentry->d_sb); in ovl_start_write()
35 int ovl_want_write(struct dentry *dentry) in ovl_want_write() argument
37 struct ovl_fs *ofs = OVL_FS(dentry->d_sb); in ovl_want_write()
41 void ovl_put_write_access(struct dentry *dentry) in ovl_put_write_access() argument
43 struct ovl_fs *ofs = OVL_FS(dentry->d_sb); in ovl_put_write_access()
47 void ovl_end_write(struct dentry *dentry) in ovl_end_write() argument
49 struct ovl_fs *ofs = OVL_FS(dentry->d_sb); in ovl_end_write()
[all …]
H A Ddir.c25 static int ovl_set_redirect(struct dentry *dentry, bool samedir);
28 struct dentry *wdentry) in ovl_cleanup_locked()
47 int ovl_cleanup(struct ovl_fs *ofs, struct dentry *workdir, in ovl_cleanup()
48 struct dentry *wdentry) in ovl_cleanup()
68 static struct dentry *ovl_start_creating_temp(struct ovl_fs *ofs, in ovl_start_creating_temp()
69 struct dentry *workdir) in ovl_start_creating_temp()
78 static struct dentry *ovl_whiteout(struct ovl_fs *ofs) in ovl_whiteout()
81 struct dentry *whiteout, *link; in ovl_whiteout()
82 struct dentry *workdir = ofs->workdir; in ovl_whiteout()
122 int ovl_cleanup_and_whiteout(struct ovl_fs *ofs, struct dentry *dir, in ovl_cleanup_and_whiteout()
[all …]
H A Dcopy_up.c47 struct dentry *dentry, const char *acl_name) in ovl_copy_acl() argument
68 err = ovl_do_set_acl(ofs, dentry, acl_name, clone); in ovl_copy_acl()
75 int ovl_copy_xattr(struct super_block *sb, const struct path *oldpath, struct dentry *new) in ovl_copy_xattr()
77 struct dentry *old = oldpath->dentry; in ovl_copy_xattr()
184 old->dentry, err); in ovl_copy_fileattr()
195 err = ovl_set_protattr(inode, new->dentry, &oldfa); in ovl_copy_fileattr()
217 new->dentry, err); in ovl_copy_fileattr()
260 static int ovl_copy_up_file(struct ovl_fs *ofs, struct dentry *dentry, in ovl_copy_up_file() argument
274 ovl_path_lowerdata(dentry, &datapath); in ovl_copy_up_file()
275 if (WARN_ON_ONCE(datapath.dentry == NULL) || in ovl_copy_up_file()
[all …]
H A Dnamei.c20 struct dentry *dentry; member
73 static int ovl_acceptable(void *ctx, struct dentry *dentry) in ovl_acceptable() argument
79 if (!d_is_dir(dentry)) in ovl_acceptable()
83 if (d_unhashed(dentry)) in ovl_acceptable()
87 return is_subdir(dentry, ((struct vfsmount *)ctx)->mnt_root); in ovl_acceptable()
117 static struct ovl_fh *ovl_get_fh(struct ovl_fs *ofs, struct dentry *upperdentry, in ovl_get_fh()
174 struct dentry *ovl_decode_real_fh(struct ovl_fs *ofs, struct ovl_fh *fh, in ovl_decode_real_fh()
177 struct dentry *real; in ovl_decode_real_fh()
211 static struct dentry *ovl_lookup_positive_unlocked(struct ovl_lookup_data *d, in ovl_lookup_positive_unlocked()
213 struct dentry *base, int len, in ovl_lookup_positive_unlocked()
[all …]
/linux/drivers/net/wireless/ti/wl1251/
H A Dwl1251.h146 struct dentry *rootdir;
147 struct dentry *fw_statistics;
149 struct dentry *tx_internal_desc_overflow;
151 struct dentry *rx_out_of_mem;
152 struct dentry *rx_hdr_overflow;
153 struct dentry *rx_hw_stuck;
154 struct dentry *rx_dropped;
155 struct dentry *rx_fcs_err;
156 struct dentry *rx_xfr_hint_trig;
157 struct dentry *rx_path_reset;
[all …]
/linux/fs/autofs/
H A Droot.c15 struct dentry *, const char *);
16 static int autofs_dir_unlink(struct inode *, struct dentry *);
17 static int autofs_dir_rmdir(struct inode *, struct dentry *);
18 static struct dentry *autofs_dir_mkdir(struct mnt_idmap *, struct inode *,
19 struct dentry *, umode_t);
26 static struct dentry *autofs_lookup(struct inode *,
27 struct dentry *, unsigned int);
30 static void autofs_dentry_release(struct dentry *);
67 static void autofs_del_active(struct dentry *dentry) in autofs_del_active() argument
69 struct autofs_sb_info *sbi = autofs_sbi(dentry->d_sb); in autofs_del_active()
[all …]
H A Dexpire.c11 static inline int autofs_can_expire(struct dentry *dentry, in autofs_can_expire() argument
14 struct autofs_info *ino = autofs_dentry_ino(dentry); in autofs_can_expire()
30 struct dentry *dentry, unsigned int how) in autofs_mount_busy() argument
32 struct dentry *top = dentry; in autofs_mount_busy()
33 struct path path = {.mnt = mnt, .dentry = dentry}; in autofs_mount_busy()
36 pr_debug("dentry %p %pd\n", dentry, dentry); in autofs_mount_busy()
43 if (is_autofs_dentry(path.dentry)) { in autofs_mount_busy()
44 struct autofs_sb_info *sbi = autofs_sbi(path.dentry->d_sb); in autofs_mount_busy()
74 static struct dentry *positive_after(struct dentry *p, struct dentry *child) in positive_after()
94 static struct dentry *get_next_positive_subdir(struct dentry *prev, in get_next_positive_subdir()
[all …]
/linux/fs/debugfs/
H A Dinode.c46 struct dentry *dentry, struct iattr *ia) in debugfs_setattr() argument
55 return simple_setattr(&nop_mnt_idmap, dentry, ia); in debugfs_setattr()
198 static int debugfs_show_options(struct seq_file *m, struct dentry *root) in debugfs_show_options()
245 static void debugfs_release_dentry(struct dentry *dentry) in debugfs_release_dentry() argument
247 struct debugfs_fsdata *fsd = dentry->d_fsdata; in debugfs_release_dentry()
258 struct inode *inode = path->dentry->d_inode; in debugfs_automount()
260 return DEBUGFS_I(inode)->automount(path->dentry, inode->i_private); in debugfs_automount()
345 struct dentry *debugfs_lookup(const char *name, struct dentry *parent) in debugfs_lookup()
347 struct dentry *dentry; in debugfs_lookup() local
355 dentry = lookup_noperm_positive_unlocked(&QSTR(name), parent); in debugfs_lookup()
[all …]
/linux/fs/ocfs2/
H A Ddcache.c26 void ocfs2_dentry_attach_gen(struct dentry *dentry) in ocfs2_dentry_attach_gen() argument
29 OCFS2_I(d_inode(dentry->d_parent))->ip_dir_lock_gen; in ocfs2_dentry_attach_gen()
30 BUG_ON(d_inode(dentry)); in ocfs2_dentry_attach_gen()
31 dentry->d_fsdata = (void *)gen; in ocfs2_dentry_attach_gen()
36 struct dentry *dentry, unsigned int flags) in ocfs2_dentry_revalidate() argument
45 inode = d_inode(dentry); in ocfs2_dentry_revalidate()
46 osb = OCFS2_SB(dentry->d_sb); in ocfs2_dentry_revalidate()
48 trace_ocfs2_dentry_revalidate(dentry, name->len, name->name); in ocfs2_dentry_revalidate()
55 unsigned long gen = (unsigned long) dentry->d_fsdata; in ocfs2_dentry_revalidate()
94 if (!dentry->d_fsdata) { in ocfs2_dentry_revalidate()
[all …]
/linux/fs/ecryptfs/
H A Dinode.c27 static struct dentry *ecryptfs_start_creating_dentry(struct dentry *dentry) in ecryptfs_start_creating_dentry() argument
29 struct dentry *parent = dget_parent(dentry); in ecryptfs_start_creating_dentry()
30 struct dentry *ret; in ecryptfs_start_creating_dentry()
33 ecryptfs_dentry_to_lower(dentry)); in ecryptfs_start_creating_dentry()
38 static struct dentry *ecryptfs_start_removing_dentry(struct dentry *dentry) in ecryptfs_start_removing_dentry() argument
40 struct dentry *parent = dget_parent(dentry); in ecryptfs_start_removing_dentry()
41 struct dentry *ret; in ecryptfs_start_removing_dentry()
44 ecryptfs_dentry_to_lower(dentry)); in ecryptfs_start_removing_dentry()
133 static int ecryptfs_interpose(struct dentry *lower_dentry, in ecryptfs_interpose()
134 struct dentry *dentry, struct super_block *sb) in ecryptfs_interpose() argument
[all …]
/linux/fs/9p/
H A Dvfs_dentry.c31 static int v9fs_cached_dentry_delete(const struct dentry *dentry) in v9fs_cached_dentry_delete() argument
34 dentry, dentry); in v9fs_cached_dentry_delete()
37 if (d_really_is_negative(dentry)) in v9fs_cached_dentry_delete()
48 static void v9fs_dentry_release(struct dentry *dentry) in v9fs_dentry_release() argument
54 dentry, dentry); in v9fs_dentry_release()
56 spin_lock(&dentry->d_lock); in v9fs_dentry_release()
57 hlist_move_list((struct hlist_head *)&dentry->d_fsdata, &head); in v9fs_dentry_release()
58 spin_unlock(&dentry->d_lock); in v9fs_dentry_release()
64 static int __v9fs_lookup_revalidate(struct dentry *dentry, unsigned int flags) in __v9fs_lookup_revalidate() argument
73 inode = d_inode(dentry); in __v9fs_lookup_revalidate()
[all …]
H A Dfid.c21 static inline void __add_fid(struct dentry *dentry, struct p9_fid *fid) in __add_fid() argument
23 hlist_add_head(&fid->dlist, (struct hlist_head *)&dentry->d_fsdata); in __add_fid()
33 void v9fs_fid_add(struct dentry *dentry, struct p9_fid **pfid) in v9fs_fid_add() argument
37 spin_lock(&dentry->d_lock); in v9fs_fid_add()
38 __add_fid(dentry, fid); in v9fs_fid_add()
39 spin_unlock(&dentry->d_lock); in v9fs_fid_add()
113 static struct p9_fid *v9fs_fid_find(struct dentry *dentry, kuid_t uid, int any) in v9fs_fid_find() argument
118 dentry, dentry, from_kuid(&init_user_ns, uid), in v9fs_fid_find()
122 if (dentry->d_fsdata) { in v9fs_fid_find()
123 struct hlist_head *h = (struct hlist_head *)&dentry->d_fsdata; in v9fs_fid_find()
[all …]
/linux/fs/ceph/
H A Ddir.c34 static int __dir_lease_try_check(const struct dentry *dentry);
39 static int ceph_d_init(struct dentry *dentry) in ceph_d_init() argument
42 struct ceph_mds_client *mdsc = ceph_sb_to_mdsc(dentry->d_sb); in ceph_d_init()
48 di->dentry = dentry; in ceph_d_init()
51 dentry->d_fsdata = di; in ceph_d_init()
130 static struct dentry *
131 __dcache_find_get_entry(struct dentry *parent, u64 idx, in __dcache_find_get_entry()
136 struct dentry *dentry; in __dcache_find_get_entry() local
137 unsigned idx_mask = (PAGE_SIZE / sizeof(struct dentry *)) - 1; in __dcache_find_get_entry()
138 loff_t ptr_pos = idx * sizeof(struct dentry *); in __dcache_find_get_entry()
[all …]
/linux/security/integrity/evm/
H A Devm_main.c131 static int evm_find_protected_xattrs(struct dentry *dentry) in evm_find_protected_xattrs() argument
133 struct inode *inode = d_backing_inode(dentry); in evm_find_protected_xattrs()
142 error = __vfs_getxattr(dentry, inode, xattr->name, NULL, 0); in evm_find_protected_xattrs()
154 static int is_unsupported_hmac_fs(struct dentry *dentry) in is_unsupported_hmac_fs() argument
156 struct inode *inode = d_backing_inode(dentry); in is_unsupported_hmac_fs()
178 static enum integrity_status evm_verify_hmac(struct dentry *dentry, in evm_verify_hmac() argument
187 struct inode *inode = d_backing_inode(dentry); in evm_verify_hmac()
200 is_unsupported_hmac_fs(dentry)) in evm_verify_hmac()
206 rc = vfs_getxattr_alloc(&nop_mnt_idmap, dentry, XATTR_NAME_EVM, in evm_verify_hmac()
211 rc = evm_find_protected_xattrs(dentry); in evm_verify_hmac()
[all …]
/linux/fs/configfs/
H A Ddir.c45 static void configfs_d_iput(struct dentry * dentry, in configfs_d_iput() argument
48 struct configfs_dirent *sd = dentry->d_fsdata; in configfs_d_iput()
59 if (sd->s_dentry == dentry) in configfs_d_iput()
232 static int configfs_dirent_exists(struct dentry *dentry) in configfs_dirent_exists() argument
234 struct configfs_dirent *parent_sd = dentry->d_parent->d_fsdata; in configfs_dirent_exists()
235 const unsigned char *new = dentry->d_name.name; in configfs_dirent_exists()
253 struct dentry * dentry, void * element, in configfs_make_dirent() argument
263 sd->s_dentry = dentry; in configfs_make_dirent()
264 if (dentry) in configfs_make_dirent()
265 dentry->d_fsdata = configfs_get(sd); in configfs_make_dirent()
[all …]
/linux/fs/tracefs/
H A Dinode.c97 static char *get_dname(struct dentry *dentry) in get_dname() argument
101 int len = dentry->d_name.len; in get_dname()
103 dname = dentry->d_name.name; in get_dname()
112 static struct dentry *tracefs_syscall_mkdir(struct mnt_idmap *idmap, in tracefs_syscall_mkdir()
113 struct inode *inode, struct dentry *dentry, in tracefs_syscall_mkdir() argument
120 name = get_dname(dentry); in tracefs_syscall_mkdir()
147 static int tracefs_syscall_rmdir(struct inode *inode, struct dentry *dentry) in tracefs_syscall_rmdir() argument
152 name = get_dname(dentry); in tracefs_syscall_rmdir()
164 inode_unlock(d_inode(dentry)); in tracefs_syscall_rmdir()
169 inode_lock(d_inode(dentry)); in tracefs_syscall_rmdir()
[all …]
/linux/fs/nfs/
H A Ddir.c59 static int nfs_do_create(struct inode *dir, struct dentry *dentry,
589 .dentry = file_dentry(desc->file), in nfs_readdir_xdr_filler()
641 int nfs_same_file(struct dentry *dentry, struct nfs_entry *entry) in nfs_same_file() argument
646 if (d_really_is_negative(dentry)) in nfs_same_file()
649 inode = d_inode(dentry); in nfs_same_file()
726 void nfs_prime_dcache(struct dentry *parent, struct nfs_entry *entry, in nfs_prime_dcache()
731 struct dentry *dentry; in nfs_prime_dcache() local
732 struct dentry *alias; in nfs_prime_dcache()
756 dentry = d_lookup(parent, &filename); in nfs_prime_dcache()
758 if (!dentry) { in nfs_prime_dcache()
[all …]
H A Dunlink.c49 struct inode *dir = d_inode(data->dentry->d_parent); in nfs_async_unlink_done()
66 struct dentry *dentry = data->dentry; in nfs_async_unlink_release() local
67 struct super_block *sb = dentry->d_sb; in nfs_async_unlink_release()
69 up_read_non_owner(&NFS_I(d_inode(dentry->d_parent))->rmdir_sem); in nfs_async_unlink_release()
70 d_lookup_done(dentry); in nfs_async_unlink_release()
72 dput(dentry); in nfs_async_unlink_release()
79 struct inode *dir = d_inode(data->dentry->d_parent); in nfs_unlink_prepare()
104 struct inode *dir = d_inode(data->dentry->d_parent); in nfs_do_call_unlink()
113 NFS_PROTO(dir)->unlink_setup(&msg, data->dentry, inode); in nfs_do_call_unlink()
121 static int nfs_call_unlink(struct dentry *dentry, struct inode *inode, struct nfs_unlinkdata *data) in nfs_call_unlink() argument
[all …]
/linux/Documentation/translations/zh_CN/filesystems/
H A Ddebugfs.rst41 struct dentry *debugfs_create_dir(const char *name, struct dentry *parent);
44 则会在debugfs根目录中创建。创建目录成功时,返回值是一个指向dentry结构体的指针。
45dentry结构体的指针可用于在目录中创建文件(以及最后将其清理干净)。ERR_PTR
51 struct dentry *debugfs_create_file(const char *name, umode_t mode,
52 struct dentry *parent, void *data,
59dentry指针,错误时返回ERR_PTR(-ERROR),系统不支持debugfs时返回值为ERR_PTR
62 struct dentry *debugfs_create_file_size(const char *name, umode_t mode,
63 struct dentry *parent, void *data,
73 struct dentry *parent, u8 *value);
75 struct dentry *parent, u16 *value);
[all …]

12345678910>>...56