diff options
author | YueHaibing <yuehaibing@huawei.com> | 2019-10-14 17:36:42 +0300 |
---|---|---|
committer | Stephen Boyd <sboyd@kernel.org> | 2019-10-17 02:16:50 +0300 |
commit | 4d3a369510dda6336534c4364910312f432c54a5 (patch) | |
tree | 6278ee2dc261032d115cb2d56b38c7a8d8de1f5c /drivers/clk/bcm/clk-bcm2835-aux.c | |
parent | 54ecb8f7028c5eb3d740bb82b0f1d90f2df63c5c (diff) | |
download | linux-4d3a369510dda6336534c4364910312f432c54a5.tar.xz |
clk: bcm2835: use devm_platform_ioremap_resource() to simplify code
Use devm_platform_ioremap_resource() to simplify the code a bit.
This is detected by coccinelle.
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Link: https://lkml.kernel.org/r/20191014143642.24552-1-yuehaibing@huawei.com
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
Diffstat (limited to 'drivers/clk/bcm/clk-bcm2835-aux.c')
-rw-r--r-- | drivers/clk/bcm/clk-bcm2835-aux.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/clk/bcm/clk-bcm2835-aux.c b/drivers/clk/bcm/clk-bcm2835-aux.c index b6d07ca0164f..290a2846a86b 100644 --- a/drivers/clk/bcm/clk-bcm2835-aux.c +++ b/drivers/clk/bcm/clk-bcm2835-aux.c @@ -19,7 +19,6 @@ static int bcm2835_aux_clk_probe(struct platform_device *pdev) struct clk_hw_onecell_data *onecell; const char *parent; struct clk *parent_clk; - struct resource *res; void __iomem *reg, *gate; parent_clk = devm_clk_get(dev, NULL); @@ -27,8 +26,7 @@ static int bcm2835_aux_clk_probe(struct platform_device *pdev) return PTR_ERR(parent_clk); parent = __clk_get_name(parent_clk); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - reg = devm_ioremap_resource(dev, res); + reg = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(reg)) return PTR_ERR(reg); |