Loading fs/tracefs/inode.c +20 −0 Original line number Diff line number Diff line Loading @@ -504,6 +504,26 @@ struct dentry *tracefs_end_creating(struct dentry *dentry) return dentry; } /* Find the inode that this will use for default */ static struct inode *instance_inode(struct dentry *parent, struct inode *inode) { struct tracefs_inode *ti; /* If parent is NULL then use root inode */ if (!parent) return d_inode(inode->i_sb->s_root); /* Find the inode that is flagged as an instance or the root inode */ while (!IS_ROOT(parent)) { ti = get_tracefs(d_inode(parent)); if (ti->flags & TRACEFS_INSTANCE_INODE) break; parent = parent->d_parent; } return d_inode(parent); } /** * eventfs_start_creating - start the process of creating a dentry * @name: Name of the file created for the dentry Loading Loading
fs/tracefs/inode.c +20 −0 Original line number Diff line number Diff line Loading @@ -504,6 +504,26 @@ struct dentry *tracefs_end_creating(struct dentry *dentry) return dentry; } /* Find the inode that this will use for default */ static struct inode *instance_inode(struct dentry *parent, struct inode *inode) { struct tracefs_inode *ti; /* If parent is NULL then use root inode */ if (!parent) return d_inode(inode->i_sb->s_root); /* Find the inode that is flagged as an instance or the root inode */ while (!IS_ROOT(parent)) { ti = get_tracefs(d_inode(parent)); if (ti->flags & TRACEFS_INSTANCE_INODE) break; parent = parent->d_parent; } return d_inode(parent); } /** * eventfs_start_creating - start the process of creating a dentry * @name: Name of the file created for the dentry Loading