summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorCai Huoqing <caihuoqing@baidu.com>2021-09-08 10:02:11 +0200
committerBjorn Andersson <bjorn.andersson@linaro.org>2021-09-22 00:41:48 +0200
commit0e6fda9c65634e1f6f4a18fd1c48acf0af761deb (patch)
treed898363acd057c61f7f6a867e7a643b237cc610f /drivers
parentsoc: qcom: socinfo: Add IPQ8074 family ID-s (diff)
downloadlinux-0e6fda9c65634e1f6f4a18fd1c48acf0af761deb.tar.xz
linux-0e6fda9c65634e1f6f4a18fd1c48acf0af761deb.zip
PM: AVS: qcom-cpr: Make use of the helper function devm_platform_ioremap_resource()
Use the devm_platform_ioremap_resource() helper instead of calling platform_get_resource() and devm_ioremap_resource() separately Signed-off-by: Cai Huoqing <caihuoqing@baidu.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Link: https://lore.kernel.org/r/20210908080216.1301-1-caihuoqing@baidu.com
Diffstat (limited to 'drivers')
-rw-r--r--drivers/soc/qcom/cpr.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/soc/qcom/cpr.c b/drivers/soc/qcom/cpr.c
index 4ce8e816154f..1d818a8ba208 100644
--- a/drivers/soc/qcom/cpr.c
+++ b/drivers/soc/qcom/cpr.c
@@ -1614,7 +1614,6 @@ static void cpr_debugfs_init(struct cpr_drv *drv)
static int cpr_probe(struct platform_device *pdev)
{
- struct resource *res;
struct device *dev = &pdev->dev;
struct cpr_drv *drv;
int irq, ret;
@@ -1648,8 +1647,7 @@ static int cpr_probe(struct platform_device *pdev)
if (IS_ERR(drv->tcsr))
return PTR_ERR(drv->tcsr);
- res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- drv->base = devm_ioremap_resource(dev, res);
+ drv->base = devm_platform_ioremap_resource(pdev, 0);
if (IS_ERR(drv->base))
return PTR_ERR(drv->base);