From a1212d278c05ca0a38f5cbd7ae90ac2e367228a8 Mon Sep 17 00:00:00 2001 From: Linus Torvalds Date: Thu, 7 Nov 2013 20:47:28 +0900 Subject: Revert "sysfs: drop kobj_ns_type handling" This reverts commit cb26a311578e67769e92a39a0a63476533cb7e12. It mysteriously causes NetworkManager to not find the wireless device for me. As far as I can tell, Tejun *meant* for this commit to not make any semantic changes, but there clearly are some. So revert it, taking into account some of the calling convention changes that happened in this area in subsequent commits. Cc: Tejun Heo Cc: Greg Kroah-Hartman Signed-off-by: Linus Torvalds --- lib/kobject.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'lib/kobject.c') diff --git a/lib/kobject.c b/lib/kobject.c index 7a1c203083e..5b4b8886435 100644 --- a/lib/kobject.c +++ b/lib/kobject.c @@ -30,14 +30,11 @@ const void *kobject_namespace(struct kobject *kobj) { const struct kobj_ns_type_operations *ns_ops = kobj_ns_ops(kobj); - const void *ns; if (!ns_ops || ns_ops->type == KOBJ_NS_TYPE_NONE) return NULL; - ns = kobj->ktype->namespace(kobj); - WARN_ON(!ns); /* @kobj in a namespace is required to have !NULL tag */ - return ns; + return kobj->ktype->namespace(kobj); } /* -- cgit v1.2.3-70-g09d2