Skip to contentSkip to conversation

fix devres_release_all() return value

PATCH In review Adrian Bunk 3 participants 3 messages Jun 17, 2007 – Jun 25, 2007 Driver core

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 fix devres_release_all() return value

Every file should include the headers containing the prototypes for it's global functions.

Since the GNU C compiler is now able to detect that the function prototype of devres_release_all() in the header and the actual function disagree regarding the return value, this patch also fixes this bug.

---

 drivers/base/base.h   |    2 +-
 drivers/base/devres.c |    2 ++
 2 files changed, 3 insertions(+), 1 deletion(-)
drivers/base/base.h renamed from drivers/base/base.h.old +1 -1
@@ -44,6 +44,6 @@
 
 extern char *make_class_name(const char *name, struct kobject *kobj);
 
-extern void devres_release_all(struct device *dev);
+extern int devres_release_all(struct device *dev);
 
 extern struct kset devices_subsys;
drivers/base/devres.c renamed from drivers/base/devres.c.old +2 -0
@@ -10,6 +10,8 @@
 #include <linux/device.h>
 #include <linux/module.h>
 
+#include "base.h"
+
 struct devres_node {
 	struct list_head		entry;
 	dr_release_t			release;
Acked-by on v1 1/1
#1 lore raw
Quoted 8 lines · Adrian Bunk

Every file should include the headers containing the prototypes for it's global functions.

Since the GNU C compiler is now able to detect that the function prototype of devres_release_all() in the header and the actual function disagree regarding the return value, this patch also fixes this bug.

This should go through Greg.

http://article.gmane.org/gmane.linux.kernel/544290/raw

Signature · 1 line
tejun
#2 lore raw
Quoted 8 lines · Tejun Heo
Quoted 7 lines · Adrian Bunk

Every file should include the headers containing the prototypes for it's global functions.

Since the GNU C compiler is now able to detect that the function prototype of devres_release_all() in the header and the actual function disagree regarding the return value, this patch also fixes this bug.

Quoted 7 lines
Quoted 1 line

This should go through Greg.

http://article.gmane.org/gmane.linux.kernel/544290/raw

Thanks, I've picked it up now.

greg k-h