From: Md Sadre Alam Date: Mon, 6 Mar 2023 14:45:22 +0000 (+0530) Subject: i2c: qcom-cci:Use devm_platform_get_and_ioremap_resource() X-Git-Tag: v6.5-rc1~88^2~23 X-Git-Url: https://git.kernel.dk/?a=commitdiff_plain;h=fdbd69549be8760060952e431ba940112ea623cc;p=linux-block.git i2c: qcom-cci:Use devm_platform_get_and_ioremap_resource() Convert platform_get_resource(), devm_ioremap_resource() to a single call to devm_platform_get_and_ioremap_resource(), as this is exactly what this function does. Signed-off-by: Md Sadre Alam Acked-by: Robert Foss Signed-off-by: Wolfram Sang --- diff --git a/drivers/i2c/busses/i2c-qcom-cci.c b/drivers/i2c/busses/i2c-qcom-cci.c index 58860014e068..622dc14add9d 100644 --- a/drivers/i2c/busses/i2c-qcom-cci.c +++ b/drivers/i2c/busses/i2c-qcom-cci.c @@ -581,8 +581,7 @@ static int cci_probe(struct platform_device *pdev) /* Memory */ - r = platform_get_resource(pdev, IORESOURCE_MEM, 0); - cci->base = devm_ioremap_resource(dev, r); + cci->base = devm_platform_get_and_ioremap_resource(pdev, 0, &r); if (IS_ERR(cci->base)) return PTR_ERR(cci->base);