]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
dibs: Use subsys_initcall()
authorAlexandra Winter <wintera@linux.ibm.com>
Thu, 23 Oct 2025 15:06:36 +0000 (17:06 +0200)
committerPaolo Abeni <pabeni@redhat.com>
Tue, 28 Oct 2025 12:42:31 +0000 (13:42 +0100)
In the case of built-in modules, the order of module_init() calls are
derived from the Makefiles.

Use subsys_initcall() for the dibs module, to make sure dibs_init() is
executed before dibs clients like smc and dibs devices like ism are
initialized. So future dibs client or dibs device modules can use
module_init() without the risk of getting the order in the Makefiles wrong.

Reported-by: Mete Durlu <meted@linux.ibm.com>
Signed-off-by: Alexandra Winter <wintera@linux.ibm.com>
Reviewed-by: Alexander Lobakin <aleksander.lobakin@intel.com>
Link: https://patch.msgid.link/20251023150636.3995476-2-wintera@linux.ibm.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
drivers/dibs/dibs_main.c

index b015578b4d2e3ac21bae387821949f4d0a411d18..dac14d843af73c89e8c298b2f99ab0d0bc7d5be5 100644 (file)
@@ -271,5 +271,5 @@ static void __exit dibs_exit(void)
        class_destroy(dibs_class);
 }
 
-module_init(dibs_init);
+subsys_initcall(dibs_init);
 module_exit(dibs_exit);