summaryrefslogtreecommitdiffstats
path: root/drivers/perf/arm-ccn.c
diff options
context:
space:
mode:
authorYueHaibing <yuehaibing@huawei.com>2019-09-06 16:39:28 +0200
committerWill Deacon <will@kernel.org>2019-10-01 13:28:46 +0200
commit1c8d96b41d8b05ed9dbc2bea03edf878f544f93e (patch)
tree478743d098d99695ebf4e25324d636333010e501 /drivers/perf/arm-ccn.c
parentperf: xgene: use devm_platform_ioremap_resource() to simplify code (diff)
downloadlinux-1c8d96b41d8b05ed9dbc2bea03edf878f544f93e.tar.xz
linux-1c8d96b41d8b05ed9dbc2bea03edf878f544f93e.zip
perf/arm-ccn: 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> Signed-off-by: Will Deacon <will@kernel.org>
Diffstat (limited to 'drivers/perf/arm-ccn.c')
-rw-r--r--drivers/perf/arm-ccn.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/perf/arm-ccn.c b/drivers/perf/arm-ccn.c
index 6fc0273b6129..fee5cb2e8afb 100644
--- a/drivers/perf/arm-ccn.c
+++ b/drivers/perf/arm-ccn.c
@@ -1477,8 +1477,7 @@ static int arm_ccn_probe(struct platform_device *pdev)
ccn->dev = &pdev->dev;
platform_set_drvdata(pdev, ccn);
- res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- ccn->base = devm_ioremap_resource(ccn->dev, res);
+ ccn->base = devm_platform_ioremap_resource(pdev, 0);
if (IS_ERR(ccn->base))
return PTR_ERR(ccn->base);