Loading arch/s390/hypfs/inode.c +9 −14 Original line number Diff line number Diff line Loading @@ -311,7 +311,7 @@ static void hypfs_kill_super(struct super_block *sb) struct hypfs_sb_info *sb_info = sb->s_fs_info; hypfs_last_dentry = NULL; kill_litter_super(sb); kill_anon_super(sb); kfree(sb_info); } Loading @@ -321,17 +321,13 @@ static struct dentry *hypfs_create_file(struct dentry *parent, const char *name, struct dentry *dentry; struct inode *inode; inode_lock(d_inode(parent)); dentry = lookup_noperm(&QSTR(name), parent); if (IS_ERR(dentry)) { dentry = ERR_PTR(-ENOMEM); goto fail; } dentry = simple_start_creating(parent, name); if (IS_ERR(dentry)) return ERR_PTR(-ENOMEM); inode = hypfs_make_inode(parent->d_sb, mode); if (!inode) { dput(dentry); dentry = ERR_PTR(-ENOMEM); goto fail; simple_done_creating(dentry); return ERR_PTR(-ENOMEM); } if (S_ISREG(mode)) { inode->i_fop = &hypfs_file_ops; Loading @@ -346,10 +342,9 @@ static struct dentry *hypfs_create_file(struct dentry *parent, const char *name, } else BUG(); inode->i_private = data; d_instantiate(dentry, inode); fail: inode_unlock(d_inode(parent)); return dentry; d_make_persistent(dentry, inode); simple_done_creating(dentry); return dentry; // borrowed } struct dentry *hypfs_mkdir(struct dentry *parent, const char *name) Loading Loading
arch/s390/hypfs/inode.c +9 −14 Original line number Diff line number Diff line Loading @@ -311,7 +311,7 @@ static void hypfs_kill_super(struct super_block *sb) struct hypfs_sb_info *sb_info = sb->s_fs_info; hypfs_last_dentry = NULL; kill_litter_super(sb); kill_anon_super(sb); kfree(sb_info); } Loading @@ -321,17 +321,13 @@ static struct dentry *hypfs_create_file(struct dentry *parent, const char *name, struct dentry *dentry; struct inode *inode; inode_lock(d_inode(parent)); dentry = lookup_noperm(&QSTR(name), parent); if (IS_ERR(dentry)) { dentry = ERR_PTR(-ENOMEM); goto fail; } dentry = simple_start_creating(parent, name); if (IS_ERR(dentry)) return ERR_PTR(-ENOMEM); inode = hypfs_make_inode(parent->d_sb, mode); if (!inode) { dput(dentry); dentry = ERR_PTR(-ENOMEM); goto fail; simple_done_creating(dentry); return ERR_PTR(-ENOMEM); } if (S_ISREG(mode)) { inode->i_fop = &hypfs_file_ops; Loading @@ -346,10 +342,9 @@ static struct dentry *hypfs_create_file(struct dentry *parent, const char *name, } else BUG(); inode->i_private = data; d_instantiate(dentry, inode); fail: inode_unlock(d_inode(parent)); return dentry; d_make_persistent(dentry, inode); simple_done_creating(dentry); return dentry; // borrowed } struct dentry *hypfs_mkdir(struct dentry *parent, const char *name) Loading