[PATCH] driver core: class: Remove needless return in void API class_remove_file()
From: Zijun Hu
Date: Sat Feb 08 2025 - 09:16:00 EST
From: Zijun Hu <quic_zijuhu@xxxxxxxxxxx>
Remove return since both class_remove_file() and class_remove_file_ns()
are void functions.
Signed-off-by: Zijun Hu <quic_zijuhu@xxxxxxxxxxx>
---
include/linux/device/class.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/linux/device/class.h b/include/linux/device/class.h
index 45ee3a634999331d4f9efa4c85bb1d36918eb27b..65880e60c720834f5a9cf102a93274e03300ce6c 100644
--- a/include/linux/device/class.h
+++ b/include/linux/device/class.h
@@ -193,7 +193,7 @@ static inline int __must_check class_create_file(const struct class *class,
static inline void class_remove_file(const struct class *class,
const struct class_attribute *attr)
{
- return class_remove_file_ns(class, attr, NULL);
+ class_remove_file_ns(class, attr, NULL);
}
/* Simple class attribute that is just a static string */
---
base-commit: 2014c95afecee3e76ca4a56956a936e23283f05b
change-id: 20250208-cls_rmv_return-e39485dd3b99
Best regards,
--
Zijun Hu <quic_zijuhu@xxxxxxxxxxx>