[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <m11wix8n74.fsf@ebiederm.dsl.xmission.com>
Date: Fri, 06 Apr 2007 10:47:11 -0600
From: ebiederm@...ssion.com (Eric W. Biederman)
To: Greg Kroah-Hartman <gregkh@...e.de>
Cc: Kay Sievers <kay.sievers@...y.org>, <linux-kernel@...r.kernel.org>,
Linux Containers <containers@...ts.osdl.org>
Subject: [PATCH 1/5] kobject: Comment and warning fixes to kobject.c
This dots some i's and crosses some t's after left over from when
kobject_kset_add_dir was built from kobject_add_dir.
Signed-off-by: Eric W. Biederman <ebiederm@...ssion.com>
---
lib/kobject.c | 13 ++++++++++---
1 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/lib/kobject.c b/lib/kobject.c
index f664551..09cb276 100644
--- a/lib/kobject.c
+++ b/lib/kobject.c
@@ -488,7 +488,7 @@ static struct kobj_type dir_ktype = {
};
/**
- * kobject__kset_add_dir - add sub directory of object.
+ * kobject_kset_add_dir - add sub directory of object.
* @kset: kset the directory is belongs to.
* @parent: object in which a directory is created.
* @name: directory name.
@@ -514,8 +514,8 @@ struct kobject *kobject_kset_add_dir(struct kset *kset,
kobject_set_name(k, name);
ret = kobject_register(k);
if (ret < 0) {
- printk(KERN_WARNING "kobject_add_dir: "
- "kobject_register error: %d\n", ret);
+ printk(KERN_WARNING "%s: kobject_register error: %d\n",
+ __func__, ret);
kobject_del(k);
return NULL;
}
@@ -523,6 +523,13 @@ struct kobject *kobject_kset_add_dir(struct kset *kset,
return k;
}
+/**
+ * kobject_add_dir - add sub directory of object.
+ * @parent: object in which a directory is created.
+ * @name: directory name.
+ *
+ * Add a plain directory object as child of given object.
+ */
struct kobject *kobject_add_dir(struct kobject *parent, const char *name)
{
return kobject_kset_add_dir(NULL, parent, name);
--
1.5.0.g53756
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists