msm: camera: common: Make platform register centralized
Currently camera modules platform registration/remove function is being called as a part of module_init function individually. Building camera as module, current infrastructure cannot support it, as DLKM only support single module_init/exit function. This change enables that support by combining all platform entry/remove functions centrally. Also, remove all submodule makefiles and combined into one root makefile in order to generate single kernel object file to dynamically loading the kernel module in case of DLKM compilation. CRs-Fixed: 2569808 Change-Id: I59db3ed6cef60123e474db2f222c39836056bd6e Signed-off-by: Jigarkumar Zala <jzala@codeaurora.org> Signed-off-by: Karthik Jayakumar <kjayakum@codeaurora.org>
This commit is contained in:

committed by
Karthik Jayakumar

parent
2478b5c0f7
commit
03b6c2140f
@@ -183,17 +183,15 @@ static struct platform_driver custom_driver = {
|
||||
},
|
||||
};
|
||||
|
||||
static int __init cam_custom_dev_init_module(void)
|
||||
int cam_custom_dev_init_module(void)
|
||||
{
|
||||
return platform_driver_register(&custom_driver);
|
||||
}
|
||||
|
||||
static void __exit cam_custom_dev_exit_module(void)
|
||||
void cam_custom_dev_exit_module(void)
|
||||
{
|
||||
platform_driver_unregister(&custom_driver);
|
||||
}
|
||||
|
||||
module_init(cam_custom_dev_init_module);
|
||||
module_exit(cam_custom_dev_exit_module);
|
||||
MODULE_DESCRIPTION("MSM CUSTOM driver");
|
||||
MODULE_LICENSE("GPL v2");
|
||||
|
Reference in New Issue
Block a user