[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date: Thu, 8 Aug 2019 18:10:53 +0200 (CEST)
From: Julia Lawall <julia.lawall@...6.fr>
To: Jonas Gorski <jonas.gorski@...il.com>
cc: linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-clk@...r.kernel.org, bcm-kernel-feedback-list@...adcom.com,
Michael Turquette <mturquette@...libre.com>,
Philippe Mathieu-Daud?? <f4bug@...at.org>,
Florian Fainelli <f.fainelli@...il.com>,
Stephen Boyd <sboyd@...nel.org>, linux-kernel@...r.kernel.org,
kbuild-all@...org
Subject: [PATCH] clk: fix devm_platform_ioremap_resource.cocci warnings
From: kbuild test robot <lkp@...el.com>
drivers/clk/bcm/clk-bcm63xx-gate.c:174:1-9: WARNING: Use devm_platform_ioremap_resource for hw -> regs
Use devm_platform_ioremap_resource helper which wraps
platform_get_resource() and devm_ioremap_resource() together.
Generated by: scripts/coccinelle/api/devm_platform_ioremap_resource.cocci
Fixes: 1c099779c1e2 ("clk: add BCM63XX gated clock controller driver")
CC: Jonas Gorski <jonas.gorski@...il.com>
Signed-off-by: kbuild test robot <lkp@...el.com>
Signed-off-by: Julia Lawall <julia.lawall@...6.fr>
---
tree: https://kernel.googlesource.com/pub/scm/linux/kernel/git/torvalds/linux.git master
head: ecb095bff5d4b8711a81968625b3b4a235d3e477
commit: 1c099779c1e2e8e0e10cdb2aecd4b35f428e9f00 clk: add BCM63XX gated clock controller driver
:::::: branch date: 15 hours ago
:::::: commit date: 6 weeks ago
clk-bcm63xx-gate.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
--- a/drivers/clk/bcm/clk-bcm63xx-gate.c
+++ b/drivers/clk/bcm/clk-bcm63xx-gate.c
@@ -146,7 +146,6 @@ static int clk_bcm63xx_probe(struct plat
{
const struct clk_bcm63xx_table_entry *entry, *table;
struct clk_bcm63xx_hw *hw;
- struct resource *r;
u8 maxbit = 0;
int i, ret;
@@ -170,8 +169,7 @@ static int clk_bcm63xx_probe(struct plat
for (i = 0; i < maxbit; i++)
hw->data.hws[i] = ERR_PTR(-ENODEV);
- r = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- hw->regs = devm_ioremap_resource(&pdev->dev, r);
+ hw->regs = devm_platform_ioremap_resource(pdev, 0);
if (IS_ERR(hw->regs))
return PTR_ERR(hw->regs);
Powered by blists - more mailing lists