From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 29098C6FD1F for ; Thu, 16 Mar 2023 05:44:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=h+LM0Y+xeYEX+PD/ceyKz8zspZH1mtfpXZfui9ZZH24=; b=Ion5aFF8uyXkAu Lbvo1DNHZWn4aRwCYF6ueC3l+7XKL8MHiz76Vf55HhPMuflFW1BCGN78Ed/2tKvS++wAoKYJCu2Yp H40cjpSXGPRSjKFGgLVVDaOzh2kaYklmtCOza16P2A3leUYYf84AyKKGFMUbwkfs5IXlZVvJLnbUA e4iVX1TJ/2xzYXztzfQ4ZlOcr5Y+bYBO9zTpUCs/IEV39khrOzltpnLeOn+uq75WeRlnMrLSjat6/ CQO8F9Z4yz6xh1ADlgQ7/xFQs776FYzkIBMmFRMd4Fh/8MYdV4p2716fQxuMWBK0eniqB+In4HllQ 9awnLpLJJ3FWePJrqeLA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1pcgOn-00FIXt-31; Thu, 16 Mar 2023 05:43:37 +0000 Received: from out30-100.freemail.mail.aliyun.com ([115.124.30.100]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1pcgOk-00FIX1-2C for linux-arm-kernel@lists.infradead.org; Thu, 16 Mar 2023 05:43:36 +0000 X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R591e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018046049;MF=yang.lee@linux.alibaba.com;NM=1;PH=DS;RN=5;SR=0;TI=SMTPD_---0VdymIEA_1678945406; Received: from localhost(mailfrom:yang.lee@linux.alibaba.com fp:SMTPD_---0VdymIEA_1678945406) by smtp.aliyun-inc.com; Thu, 16 Mar 2023 13:43:27 +0800 From: Yang Li To: michal.simek@xilinx.com Cc: linux-arm-kernel@lists.infradead.org, linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org, Yang Li Subject: [PATCH -next] i2c: xiic: Use devm_platform_get_and_ioremap_resource() Date: Thu, 16 Mar 2023 13:43:25 +0800 Message-Id: <20230316054325.108457-1-yang.lee@linux.alibaba.com> X-Mailer: git-send-email 2.20.1.7.g153144c MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230315_224334_914463_894BC5E7 X-CRM114-Status: UNSURE ( 8.72 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org According to commit 890cc39a8799 ("drivers: provide 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: Yang Li --- drivers/i2c/busses/i2c-xiic.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/i2c/busses/i2c-xiic.c b/drivers/i2c/busses/i2c-xiic.c index dbb792fc197e..0eea00d10545 100644 --- a/drivers/i2c/busses/i2c-xiic.c +++ b/drivers/i2c/busses/i2c-xiic.c @@ -1233,8 +1233,7 @@ static int xiic_i2c_probe(struct platform_device *pdev) i2c->quirks = data->quirks; } - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - i2c->base = devm_ioremap_resource(&pdev->dev, res); + i2c->base = devm_platform_get_and_ioremap_resource(pdev, 0, &res); if (IS_ERR(i2c->base)) return PTR_ERR(i2c->base); -- 2.20.1.7.g153144c _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel