mm/compaction: don't use modular references for non modular code
Subsystems (2)
PATCH 1/1 mm/compaction: don't use modular references for non modular code
replace module_init with subsys_initcall ; which will be two levels earlier, but mm smells like a subsystem to me.
Compile tested only.
---
[Feel free to squash this into the original, if desired.]
mm/compaction.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
mm/compaction.c +1 -3
@@ -20,7 +20,6 @@#include <linux/kasan.h> #include <linux/kthread.h> #include <linux/freezer.h> -#include <linux/module.h> #include "internal.h" #ifdef CONFIG_COMPACTION
@@ -1954,7 +1953,6 @@ static int __init kcompactd_init(void)hotcpu_notifier (cpu_callback,0 );return 0 ; } - -module_init(kcompactd_init) +subsys_initcall(kcompactd_init)#endif /* CONFIG_COMPACTION */
Signature · 7 lines
2.6.1 -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"[email protected]"> [email protected] </a>
Quoted 2 lines · Paul Gortmaker
replace
module_initwithsubsys_initcall; which will be two levels earlier, but mm smells like a subsystem to me.
I admit I don't know the exact differences here, but it makes sense as it's not a module. I just copied this code from kswapd, which also uses module_init(). Should it be also converted?
Quoted 26 lines
Compile tested only.
Cc Vlastimil Babka <[email protected]>Cc Andrew Morton <[email protected]>Signed-off-by Paul Gortmaker <[email protected]>---
[Feel free to squash this into the original, if desired.]
mm/compaction.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)mm/compaction.c +0
-1@@ -20,7 +20,6 @@#include <linux/kasan.h> #include <linux/kthread.h> #include <linux/freezer.h> -#include <linux/module.h> #include "internal.h" #ifdef CONFIG_COMPACTION
mm/compaction.c static int __init kcompactd_init(void) · line 1958
Quoted 8 lines
mm/compaction.c +1
-2@@ -1954,7 +1953,6 @@ static int __init kcompactd_init(void)hotcpu_notifier (cpu_callback,0 );return 0 ; } - -module_init(kcompactd_init) +subsys_initcall(kcompactd_init)#endif /* CONFIG_COMPACTION */
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>