/fs/kernfs/ |
D | dir.c | 47 return strlcpy(buf, kn->parent ? kn->name : "/", buflen); in kernfs_name_locked() 55 while (to->parent && to != from) { in kernfs_depth() 57 to = to->parent; in kernfs_depth() 75 a = a->parent; in kernfs_common_ancestor() 79 b = b->parent; in kernfs_common_ancestor() 85 b = b->parent; in kernfs_common_ancestor() 86 a = a->parent; in kernfs_common_ancestor() 159 kn = kn->parent; in kernfs_path_from_node_locked() 281 struct kernfs_node *parent; in kernfs_get_parent() local 285 parent = kn->parent; in kernfs_get_parent() [all …]
|
D | symlink.c | 25 struct kernfs_node *kernfs_create_link(struct kernfs_node *parent, in kernfs_create_link() argument 39 kn = kernfs_new_node(parent, name, S_IFLNK|S_IRWXUGO, uid, gid, in kernfs_create_link() 44 if (kernfs_ns_enabled(parent)) in kernfs_create_link() 57 static int kernfs_get_target_path(struct kernfs_node *parent, in kernfs_get_target_path() argument 65 base = parent; in kernfs_get_target_path() 66 while (base->parent) { in kernfs_get_target_path() 67 kn = target->parent; in kernfs_get_target_path() 68 while (kn->parent && base != kn) in kernfs_get_target_path() 69 kn = kn->parent; in kernfs_get_target_path() 79 base = base->parent; in kernfs_get_target_path() [all …]
|
/fs/debugfs/ |
D | inode.c | 292 struct dentry *debugfs_lookup(const char *name, struct dentry *parent) in debugfs_lookup() argument 296 if (IS_ERR(parent)) in debugfs_lookup() 299 if (!parent) in debugfs_lookup() 300 parent = debugfs_mount->mnt_root; in debugfs_lookup() 302 dentry = lookup_one_len_unlocked(name, parent, strlen(name)); in debugfs_lookup() 313 static struct dentry *start_creating(const char *name, struct dentry *parent) in start_creating() argument 320 if (IS_ERR(parent)) in start_creating() 321 return parent; in start_creating() 335 if (!parent) in start_creating() 336 parent = debugfs_mount->mnt_root; in start_creating() [all …]
|
D | file.c | 382 struct dentry *parent, void *value, in debugfs_create_mode_unsafe() argument 389 return debugfs_create_file_unsafe(name, mode, parent, value, 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() 437 struct dentry *parent, u8 *value) in debugfs_create_u8() argument 439 return debugfs_create_mode_unsafe(name, mode, parent, value, &fops_u8, in debugfs_create_u8() 482 struct dentry *parent, u16 *value) in debugfs_create_u16() argument 484 return debugfs_create_mode_unsafe(name, mode, parent, value, &fops_u16, in debugfs_create_u16() 527 struct dentry *parent, u32 *value) in debugfs_create_u32() argument 529 return debugfs_create_mode_unsafe(name, mode, parent, value, &fops_u32, in debugfs_create_u32() [all …]
|
/fs/sysfs/ |
D | group.c | 19 static void remove_files(struct kernfs_node *parent, in remove_files() argument 27 kernfs_remove_by_name(parent, (*attr)->name); in remove_files() 30 kernfs_remove_by_name(parent, (*bin_attr)->attr.name); in remove_files() 33 static int create_files(struct kernfs_node *parent, struct kobject *kobj, in create_files() argument 51 kernfs_remove_by_name(parent, (*attr)->name); in create_files() 63 error = sysfs_add_file_mode_ns(parent, *attr, false, in create_files() 69 remove_files(parent, grp); in create_files() 79 kernfs_remove_by_name(parent, in create_files() 92 error = sysfs_add_file_mode_ns(parent, in create_files() 100 remove_files(parent, grp); in create_files() [all …]
|
D | dir.c | 21 void sysfs_warn_dup(struct kernfs_node *parent, const char *name) in sysfs_warn_dup() argument 27 kernfs_path(parent, buf, PATH_MAX); in sysfs_warn_dup() 42 struct kernfs_node *parent, *kn; in sysfs_create_dir_ns() local 49 if (kobj->parent) in sysfs_create_dir_ns() 50 parent = kobj->parent->sd; in sysfs_create_dir_ns() 52 parent = sysfs_root_kn; in sysfs_create_dir_ns() 54 if (!parent) in sysfs_create_dir_ns() 59 kn = kernfs_create_dir_ns(parent, kobject_name(kobj), in sysfs_create_dir_ns() 64 sysfs_warn_dup(parent, kobject_name(kobj)); in sysfs_create_dir_ns() 109 struct kernfs_node *parent; in sysfs_rename_dir_ns() local [all …]
|
D | symlink.c | 20 static int sysfs_do_create_link_sd(struct kernfs_node *parent, in sysfs_do_create_link_sd() argument 26 if (WARN_ON(!name || !parent)) in sysfs_do_create_link_sd() 44 kn = kernfs_create_link(parent, name, target); in sysfs_do_create_link_sd() 51 sysfs_warn_dup(parent, name); in sysfs_do_create_link_sd() 70 struct kernfs_node *parent = NULL; in sysfs_do_create_link() local 73 parent = sysfs_root_kn; in sysfs_do_create_link() 75 parent = kobj->sd; in sysfs_do_create_link() 77 if (!parent) in sysfs_do_create_link() 80 return sysfs_do_create_link_sd(parent, target, name, warn); in sysfs_do_create_link() 145 struct kernfs_node *parent = NULL; in sysfs_remove_link() local [all …]
|
D | file.c | 27 struct kobject *kobj = kn->parent->priv; in sysfs_file_ops() 42 struct kobject *kobj = of->kn->parent->priv; in sysfs_kf_seq_show() 83 struct kobject *kobj = of->kn->parent->priv; in sysfs_kf_bin_read() 107 struct kobject *kobj = of->kn->parent->priv; in sysfs_kf_read() 133 struct kobject *kobj = of->kn->parent->priv; in sysfs_kf_write() 146 struct kobject *kobj = of->kn->parent->priv; in sysfs_kf_bin_write() 167 struct kobject *kobj = of->kn->parent->priv; in sysfs_kf_bin_mmap() 245 int sysfs_add_file_mode_ns(struct kernfs_node *parent, in sysfs_add_file_mode_ns() argument 255 struct kobject *kobj = parent->priv; in sysfs_add_file_mode_ns() 305 kn = __kernfs_create_file(parent, attr->name, mode & 0777, uid, gid, in sysfs_add_file_mode_ns() [all …]
|
/fs/tracefs/ |
D | inode.c | 312 static struct dentry *start_creating(const char *name, struct dentry *parent) in start_creating() argument 329 if (!parent) in start_creating() 330 parent = tracefs_mount->mnt_root; in start_creating() 332 inode_lock(parent->d_inode); in start_creating() 333 dentry = lookup_one_len(name, parent, strlen(name)); in start_creating() 340 inode_unlock(parent->d_inode); in start_creating() 388 struct dentry *parent, void *data, in tracefs_create_file() argument 400 dentry = start_creating(name, parent); in tracefs_create_file() 417 static struct dentry *__create_dir(const char *name, struct dentry *parent, in __create_dir() argument 420 struct dentry *dentry = start_creating(name, parent); in __create_dir() [all …]
|
/fs/proc/ |
D | generic.c | 94 struct rb_node **new = &root->rb_node, *parent = NULL; in pde_subdir_insert() local 103 parent = *new; in pde_subdir_insert() 113 rb_link_node(&de->subdir_node, parent, new); in pde_subdir_insert() 358 dp->parent = dir; in proc_register() 375 static struct proc_dir_entry *__proc_create(struct proc_dir_entry **parent, in __proc_create() argument 384 if (xlate_proc_name(name, parent, &fn) != 0) in __proc_create() 400 if (*parent == &proc_root && name_to_int(&qstr) != ~0U) { in __proc_create() 404 if (is_empty_pde(*parent)) { in __proc_create() 431 proc_set_user(ent, (*parent)->uid, (*parent)->gid); in __proc_create() 440 struct proc_dir_entry *parent, const char *dest) in proc_symlink() argument [all …]
|
D | proc_net.c | 34 return pde->parent->data; in PDE_NET() 102 struct proc_dir_entry *parent, const struct seq_operations *ops, in proc_create_net_data() argument 107 p = proc_create_reg(name, mode, &parent, data); in proc_create_net_data() 114 return proc_register(parent, p); in proc_create_net_data() 144 struct proc_dir_entry *parent, in proc_create_net_data_write() argument 151 p = proc_create_reg(name, mode, &parent, data); in proc_create_net_data_write() 159 return proc_register(parent, p); in proc_create_net_data_write() 195 struct proc_dir_entry *parent, in proc_create_net_single() argument 200 p = proc_create_reg(name, mode, &parent, data); in proc_create_net_single() 206 return proc_register(parent, p); in proc_create_net_single() [all …]
|
/fs/exportfs/ |
D | expfs.c | 78 struct dentry *parent = dget_parent(dentry); in dentry_connected() local 81 if (dentry == parent) { in dentry_connected() 82 dput(parent); in dentry_connected() 85 dentry = parent; in dentry_connected() 95 struct dentry *parent = dget_parent(dentry); in clear_disconnected() local 104 dentry = parent; in clear_disconnected() 124 struct dentry *parent; in reconnect_one() local 128 parent = ERR_PTR(-EACCES); in reconnect_one() 131 parent = mnt->mnt_sb->s_export_op->get_parent(dentry); in reconnect_one() 134 if (IS_ERR(parent)) { in reconnect_one() [all …]
|
/fs/hfs/ |
D | brec.c | 147 if (!new_node->parent) { in hfs_brec_insert() 149 new_node->parent = tree->root; in hfs_brec_insert() 151 fd->bnode = hfs_bnode_find(tree, new_node->parent); in hfs_brec_insert() 180 struct hfs_bnode *node, *parent; in hfs_brec_remove() local 198 if (!node->parent) in hfs_brec_remove() 200 parent = hfs_bnode_find(tree, node->parent); in hfs_brec_remove() 201 if (IS_ERR(parent)) in hfs_brec_remove() 202 return PTR_ERR(parent); in hfs_brec_remove() 204 node = fd->bnode = parent; in hfs_brec_remove() 249 new_node->parent = node->parent; in hfs_bnode_split() [all …]
|
/fs/hfsplus/ |
D | brec.c | 147 if (!new_node->parent) { in hfs_brec_insert() 149 new_node->parent = tree->root; in hfs_brec_insert() 151 fd->bnode = hfs_bnode_find(tree, new_node->parent); in hfs_brec_insert() 182 struct hfs_bnode *node, *parent; in hfs_brec_remove() local 200 if (!node->parent) in hfs_brec_remove() 202 parent = hfs_bnode_find(tree, node->parent); in hfs_brec_remove() 203 if (IS_ERR(parent)) in hfs_brec_remove() 204 return PTR_ERR(parent); in hfs_brec_remove() 206 node = fd->bnode = parent; in hfs_brec_remove() 253 new_node->parent = node->parent; in hfs_bnode_split() [all …]
|
/fs/fscache/ |
D | object.c | 151 struct fscache_object *parent = object->parent; in fscache_done_parent_op() local 154 object->debug_id, parent->debug_id, parent->n_ops); in fscache_done_parent_op() 156 spin_lock_nested(&parent->lock, 1); in fscache_done_parent_op() 157 parent->n_obj_ops--; in fscache_done_parent_op() 158 parent->n_ops--; in fscache_done_parent_op() 159 if (parent->n_ops == 0) in fscache_done_parent_op() 160 fscache_raise_event(parent, FSCACHE_OBJECT_EV_CLEARED); in fscache_done_parent_op() 161 spin_unlock(&parent->lock); in fscache_done_parent_op() 327 object->parent = NULL; in fscache_object_init() 375 struct fscache_object *parent; in fscache_initialise_object() local [all …]
|
D | cookie.c | 37 prefix, cookie, cookie->parent, cookie->flags, in fscache_print_cookie() 98 h = (unsigned long)cookie->parent; in fscache_set_key() 115 if (a->parent != b->parent) in fscache_compare_cookie() 116 return (long)a->parent - (long)b->parent; in fscache_compare_cookie() 136 struct fscache_cookie *parent, in fscache_alloc_cookie() argument 173 cookie->parent = parent; in fscache_alloc_cookie() 212 fscache_cookie_get(candidate->parent, fscache_cookie_get_acquire_parent); in fscache_hash_cookie() 213 atomic_inc(&candidate->parent->n_children); in fscache_hash_cookie() 250 struct fscache_cookie *parent, in __fscache_acquire_cookie() argument 263 parent ? (char *) parent->def->name : "<no-parent>", in __fscache_acquire_cookie() [all …]
|
/fs/ocfs2/ |
D | export.c | 135 struct dentry *parent; in ocfs2_get_parent() local 145 parent = ERR_PTR(status); in ocfs2_get_parent() 153 parent = ERR_PTR(status); in ocfs2_get_parent() 159 parent = ERR_PTR(-ENOENT); in ocfs2_get_parent() 169 parent = ERR_PTR(status); in ocfs2_get_parent() 176 parent = ERR_PTR(status); in ocfs2_get_parent() 180 parent = d_obtain_alias(ocfs2_iget(OCFS2_SB(dir->i_sb), blkno, 0, 0)); in ocfs2_get_parent() 189 trace_ocfs2_get_parent_end(parent); in ocfs2_get_parent() 191 return parent; in ocfs2_get_parent() 195 struct inode *parent) in ocfs2_encode_fh() argument [all …]
|
/fs/ |
D | pnode.c | 246 struct mount *parent = last_source->mnt_parent; in propagate_one() local 249 done = parent->mnt_master == p; in propagate_one() 250 if (done && peers(n, parent)) in propagate_one() 373 struct mount *parent = mnt->mnt_parent; in propagate_mount_busy() local 375 if (mnt == parent) in propagate_mount_busy() 386 for (m = propagation_next(parent, parent); m; in propagate_mount_busy() 387 m = propagation_next(m, parent)) { in propagate_mount_busy() 415 struct mount *parent = mnt->mnt_parent; in propagate_mount_unlock() local 418 BUG_ON(parent == mnt); in propagate_mount_unlock() 420 for (m = propagation_next(parent, parent); m; in propagate_mount_unlock() [all …]
|
D | dcache.c | 109 static inline struct hlist_bl_head *in_lookup_hash(const struct dentry *parent, in in_lookup_hash() argument 112 hash += (unsigned long) parent / L1_CACHE_BYTES; in in_lookup_hash() 512 static inline void dentry_unlist(struct dentry *dentry, struct dentry *parent) in dentry_unlist() argument 542 while (dentry->d_child.next != &parent->d_subdirs) { in dentry_unlist() 552 struct dentry *parent = NULL; in __dentry_kill() local 555 parent = dentry->d_parent; in __dentry_kill() 575 dentry_unlist(dentry, parent); in __dentry_kill() 576 if (parent) in __dentry_kill() 577 spin_unlock(&parent->d_lock); in __dentry_kill() 599 struct dentry *parent; in __lock_parent() local [all …]
|
/fs/overlayfs/ |
D | export.c | 107 struct dentry *next, *parent = NULL; in ovl_connect_layer() local 122 parent = dget_parent(next); in ovl_connect_layer() 123 if (WARN_ON(parent == next)) { in ovl_connect_layer() 132 if (ovl_connectable_layer(parent) < origin_layer) { in ovl_connect_layer() 138 if (ovl_dentry_test_flag(OVL_E_CONNECTED, parent) || in ovl_connect_layer() 139 ovl_test_flag(OVL_INDEX, d_inode(parent))) in ovl_connect_layer() 143 next = parent; in ovl_connect_layer() 146 dput(parent); in ovl_connect_layer() 267 struct inode *parent) in ovl_encode_fh() argument 273 if (parent) in ovl_encode_fh() [all …]
|
/fs/gfs2/ |
D | export.c | 29 struct inode *parent) in gfs2_encode_fh() argument 35 if (parent && (*len < GFS2_LARGE_FH_SIZE)) { in gfs2_encode_fh() 49 if (!parent || inode == d_inode(sb->s_root)) in gfs2_encode_fh() 52 ip = GFS2_I(parent); in gfs2_encode_fh() 85 static int gfs2_get_name(struct dentry *parent, char *name, in gfs2_get_name() argument 88 struct inode *dir = d_inode(parent); in gfs2_get_name() 169 struct gfs2_inum_host parent; in gfs2_fh_to_parent() local 177 parent.no_formal_ino = ((u64)be32_to_cpu(fh[4])) << 32; in gfs2_fh_to_parent() 178 parent.no_formal_ino |= be32_to_cpu(fh[5]); in gfs2_fh_to_parent() 179 parent.no_addr = ((u64)be32_to_cpu(fh[6])) << 32; in gfs2_fh_to_parent() [all …]
|
/fs/ceph/ |
D | snap.c | 87 struct rb_node *parent = NULL; in __insert_snap_realm() local 91 parent = *p; in __insert_snap_realm() 92 r = rb_entry(parent, struct ceph_snap_realm, node); in __insert_snap_realm() 101 rb_link_node(&new->node, parent, p); in __insert_snap_realm() 184 if (realm->parent) { in __destroy_snap_realm() 186 __put_snap_realm(mdsc, realm->parent); in __destroy_snap_realm() 270 struct ceph_snap_realm *parent; in adjust_snap_realm_parent() local 275 parent = ceph_lookup_snap_realm(mdsc, parentino); in adjust_snap_realm_parent() 276 if (!parent) { in adjust_snap_realm_parent() 277 parent = ceph_create_snap_realm(mdsc, parentino); in adjust_snap_realm_parent() [all …]
|
/fs/ubifs/ |
D | lpt.c | 486 struct ubifs_nnode *np = nnode->parent; in ubifs_add_nnode_dirt() 507 ubifs_add_lpt_dirt(c, pnode->parent->nbranch[pnode->iip].lnum, in add_pnode_dirt() 549 struct ubifs_nnode *parent, int iip) in calc_nnode_num_from_parent() argument 553 if (!parent) in calc_nnode_num_from_parent() 555 shft = (c->lpt_hght - parent->level) * UBIFS_LPT_FANOUT_SHIFT; in calc_nnode_num_from_parent() 556 num = parent->num ^ (1 << shft); in calc_nnode_num_from_parent() 574 struct ubifs_nnode *parent, int iip) in calc_pnode_num_from_parent() argument 576 int i, n = c->lpt_hght - 1, pnum = parent->num, num = 0; in calc_pnode_num_from_parent() 1105 struct ubifs_nnode *parent, int iip) in validate_nnode() argument 1110 int num = calc_nnode_num_from_parent(c, parent, iip); in validate_nnode() [all …]
|
/fs/sdcardfs/ |
D | derived_perm.c | 24 static void inherit_derived_state(struct inode *parent, struct inode *child) in inherit_derived_state() argument 26 struct sdcardfs_inode_info *pi = SDCARDFS_I(parent); in inherit_derived_state() 54 void get_derived_permission_new(struct dentry *parent, struct dentry *dentry, in get_derived_permission_new() argument 58 struct sdcardfs_inode_info *parent_info = SDCARDFS_I(d_inode(parent)); in get_derived_permission_new() 78 inherit_derived_state(d_inode(parent), d_inode(dentry)); in get_derived_permission_new() 148 void get_derived_permission(struct dentry *parent, struct dentry *dentry) in get_derived_permission() argument 150 get_derived_permission_new(parent, dentry, &dentry->d_name); in get_derived_permission() 335 struct dentry *parent; in update_derived_permission_lock() local 346 parent = dget_parent(dentry); in update_derived_permission_lock() 347 if (parent) { in update_derived_permission_lock() [all …]
|
/fs/unicode/ |
D | mkutf8data.c | 366 struct node *parent; member 480 node = node->parent; in tree_walk() 492 static struct node *alloc_node(struct node *parent) in alloc_node() argument 499 node->parent = parent; in alloc_node() 509 if (node->parent) { in alloc_node() 510 bitnum = parent->bitnum; in alloc_node() 536 struct node *parent; in insert() local 579 parent = node->parent; in insert() 580 if (!parent) { in insert() 584 } else if (parent->left == node) { in insert() [all …]
|