Skip to contentSkip to conversation

sysfs.h: don't return a void-valued expression in sysfs_remove_file

PATCH New Simon Wunderlich 1 participant 1 message Apr 16, 2014 Driver core

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 sysfs.h: don't return a void-valued expression in sysfs_remove_file

Sparse was complaining about that:
include/linux/sysfs.h:432:9: warning: returning void-valued expression

---
 include/linux/sysfs.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
include/linux/sysfs.h +1 -1
index 084354b..d451ec5 100644
@@ -446,7 +446,7 @@ static inline int __must_check sysfs_create_file(struct kobject *kobj,
 static inline void sysfs_remove_file(struct kobject *kobj,
 				     const struct attribute *attr)
 {
-	return sysfs_remove_file_ns(kobj, attr, NULL);
+	sysfs_remove_file_ns(kobj, attr, NULL);
 }
 
 static inline int sysfs_rename_link(struct kobject *kobj, struct kobject *target,
Signature · 1 line
1.9.1