Commit 1fccd1ef authored by AngeloGioacchino Del Regno's avatar AngeloGioacchino Del Regno Committed by Matthias Brugger
Browse files

soc: mediatek: mtk-mutex: Use module_platform_driver() macro



Replace open-coded init/exit calls with the module_platform_driver()
macro being equivalent.

Signed-off-by: default avatarAngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Reviewed-by: default avatarChen-Yu Tsai <wenst@chromium.org>
Link: https://lore.kernel.org/r/20230222094253.23678-8-angelogioacchino.delregno@collabora.com


Signed-off-by: default avatarMatthias Brugger <matthias.bgg@gmail.com>
parent dc36768d
Loading
Loading
Loading
Loading
+1 −13
Original line number Diff line number Diff line
@@ -1067,19 +1067,7 @@ static struct platform_driver mtk_mutex_driver = {
		.of_match_table = mutex_driver_dt_match,
	},
};

static int __init mtk_mutex_init(void)
{
	return platform_driver_register(&mtk_mutex_driver);
}

static void __exit mtk_mutex_exit(void)
{
	platform_driver_unregister(&mtk_mutex_driver);
}

module_init(mtk_mutex_init);
module_exit(mtk_mutex_exit);
module_platform_driver(mtk_mutex_driver);

MODULE_AUTHOR("Yongqiang Niu <yongqiang.niu@mediatek.com>");
MODULE_DESCRIPTION("MediaTek SoC MUTEX driver");