mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-28 06:34:12 +08:00
clk: mediatek: Make mtk_clk_pdev_remove() return void
This function returns 0 unconditionally. Make it return no value instead and convert the drivers making use of it to platform_driver's .remove_new(). This makes the semantics in the callers of mtk_clk_simple_remove() clearer and prepares for the quest to make platform driver's remove function return void. There is no semantic change. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Link: https://lore.kernel.org/r/20230430190233.878921-3-u.kleine-koenig@pengutronix.de Signed-off-by: Stephen Boyd <sboyd@kernel.org>
This commit is contained in:
parent
61ca6ee782
commit
b3bc72757e
@ -80,7 +80,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt2701_mm_id_table);
|
||||
|
||||
static struct platform_driver clk_mt2701_mm_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt2701-mm",
|
||||
},
|
||||
|
@ -121,7 +121,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt2712_mm_id_table);
|
||||
|
||||
static struct platform_driver clk_mt2712_mm_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt2712-mm",
|
||||
},
|
||||
|
@ -98,7 +98,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt6779_mm_id_table);
|
||||
|
||||
static struct platform_driver clk_mt6779_mm_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt6779-mm",
|
||||
},
|
||||
|
@ -93,7 +93,7 @@ static struct platform_driver clk_mt6795_mm_drv = {
|
||||
},
|
||||
.id_table = clk_mt6795_mm_id_table,
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
};
|
||||
module_platform_driver(clk_mt6795_mm_drv);
|
||||
|
||||
|
@ -93,7 +93,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt6797_mm_id_table);
|
||||
|
||||
static struct platform_driver clk_mt6797_mm_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt6797-mm",
|
||||
},
|
||||
|
@ -87,7 +87,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt8167_mm_id_table);
|
||||
|
||||
static struct platform_driver clk_mt8167_mm_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt8167-mm",
|
||||
},
|
||||
|
@ -106,7 +106,7 @@ static struct platform_driver clk_mt8173_mm_drv = {
|
||||
},
|
||||
.id_table = clk_mt8173_mm_id_table,
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
};
|
||||
module_platform_driver(clk_mt8173_mm_drv);
|
||||
|
||||
|
@ -95,7 +95,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt8183_mm_id_table);
|
||||
|
||||
static struct platform_driver clk_mt8183_mm_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt8183-mm",
|
||||
},
|
||||
|
@ -71,7 +71,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt8186_mm_id_table);
|
||||
|
||||
static struct platform_driver clk_mt8186_mm_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt8186-mm",
|
||||
},
|
||||
|
@ -97,7 +97,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt8188_vdo0_id_table);
|
||||
|
||||
static struct platform_driver clk_mt8188_vdo0_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt8188-vdo0",
|
||||
},
|
||||
|
@ -144,7 +144,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt8188_vdo1_id_table);
|
||||
|
||||
static struct platform_driver clk_mt8188_vdo1_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt8188-vdo1",
|
||||
},
|
||||
|
@ -104,7 +104,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt8188_vpp0_id_table);
|
||||
|
||||
static struct platform_driver clk_mt8188_vpp0_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt8188-vpp0",
|
||||
},
|
||||
|
@ -99,7 +99,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt8188_vpp1_id_table);
|
||||
|
||||
static struct platform_driver clk_mt8188_vpp1_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt8188-vpp1",
|
||||
},
|
||||
|
@ -93,7 +93,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt8192_mm_id_table);
|
||||
|
||||
static struct platform_driver clk_mt8192_mm_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt8192-mm",
|
||||
},
|
||||
|
@ -106,7 +106,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt8195_vdo0_id_table);
|
||||
|
||||
static struct platform_driver clk_mt8195_vdo0_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt8195-vdo0",
|
||||
},
|
||||
|
@ -133,7 +133,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt8195_vdo1_id_table);
|
||||
|
||||
static struct platform_driver clk_mt8195_vdo1_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt8195-vdo1",
|
||||
},
|
||||
|
@ -99,7 +99,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt8195_vpp0_id_table);
|
||||
|
||||
static struct platform_driver clk_mt8195_vpp0_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt8195-vpp0",
|
||||
},
|
||||
|
@ -97,7 +97,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt8195_vpp1_id_table);
|
||||
|
||||
static struct platform_driver clk_mt8195_vpp1_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt8195-vpp1",
|
||||
},
|
||||
|
@ -85,7 +85,7 @@ MODULE_DEVICE_TABLE(platform, clk_mt8365_mm_id_table);
|
||||
|
||||
static struct platform_driver clk_mt8365_mm_drv = {
|
||||
.probe = mtk_clk_pdev_probe,
|
||||
.remove = mtk_clk_pdev_remove,
|
||||
.remove_new = mtk_clk_pdev_remove,
|
||||
.driver = {
|
||||
.name = "clk-mt8365-mm",
|
||||
},
|
||||
|
@ -648,14 +648,12 @@ int mtk_clk_simple_probe(struct platform_device *pdev)
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(mtk_clk_simple_probe);
|
||||
|
||||
int mtk_clk_pdev_remove(struct platform_device *pdev)
|
||||
void mtk_clk_pdev_remove(struct platform_device *pdev)
|
||||
{
|
||||
struct device *dev = &pdev->dev;
|
||||
struct device_node *node = dev->parent->of_node;
|
||||
|
||||
__mtk_clk_simple_remove(pdev, node);
|
||||
|
||||
return 0;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(mtk_clk_pdev_remove);
|
||||
|
||||
|
@ -240,7 +240,7 @@ struct mtk_clk_desc {
|
||||
};
|
||||
|
||||
int mtk_clk_pdev_probe(struct platform_device *pdev);
|
||||
int mtk_clk_pdev_remove(struct platform_device *pdev);
|
||||
void mtk_clk_pdev_remove(struct platform_device *pdev);
|
||||
int mtk_clk_simple_probe(struct platform_device *pdev);
|
||||
void mtk_clk_simple_remove(struct platform_device *pdev);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user