Home
last modified time | relevance | path

Searched refs:dent (Results 1 – 14 of 14) sorted by relevance

/fs/gfs2/
Ddir.c87 typedef int (*gfs2_dscan_t)(const struct gfs2_dirent *dent,
391 static inline int gfs2_dirent_sentinel(const struct gfs2_dirent *dent) in gfs2_dirent_sentinel() argument
393 return dent->de_inum.no_addr == 0 || dent->de_inum.no_formal_ino == 0; in gfs2_dirent_sentinel()
396 static inline int __gfs2_dirent_find(const struct gfs2_dirent *dent, in __gfs2_dirent_find() argument
399 if (!gfs2_dirent_sentinel(dent) && in __gfs2_dirent_find()
400 be32_to_cpu(dent->de_hash) == name->hash && in __gfs2_dirent_find()
401 be16_to_cpu(dent->de_name_len) == name->len && in __gfs2_dirent_find()
402 memcmp(dent+1, name->name, name->len) == 0) in __gfs2_dirent_find()
407 static int gfs2_dirent_find(const struct gfs2_dirent *dent, in gfs2_dirent_find() argument
411 return __gfs2_dirent_find(dent, name, 1); in gfs2_dirent_find()
[all …]
Ddir.h54 static inline void gfs2_qstr2dirent(const struct qstr *name, u16 reclen, struct gfs2_dirent *dent) in gfs2_qstr2dirent() argument
56 dent->de_inum.no_addr = cpu_to_be64(0); in gfs2_qstr2dirent()
57 dent->de_inum.no_formal_ino = cpu_to_be64(0); in gfs2_qstr2dirent()
58 dent->de_hash = cpu_to_be32(name->hash); in gfs2_qstr2dirent()
59 dent->de_rec_len = cpu_to_be16(reclen); in gfs2_qstr2dirent()
60 dent->de_name_len = cpu_to_be16(name->len); in gfs2_qstr2dirent()
61 dent->de_type = cpu_to_be16(0); in gfs2_qstr2dirent()
62 memset(dent->__pad, 0, sizeof(dent->__pad)); in gfs2_qstr2dirent()
63 memcpy(dent + 1, name->name, name->len); in gfs2_qstr2dirent()
Dinode.h79 struct gfs2_dirent *dent) in gfs2_inum_out() argument
81 dent->de_inum.no_formal_ino = cpu_to_be64(ip->i_no_formal_ino); in gfs2_inum_out()
82 dent->de_inum.no_addr = cpu_to_be64(ip->i_no_addr); in gfs2_inum_out()
Dinode.c416 struct gfs2_dirent *dent = (struct gfs2_dirent *)(di+1); in gfs2_init_dir() local
418 gfs2_qstr2dirent(&gfs2_qdot, GFS2_DIRENT_SIZE(gfs2_qdot.len), dent); in gfs2_init_dir()
419 dent->de_inum = di->di_num; /* already GFS2 endian */ in gfs2_init_dir()
420 dent->de_type = cpu_to_be16(DT_DIR); in gfs2_init_dir()
422 dent = (struct gfs2_dirent *)((char*)dent + GFS2_DIRENT_SIZE(1)); in gfs2_init_dir()
423 …_qstr2dirent(&gfs2_qdotdot, dibh->b_size - GFS2_DIRENT_SIZE(1) - sizeof(struct gfs2_dinode), dent); in gfs2_init_dir()
424 gfs2_inum_out(parent, dent); in gfs2_init_dir()
425 dent->de_type = cpu_to_be16(DT_DIR); in gfs2_init_dir()
/fs/9p/
Dfid.c46 struct v9fs_dentry *dent; in v9fs_fid_add() local
51 dent = dentry->d_fsdata; in v9fs_fid_add()
52 if (!dent) { in v9fs_fid_add()
53 dent = kmalloc(sizeof(struct v9fs_dentry), GFP_KERNEL); in v9fs_fid_add()
54 if (!dent) in v9fs_fid_add()
57 spin_lock_init(&dent->lock); in v9fs_fid_add()
58 INIT_LIST_HEAD(&dent->fidlist); in v9fs_fid_add()
59 dentry->d_fsdata = dent; in v9fs_fid_add()
62 spin_lock(&dent->lock); in v9fs_fid_add()
63 list_add(&fid->dlist, &dent->fidlist); in v9fs_fid_add()
[all …]
Dvfs_dentry.c86 struct v9fs_dentry *dent; in v9fs_dentry_release() local
91 dent = dentry->d_fsdata; in v9fs_dentry_release()
92 if (dent) { in v9fs_dentry_release()
93 list_for_each_entry_safe(current_fid, temp, &dent->fidlist, in v9fs_dentry_release()
98 kfree(dent); in v9fs_dentry_release()
/fs/ubifs/
Ddebug.c240 struct ubifs_dent_node *dent, *pdent = NULL; in dbg_dump_inode() local
284 dent = ubifs_tnc_next_ent(c, &key, &nm); in dbg_dump_inode()
285 if (IS_ERR(dent)) { in dbg_dump_inode()
286 if (PTR_ERR(dent) != -ENOENT) in dbg_dump_inode()
287 printk(KERN_ERR "error %ld\n", PTR_ERR(dent)); in dbg_dump_inode()
292 count++, dent->name, get_dent_type(dent->type)); in dbg_dump_inode()
294 nm.name = dent->name; in dbg_dump_inode()
295 nm.len = le16_to_cpu(dent->nlen); in dbg_dump_inode()
297 pdent = dent; in dbg_dump_inode()
298 key_read(c, &dent->key, &key); in dbg_dump_inode()
[all …]
Ddir.c176 const struct ubifs_dent_node *dent, in dbg_check_name() argument
181 if (le16_to_cpu(dent->nlen) != nm->len) in dbg_check_name()
183 if (memcmp(dent->name, nm->name, nm->len)) in dbg_check_name()
190 #define dbg_check_name(c, dent, nm) 0 argument
200 struct ubifs_dent_node *dent; in ubifs_lookup() local
209 dent = kmalloc(UBIFS_MAX_DENT_NODE_SZ, GFP_NOFS); in ubifs_lookup()
210 if (!dent) in ubifs_lookup()
215 err = ubifs_tnc_lookup_nm(c, &key, dent, &dentry->d_name); in ubifs_lookup()
224 if (dbg_check_name(c, dent, &dentry->d_name)) { in ubifs_lookup()
229 inode = ubifs_iget(dir->i_sb, le64_to_cpu(dent->inum)); in ubifs_lookup()
[all …]
Djournal.c78 static inline void zero_dent_node_unused(struct ubifs_dent_node *dent) in zero_dent_node_unused() argument
80 dent->padding1 = 0; in zero_dent_node_unused()
81 memset(dent->padding2, 0, 4); in zero_dent_node_unused()
550 struct ubifs_dent_node *dent; in ubifs_jnl_update() local
576 dent = kmalloc(len, GFP_NOFS); in ubifs_jnl_update()
577 if (!dent) in ubifs_jnl_update()
586 dent->ch.node_type = UBIFS_DENT_NODE; in ubifs_jnl_update()
589 dent->ch.node_type = UBIFS_XENT_NODE; in ubifs_jnl_update()
593 key_write(c, &dent_key, dent->key); in ubifs_jnl_update()
594 dent->inum = deletion ? 0 : cpu_to_le64(inode->i_ino); in ubifs_jnl_update()
[all …]
Dreplay.c452 const struct ubifs_dent_node *dent) in ubifs_validate_entry() argument
454 int key_type = key_type_flash(c, dent->key); in ubifs_validate_entry()
455 int nlen = le16_to_cpu(dent->nlen); in ubifs_validate_entry()
457 if (le32_to_cpu(dent->ch.len) != nlen + UBIFS_DENT_NODE_SZ + 1 || in ubifs_validate_entry()
458 dent->type >= UBIFS_ITYPES_CNT || in ubifs_validate_entry()
459 nlen > UBIFS_MAX_NLEN || dent->name[nlen] != 0 || in ubifs_validate_entry()
460 strnlen(dent->name, nlen) != nlen || in ubifs_validate_entry()
461 le64_to_cpu(dent->inum) > MAX_INUM) { in ubifs_validate_entry()
628 struct ubifs_dent_node *dent = snod->node; in replay_bud() local
630 err = ubifs_validate_entry(c, dent); in replay_bud()
[all …]
Dtnc.c334 const struct ubifs_dent_node *dent = node; in lnc_add() local
340 err = ubifs_validate_entry(c, dent); in lnc_add()
343 dbg_dump_node(c, dent); in lnc_add()
514 struct ubifs_dent_node *dent = node; in fallible_read_node() local
517 key_read(c, &dent->key, &node_key); in fallible_read_node()
541 struct ubifs_dent_node *dent; in matches_name() local
546 dent = kmalloc(zbr->len, GFP_NOFS); in matches_name()
547 if (!dent) in matches_name()
550 err = ubifs_tnc_read_node(c, zbr, dent); in matches_name()
555 err = lnc_add_directly(c, zbr, dent); in matches_name()
[all …]
Dubifs.h1651 const struct ubifs_dent_node *dent);
/fs/ntfs/
Dnamei.c103 static struct dentry *ntfs_lookup(struct inode *dir_ino, struct dentry *dent, in ntfs_lookup() argument
115 dent->d_name.name, dir_ino->i_ino); in ntfs_lookup()
117 uname_len = ntfs_nlstoucs(vol, dent->d_name.name, dent->d_name.len, in ntfs_lookup()
140 return d_splice_alias(dent_inode, dent); in ntfs_lookup()
168 d_add(dent, NULL); in ntfs_lookup()
258 dent = d_add_ci(dent, dent_inode, &nls_name); in ntfs_lookup()
260 return dent; in ntfs_lookup()
/fs/ncpfs/
Ddir.c375 struct dentry *dent = dentry; in ncp_dget_fpos() local
378 if (d_validate(dent, parent)) { in ncp_dget_fpos()
379 if (dent->d_name.len <= NCP_MAXPATHLEN && in ncp_dget_fpos()
380 (unsigned long)dent->d_fsdata == fpos) { in ncp_dget_fpos()
381 if (!dent->d_inode) { in ncp_dget_fpos()
382 dput(dent); in ncp_dget_fpos()
383 dent = NULL; in ncp_dget_fpos()
385 return dent; in ncp_dget_fpos()
387 dput(dent); in ncp_dget_fpos()
394 dent = list_entry(next, struct dentry, d_u.d_child); in ncp_dget_fpos()
[all …]