[PATCH v2 2/2] lib/lwq: add missing module_exit for test module

Josh Law posted 2 patches 3 weeks, 2 days ago
[PATCH v2 2/2] lib/lwq: add missing module_exit for test module
Posted by Josh Law 3 weeks, 2 days ago
From: Josh Law <objecting@objecting.org>

module_init(lwq_test) is declared without a corresponding module_exit,
preventing the module from being unloaded when built as a module.

Add an empty module_exit handler.

Signed-off-by: Josh Law <objecting@objecting.org>
---
 lib/lwq.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/lib/lwq.c b/lib/lwq.c
index 1fd2ed612c75..cf4d174d6898 100644
--- a/lib/lwq.c
+++ b/lib/lwq.c
@@ -157,5 +157,10 @@ static int lwq_test(void)
 	return 0;
 }
 
+static void lwq_test_exit(void)
+{
+}
+
 module_init(lwq_test);
+module_exit(lwq_test_exit);
 #endif /* CONFIG_LWQ_TEST*/
-- 
2.34.1