From patchwork Fri Feb 17 08:30:05 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yang Li X-Patchwork-Id: 58410 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp768421wrn; Fri, 17 Feb 2023 00:31:16 -0800 (PST) X-Google-Smtp-Source: AK7set/p084MK1yDF9DslUiA42uSNcAtEwZm6FdhJLzZs94xEBjmdCCF+/o6gMdPex/vhUXwrEzm X-Received: by 2002:a05:6a20:3104:b0:b8:5a85:6332 with SMTP id 4-20020a056a20310400b000b85a856332mr371169pzf.7.1676622676153; Fri, 17 Feb 2023 00:31:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1676622676; cv=none; d=google.com; s=arc-20160816; b=e9Ea27OV3cTy8OKIBG/uCOq7IA/yvGQK6hwPQeTrvY6wBvXQ9cdYHajU9W+EI3UBQL eO0aSMLlXdNSeYct92Jmu5wuDGAn2C4SBxQnVM3inFgXklqMrH0iW2VsV/K4Wpma5EK+ 1DKkrzEW3U0lb2Ud4H8Y+w6hZhJbxcih/P3Qa5Z1YxVUc5sLNPlB6FRH2f2JUXTmqJrW odRZFUHxP0WOdwDDAN5kOx6LRnhceNU50FR1g+ogAIwCsT/mawClGiLVZd+AQKWiaMee pShoWjuToGy1xiESRWLYg2GhAJLMzP0nkvDvz8z23hkaXxd/MKbD0WvDy0UIMKzO726u KWlg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=/JExXjUvrpCvXliP4f7woAZD1aumSHUr7tUYb//y2Es=; b=kv1vug9RrgpVx9golsaQfB6f8LNukN5s07rlKWsIRfWSUyZpB4ofK0oTRM5KajF/nJ I5mX15jfF5I3B1e28uStnrdcPmgD2CISqte856BRSjKf1E1YZXiaoZXiylV3Hlu2Ij4d k7UFW5+Ssh/AtS4qwrYq17mdV0CPgwAuV5l8Fk+QBdu0kul4XryVzaTQ79Wu/NliTZqg MYxMPY1ACfoFozkvge4oAFFTdjxYuu29gurBZ3f62/bPjztN8bI7kFQscYM5MGF1nNTn RD+9kqjL5LdyNFX3n7aH2sYis1frY8Hx4bNICrOQJS3QbNiFti1GOw++j9wYCYN/DxsG urbw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id o18-20020a63f152000000b004fc29eda891si2491009pgk.277.2023.02.17.00.31.03; Fri, 17 Feb 2023 00:31:16 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229840AbjBQIaO (ORCPT + 99 others); Fri, 17 Feb 2023 03:30:14 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60822 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229512AbjBQIaM (ORCPT ); Fri, 17 Feb 2023 03:30:12 -0500 Received: from out30-97.freemail.mail.aliyun.com (out30-97.freemail.mail.aliyun.com [115.124.30.97]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EE6631C596; Fri, 17 Feb 2023 00:30:10 -0800 (PST) X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R381e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018046056;MF=yang.lee@linux.alibaba.com;NM=1;PH=DS;RN=10;SR=0;TI=SMTPD_---0Vbs.8lH_1676622607; Received: from localhost(mailfrom:yang.lee@linux.alibaba.com fp:SMTPD_---0Vbs.8lH_1676622607) by smtp.aliyun-inc.com; Fri, 17 Feb 2023 16:30:08 +0800 From: Yang Li To: ulf.hansson@linaro.org Cc: neil.armstrong@linaro.org, khilman@baylibre.com, jbrunet@baylibre.com, martin.blumenstingl@googlemail.com, linux-mmc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-amlogic@lists.infradead.org, linux-kernel@vger.kernel.org, Yang Li Subject: [PATCH -next] mmc: meson-gx: Use devm_platform_get_and_ioremap_resource() Date: Fri, 17 Feb 2023 16:30:05 +0800 Message-Id: <20230217083005.128668-1-yang.lee@linux.alibaba.com> X-Mailer: git-send-email 2.20.1.7.g153144c MIME-Version: 1.0 X-Spam-Status: No, score=-9.9 required=5.0 tests=BAYES_00, ENV_AND_HDR_SPF_MATCH,SPF_HELO_NONE,SPF_PASS,UNPARSEABLE_RELAY, USER_IN_DEF_SPF_WL autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1758066299506687065?= X-GMAIL-MSGID: =?utf-8?q?1758066299506687065?= 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/mmc/host/meson-gx-mmc.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/mmc/host/meson-gx-mmc.c b/drivers/mmc/host/meson-gx-mmc.c index 079c52dbeca6..a5a9a19a9a42 100644 --- a/drivers/mmc/host/meson-gx-mmc.c +++ b/drivers/mmc/host/meson-gx-mmc.c @@ -1204,8 +1204,7 @@ static int meson_mmc_probe(struct platform_device *pdev) if (ret) return dev_err_probe(&pdev->dev, ret, "device reset failed\n"); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - host->regs = devm_ioremap_resource(&pdev->dev, res); + host->regs = devm_platform_get_and_ioremap_resource(pdev, 0, &res); if (IS_ERR(host->regs)) return PTR_ERR(host->regs);