summaryrefslogtreecommitdiff
path: root/drivers/clk/nuvoton
diff options
context:
space:
mode:
authorYangtao Li <frank.li@vivo.com>2023-07-05 14:53:12 +0800
committerStephen Boyd <sboyd@kernel.org>2023-08-22 14:52:11 -0700
commit257cb9f2da55d5d97cdeaa68d11202595aede27d (patch)
treed3d40368ab0068ada9f2cfd4559bfa1c256ed3b3 /drivers/clk/nuvoton
parent90f79ac5bf67ce5a347a0c5fe2b2d87618c306a9 (diff)
clk: nuvoton: Convert to devm_platform_ioremap_resource()
Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li <frank.li@vivo.com> Link: https://lore.kernel.org/r/20230705065313.67043-12-frank.li@vivo.com Acked-by: Jacky Huang <ychuang3@nuvoton.com> Signed-off-by: Stephen Boyd <sboyd@kernel.org>
Diffstat (limited to 'drivers/clk/nuvoton')
-rw-r--r--drivers/clk/nuvoton/clk-ma35d1.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/clk/nuvoton/clk-ma35d1.c b/drivers/clk/nuvoton/clk-ma35d1.c
index f1fe7edd21b5..9f65d0623517 100644
--- a/drivers/clk/nuvoton/clk-ma35d1.c
+++ b/drivers/clk/nuvoton/clk-ma35d1.c
@@ -460,7 +460,6 @@ static int ma35d1_clocks_probe(struct platform_device *pdev)
{
struct device *dev = &pdev->dev;
struct device_node *clk_node = pdev->dev.of_node;
- struct resource *res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
void __iomem *clk_base;
static struct clk_hw **hws;
static struct clk_hw_onecell_data *ma35d1_hw_data;
@@ -476,7 +475,7 @@ static int ma35d1_clocks_probe(struct platform_device *pdev)
ma35d1_hw_data->num = CLK_MAX_IDX;
hws = ma35d1_hw_data->hws;
- clk_base = devm_ioremap_resource(dev, res);
+ clk_base = devm_platform_ioremap_resource(pdev, 0);
if (IS_ERR(clk_base))
return PTR_ERR(clk_base);