Skip to contentSkip to conversation

typo in new class_device_release

PATCH In review Stephen Hemminger 2 participants 2 messages Jun 5, 2003 Driver core

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 typo in new class_device_release

There is a typo in the current 2.5.70 bk version of class_device_release that was not there in my original patch. By confusing the class and the class_device, the release function oops. cd->release is always the function itself (class_device_release), cls->release is the one setup for the class (net_class in my case).

drivers/base/class.c +1 -1
diff -Nru a/drivers/base/class.c b/drivers/base/class.c
@@ -191,7 +191,7 @@
 	pr_debug("device class '%s': release.\n",cd->class_id);
 
 	if (cls->release)
-		cd->release(cd);
+		cls->release(cd);
 }
 
 static struct kobj_type ktype_class_device = {
#1 lore raw
Quoted 4 lines · Stephen Hemminger

There is a typo in the current 2.5.70 bk version of class_device_release that was not there in my original patch. By confusing the class and the class_device, the release function oops. cd->release is always the function itself (class_device_release), cls->release is the one setup for the class (net_class in my case).

Bah, sloppy fixup..

Thanks,

-pat