summaryrefslogtreecommitdiffstats
path: root/fs/kernfs/file.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-01-13 14:36:03 -0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-01-13 14:36:03 -0800
commit798c75a0d44cdbd6e3d82a6a676e6de38525b3bb (patch)
tree358f5deccf0f6b6afa833d0264f2e3aefcca02ce /fs/kernfs/file.c
parent4f4b1b6471cf219d136776f9ff9631a07c4e92b5 (diff)
downloadlinux-798c75a0d44cdbd6e3d82a6a676e6de38525b3bb.tar.bz2
Revert "kernfs: remove KERNFS_REMOVED"
This reverts commit ae34372eb8408b3d07e870f1939f99007a730d28. Tejun writes: I'm sorry but can you please revert the whole series? get_active() waiting while a node is deactivated has potential to lead to deadlock and that deactivate/reactivate interface is something fundamentally flawed and that cgroup will have to work with the remove_self() like everybody else. IOW, I think the first posting was correct. Cc: Tejun Heo <tj@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'fs/kernfs/file.c')
-rw-r--r--fs/kernfs/file.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/fs/kernfs/file.c b/fs/kernfs/file.c
index 231a171f48b6..bdd38854ef65 100644
--- a/fs/kernfs/file.c
+++ b/fs/kernfs/file.c
@@ -856,13 +856,9 @@ struct kernfs_node *__kernfs_create_file(struct kernfs_node *parent,
if (ops->mmap)
kn->flags |= KERNFS_HAS_MMAP;
- rc = -ENOENT;
- if (kernfs_get_active(parent)) {
- kernfs_addrm_start(&acxt);
- rc = kernfs_add_one(&acxt, kn, parent);
- kernfs_addrm_finish(&acxt);
- kernfs_put_active(parent);
- }
+ kernfs_addrm_start(&acxt);
+ rc = kernfs_add_one(&acxt, kn, parent);
+ kernfs_addrm_finish(&acxt);
if (rc) {
kernfs_put(kn);