Skip to content

Commit 41c54f1

Browse files
bbkzzbebarino
authored andcommitted
clk: gemini: Convert to devm_platform_ioremap_resource()
Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Stephen Boyd <[email protected]>
1 parent d1aa454 commit 41c54f1

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

drivers/clk/clk-gemini.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,6 @@ static int gemini_clk_probe(struct platform_device *pdev)
276276
struct device *dev = &pdev->dev;
277277
struct device_node *np = dev->of_node;
278278
unsigned int mult, div;
279-
struct resource *res;
280279
u32 val;
281280
int ret;
282281
int i;
@@ -286,8 +285,7 @@ static int gemini_clk_probe(struct platform_device *pdev)
286285
return -ENOMEM;
287286

288287
/* Remap the system controller for the exclusive register */
289-
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
290-
base = devm_ioremap_resource(dev, res);
288+
base = devm_platform_ioremap_resource(pdev, 0);
291289
if (IS_ERR(base))
292290
return PTR_ERR(base);
293291

0 commit comments

Comments
 (0)