summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-01-13 14:05:13 -0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-01-13 14:05:13 -0800
commita9f138b0e537de55933335d580ebd38c2bc53c47 (patch)
treef54235f920d392519bde975d42aa4b4534f9561a /include/linux
parent8634c422c1b7e50ca8e346f65afc140d93a3212c (diff)
Revert "kernfs, sysfs, driver-core: implement kernfs_remove_self() and its wrappers"
This reverts commit 1ae06819c77cff1ea2833c94f8c093fe8a5c79db. 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> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/device.h2
-rw-r--r--include/linux/kernfs.h6
-rw-r--r--include/linux/sysfs.h7
3 files changed, 0 insertions, 15 deletions
diff --git a/include/linux/device.h b/include/linux/device.h
index 1ff3f1697513..952b01033c32 100644
--- a/include/linux/device.h
+++ b/include/linux/device.h
@@ -560,8 +560,6 @@ extern int device_create_file(struct device *device,
const struct device_attribute *entry);
extern void device_remove_file(struct device *dev,
const struct device_attribute *attr);
-extern bool device_remove_file_self(struct device *dev,
- const struct device_attribute *attr);
extern int __must_check device_create_bin_file(struct device *dev,
const struct bin_attribute *attr);
extern void device_remove_bin_file(struct device *dev,
diff --git a/include/linux/kernfs.h b/include/linux/kernfs.h
index 0b7b7cc352eb..ac8693027058 100644
--- a/include/linux/kernfs.h
+++ b/include/linux/kernfs.h
@@ -43,8 +43,6 @@ enum kernfs_node_flag {
KERNFS_HAS_MMAP = 0x0080,
KERNFS_LOCKDEP = 0x0100,
KERNFS_STATIC_NAME = 0x0200,
- KERNFS_SUICIDAL = 0x0400,
- KERNFS_SUICIDED = 0x0800,
};
/* type-specific structures for kernfs_node union members */
@@ -241,7 +239,6 @@ void kernfs_reactivate(struct kernfs_node *kn);
void kernfs_deactivate_self(struct kernfs_node *kn);
void kernfs_reactivate_self(struct kernfs_node *kn);
void kernfs_remove(struct kernfs_node *kn);
-bool kernfs_remove_self(struct kernfs_node *kn);
int kernfs_remove_by_name_ns(struct kernfs_node *parent, const char *name,
const void *ns);
int kernfs_rename_ns(struct kernfs_node *kn, struct kernfs_node *new_parent,
@@ -299,9 +296,6 @@ kernfs_create_link(struct kernfs_node *parent, const char *name,
static inline void kernfs_remove(struct kernfs_node *kn) { }
-static inline bool kernfs_remove_self(struct kernfs_node *kn)
-{ return false; }
-
static inline int kernfs_remove_by_name_ns(struct kernfs_node *kn,
const char *name, const void *ns)
{ return -ENOSYS; }
diff --git a/include/linux/sysfs.h b/include/linux/sysfs.h
index bd96c603ab6c..30b2ebee6439 100644
--- a/include/linux/sysfs.h
+++ b/include/linux/sysfs.h
@@ -198,7 +198,6 @@ int __must_check sysfs_chmod_file(struct kobject *kobj,
const struct attribute *attr, umode_t mode);
void sysfs_remove_file_ns(struct kobject *kobj, const struct attribute *attr,
const void *ns);
-bool sysfs_remove_file_self(struct kobject *kobj, const struct attribute *attr);
void sysfs_remove_files(struct kobject *kobj, const struct attribute **attr);
int __must_check sysfs_create_bin_file(struct kobject *kobj,
@@ -302,12 +301,6 @@ static inline void sysfs_remove_file_ns(struct kobject *kobj,
{
}
-static inline bool sysfs_remove_file_self(struct kobject *kobj,
- const struct attribute *attr)
-{
- return false;
-}
-
static inline void sysfs_remove_files(struct kobject *kobj,
const struct attribute **attr)
{