Linux Headquarters
[ Register ]
[ About us ] [ Home Page ]

Advertisement
[ Kernel ] [ Documentation ] [ Links ] [ Books ]

Advertisement

Kernel v2.5.75 /lib/kobject.c

Filename:/lib/kobject.c
Lines Added:15
Lines Deleted:0
Also changed in: (Previous) 2.5.74-bk7  2.5.74-bk6  2.5.74-bk5  2.5.74-bk4  2.5.74-bk3  2.5.74-bk2 
(Following)

Location
[  2.5.75
  [  lib
     o  kobject.c

Patch

diff -Nru a/lib/kobject.c b/lib/kobject.c
--- a/lib/kobject.c   Thu Jul 10 13:16:28 2003
+++ b/lib/kobject.c   Thu Jul 10 13:16:28 2003
@@ -314,6 +314,21 @@
 }
 
 /**
+ *   kobject_rename - change the name of an object
+ *   @kobj:   object in question.
+ *   @new_name: object's new name
+ */
+
+void kobject_rename(struct kobject * kobj, char *new_name)
+{
+   kobj = kobject_get(kobj);
+   if (!kobj)
+      return;
+   sysfs_rename_dir(kobj, new_name);
+   kobject_put(kobj);
+}
+
+/**
  *   kobject_del - unlink kobject from hierarchy.
  *    @kobj:   object.
  */


Comments: webmaster (at) linuxhq.com.
Advertising: banners (at) linuxhq.com.
Compilation ©1998-2008 Linux Headquarters, Inc.