[PATCH] kobject rename can take const char

From: Stephen Hemminger
Date: Fri Aug 15 2003 - 13:22:35 EST


kobject_rename doesn't change the name string.

diff -Nru a/include/linux/kobject.h b/include/linux/kobject.h
--- a/include/linux/kobject.h Fri Aug 15 11:19:55 2003
+++ b/include/linux/kobject.h Fri Aug 15 11:19:55 2003
@@ -39,7 +39,7 @@
extern int kobject_add(struct kobject *);
extern void kobject_del(struct kobject *);

-extern void kobject_rename(struct kobject *, char *new_name);
+extern void kobject_rename(struct kobject *, const char *new_name);

extern int kobject_register(struct kobject *);
extern void kobject_unregister(struct kobject *);
diff -Nru a/lib/kobject.c b/lib/kobject.c
--- a/lib/kobject.c Fri Aug 15 11:19:55 2003
+++ b/lib/kobject.c Fri Aug 15 11:19:55 2003
@@ -319,7 +319,7 @@
* @new_name: object's new name
*/

-void kobject_rename(struct kobject * kobj, char *new_name)
+void kobject_rename(struct kobject * kobj, const char *new_name)
{
kobj = kobject_get(kobj);
if (!kobj)
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/