Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

clk: qcom: camcc-*: switch to module_platform_driver

There is no need to register camera clock controllers during subsys init
calls. Use module_platform_driver() instead.

Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
Link: https://lore.kernel.org/r/20240206-clk-module-platform-driver-v1-1-db799bd2feeb@linaro.org
Signed-off-by: Bjorn Andersson <andersson@kernel.org>

authored by

Dmitry Baryshkov and committed by
Bjorn Andersson
8f4bfd9e d2cd22c9

+4 -44
+1 -11
drivers/clk/qcom/camcc-sc7180.c
··· 1703 1703 }, 1704 1704 }; 1705 1705 1706 - static int __init cam_cc_sc7180_init(void) 1707 - { 1708 - return platform_driver_register(&cam_cc_sc7180_driver); 1709 - } 1710 - subsys_initcall(cam_cc_sc7180_init); 1711 - 1712 - static void __exit cam_cc_sc7180_exit(void) 1713 - { 1714 - platform_driver_unregister(&cam_cc_sc7180_driver); 1715 - } 1716 - module_exit(cam_cc_sc7180_exit); 1706 + module_platform_driver(cam_cc_sc7180_driver); 1717 1707 1718 1708 MODULE_DESCRIPTION("QTI CAM_CC SC7180 Driver"); 1719 1709 MODULE_LICENSE("GPL v2");
+1 -11
drivers/clk/qcom/camcc-sc7280.c
··· 2468 2468 }, 2469 2469 }; 2470 2470 2471 - static int __init cam_cc_sc7280_init(void) 2472 - { 2473 - return platform_driver_register(&cam_cc_sc7280_driver); 2474 - } 2475 - subsys_initcall(cam_cc_sc7280_init); 2476 - 2477 - static void __exit cam_cc_sc7280_exit(void) 2478 - { 2479 - platform_driver_unregister(&cam_cc_sc7280_driver); 2480 - } 2481 - module_exit(cam_cc_sc7280_exit); 2471 + module_platform_driver(cam_cc_sc7280_driver); 2482 2472 2483 2473 MODULE_DESCRIPTION("QTI CAM_CC SC7280 Driver"); 2484 2474 MODULE_LICENSE("GPL v2");
+1 -11
drivers/clk/qcom/camcc-sdm845.c
··· 1746 1746 }, 1747 1747 }; 1748 1748 1749 - static int __init cam_cc_sdm845_init(void) 1750 - { 1751 - return platform_driver_register(&cam_cc_sdm845_driver); 1752 - } 1753 - subsys_initcall(cam_cc_sdm845_init); 1754 - 1755 - static void __exit cam_cc_sdm845_exit(void) 1756 - { 1757 - platform_driver_unregister(&cam_cc_sdm845_driver); 1758 - } 1759 - module_exit(cam_cc_sdm845_exit); 1749 + module_platform_driver(cam_cc_sdm845_driver); 1760 1750 1761 1751 MODULE_DESCRIPTION("QTI CAM_CC SDM845 Driver"); 1762 1752 MODULE_LICENSE("GPL v2");
+1 -11
drivers/clk/qcom/camcc-sm6350.c
··· 1890 1890 }, 1891 1891 }; 1892 1892 1893 - static int __init camcc_sm6350_init(void) 1894 - { 1895 - return platform_driver_register(&camcc_sm6350_driver); 1896 - } 1897 - subsys_initcall(camcc_sm6350_init); 1898 - 1899 - static void __exit camcc_sm6350_exit(void) 1900 - { 1901 - platform_driver_unregister(&camcc_sm6350_driver); 1902 - } 1903 - module_exit(camcc_sm6350_exit); 1893 + module_platform_driver(camcc_sm6350_driver); 1904 1894 1905 1895 MODULE_DESCRIPTION("QTI CAMCC SM6350 Driver"); 1906 1896 MODULE_LICENSE("GPL");