diff options
author | AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> | 2023-05-25 13:52:57 +0200 |
---|---|---|
committer | Vinod Koul <vkoul@kernel.org> | 2023-07-12 18:57:42 +0200 |
commit | e90da3fc82f4e3bc86e29ca89ea6cceb5dcd3613 (patch) | |
tree | 4843df9f2bbb4f1bffacae37c9fabcfc7ba869bd /drivers/phy/mediatek | |
parent | phy: mediatek: mipi-dsi: Convert to register clk_hw (diff) | |
download | linux-e90da3fc82f4e3bc86e29ca89ea6cceb5dcd3613.tar.xz linux-e90da3fc82f4e3bc86e29ca89ea6cceb5dcd3613.zip |
phy: mediatek: mipi-dsi: Use devm variant for of_clk_add_hw_provider()
Switch to devm_of_clk_add_hw_provider() in the probe function: this
also allows to entirely remove the .remove_new() callback, as its
only task was to unregister the clock provider.
Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Link: https://lore.kernel.org/r/20230525115258.90091-3-angelogioacchino.delregno@collabora.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'drivers/phy/mediatek')
-rw-r--r-- | drivers/phy/mediatek/phy-mtk-mipi-dsi.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/phy/mediatek/phy-mtk-mipi-dsi.c b/drivers/phy/mediatek/phy-mtk-mipi-dsi.c index 362145198ff5..4e75c34c819b 100644 --- a/drivers/phy/mediatek/phy-mtk-mipi-dsi.c +++ b/drivers/phy/mediatek/phy-mtk-mipi-dsi.c @@ -176,12 +176,7 @@ static int mtk_mipi_tx_probe(struct platform_device *pdev) mtk_mipi_tx_get_calibration_datal(mipi_tx); - return of_clk_add_hw_provider(dev->of_node, of_clk_hw_simple_get, &mipi_tx->pll_hw); -} - -static void mtk_mipi_tx_remove(struct platform_device *pdev) -{ - of_clk_del_provider(pdev->dev.of_node); + return devm_of_clk_add_hw_provider(dev, of_clk_hw_simple_get, &mipi_tx->pll_hw); } static const struct of_device_id mtk_mipi_tx_match[] = { @@ -197,7 +192,6 @@ MODULE_DEVICE_TABLE(of, mtk_mipi_tx_match); static struct platform_driver mtk_mipi_tx_driver = { .probe = mtk_mipi_tx_probe, - .remove_new = mtk_mipi_tx_remove, .driver = { .name = "mediatek-mipi-tx", .of_match_table = mtk_mipi_tx_match, |