Received: by 2002:a05:6a10:1d13:0:0:0:0 with SMTP id pp19csp873611pxb; Wed, 1 Sep 2021 11:49:18 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyxkD4rZ7EseoK5KJWDWDRFqgripu96Gq5lerdNjg/vfE1fqvmjVh4CnaImKTFRpd19io5h X-Received: by 2002:a05:6602:2436:: with SMTP id g22mr827910iob.109.1630522157179; Wed, 01 Sep 2021 11:49:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1630522157; cv=none; d=google.com; s=arc-20160816; b=wVgv97w6bHM9bEG4SqIon3DLBR2nAJsIoQ3bjTLQhPhOLR8cvDJsmksleK/fTZOot7 CiNVzYfr/kGo7Ck6ZqMdTHGlTXmeIze+4/nUzr/LeZ1XpVQIfZcSeow6VDRwfdvaU/kX gawN4MkeQKPBxlZjxQPNtXX6g7wTI5vw2RhwW/CmP7yh97bF1mTtGKzp6VYuE6YZNkZs q5XjKnfBvQmAKCPmasttpQlv2tph8SMrEf6ilUWl8UkwdtbZxCSqJJDC8AIdNiGhLWLP Ntfpog8+u/lL/B59bHlEeElSulCro7GDHYG8eTnMlv5ynLTQm+i9t4/lrsb/D4roJNJu mOWw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from; bh=310Suj7KqBDGrpFHEcS/UK7JSWVqJk2QG2EyfU+DF6g=; b=IMJPBIKcO/O69YlYhjjiGpFY4bKlLWTcBX6n2umNgS3fxFAn+v1yBXl6HKfit5ig7A 951tDADntGZSR1mrxV2E8jV8LmwgeENj0BTYCA0ENlb3QayF9nALwOOamgVdNX4ggJtC gH5WbAU3bmi/b9Mrla9A6Bpnu7uvRq59qC/zSg5gv5iN7DFyH8RghU8qaEO2/zMsy9ty /BD8jAFhOJyHAlAJFUZSJxEmbo86EBxkMA0tSFyOh/c9HXXtqrhUQu6rgX+MTH8u+4x9 xLVcbhBjSrluEI9CRjfj99bRItT1MqOw+D4gdV7xLEqQOxyC8vwsibHox9xMbLLCJK0S RrAw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id p6si336861ilj.154.2021.09.01.11.49.06; Wed, 01 Sep 2021 11:49:17 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242579AbhIAHma (ORCPT + 99 others); Wed, 1 Sep 2021 03:42:30 -0400 Received: from mx21.baidu.com ([220.181.3.85]:53146 "EHLO baidu.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S242697AbhIAHm1 (ORCPT ); Wed, 1 Sep 2021 03:42:27 -0400 Received: from BJHW-Mail-Ex11.internal.baidu.com (unknown [10.127.64.34]) by Forcepoint Email with ESMTPS id B7616A793941BB51D41B; Wed, 1 Sep 2021 15:41:29 +0800 (CST) Received: from BJHW-MAIL-EX27.internal.baidu.com (10.127.64.42) by BJHW-Mail-Ex11.internal.baidu.com (10.127.64.34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2308.14; Wed, 1 Sep 2021 15:41:29 +0800 Received: from LAPTOP-UKSR4ENP.internal.baidu.com (172.31.63.8) by BJHW-MAIL-EX27.internal.baidu.com (10.127.64.42) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2308.14; Wed, 1 Sep 2021 15:41:29 +0800 From: Cai Huoqing To: CC: Miquel Raynal , Richard Weinberger , Vignesh Raghavendra , , Subject: [PATCH] mtd: rawnand: gpio: Make use of the helper function devm_platform_ioremap_resource() Date: Wed, 1 Sep 2021 15:41:22 +0800 Message-ID: <20210901074123.9033-1-caihuoqing@baidu.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [172.31.63.8] X-ClientProxiedBy: BJHW-Mail-Ex07.internal.baidu.com (10.127.64.17) To BJHW-MAIL-EX27.internal.baidu.com (10.127.64.42) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Use the devm_platform_ioremap_resource() helper instead of calling platform_get_resource() and devm_ioremap_resource() separately Signed-off-by: Cai Huoqing --- drivers/mtd/nand/raw/gpio.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/mtd/nand/raw/gpio.c b/drivers/mtd/nand/raw/gpio.c index fb7a086de35e..8901c4aa0c21 100644 --- a/drivers/mtd/nand/raw/gpio.c +++ b/drivers/mtd/nand/raw/gpio.c @@ -303,8 +303,7 @@ static int gpio_nand_probe(struct platform_device *pdev) chip = &gpiomtd->nand_chip; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - gpiomtd->io = devm_ioremap_resource(dev, res); + gpiomtd->io = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(gpiomtd->io)) return PTR_ERR(gpiomtd->io); -- 2.25.1