From patchwork Thu Oct 17 12:26:11 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195771 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 2319913BD for ; Thu, 17 Oct 2019 12:50:37 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id BD89F214E0 for ; Thu, 17 Oct 2019 12:50:36 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="cqmQ5kJK" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org BD89F214E0 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=z6tZeqlW8etHeB/Fj7C9Ma+o+3P8m0naMxVV6GT4TzQ=; b=cqmQ5kJK3/WSlX +aMcFequ3wg9GlycrQ994insJo7jBweHab9RHjQZbvUdjF29OlSQbA/yYe5b+U+8/Zqg2k93uX267 e4OCfW7Liy3dRQkgLeVLsWU8+FfMQktQg9V62I2ofwd3MZt5QoU1VmCau//6izNjtKkcEYBaZoYLY D8osgAKYWJtMw4qUowhpvGpl+/40k+7CtLJtMBDwbNx5viRUdZTwz7za8QpwMn17wO14lC5U6GmzX TA6uGfBBtd/Q6ojRTuygP6fB80S/ssw/VczceEZ2Lm8zB5B6nkt5Xe5GG1AP1uEUHI2C80dLojQiI y2y3VJE8k9ttV0t558Gg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Ea-0007F0-Th; Thu, 17 Oct 2019 12:50:28 +0000 Received: from szxga04-in.huawei.com ([45.249.212.190] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Cb-0004HN-DR for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:27 +0000 Received: from DGGEMS413-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id 2EBA61F014ACEAE9646D; Thu, 17 Oct 2019 20:48:11 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS413-HUB.china.huawei.com (10.3.19.213) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:04 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 01/30] pinctrl: pxa25x: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:11 +0800 Message-ID: <20191017122640.22976-2-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054825_792583_A810D5E1 X-CRM114-Status: UNSURE ( 8.40 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.190 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/pxa/pinctrl-pxa25x.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/drivers/pinctrl/pxa/pinctrl-pxa25x.c b/drivers/pinctrl/pxa/pinctrl-pxa25x.c index 8d12470..9564069 100644 --- a/drivers/pinctrl/pxa/pinctrl-pxa25x.c +++ b/drivers/pinctrl/pxa/pinctrl-pxa25x.c @@ -216,25 +216,20 @@ static int pxa25x_pinctrl_probe(struct platform_device *pdev) void __iomem *base_af[8]; void __iomem *base_dir[4]; void __iomem *base_sleep[4]; - struct resource *res; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - base_af[0] = devm_ioremap_resource(&pdev->dev, res); + base_af[0] = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(base_af[0])) return PTR_ERR(base_af[0]); - res = platform_get_resource(pdev, IORESOURCE_MEM, 1); - base_dir[0] = devm_ioremap_resource(&pdev->dev, res); + base_dir[0] = devm_platform_ioremap_resource(pdev, 1); if (IS_ERR(base_dir[0])) return PTR_ERR(base_dir[0]); - res = platform_get_resource(pdev, IORESOURCE_MEM, 2); - base_dir[3] = devm_ioremap_resource(&pdev->dev, res); + base_dir[3] = devm_platform_ioremap_resource(pdev, 2); if (IS_ERR(base_dir[3])) return PTR_ERR(base_dir[3]); - res = platform_get_resource(pdev, IORESOURCE_MEM, 3); - base_sleep[0] = devm_ioremap_resource(&pdev->dev, res); + base_sleep[0] = devm_platform_ioremap_resource(pdev, 3); if (IS_ERR(base_sleep[0])) return PTR_ERR(base_sleep[0]); From patchwork Thu Oct 17 12:26:12 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195669 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 1749813BD for ; Thu, 17 Oct 2019 12:48:41 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id E9CE320854 for ; Thu, 17 Oct 2019 12:48:40 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="IZYjQiXi" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E9CE320854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=WEgton0f2swL4APzgVAG6Tj1zL5oNf8fNVfwhqNxhVw=; b=IZYjQiXiODLnFA aE+JUf9Vqh7KIg9Ozzfjon956TbdjwF2ia0KdVlS8Lgwg10OvQwbmbMm7+ULZyb0QuoIJkg/0w52D /+p+TmlQFuozuaIYvBlAmOOjxMepLE21GRG2m56dcE6QqWN51cpPOhD7H/vtxmKFnYxKBlmATKLiM 0k5f5gmPwkBdauoOVuX/v/4YHY+JKPr9aQmYZ0zDlcfowx4PlBSYD6I5K86tIaCpGnMFgjEMyeKdk wvMWi458WUslmMiaUsZQSlR70Hq3PiMEZ38A7y+T52uR6DzGkasuEGYE+7u/+kwXP+eDYnO9czgan hPanXRwI773L9Gz7spQA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Cp-0004Wd-Lk; Thu, 17 Oct 2019 12:48:39 +0000 Received: from szxga07-in.huawei.com ([45.249.212.35] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5CU-0004Gc-6H for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:20 +0000 Received: from DGGEMS403-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id B8427EC39B2F6B85D09E; Thu, 17 Oct 2019 20:48:16 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS403-HUB.china.huawei.com (10.3.19.203) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:06 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 02/30] pinctrl: pxa27x: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:12 +0800 Message-ID: <20191017122640.22976-3-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054818_812905_8A8FE4D9 X-CRM114-Status: UNSURE ( 8.29 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.35 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/pxa/pinctrl-pxa27x.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/drivers/pinctrl/pxa/pinctrl-pxa27x.c b/drivers/pinctrl/pxa/pinctrl-pxa27x.c index 64943e8..48ccfb5 100644 --- a/drivers/pinctrl/pxa/pinctrl-pxa27x.c +++ b/drivers/pinctrl/pxa/pinctrl-pxa27x.c @@ -508,25 +508,20 @@ static int pxa27x_pinctrl_probe(struct platform_device *pdev) void __iomem *base_af[8]; void __iomem *base_dir[4]; void __iomem *base_sleep[4]; - struct resource *res; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - base_af[0] = devm_ioremap_resource(&pdev->dev, res); + base_af[0] = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(base_af[0])) return PTR_ERR(base_af[0]); - res = platform_get_resource(pdev, IORESOURCE_MEM, 1); - base_dir[0] = devm_ioremap_resource(&pdev->dev, res); + base_dir[0] = devm_platform_ioremap_resource(pdev, 1); if (IS_ERR(base_dir[0])) return PTR_ERR(base_dir[0]); - res = platform_get_resource(pdev, IORESOURCE_MEM, 2); - base_dir[3] = devm_ioremap_resource(&pdev->dev, res); + base_dir[3] = devm_platform_ioremap_resource(pdev, 2); if (IS_ERR(base_dir[3])) return PTR_ERR(base_dir[3]); - res = platform_get_resource(pdev, IORESOURCE_MEM, 3); - base_sleep[0] = devm_ioremap_resource(&pdev->dev, res); + base_sleep[0] = devm_platform_ioremap_resource(pdev, 3); if (IS_ERR(base_sleep[0])) return PTR_ERR(base_sleep[0]); From patchwork Thu Oct 17 12:26:13 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195683 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 3FEE813BD for ; Thu, 17 Oct 2019 12:49:01 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 1D0A621835 for ; Thu, 17 Oct 2019 12:49:01 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="YLP94e5B" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1D0A621835 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=YZKBAPxJckb62UQecV8LlOUQzYQEiF1ShcC25UWDBUA=; b=YLP94e5BvaCwfH lHIm0IpAA86/hjRvcPpbhnab2nEMEcNhZjcMe9/cz4lOMz3sUZJg9NAfvNfoP48Gz8ohbYPk4+KTt Ba/Naf/H2tokc5XVvPvHtlkoZJzoGrERc+njqSRScyj3ZHiLKQ3U0rX8LmhSDBZBKJ7vuANHNaviN QppsoGYQJHnSUPkaluY/9eKRAqzwrs028DfxObsTaa4K3VZ4zkyJqR/w/4DRHzCVyj1dXAgvcHFVt BlrZFks+W5JXxvQJwIXHWKFqCYoeOZHrdlHBfzQLE1+ba4GIpHx5sPElIaQuLFkaziNf/BknkLWPj eAd8XLZd+/g33OmMUoZw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5D9-0004rT-Dl; Thu, 17 Oct 2019 12:48:59 +0000 Received: from szxga05-in.huawei.com ([45.249.212.191] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5CW-0004GH-4L for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:21 +0000 Received: from DGGEMS405-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id DB37F1BC907B28B1DAF3; Thu, 17 Oct 2019 20:48:15 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS405-HUB.china.huawei.com (10.3.19.205) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:08 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 03/30] pinctrl: cygnus-mux: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:13 +0800 Message-ID: <20191017122640.22976-4-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054820_337785_B652EAD4 X-CRM114-Status: UNSURE ( 9.64 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.191 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/bcm/pinctrl-cygnus-mux.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/pinctrl/bcm/pinctrl-cygnus-mux.c b/drivers/pinctrl/bcm/pinctrl-cygnus-mux.c index dcab220..4344c57 100644 --- a/drivers/pinctrl/bcm/pinctrl-cygnus-mux.c +++ b/drivers/pinctrl/bcm/pinctrl-cygnus-mux.c @@ -940,7 +940,6 @@ static int cygnus_mux_log_init(struct cygnus_pinctrl *pinctrl) static int cygnus_pinmux_probe(struct platform_device *pdev) { struct cygnus_pinctrl *pinctrl; - struct resource *res; int i, ret; struct pinctrl_pin_desc *pins; unsigned num_pins = ARRAY_SIZE(cygnus_pins); @@ -953,15 +952,13 @@ static int cygnus_pinmux_probe(struct platform_device *pdev) platform_set_drvdata(pdev, pinctrl); spin_lock_init(&pinctrl->lock); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - pinctrl->base0 = devm_ioremap_resource(&pdev->dev, res); + pinctrl->base0 = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(pinctrl->base0)) { dev_err(&pdev->dev, "unable to map I/O space\n"); return PTR_ERR(pinctrl->base0); } - res = platform_get_resource(pdev, IORESOURCE_MEM, 1); - pinctrl->base1 = devm_ioremap_resource(&pdev->dev, res); + pinctrl->base1 = devm_platform_ioremap_resource(pdev, 1); if (IS_ERR(pinctrl->base1)) { dev_err(&pdev->dev, "unable to map I/O space\n"); return PTR_ERR(pinctrl->base1); From patchwork Thu Oct 17 12:26:14 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195689 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id AC7D813BD for ; Thu, 17 Oct 2019 12:49:22 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 7B27A21835 for ; Thu, 17 Oct 2019 12:49:22 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="OYiqqdo+" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 7B27A21835 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=fwIpBrlBMUzeUr72JRCWWem48pXsLWEMgnJf+xbrppI=; b=OYiqqdo+lQeMfp TLs6hkYUK9PVZf6HK1+8vApBLjcu5+J7BLxRRLgxkVGg+8chwrEaTmwgJfw1r61jTqHxGKBO3x/fw 56Di22ztJL2s/Kwj8TJs9OYdZJaaCxN0xjQ12/Eo2C6gRJ0avcZad2TMZ0+3FyeiQ1qBdeizJHkT4 KTsDLnw2ljozl3HkNIhPRalRf+FQhu+gG4qRgReDYru5XNpyzkom+oX0G9hWRZDicoAnH8dvDlQ3I gauNYVUKw/AumP+Oq+/AlL7yiXGbnGVWaSqBnVHWygCxvYYD9r3bjtR4Tve71DQQRugH84Lu5Tt8+ VQ9Tkm0/7K6CG0Pm/uKw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5DU-0005AL-IL; Thu, 17 Oct 2019 12:49:20 +0000 Received: from szxga04-in.huawei.com ([45.249.212.190] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5CY-0004Gy-IZ for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:24 +0000 Received: from DGGEMS411-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id 1C6EEA0285BC7057AC06; Thu, 17 Oct 2019 20:48:18 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS411-HUB.china.huawei.com (10.3.19.211) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:11 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 04/30] pinctrl: pic32: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:14 +0800 Message-ID: <20191017122640.22976-5-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054822_811346_39EA26CF X-CRM114-Status: UNSURE ( 9.18 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.190 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/pinctrl-pic32.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-pic32.c b/drivers/pinctrl/pinctrl-pic32.c index 7e4c5a0..e5d6d3f 100644 --- a/drivers/pinctrl/pinctrl-pic32.c +++ b/drivers/pinctrl/pinctrl-pic32.c @@ -2202,7 +2202,6 @@ static int pic32_gpio_probe(struct platform_device *pdev) struct pic32_gpio_bank *bank; u32 id; int irq, ret; - struct resource *res; struct gpio_irq_chip *girq; if (of_property_read_u32(np, "microchip,gpio-bank", &id)) { @@ -2217,8 +2216,7 @@ static int pic32_gpio_probe(struct platform_device *pdev) bank = &pic32_gpio_banks[id]; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - bank->reg_base = devm_ioremap_resource(&pdev->dev, res); + bank->reg_base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(bank->reg_base)) return PTR_ERR(bank->reg_base); From patchwork Thu Oct 17 12:26:15 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195703 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id AB52713BD for ; Thu, 17 Oct 2019 12:49:44 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 895F3214E0 for ; Thu, 17 Oct 2019 12:49:44 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="nIkg8HEX" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 895F3214E0 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=RAwhaclH5oiXGWVG47h5rVz1I8MwYalo/p51lQmMgk0=; b=nIkg8HEXIKiw2M leXfTGq9J/y838vT4b5nylSrJXdOil1pz47n2RcSL3UkNkM3JvkfRB2Z9aNvD+x0CSipUOXr6Cs9G dOMsvTnFJquMKw9OX/DUDD30fMUe4TQJkhVFZKPmtI3KzMFALc8KTq5WZRA/aIJrDKvuq4kd7Qy+m f5RSXIIiSN6yyapNF71WMK3YXWEPKhVZ1Y/7SklbQz7Tx6N2YR5+PzAjVmRCfLo1lXA42i2aNjM2t hvpWyYkd9HqScf48fYGVKXTWIrbu4EH5BizClEJkjg2/krtfat1NhhZvD1r1v2lgvf0gQMuFepu1N y85bvzsi3uBQnE0org5w==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Dq-0005Rz-5f; Thu, 17 Oct 2019 12:49:42 +0000 Received: from szxga05-in.huawei.com ([45.249.212.191] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5CZ-0004Il-27 for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:24 +0000 Received: from DGGEMS403-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id 8AC5BB2FB796D21AB281; Thu, 17 Oct 2019 20:48:21 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS403-HUB.china.huawei.com (10.3.19.203) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:13 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 05/30] pinctrl: nsp-gpio: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:15 +0800 Message-ID: <20191017122640.22976-6-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054823_290909_D55711AC X-CRM114-Status: UNSURE ( 9.91 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.191 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/bcm/pinctrl-nsp-gpio.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/pinctrl/bcm/pinctrl-nsp-gpio.c b/drivers/pinctrl/bcm/pinctrl-nsp-gpio.c index e67ae52..8db87e5 100644 --- a/drivers/pinctrl/bcm/pinctrl-nsp-gpio.c +++ b/drivers/pinctrl/bcm/pinctrl-nsp-gpio.c @@ -613,7 +613,6 @@ static const struct of_device_id nsp_gpio_of_match[] = { static int nsp_gpio_probe(struct platform_device *pdev) { struct device *dev = &pdev->dev; - struct resource *res; struct nsp_gpio *chip; struct gpio_chip *gc; u32 val, count; @@ -631,15 +630,13 @@ static int nsp_gpio_probe(struct platform_device *pdev) chip->dev = dev; platform_set_drvdata(pdev, chip); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - chip->base = devm_ioremap_resource(dev, res); + chip->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(chip->base)) { dev_err(dev, "unable to map I/O memory\n"); return PTR_ERR(chip->base); } - res = platform_get_resource(pdev, IORESOURCE_MEM, 1); - chip->io_ctrl = devm_ioremap_resource(dev, res); + chip->io_ctrl = devm_platform_ioremap_resource(pdev, 1); if (IS_ERR(chip->io_ctrl)) { dev_err(dev, "unable to map I/O memory\n"); return PTR_ERR(chip->io_ctrl); From patchwork Thu Oct 17 12:26:16 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195735 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id A3E5813BD for ; Thu, 17 Oct 2019 12:50:05 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 7C119214E0 for ; Thu, 17 Oct 2019 12:50:05 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="Q/DKFgI8" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 7C119214E0 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=xEumAR4LN/WTAZDCxDYh62YZMmb2oMFOokjdM7Mys5g=; b=Q/DKFgI8nfinj9 dpMKk7mKir4VrJH3h/b46EFUDSEC3mTo8gxEt1vrFz764MRXpuX+DZLsfMjq86tC/5hnXb4TJTJTb NGO/ZDqMVloNyyNEg2vF+Ae9zCKAhoZuCoU5zJdqf2kvGKtFg3VfzjmOs4kD7nA2fMvktA4pgDwMS Axx8m72xmypcQlOv8yEMKgyfyKt+Tqwt3O6OKH62eBijUoCkurO/ksivHWMbJUEUEx7NL/se85qQj MMTWakePCVAmFQ773kV05eTHSIZJu4ZohkIfku0/8Ky5Sh68oXtIBEadE0jJAC/UrhZek20I0aJRb vDi8l/0XDmlCFHmxR3IA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5EC-0005md-Qd; Thu, 17 Oct 2019 12:50:04 +0000 Received: from szxga04-in.huawei.com ([45.249.212.190] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Ca-0004KR-Mw for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:26 +0000 Received: from DGGEMS402-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id 244A2DE6D269943AC0B1; Thu, 17 Oct 2019 20:48:23 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS402-HUB.china.huawei.com (10.3.19.202) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:16 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 06/30] pinctrl: nsp: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:16 +0800 Message-ID: <20191017122640.22976-7-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054824_938278_86EC035E X-CRM114-Status: UNSURE ( 8.91 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.190 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/bcm/pinctrl-nsp-mux.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/pinctrl/bcm/pinctrl-nsp-mux.c b/drivers/pinctrl/bcm/pinctrl-nsp-mux.c index 87618a4..3756fc9 100644 --- a/drivers/pinctrl/bcm/pinctrl-nsp-mux.c +++ b/drivers/pinctrl/bcm/pinctrl-nsp-mux.c @@ -571,8 +571,7 @@ static int nsp_pinmux_probe(struct platform_device *pdev) platform_set_drvdata(pdev, pinctrl); spin_lock_init(&pinctrl->lock); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - pinctrl->base0 = devm_ioremap_resource(&pdev->dev, res); + pinctrl->base0 = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(pinctrl->base0)) return PTR_ERR(pinctrl->base0); @@ -586,8 +585,7 @@ static int nsp_pinmux_probe(struct platform_device *pdev) return -ENOMEM; } - res = platform_get_resource(pdev, IORESOURCE_MEM, 2); - pinctrl->base2 = devm_ioremap_resource(&pdev->dev, res); + pinctrl->base2 = devm_platform_ioremap_resource(pdev, 2); if (IS_ERR(pinctrl->base2)) return PTR_ERR(pinctrl->base2); From patchwork Thu Oct 17 12:26:17 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195789 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id B910013BD for ; Thu, 17 Oct 2019 12:51:12 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 8BF0E20854 for ; Thu, 17 Oct 2019 12:51:12 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="j1XOIJOp" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 8BF0E20854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=SOdLluCmHcsMC3F48Q+3kNir7+9RuONeFDfyyCoJTYs=; b=j1XOIJOpfk4L0a 86HOEXH8/tAhvfbiv6uTmRUbBMKbeBnnK43LfLrpzGmgylRuQ0hexF0CuT2z/P608ckn5hQVodnbX vJbovPLFCFw4SqxSkc/cZ5TarkOkj13KX3yO4eFaii/i30hDBWyc952/26rQ04QmLEayJc0Ii/rFx pzQnUN4nGg+NZsv6T0xDp+XM++P5/J1SZ6wWKILayRvS8rnRkivGqtppfSGIA6YAEIS+sbOVnT1ZD mXzxVvJpe7cmQmdDfs11RoRpLHjMruoP3lj6N9EyecnLpui4sTfL9KZbS/xJ3ETi4MCaQ8TmreePN jlp8GVKy2ADQHLPMvruQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5FH-0007nw-Nx; Thu, 17 Oct 2019 12:51:11 +0000 Received: from szxga07-in.huawei.com ([45.249.212.35] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Ch-0004R0-Ma for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:33 +0000 Received: from DGGEMS401-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id B4EFF685EF95C51EF687; Thu, 17 Oct 2019 20:48:29 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS401-HUB.china.huawei.com (10.3.19.201) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:19 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 07/30] pinctrl: ns2: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:17 +0800 Message-ID: <20191017122640.22976-8-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054831_958214_90AC5EDC X-CRM114-Status: UNSURE ( 8.53 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.35 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/bcm/pinctrl-ns2-mux.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/pinctrl/bcm/pinctrl-ns2-mux.c b/drivers/pinctrl/bcm/pinctrl-ns2-mux.c index 9fabc45..32f268f 100644 --- a/drivers/pinctrl/bcm/pinctrl-ns2-mux.c +++ b/drivers/pinctrl/bcm/pinctrl-ns2-mux.c @@ -1042,8 +1042,7 @@ static int ns2_pinmux_probe(struct platform_device *pdev) platform_set_drvdata(pdev, pinctrl); spin_lock_init(&pinctrl->lock); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - pinctrl->base0 = devm_ioremap_resource(&pdev->dev, res); + pinctrl->base0 = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(pinctrl->base0)) return PTR_ERR(pinctrl->base0); @@ -1057,8 +1056,7 @@ static int ns2_pinmux_probe(struct platform_device *pdev) return -ENOMEM; } - res = platform_get_resource(pdev, IORESOURCE_MEM, 2); - pinctrl->pinconf_base = devm_ioremap_resource(&pdev->dev, res); + pinctrl->pinconf_base = devm_platform_ioremap_resource(pdev, 2); if (IS_ERR(pinctrl->pinconf_base)) return PTR_ERR(pinctrl->pinconf_base); From patchwork Thu Oct 17 12:26:18 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195791 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id A9AD314DB for ; Thu, 17 Oct 2019 12:51:26 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 4198D20854 for ; Thu, 17 Oct 2019 12:51:26 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="Jp4lgTRf" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4198D20854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=F044o9kEh8E+m7IOVjWuEazLZv3Dp4n8Lh4jdOLnPzA=; b=Jp4lgTRfnJYbT6 UsdhKjSJAcq3cHxCxLgTKwLMxBU8jDcIHoNv1lrabJrc29RGHWi60a/Ibf2VeXJOxg4/M5+SgOi2a uTmrkRod+CK5Ue5R9KVg1I8r7zBKIPI3skE9HIwyd+KeBEJlz9JgKffWZN1xyRdsQuIHgHJUkHSX+ Q/yQzzOP8E2MlvCt0vL0aY/CoWzyol3zTjo6/p9eJaudgZ3kA0QLTuPiRaGOjOZUuxK9YnetvQQg4 eWsAXJ5GuaTVyYcIsdz2BoSOx2Q+mYm2YKNVR2Ih95yfJ2T9DJL1j6CfvtJ3bqbsuoDVgPspJ+xI5 4gNu39EqPo5kzP2/TpcQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5FU-00080u-Hf; Thu, 17 Oct 2019 12:51:24 +0000 Received: from szxga04-in.huawei.com ([45.249.212.190] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Cj-0004Se-FW for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:35 +0000 Received: from DGGEMS414-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id CBF3761E3E7450A6C30C; Thu, 17 Oct 2019 20:48:31 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS414-HUB.china.huawei.com (10.3.19.214) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:21 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 08/30] pinctrl: bcm281xx: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:18 +0800 Message-ID: <20191017122640.22976-9-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054834_104468_FFDD5675 X-CRM114-Status: GOOD ( 10.26 ) X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.190 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/bcm/pinctrl-bcm281xx.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/bcm/pinctrl-bcm281xx.c b/drivers/pinctrl/bcm/pinctrl-bcm281xx.c index bc3b232..f690fc5 100644 --- a/drivers/pinctrl/bcm/pinctrl-bcm281xx.c +++ b/drivers/pinctrl/bcm/pinctrl-bcm281xx.c @@ -1400,12 +1400,10 @@ static struct pinctrl_desc bcm281xx_pinctrl_desc = { static int __init bcm281xx_pinctrl_probe(struct platform_device *pdev) { struct bcm281xx_pinctrl_data *pdata = &bcm281xx_pinctrl; - struct resource *res; struct pinctrl_dev *pctl; /* So far We can assume there is only 1 bank of registers */ - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - pdata->reg_base = devm_ioremap_resource(&pdev->dev, res); + pdata->reg_base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(pdata->reg_base)) { dev_err(&pdev->dev, "Failed to ioremap MEM resource\n"); return -ENODEV; From patchwork Thu Oct 17 12:26:19 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195793 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id B6B2B13BD for ; Thu, 17 Oct 2019 12:51:42 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 947E420854 for ; Thu, 17 Oct 2019 12:51:42 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="rv6FXUof" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 947E420854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=zg6022oS+wRc1V200J9VVwm2AlEjyw7xz1w8GYPde04=; b=rv6FXUofxPQV6P UVuQ9Fe/sOCiCKaJYLj58wy9rKvoO39I15vhGJHya85r3dK1+6wCkjMTsl6rGSZiLznA6xG7yZHBx /jA4UqXCkccru0h/50Zwqd6tlP5DVzJdfoxu0XomSjXvV9T/uzlu9YG3OMKJR10NcFMvL12lTuw8V U/4vG7j8YVr+7Uj7VeXDChU4/9uaaJ1pt4TzKbUBpmX4K0rh4Wx5d5bYbIu+pLDnjIBWnyHJHsYK3 UfUfEECzMfMHrn2fHQIs0S5dg1MyBXlNiD83g+HWfVvNCwaJn7CbHUGAjLbZF31srM/QaWCdPhWpO pcpNN2JBUwHaT3YDaoAQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Fl-0008H1-Vs; Thu, 17 Oct 2019 12:51:41 +0000 Received: from szxga07-in.huawei.com ([45.249.212.35] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Cl-0004Ta-Kp for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:37 +0000 Received: from DGGEMS402-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id 44A7D8F936FF819573C2; Thu, 17 Oct 2019 20:48:33 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS402-HUB.china.huawei.com (10.3.19.202) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:24 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 09/30] pinctrl: sunxi: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:19 +0800 Message-ID: <20191017122640.22976-10-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054835_893765_EFB171FB X-CRM114-Status: UNSURE ( 8.70 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.35 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/sunxi/pinctrl-sunxi.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/sunxi/pinctrl-sunxi.c b/drivers/pinctrl/sunxi/pinctrl-sunxi.c index 0cbca30..b35c324 100644 --- a/drivers/pinctrl/sunxi/pinctrl-sunxi.c +++ b/drivers/pinctrl/sunxi/pinctrl-sunxi.c @@ -1385,7 +1385,6 @@ int sunxi_pinctrl_init_with_variant(struct platform_device *pdev, struct pinctrl_pin_desc *pins; struct sunxi_pinctrl *pctl; struct pinmux_ops *pmxops; - struct resource *res; int i, ret, last_pin, pin_idx; struct clk *clk; @@ -1396,8 +1395,7 @@ int sunxi_pinctrl_init_with_variant(struct platform_device *pdev, raw_spin_lock_init(&pctl->lock); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - pctl->membase = devm_ioremap_resource(&pdev->dev, res); + pctl->membase = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(pctl->membase)) return PTR_ERR(pctl->membase); From patchwork Thu Oct 17 12:26:20 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195795 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 742B113BD for ; Thu, 17 Oct 2019 12:52:03 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 5199A20854 for ; Thu, 17 Oct 2019 12:52:03 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="DW6i0bSl" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 5199A20854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=m2mSzh1xLyWpAznHaMxcp79OoHcZBll9xdFgIxm6zDE=; b=DW6i0bSldCl3bV 6QciQFsiyndUeIIOdNhAS0cJK46IQAhBFdA0RQ1qmo+vxvTgvSuB2aSVriK1+ZK6PmQHpFwOc7PhP /+1M4B5iMYj0/y/RpUNaF7MLOM+KqEjh+L0d5rlhvn/T4DabkQmsSiLiudsetcm40orgnGVKyddZn FYptwl0vjtKnN56U/ybK8yjaiy5H1U03aPeeyISP50W/F9p4GEWuOaJ9AUoDI/6pDv5q7t/e4pA94 YQS7ruc9mIcvr90Io/XUYr3cxdsTRZj+OoZ5b7xDXorAcqvrRtrXstv5Y/h8g8QtWsJJ0iTyRZmOK lvALyGYW/ply660E1DDg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5G6-00007Y-KU; Thu, 17 Oct 2019 12:52:02 +0000 Received: from szxga04-in.huawei.com ([45.249.212.190] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Co-0004WC-5b for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:41 +0000 Received: from DGGEMS401-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id C0D9B979CB2B58CDF78E; Thu, 17 Oct 2019 20:48:34 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS401-HUB.china.huawei.com (10.3.19.201) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:26 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 10/30] pinctrl: tegra: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:20 +0800 Message-ID: <20191017122640.22976-11-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054838_808863_A047ED8B X-CRM114-Status: UNSURE ( 9.75 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.190 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing Acked-by: Thierry Reding --- drivers/pinctrl/tegra/pinctrl-tegra-xusb.c | 4 +--- drivers/pinctrl/tegra/pinctrl-tegra.c | 3 +-- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/pinctrl/tegra/pinctrl-tegra-xusb.c b/drivers/pinctrl/tegra/pinctrl-tegra-xusb.c index f2fa1f7..6f7b376 100644 --- a/drivers/pinctrl/tegra/pinctrl-tegra-xusb.c +++ b/drivers/pinctrl/tegra/pinctrl-tegra-xusb.c @@ -873,7 +873,6 @@ int tegra_xusb_padctl_legacy_probe(struct platform_device *pdev) { struct tegra_xusb_padctl *padctl; const struct of_device_id *match; - struct resource *res; struct phy *phy; int err; @@ -894,8 +893,7 @@ int tegra_xusb_padctl_legacy_probe(struct platform_device *pdev) match = of_match_node(tegra_xusb_padctl_of_match, pdev->dev.of_node); padctl->soc = match->data; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - padctl->regs = devm_ioremap_resource(&pdev->dev, res); + padctl->regs = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(padctl->regs)) return PTR_ERR(padctl->regs); diff --git a/drivers/pinctrl/tegra/pinctrl-tegra.c b/drivers/pinctrl/tegra/pinctrl-tegra.c index e9a7cbb..692d8b3 100644 --- a/drivers/pinctrl/tegra/pinctrl-tegra.c +++ b/drivers/pinctrl/tegra/pinctrl-tegra.c @@ -781,8 +781,7 @@ int tegra_pinctrl_probe(struct platform_device *pdev, return -ENOMEM; for (i = 0; i < pmx->nbanks; i++) { - res = platform_get_resource(pdev, IORESOURCE_MEM, i); - pmx->regs[i] = devm_ioremap_resource(&pdev->dev, res); + pmx->regs[i] = devm_platform_ioremap_resource(pdev, i); if (IS_ERR(pmx->regs[i])) return PTR_ERR(pmx->regs[i]); } From patchwork Thu Oct 17 12:26:21 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195797 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id A3D7D14DB for ; Thu, 17 Oct 2019 12:52:18 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 81BD020854 for ; Thu, 17 Oct 2019 12:52:18 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="KoV/2nDv" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 81BD020854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=X/pOpmR+yAAmtZv4SjJ2DG6PAksUk903/lLSSPhSPzc=; b=KoV/2nDv1AzxsL KITkz1kfaTWeoBdiF6DQhiJs/rN2DfJbRyVHP7zN5gQ8FclAbj8poNA9tgv4pSJYecnu0yccy2Kcp VNAohMOYbAIlodbd7v1SZC60C29zcVYyvhEZjXcKOafE3q9FVVleXr2pur06N1I9eDZHUwvYsyP4W w8Zvx3kji88b/fbfeLHm7XBdyPe+JETExZYsFn8iIS/kOxpuJOAuwPp3IoOfoBFpWdZoJOPYae018 H80C9NDXRQKezvHKZlXkSW3ETYZejx0fY8ddlkrR/+/Yn1E8pLA5HuIMPBXAJF3kaaqwxMAdVKoLn /KTqrRHdsuHXPWHTxi6g==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5GL-0000KO-Cp; Thu, 17 Oct 2019 12:52:17 +0000 Received: from szxga07-in.huawei.com ([45.249.212.35] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Cs-0004YY-J0 for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:44 +0000 Received: from DGGEMS404-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id AED7093E256819B6443D; Thu, 17 Oct 2019 20:48:38 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS404-HUB.china.huawei.com (10.3.19.204) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:29 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 11/30] pinctrl: msm: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:21 +0800 Message-ID: <20191017122640.22976-12-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054843_267841_8272957F X-CRM114-Status: UNSURE ( 9.98 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.35 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing Reviewed-by: Bjorn Andersson --- drivers/pinctrl/qcom/pinctrl-msm.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/pinctrl/qcom/pinctrl-msm.c b/drivers/pinctrl/qcom/pinctrl-msm.c index 763da0b..62fcae9 100644 --- a/drivers/pinctrl/qcom/pinctrl-msm.c +++ b/drivers/pinctrl/qcom/pinctrl-msm.c @@ -1150,8 +1150,7 @@ int msm_pinctrl_probe(struct platform_device *pdev, return PTR_ERR(pctrl->regs[i]); } } else { - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - pctrl->regs[0] = devm_ioremap_resource(&pdev->dev, res); + pctrl->regs[0] = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(pctrl->regs[0])) return PTR_ERR(pctrl->regs[0]); } From patchwork Thu Oct 17 12:26:22 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195801 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 59DE614DB for ; Thu, 17 Oct 2019 12:52:52 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 37D7E20854 for ; Thu, 17 Oct 2019 12:52:52 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="YUhfuOSc" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 37D7E20854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=c/bSWE8KkBrBuuQFqW5aMljg+phtarurQPJA6xP4JxI=; b=YUhfuOScLpjlzv E6dIQNfl2xCPW002M+XMJykCrN2IoUJWAqghT7UA4m6GuT44pyLIZzQlaE9Xdw9/Hn9hEvX/XcdZu sOk6LSvYCD47FIHupat/SScxl/WwwG5qwLv6XgEJQf+4vdoUHi/goQN4Zn+R/qEzLTQP6pnjLkfZ0 yXHSlAKh3nE4ZvPDLMHqnv11To4xFQt3YIjAjgCBuwQZpddke78ZyDz8YFXOX/tGDALms7utrb+3J 9Bi+2jJxoLdD9WPbPFvOnLVQP2I6eNF5mbFs8wtXhjeY8H57ZbPr4pb3ZoyMDwioDaPOpgcBLy6M+ lKjT6WRJISlWNXdHKjdQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Gt-0000qB-4H; Thu, 17 Oct 2019 12:52:51 +0000 Received: from szxga04-in.huawei.com ([45.249.212.190] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Cv-0004aP-F7 for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:48 +0000 Received: from DGGEMS413-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id 9001D560213FE09E2984; Thu, 17 Oct 2019 20:48:41 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS413-HUB.china.huawei.com (10.3.19.213) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:32 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 12/30] pinctrl: spear: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:22 +0800 Message-ID: <20191017122640.22976-13-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054846_129548_EEDF6286 X-CRM114-Status: UNSURE ( 9.02 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.190 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/spear/pinctrl-plgpio.c | 4 +--- drivers/pinctrl/spear/pinctrl-spear.c | 4 +--- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/drivers/pinctrl/spear/pinctrl-plgpio.c b/drivers/pinctrl/spear/pinctrl-plgpio.c index c4c9a29..1ebbc49 100644 --- a/drivers/pinctrl/spear/pinctrl-plgpio.c +++ b/drivers/pinctrl/spear/pinctrl-plgpio.c @@ -515,15 +515,13 @@ static int plgpio_probe_dt(struct platform_device *pdev, struct plgpio *plgpio) static int plgpio_probe(struct platform_device *pdev) { struct plgpio *plgpio; - struct resource *res; int ret, irq; plgpio = devm_kzalloc(&pdev->dev, sizeof(*plgpio), GFP_KERNEL); if (!plgpio) return -ENOMEM; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - plgpio->base = devm_ioremap_resource(&pdev->dev, res); + plgpio->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(plgpio->base)) return PTR_ERR(plgpio->base); diff --git a/drivers/pinctrl/spear/pinctrl-spear.c b/drivers/pinctrl/spear/pinctrl-spear.c index 7ec19c7..948f56a 100644 --- a/drivers/pinctrl/spear/pinctrl-spear.c +++ b/drivers/pinctrl/spear/pinctrl-spear.c @@ -358,7 +358,6 @@ int spear_pinctrl_probe(struct platform_device *pdev, struct spear_pinctrl_machdata *machdata) { struct device_node *np = pdev->dev.of_node; - struct resource *res; struct spear_pmx *pmx; if (!machdata) @@ -368,8 +367,7 @@ int spear_pinctrl_probe(struct platform_device *pdev, if (!pmx) return -ENOMEM; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - pmx->vbase = devm_ioremap_resource(&pdev->dev, res); + pmx->vbase = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(pmx->vbase)) return PTR_ERR(pmx->vbase); From patchwork Thu Oct 17 12:26:23 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195799 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 4074F13BD for ; Thu, 17 Oct 2019 12:52:42 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 1ECA220854 for ; Thu, 17 Oct 2019 12:52:42 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="bUgkn/p9" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1ECA220854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=+6R2HfjrqmflwD+6oK8UmrRQE+SfsoBvjQmCbM23qW8=; b=bUgkn/p9zORDxd FVL/HxNaVvtVSmBCleq6DufG7GzvJQDkjPN+ab+rW/NGfQc5cxCa0mqMuFubvbpZhzDnoJJCaYTH6 haGZ1ffBrSpMwcqlVI+BWdYZ9LKUHAE/ZQ+tDpuYWXZsHTDKCizt2bt/SYAO1A39zE98kxKylBFdb CgX6eXpB5t0qj0KAKztc4zjbpZpTBzJ2v3TwiEGaTHU5wLnA20rT7Z8g9s9E3Nxx3W1Jl1qLQvN/r 8cAs7OtLFLYo4EVr92eCTae187/syWalZoSMPL9/ug2gdGDdLkroZ2wCRzFuGmr1hK4N+o/MfbfsH 2V7rSxIjC+wLFrikhWQA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Ge-0000aH-5c; Thu, 17 Oct 2019 12:52:36 +0000 Received: from szxga05-in.huawei.com ([45.249.212.191] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Cu-0004ap-7C for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:46 +0000 Received: from DGGEMS414-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id ED721B2A794F31B0C039; Thu, 17 Oct 2019 20:48:41 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS414-HUB.china.huawei.com (10.3.19.214) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:34 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 13/30] pinctrl: zte: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:23 +0800 Message-ID: <20191017122640.22976-14-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054844_467801_E2F974FF X-CRM114-Status: UNSURE ( 8.59 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.191 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/zte/pinctrl-zx.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/zte/pinctrl-zx.c b/drivers/pinctrl/zte/pinctrl-zx.c index 9512045..786bf89 100644 --- a/drivers/pinctrl/zte/pinctrl-zx.c +++ b/drivers/pinctrl/zte/pinctrl-zx.c @@ -387,7 +387,6 @@ int zx_pinctrl_init(struct platform_device *pdev, struct pinctrl_desc *pctldesc; struct zx_pinctrl *zpctl; struct device_node *np; - struct resource *res; int ret; zpctl = devm_kzalloc(&pdev->dev, sizeof(*zpctl), GFP_KERNEL); @@ -396,8 +395,7 @@ int zx_pinctrl_init(struct platform_device *pdev, spin_lock_init(&zpctl->lock); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - zpctl->base = devm_ioremap_resource(&pdev->dev, res); + zpctl->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(zpctl->base)) return PTR_ERR(zpctl->base); From patchwork Thu Oct 17 12:26:24 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195803 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 03C5C13BD for ; Thu, 17 Oct 2019 12:53:07 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id D5AD520854 for ; Thu, 17 Oct 2019 12:53:06 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="HbffGJGf" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org D5AD520854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=cWynDJ2nrMpCxkBu96o3WwquQXkgtdP2eo72zTBjGD0=; b=HbffGJGfO+jAoq rM4Mg62IdVv5eN08B1qWBPiNl3S/s7Phy4QABgdTyn2Ue8PqulNXfEqiDf/1B3YKx7sSm+0FXLQNP FPmDLGB7/ErdhGPfu3Qs6Y0tFgO5v8/7MKWXmN8eCScCIQYqJil3Ky3l6//1ngG/pZspgrsALBdrG jvisD44ZYt9u2i7/LJJW6xuf3t7k+Bp7vacheq6jqyv7w/eSnUi8Qssd4oE9IaGQ+Ha7VD7c95NZg /8tCEDW1QQcHe5TCvojQIXO+W/rRfx28DvIFNv6qYK37v7xwbfdemx4JB6daxY/Cvfxr8yNrTNDu4 axtfwMSD9mUvC02dWfFw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5H7-000142-R9; Thu, 17 Oct 2019 12:53:05 +0000 Received: from szxga07-in.huawei.com ([45.249.212.35] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Cz-0004gk-6n for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:51 +0000 Received: from DGGEMS408-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id AD6FDC47F83DD0B94E51; Thu, 17 Oct 2019 20:48:46 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS408-HUB.china.huawei.com (10.3.19.208) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:36 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 14/30] pinctrl: at91: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:24 +0800 Message-ID: <20191017122640.22976-15-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054849_448288_A4E04A56 X-CRM114-Status: UNSURE ( 9.86 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.35 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/pinctrl-at91.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-at91.c b/drivers/pinctrl/pinctrl-at91.c index 117075b..0472f3d 100644 --- a/drivers/pinctrl/pinctrl-at91.c +++ b/drivers/pinctrl/pinctrl-at91.c @@ -1811,7 +1811,6 @@ static const struct of_device_id at91_gpio_of_match[] = { static int at91_gpio_probe(struct platform_device *pdev) { struct device_node *np = pdev->dev.of_node; - struct resource *res; struct at91_gpio_chip *at91_chip = NULL; struct gpio_chip *chip; struct pinctrl_gpio_range *range; @@ -1839,8 +1838,7 @@ static int at91_gpio_probe(struct platform_device *pdev) goto err; } - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - at91_chip->regbase = devm_ioremap_resource(&pdev->dev, res); + at91_chip->regbase = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(at91_chip->regbase)) { ret = PTR_ERR(at91_chip->regbase); goto err; From patchwork Thu Oct 17 12:26:25 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195805 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 5CB7B14DB for ; Thu, 17 Oct 2019 12:53:39 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 2D4C320854 for ; Thu, 17 Oct 2019 12:53:39 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="Y2lWDI+9" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 2D4C320854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=rH4y5X2c1gotyOTQU9yKTk0SvXmbDhclSZl67i8E+ns=; b=Y2lWDI+9ssvstU WD+GLmqg1n0mtp37md/SytbtOXpSZVumMBLtVZjcPQmTGi9KLhYCnhM1bQVjiZydUJNc/h9bPdV+f 5+O/Nlrf6/oNNcDwr7+m67d/rB2wMzUFy6ZKiqkZtLB1kGudrV7M/WM/sFhRKT5SdLi7ClGhaQNPs OzMfJznPyYA8JrWgFRT/Ic1bPQCFDfRov3xGEMKp/5qQ5CYoyUdq2VBkynlwg0o5H9TzKeRiQ93TB TAU+QHnZ3WN5M/sQ3DCGskdlGWaDd4MyC4Zlre82MO6vTkJqANy+Sj6hknSpHeN1U+BumIsbNdawV rh0sPHvxzAPXGqzfuvxA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5He-0001WJ-BF; Thu, 17 Oct 2019 12:53:38 +0000 Received: from szxga04-in.huawei.com ([45.249.212.190] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5D1-0004gi-6P for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:52 +0000 Received: from DGGEMS413-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id A2D7B6223ADCEBDB3954; Thu, 17 Oct 2019 20:48:46 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS413-HUB.china.huawei.com (10.3.19.213) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:39 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 15/30] pinctrl: oxnas: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:25 +0800 Message-ID: <20191017122640.22976-16-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054851_414996_C0B4E8BB X-CRM114-Status: UNSURE ( 9.16 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.190 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing Acked-by: Neil Armstrong --- drivers/pinctrl/pinctrl-oxnas.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-oxnas.c b/drivers/pinctrl/pinctrl-oxnas.c index 40dc125..674b7b5 100644 --- a/drivers/pinctrl/pinctrl-oxnas.c +++ b/drivers/pinctrl/pinctrl-oxnas.c @@ -1196,7 +1196,6 @@ static int oxnas_gpio_probe(struct platform_device *pdev) struct oxnas_gpio_bank *bank; unsigned int id, ngpios; int irq, ret; - struct resource *res; struct gpio_irq_chip *girq; if (of_parse_phandle_with_fixed_args(np, "gpio-ranges", @@ -1220,8 +1219,7 @@ static int oxnas_gpio_probe(struct platform_device *pdev) bank = &oxnas_gpio_banks[id]; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - bank->reg_base = devm_ioremap_resource(&pdev->dev, res); + bank->reg_base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(bank->reg_base)) return PTR_ERR(bank->reg_base); From patchwork Thu Oct 17 12:26:26 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195809 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id DD7E214DB for ; Thu, 17 Oct 2019 12:54:07 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 9A0AD20854 for ; Thu, 17 Oct 2019 12:54:07 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="odpahUwJ" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 9A0AD20854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=WhIfY4lVToEgtB+CLHuF2JyRU8C2JqQxZ7PrncwCKUg=; b=odpahUwJn117a/ 21GOPfi8qymrkOTJNB0oemz5betq9394NLnRvcYm1knW41poytzT9tpaUxOOTKEE0asvKqpWWysxo avxivYjATDwGARIx3RfuYw0lFQ8zvsWILebsQjqVrnxH2EZt0tUbwDZCy/5rWH5YN4krb3lkHhjWz hi9yh5YQd5k16OiJZMihQCcogUJCiFwuHM/g/gBMqW5UpCS8uAaDtrNP7xfyn270wDL9eNsa2XlFE 6vAXOQb3fxcNTQJBaMKauRGzFBggp5xkSBrZBVSI+fcFoEYe0E5U+CKoD3mPPTjzUwh69OR3X50HS iCo4fNq/a959Gm8HFaXA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5I6-0001x6-8F; Thu, 17 Oct 2019 12:54:06 +0000 Received: from szxga07-in.huawei.com ([45.249.212.35] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5D3-0004kD-5U for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:55 +0000 Received: from DGGEMS405-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id 51DAAB3CBACA939ACFF9; Thu, 17 Oct 2019 20:48:51 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS405-HUB.china.huawei.com (10.3.19.205) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:41 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 16/30] pinctrl: pistachio: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:26 +0800 Message-ID: <20191017122640.22976-17-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054853_831928_263E0541 X-CRM114-Status: UNSURE ( 9.51 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.35 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/pinctrl-pistachio.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-pistachio.c b/drivers/pinctrl/pinctrl-pistachio.c index eb40ae9..fa370c1 100644 --- a/drivers/pinctrl/pinctrl-pistachio.c +++ b/drivers/pinctrl/pinctrl-pistachio.c @@ -1435,7 +1435,6 @@ static const struct of_device_id pistachio_pinctrl_of_match[] = { static int pistachio_pinctrl_probe(struct platform_device *pdev) { struct pistachio_pinctrl *pctl; - struct resource *res; pctl = devm_kzalloc(&pdev->dev, sizeof(*pctl), GFP_KERNEL); if (!pctl) @@ -1443,8 +1442,7 @@ static int pistachio_pinctrl_probe(struct platform_device *pdev) pctl->dev = &pdev->dev; dev_set_drvdata(&pdev->dev, pctl); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - pctl->base = devm_ioremap_resource(&pdev->dev, res); + pctl->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(pctl->base)) return PTR_ERR(pctl->base); From patchwork Thu Oct 17 12:26:27 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195807 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id C2DD614DB for ; Thu, 17 Oct 2019 12:53:55 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 9BFB820854 for ; Thu, 17 Oct 2019 12:53:55 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="IVY7zvx3" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 9BFB820854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=WUDahQQHutiUUhGUfUpR+tBpSRifp6Ik+y6DOoq3mBE=; b=IVY7zvx3LtIGf7 2+5bblxiLGfkQz0g3HyL4oe5wAS8miwMzwv56ST2ikI7h+mikE1roeFZPx9hFMWsjvy90PNbvl68Z LvsPoekWpIZv2V9HkBW897P6LXpXGFEvjNwsX+dd9MrfTg+CLqDhghZHMHoky99G3qa2PbZYm24ju YO4XjcPy5XnnNZRIZgTGcxvhCayu3mJltX0Y4vx2C1O2FBKyD8R04ZuPfVH20UW2DFQhTbel1yRyn exnKlnY1lc9545nvvidmHaELs/kaXLHbE9Fhr5dMF+Z0tzN2yaciia9hoawfxNhk6TfOnPOiS7OUf DDEtO2Z3wcZVQkmPJUsw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Ht-0001jx-7u; Thu, 17 Oct 2019 12:53:53 +0000 Received: from szxga07-in.huawei.com ([45.249.212.35] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5D2-0004kG-V8 for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:54 +0000 Received: from DGGEMS405-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id 5F7ED13C54382113A679; Thu, 17 Oct 2019 20:48:51 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS405-HUB.china.huawei.com (10.3.19.205) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:44 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 17/30] pinctrl: lpc18xx: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:27 +0800 Message-ID: <20191017122640.22976-18-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054853_608397_C8FE7F2F X-CRM114-Status: UNSURE ( 9.34 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.35 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/pinctrl-lpc18xx.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-lpc18xx.c b/drivers/pinctrl/pinctrl-lpc18xx.c index 06be55d..e467754 100644 --- a/drivers/pinctrl/pinctrl-lpc18xx.c +++ b/drivers/pinctrl/pinctrl-lpc18xx.c @@ -1324,15 +1324,13 @@ static int lpc18xx_create_group_func_map(struct device *dev, static int lpc18xx_scu_probe(struct platform_device *pdev) { struct lpc18xx_scu_data *scu; - struct resource *res; int ret; scu = devm_kzalloc(&pdev->dev, sizeof(*scu), GFP_KERNEL); if (!scu) return -ENOMEM; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - scu->base = devm_ioremap_resource(&pdev->dev, res); + scu->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(scu->base)) return PTR_ERR(scu->base); From patchwork Thu Oct 17 12:26:28 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195811 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 6193A14DB for ; Thu, 17 Oct 2019 12:54:23 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 3F00120854 for ; Thu, 17 Oct 2019 12:54:23 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="gdRb8Nnm" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 3F00120854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=qxE3X7SUPQrqKLL35UsBYqJhQQz0M+BUiHQdT8Ecu7I=; b=gdRb8Nnmj6SYLz p/Nzhv6eWnaaGmkqzAr+5lKAnG84qT/j6edqQ/0u4rexpLFw51sz4LmOEBzpV9FAEIj12umw5/U/n zKgMUv88ORseuNOS7MhYt0ro1AEo4YNlJm7o1+PoBBtlWJf21BgHcRk0Cb2LpJfHl1QQCcXvAGydh 7L0l8oLVVYP3Y6MB4P31oSH86fCq2d2NnpgTiC5eZY2IeW3GxZwLiWoVD/OQcuiey6OHJPqCdabId pivqXzLfXzoGK/2nnO6uiFEycdR6T80VCXhw+UgecRTL8IFDkoEd2fIpgraUx+drdSYvljlc6IW40 N69wnMoZOHnNMdXwRJRQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5IM-0002Dt-FI; Thu, 17 Oct 2019 12:54:22 +0000 Received: from szxga05-in.huawei.com ([45.249.212.191] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5D6-0004mn-02 for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:57 +0000 Received: from DGGEMS402-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id 8F65D54DF1C5E52328C9; Thu, 17 Oct 2019 20:48:53 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS402-HUB.china.huawei.com (10.3.19.202) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:46 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 18/30] pinctrl: da850-pupd: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:28 +0800 Message-ID: <20191017122640.22976-19-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054856_298495_84B4E7E4 X-CRM114-Status: UNSURE ( 9.26 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.191 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/pinctrl-da850-pupd.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-da850-pupd.c b/drivers/pinctrl/pinctrl-da850-pupd.c index d06f13a..5a0a1f2 100644 --- a/drivers/pinctrl/pinctrl-da850-pupd.c +++ b/drivers/pinctrl/pinctrl-da850-pupd.c @@ -146,14 +146,12 @@ static int da850_pupd_probe(struct platform_device *pdev) { struct device *dev = &pdev->dev; struct da850_pupd_data *data; - struct resource *res; data = devm_kzalloc(dev, sizeof(*data), GFP_KERNEL); if (!data) return -ENOMEM; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - data->base = devm_ioremap_resource(dev, res); + data->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(data->base)) { dev_err(dev, "Could not map resource\n"); return PTR_ERR(data->base); From patchwork Thu Oct 17 12:26:29 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195813 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 2772F13BD for ; Thu, 17 Oct 2019 12:54:41 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 02A1820854 for ; Thu, 17 Oct 2019 12:54:41 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="aqAKSVRK" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 02A1820854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=KC1rNWhjVgk9cnTpoedkiNmtsd7qqoW6VcJ/Dl2myzg=; b=aqAKSVRKYOPl1c Ajqq0liSYTLPS/k9NIZsalNWV+rFNzf2nGwORo8dkaJtDR7xqpB+6CDKp/V9mn/JQ7dFZX4TuO4Hv ESmVqIKzCOOQF8L73uVFYxp80MFoUxASxlLSjdoq/SwpTlT+NaDfkYAuxBprK80ag2PcIbJi3VZeh BPM7vm30yDU7AosFfAz5gvjyOGNQul+k2TV7vFjgnnbDo8rp1aNkzPSbz+20igflhtw+npcKrhhBY jGCLxghd0H2L+QrGqthZmZuTffn+0pF/LTfp93ujdBItPf0TeLj4cRpZWc19mX1Y57H6oLJchO1rW xCgc46SHJ5FlZ5myBrdg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Ic-0002TI-99; Thu, 17 Oct 2019 12:54:38 +0000 Received: from szxga04-in.huawei.com ([45.249.212.190] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5D7-0004ov-Bu for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:48:59 +0000 Received: from DGGEMS410-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id DCF64DF8FCD52FFBE71C; Thu, 17 Oct 2019 20:48:55 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS410-HUB.china.huawei.com (10.3.19.210) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:49 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 19/30] pinctrl: tb10x: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:29 +0800 Message-ID: <20191017122640.22976-20-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054857_579964_B2FBDBE7 X-CRM114-Status: UNSURE ( 9.76 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.190 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/pinctrl-tb10x.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-tb10x.c b/drivers/pinctrl/pinctrl-tb10x.c index 1f64e2e..ab49bd7 100644 --- a/drivers/pinctrl/pinctrl-tb10x.c +++ b/drivers/pinctrl/pinctrl-tb10x.c @@ -747,7 +747,6 @@ static struct pinctrl_desc tb10x_pindesc = { static int tb10x_pinctrl_probe(struct platform_device *pdev) { int ret = -EINVAL; - struct resource *mem; struct device *dev = &pdev->dev; struct device_node *of_node = dev->of_node; struct device_node *child; @@ -768,8 +767,7 @@ static int tb10x_pinctrl_probe(struct platform_device *pdev) platform_set_drvdata(pdev, state); mutex_init(&state->mutex); - mem = platform_get_resource(pdev, IORESOURCE_MEM, 0); - state->base = devm_ioremap_resource(dev, mem); + state->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(state->base)) { ret = PTR_ERR(state->base); goto fail; From patchwork Thu Oct 17 12:26:30 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195815 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 4167E13BD for ; Thu, 17 Oct 2019 12:55:01 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 1F92621835 for ; Thu, 17 Oct 2019 12:55:01 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="EBuuV3pJ" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1F92621835 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=R+NXaarqJfAX0plRJ8ndnrc2Dq9O4qRZs6NIzmOmjBA=; b=EBuuV3pJyHGWeK A/uFOTD8xSI+tVZaJFfjgDEvGsCi3G2fdlHTEG1E8gCY3R72aHs36Ll2cxQa+uFauME3t5tghwcAE FSZVCKkpXl7Uft/g6L6dqIiux5+pZsn/GAZhaPWtvwTyyt3RQvz3mvBzEEBKRn4J4VaXYlM8llZwH pWjuUmr8pdFRi7iiAH2n95oby0Pn77HwHq7jeQ/2AQzdKjn4Psd9CbVnTG9mI5UmcmrC6sC9BPs9c U/thvf54aZxeYJYddjwPev4MBbyucuUCJJCAOx6ci9jidgEQeI4gIAD3Ozzo6SAfvytVc4oZtY2RM M2sssyXIxQztyJXDLBBA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Ir-0002hO-AG; Thu, 17 Oct 2019 12:54:53 +0000 Received: from szxga07-in.huawei.com ([45.249.212.35] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5DE-0004vx-Rz for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:49:06 +0000 Received: from DGGEMS414-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id 384DA49473391AE0F266; Thu, 17 Oct 2019 20:49:02 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS414-HUB.china.huawei.com (10.3.19.214) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:51 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 20/30] pinctrl: u300: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:30 +0800 Message-ID: <20191017122640.22976-21-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054905_110434_AFFC6049 X-CRM114-Status: UNSURE ( 9.82 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.35 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/pinctrl-u300.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-u300.c b/drivers/pinctrl/pinctrl-u300.c index 348423b..cc30644 100644 --- a/drivers/pinctrl/pinctrl-u300.c +++ b/drivers/pinctrl/pinctrl-u300.c @@ -1055,7 +1055,6 @@ static struct pinctrl_desc u300_pmx_desc = { static int u300_pmx_probe(struct platform_device *pdev) { struct u300_pmx *upmx; - struct resource *res; /* Create state holders etc for this driver */ upmx = devm_kzalloc(&pdev->dev, sizeof(*upmx), GFP_KERNEL); @@ -1064,8 +1063,7 @@ static int u300_pmx_probe(struct platform_device *pdev) upmx->dev = &pdev->dev; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - upmx->virtbase = devm_ioremap_resource(&pdev->dev, res); + upmx->virtbase = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(upmx->virtbase)) return PTR_ERR(upmx->virtbase); From patchwork Thu Oct 17 12:26:31 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195821 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id AAA0114DB for ; Thu, 17 Oct 2019 12:55:49 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 885D120854 for ; Thu, 17 Oct 2019 12:55:49 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="dCMFgwBw" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 885D120854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=bWejERZsyGvzJjVBd0mW1mWhsAFc6OA5OICVdlWcsP4=; b=dCMFgwBwPO1htm LkuMNzTtrivsovccmdpIJgjgp5VBPtX8KJfLHA/xWNZcmFXMSTztJ5DG5ncbOtnMdjmkVV+e+ynob AMr0V/d6Vtqv//KBS06MILw4pZxxR7yiLhebN3m/wTMnct42e//7Oy++kOd77rmy1gBQKdxVCL4kQ 63cCwKf1op+uoiKLX63o24p0z5S5rgWQwBw5uiTj4NqA/u9RkvK6MsF1PD+mECMOjmJixv0PDwnmG /6i9P7QXROPYnrI8nEgjXtNByYZnZ9+cNvxBe+de6PU0Df1JR8PoB1oHsrdQhbgHB59YtPZjs0ek8 qh7/KHlFLjFiU0Jxk1lw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Jl-0004iA-1R; Thu, 17 Oct 2019 12:55:49 +0000 Received: from szxga04-in.huawei.com ([45.249.212.190] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5DI-0004xb-4N for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:49:09 +0000 Received: from DGGEMS401-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id 2A57B420EF2CCB0F76C4; Thu, 17 Oct 2019 20:49:05 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS401-HUB.china.huawei.com (10.3.19.201) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:54 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 21/30] pinctrl: vt8500: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:31 +0800 Message-ID: <20191017122640.22976-22-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054908_347708_21915D4A X-CRM114-Status: UNSURE ( 8.39 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.190 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/vt8500/pinctrl-wmt.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/vt8500/pinctrl-wmt.c b/drivers/pinctrl/vt8500/pinctrl-wmt.c index 4d5cd7d..ea910a1 100644 --- a/drivers/pinctrl/vt8500/pinctrl-wmt.c +++ b/drivers/pinctrl/vt8500/pinctrl-wmt.c @@ -553,10 +553,8 @@ int wmt_pinctrl_probe(struct platform_device *pdev, struct wmt_pinctrl_data *data) { int err; - struct resource *res; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - data->base = devm_ioremap_resource(&pdev->dev, res); + data->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(data->base)) return PTR_ERR(data->base); From patchwork Thu Oct 17 12:26:32 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195819 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 185AB13BD for ; Thu, 17 Oct 2019 12:55:33 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id E921520854 for ; Thu, 17 Oct 2019 12:55:32 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="MLtsy1b3" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E921520854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=hmqEicmYfUMx7A1mg/dlniJGCWzKbkuE/AlLPw6oc/w=; b=MLtsy1b3nqLOxK zh0waE1iZj30qleeBTe72mcPqIN2YG4pzQgYxny8orumig/pukS2Ctg4Ny0k7wcP0ttxalolg5LJL Sv80lU7zDrIdIEPdFP3mZOI55zuxP+r+Odg6jWnOwLnwTimj9JJo8vht6mYKAiv/D/a67i9MiMg+n V1Lx2WnKE6Uq3Pyg9YWar2OQ3hocm2Wor7ZKThgGtClsUSbnXW3vA3tBmGl6uhZG1KF+oR0SX5fiN GPT86nwN4PipB7KYNuSBPnge6yhru95dyMAUqfubzv0p8Z+q/G2PfFNg+yeKNT43VRWKFHIjxwUUW kJnj3ivo2UJb4CYVZHQg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5JU-0004QL-6u; Thu, 17 Oct 2019 12:55:32 +0000 Received: from szxga06-in.huawei.com ([45.249.212.32] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5DK-00050E-DM for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:49:12 +0000 Received: from DGGEMS403-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id 2FE54EC8D68941494BFA; Thu, 17 Oct 2019 20:49:07 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS403-HUB.china.huawei.com (10.3.19.203) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:56 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 22/30] pinctrl: xway: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:32 +0800 Message-ID: <20191017122640.22976-23-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054910_650643_FA5EE4F9 X-CRM114-Status: UNSURE ( 9.42 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.32 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/pinctrl-xway.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-xway.c b/drivers/pinctrl/pinctrl-xway.c index 913d38f..5e3f31b 100644 --- a/drivers/pinctrl/pinctrl-xway.c +++ b/drivers/pinctrl/pinctrl-xway.c @@ -1705,12 +1705,10 @@ static int pinmux_xway_probe(struct platform_device *pdev) { const struct of_device_id *match; const struct pinctrl_xway_soc *xway_soc; - struct resource *res; int ret, i; /* get and remap our register range */ - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - xway_info.membase[0] = devm_ioremap_resource(&pdev->dev, res); + xway_info.membase[0] = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(xway_info.membase[0])) return PTR_ERR(xway_info.membase[0]); From patchwork Thu Oct 17 12:26:33 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195817 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id D6A0614DB for ; Thu, 17 Oct 2019 12:55:16 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id AA48620854 for ; Thu, 17 Oct 2019 12:55:16 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="hDS7wZ/w" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org AA48620854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=62aNJkfRLGjsRSAQTWxA2MalX9n6v6yHvJ6CzD2UmG8=; b=hDS7wZ/w0cl5IE EQXJp3a7HZYZ3gm/BMAtnbhYmQaqqsGP1slGvJiNhM6kanZp7AW3UwYj/uXLVsMNDN+ISogsI0ht0 AP0MxaUFcKmuJ5eQsF+np34UzrKDmW+b+Nzvmroqei7AOPYyzNOonk15UQKXut9nR8Vf4DANGJCXS 8pvVx2wBE6+edb6672lInml8MZjUC3uTjmpvxr7cDT1/x02AT9oG2vNHWZpeV9sWhWvf6voC4wan6 Mkx/jjNQU9g7cu/RkjIlZPwuWEWTLYUvX9iiiJ+jJMhS7vsBFRtYXEVQXpVqWrG3wzZp/rWn5gHMw LReH1NDLBP2LL9YfUjcw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5JE-00049q-0p; Thu, 17 Oct 2019 12:55:16 +0000 Received: from szxga04-in.huawei.com ([45.249.212.190] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5DJ-0004zX-2I for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:49:10 +0000 Received: from DGGEMS408-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id F08C7C3E838AE4F9EC76; Thu, 17 Oct 2019 20:49:06 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS408-HUB.china.huawei.com (10.3.19.208) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:48:58 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 23/30] pinctrl: rza2: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:33 +0800 Message-ID: <20191017122640.22976-24-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054909_694962_BFE1DAE7 X-CRM114-Status: UNSURE ( 9.62 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.190 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/pinctrl-rza2.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-rza2.c b/drivers/pinctrl/pinctrl-rza2.c index 3be1d83..e27ed2f 100644 --- a/drivers/pinctrl/pinctrl-rza2.c +++ b/drivers/pinctrl/pinctrl-rza2.c @@ -462,7 +462,6 @@ static const struct pinmux_ops rza2_pinmux_ops = { static int rza2_pinctrl_probe(struct platform_device *pdev) { struct rza2_pinctrl_priv *priv; - struct resource *res; int ret; priv = devm_kzalloc(&pdev->dev, sizeof(*priv), GFP_KERNEL); @@ -471,8 +470,7 @@ static int rza2_pinctrl_probe(struct platform_device *pdev) priv->dev = &pdev->dev; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - priv->base = devm_ioremap_resource(&pdev->dev, res); + priv->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(priv->base)) return PTR_ERR(priv->base); From patchwork Thu Oct 17 12:26:34 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195825 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 5D9A114DB for ; Thu, 17 Oct 2019 12:56:18 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 3BC8C20854 for ; Thu, 17 Oct 2019 12:56:18 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="XbXfRfYH" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 3BC8C20854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=XDS6oA47kjCnDzAQZmbwa2nZ38dbdSHTc8FFslHxD+4=; b=XbXfRfYHuvC/BF lqNnHi46N/QF5ea7WpUhQyKBCL4UxiTREcuygs29lLQve8vIAqmNHK+q3qCxPgbsgTfKaAjg7oPR9 UFfoh2Y3F8+AUfze1F41cupNO2Tw7Hkk3fTfGaPv17e8YksSXlGvRex5vdPCCi6w7bAKD8Phr+GU8 Har4bYyNTlEiFZl59n5+VxLCiaN0+LZUpJOwM11r3Go9y7zAI7W3TmDYjvQNP66aTiInyZAKbcrir msMnm0Gr5dA36D+MCOZlOCZ9PubkCKaoYGmcTMWdybmmpWaRQLLeC4gEWFld/tUFUY/MQkTgNnyKo +cFORaRMjhCSrP8RpAqA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5KD-0005CO-LR; Thu, 17 Oct 2019 12:56:17 +0000 Received: from szxga04-in.huawei.com ([45.249.212.190] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5DP-00054C-HG for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:49:17 +0000 Received: from DGGEMS403-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id 4030555D330CE5AF0614; Thu, 17 Oct 2019 20:49:12 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS403-HUB.china.huawei.com (10.3.19.203) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:49:01 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 24/30] pinctrl: digicolor: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:34 +0800 Message-ID: <20191017122640.22976-25-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054915_779597_49A9C7A0 X-CRM114-Status: UNSURE ( 9.15 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.190 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/pinctrl-digicolor.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-digicolor.c b/drivers/pinctrl/pinctrl-digicolor.c index 7e1ceee..ff702cf 100644 --- a/drivers/pinctrl/pinctrl-digicolor.c +++ b/drivers/pinctrl/pinctrl-digicolor.c @@ -270,7 +270,6 @@ static int dc_gpiochip_add(struct dc_pinmap *pmap, struct device_node *np) static int dc_pinctrl_probe(struct platform_device *pdev) { struct dc_pinmap *pmap; - struct resource *r; struct pinctrl_pin_desc *pins; struct pinctrl_desc *pctl_desc; char *pin_names; @@ -281,8 +280,7 @@ static int dc_pinctrl_probe(struct platform_device *pdev) if (!pmap) return -ENOMEM; - r = platform_get_resource(pdev, IORESOURCE_MEM, 0); - pmap->regs = devm_ioremap_resource(&pdev->dev, r); + pmap->regs = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(pmap->regs)) return PTR_ERR(pmap->regs); From patchwork Thu Oct 17 12:26:35 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195823 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 15E4714DB for ; Thu, 17 Oct 2019 12:56:10 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id E85AB20854 for ; Thu, 17 Oct 2019 12:56:09 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="TEwXIeHX" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E85AB20854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=HVUACzjdIx8XuF6wxPJnyvtzxsl3JWXVA5zMQKzoBA0=; b=TEwXIeHXNFAfIk UeiSpXm5olVKmQkWdS+eO9mm9nbKeBSXs47zbVN8c26pXEJvzNpRJiJB22pGxZ0jMpkWkU4yH2Yn/ 6wCMmlQFLV41v2VWtUCC6zwKwaF406hp5K3d5KVmG//fIDeHcQYm4/cPg8VbGJdXAo4dTYJnEXCMW TSN/C2BkQ7GLiRZ5sEtEPlhro99mXySX0oqy7juh8Lk1G5OiY8qbSeATYCYQK5cgxNMFgohTmM5XI 5wpw3InaBUuGsHvNYrPpo3nktrUsxiPVIZYOhh62NaCMzcAYVd71gIiiBZHFDs9t85Og6fRRw4qgK YxKuJakca7CRUx5Y0aIQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Jz-0004wv-2z; Thu, 17 Oct 2019 12:56:03 +0000 Received: from szxga06-in.huawei.com ([45.249.212.32] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5DQ-00056V-DJ for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:49:18 +0000 Received: from DGGEMS402-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id C8110B962874AFB30720; Thu, 17 Oct 2019 20:49:13 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS402-HUB.china.huawei.com (10.3.19.202) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:49:03 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 25/30] pinctrl: coh901: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:35 +0800 Message-ID: <20191017122640.22976-26-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054916_679306_C5672B9C X-CRM114-Status: GOOD ( 10.27 ) X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.32 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/pinctrl-coh901.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-coh901.c b/drivers/pinctrl/pinctrl-coh901.c index 063a629..2905348 100644 --- a/drivers/pinctrl/pinctrl-coh901.c +++ b/drivers/pinctrl/pinctrl-coh901.c @@ -615,7 +615,6 @@ static struct coh901_pinpair coh901_pintable[] = { static int __init u300_gpio_probe(struct platform_device *pdev) { struct u300_gpio *gpio; - struct resource *memres; struct gpio_irq_chip *girq; int err = 0; int portno; @@ -633,8 +632,7 @@ static int __init u300_gpio_probe(struct platform_device *pdev) gpio->chip.base = 0; gpio->dev = &pdev->dev; - memres = platform_get_resource(pdev, IORESOURCE_MEM, 0); - gpio->base = devm_ioremap_resource(&pdev->dev, memres); + gpio->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(gpio->base)) return PTR_ERR(gpio->base); From patchwork Thu Oct 17 12:26:36 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195827 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id EB35C13BD for ; Thu, 17 Oct 2019 12:56:33 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id C965B20854 for ; Thu, 17 Oct 2019 12:56:33 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="j8dJMgfX" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org C965B20854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=EZb6LswQOa7mKGLDgKqYSP80ZzEMKmPMIkWSneJr/nQ=; b=j8dJMgfX0imRgs +InMMsnWqa9WOBSb5OR8rypny1Dnq2Ov1E8RSDnAPeYaFHgw71InZxJpwLAsUhN3aaS3NLBt6Oeif grk3MCZigrT0AsUEU3q8hqhY0am1FQJgcac6mHgFy4awG7iymUOOQAAlXt+J4P2wNjTWMmcPaDVsS NTiGfFiMdPoQy4a4tfkNCWgyRAiRxv5hQ3bD9PVHp56iVC7G/I67s8IrYtCAcjGtG5+7RUWIGUy2y bHQpbU2FtOYqUKHvTlc1MxIWPFpcsfsweZoS9pSN5vA+ZDi4Nq2thE1ojevLT3PLrSSOYzqVW3aBr iP4kSqLCNsBZN/sjGZTw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5KS-0005Qr-42; Thu, 17 Oct 2019 12:56:32 +0000 Received: from szxga05-in.huawei.com ([45.249.212.191] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5DR-00057E-FZ for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:49:19 +0000 Received: from DGGEMS412-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id B0EC86049EB89F9F20A1; Thu, 17 Oct 2019 20:49:14 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS412-HUB.china.huawei.com (10.3.19.212) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:49:06 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 26/30] pinctrl: bm1880: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:36 +0800 Message-ID: <20191017122640.22976-27-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054917_714534_AE2DDBAA X-CRM114-Status: UNSURE ( 9.51 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.191 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing Acked-by: Manivannan Sadhasivam --- drivers/pinctrl/pinctrl-bm1880.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-bm1880.c b/drivers/pinctrl/pinctrl-bm1880.c index 63b130c..f7dff4f 100644 --- a/drivers/pinctrl/pinctrl-bm1880.c +++ b/drivers/pinctrl/pinctrl-bm1880.c @@ -1308,15 +1308,13 @@ static struct pinctrl_desc bm1880_desc = { static int bm1880_pinctrl_probe(struct platform_device *pdev) { - struct resource *res; struct bm1880_pinctrl *pctrl; pctrl = devm_kzalloc(&pdev->dev, sizeof(*pctrl), GFP_KERNEL); if (!pctrl) return -ENOMEM; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - pctrl->base = devm_ioremap_resource(&pdev->dev, res); + pctrl->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(pctrl->base)) return PTR_ERR(pctrl->base); From patchwork Thu Oct 17 12:26:37 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195829 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 0BF3F13BD for ; Thu, 17 Oct 2019 12:57:07 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id D947D20854 for ; Thu, 17 Oct 2019 12:57:06 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="uk8azRFN" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org D947D20854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=VSK8zJ6GZvn4ZXzv9D89c1HHC2fvBQMZTTqAfemc7BU=; b=uk8azRFNMKtVg1 ZADIA1hsA4Pyk9Z6FI3uWGtLDxlnMyVnd4MRem2lR4uLXMn0l53pcKMhwxpIzYF25fSTZDIvXNrgb OU1UALP16QUVC3USPs3q5uGJj86O6OMoRQOwEXhTZZnVSS3lPS+Puj/naiIhEPuAUxgzAAib/OUpd IXtNvt7c0Lu92y/gxaZLnqpW8Ukdf411HGctnSzX76n/iZoCEVGcdAefrht+Bhj8CaSInGy30gB3M FqgAtyLBNVygpZ24WzllmyYaGUaxHoEQoHB7ETg37OJYYkXwgW1+9P6ECuJZnHwH5ttOMNVdPmuEf MunJE2O/URlFjdQef8NQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5L0-00061r-6z; Thu, 17 Oct 2019 12:57:06 +0000 Received: from szxga06-in.huawei.com ([45.249.212.32] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5DS-00058p-Pz for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:49:20 +0000 Received: from DGGEMS406-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id 34A8B769474F2EBF411E; Thu, 17 Oct 2019 20:49:17 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS406-HUB.china.huawei.com (10.3.19.206) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:49:08 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 27/30] pinctrl: artpec6: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:37 +0800 Message-ID: <20191017122640.22976-28-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054919_019425_83DD4B10 X-CRM114-Status: UNSURE ( 9.20 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.32 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing Acked-by: Jesper Nilsson --- drivers/pinctrl/pinctrl-artpec6.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-artpec6.c b/drivers/pinctrl/pinctrl-artpec6.c index e3239cf..986e04a 100644 --- a/drivers/pinctrl/pinctrl-artpec6.c +++ b/drivers/pinctrl/pinctrl-artpec6.c @@ -936,7 +936,6 @@ static void artpec6_pmx_reset(struct artpec6_pmx *pmx) static int artpec6_pmx_probe(struct platform_device *pdev) { struct artpec6_pmx *pmx; - struct resource *res; pmx = devm_kzalloc(&pdev->dev, sizeof(*pmx), GFP_KERNEL); if (!pmx) @@ -944,8 +943,7 @@ static int artpec6_pmx_probe(struct platform_device *pdev) pmx->dev = &pdev->dev; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - pmx->base = devm_ioremap_resource(&pdev->dev, res); + pmx->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(pmx->base)) return PTR_ERR(pmx->base); From patchwork Thu Oct 17 12:26:38 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195833 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id DCCD414DB for ; Thu, 17 Oct 2019 12:57:20 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id BA4B621848 for ; Thu, 17 Oct 2019 12:57:20 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="KPF2/rhO" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org BA4B621848 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=OQfdh8qWrVheVnmJ3ZRGqAvw5MUhXbCfh7mAY7UywgQ=; b=KPF2/rhO3QPeZw 0YwFhDkDUAgiPUXQ1RGsz0JewJYFyBGnLYx1AVdR3Cyfb+E/lc38I0zGowbKpdLHa7SoOKZHgGr2J 6+8YI6B/CdDPgRIZep/dPjkKzbhgY0V3lHoa9U5LmqPcp3dRP8dvt3LlAoNw+CFCThz82Yo9Whxgi UPnPBKI1pFC93FSFJc0a6sWQ0dXTI+LiYjX6dFmop06J2YP3k/yc1c7dyVBzVNo0yQ983LdqkfLOg avDDCU71V+WQPB+Jb2/RMTinnOxL1uumoE0GSzcW6GpE+ZI6l7OOR8sE3vh68j4NQoj/Ki1Z45yJx owN6sq1CCiWArWfifwPA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5LC-0006HU-Pt; Thu, 17 Oct 2019 12:57:18 +0000 Received: from szxga07-in.huawei.com ([45.249.212.35] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5DX-0005Dz-Qf for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:49:26 +0000 Received: from DGGEMS406-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id 0D1196BE06B500DCD430; Thu, 17 Oct 2019 20:49:22 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS406-HUB.china.huawei.com (10.3.19.206) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:49:11 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 28/30] pinctrl: actions: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:38 +0800 Message-ID: <20191017122640.22976-29-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054924_464589_91FD4B80 X-CRM114-Status: UNSURE ( 9.15 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.35 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing Acked-by: Manivannan Sadhasivam --- drivers/pinctrl/actions/pinctrl-owl.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pinctrl/actions/pinctrl-owl.c b/drivers/pinctrl/actions/pinctrl-owl.c index 5dfe718..5a0c8e8 100644 --- a/drivers/pinctrl/actions/pinctrl-owl.c +++ b/drivers/pinctrl/actions/pinctrl-owl.c @@ -915,7 +915,6 @@ static int owl_gpio_init(struct owl_pinctrl *pctrl) int owl_pinctrl_probe(struct platform_device *pdev, struct owl_pinctrl_soc_data *soc_data) { - struct resource *res; struct owl_pinctrl *pctrl; int ret, i; @@ -923,8 +922,7 @@ int owl_pinctrl_probe(struct platform_device *pdev, if (!pctrl) return -ENOMEM; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - pctrl->base = devm_ioremap_resource(&pdev->dev, res); + pctrl->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(pctrl->base)) return PTR_ERR(pctrl->base); From patchwork Thu Oct 17 12:26:39 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195835 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 3C45C17E1 for ; Thu, 17 Oct 2019 12:57:37 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 017B820854 for ; Thu, 17 Oct 2019 12:57:37 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="cOvT9uyQ" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 017B820854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=CSks2+Yv95Vcjn9GFw1xQ+lErH50Dd76xyaoq83T878=; b=cOvT9uyQK0qDF8 XY5zgxqPJICSF8E5k8SLhlmK76JK67vltUUkhu+QWDyD2A0PuVF5E/lRC08d3PUV4y+fxiV49nNa8 cHvDggliAz1kiJ323lDc6Xgmrd52nhJMuxWvfgrWG9ltYSgeiSayovu+utj+TA6NOvKH4uixZkoG/ Ny64/HZY75oSXOCg5nCV2L4MoRh0n/nyz9B+aNzcmV7/dFZ+VqDmtqk4rrOV+aUmaSU7XDsiWthdU r3aBv4G/JWe+gp34a6cokxpTzuaNZOdMhITnXHAsFvp0d447XlUwRwSkl6At9MR9ceaRrlvooBxuY icjSScIBdjU7rlwxUQ4w==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5LS-0006Wi-Le; Thu, 17 Oct 2019 12:57:34 +0000 Received: from szxga05-in.huawei.com ([45.249.212.191] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5DX-0005E9-Ob for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:49:25 +0000 Received: from DGGEMS408-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id 2908E7E955C150CCF85C; Thu, 17 Oct 2019 20:49:22 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS408-HUB.china.huawei.com (10.3.19.208) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:49:13 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 29/30] pinctrl: at91-pio4: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:39 +0800 Message-ID: <20191017122640.22976-30-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054924_003369_4570FB4E X-CRM114-Status: GOOD ( 10.07 ) X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.191 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/pinctrl-at91-pio4.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/pinctrl/pinctrl-at91-pio4.c b/drivers/pinctrl/pinctrl-at91-pio4.c index e380202..6949124 100644 --- a/drivers/pinctrl/pinctrl-at91-pio4.c +++ b/drivers/pinctrl/pinctrl-at91-pio4.c @@ -1017,8 +1017,7 @@ static int atmel_pinctrl_probe(struct platform_device *pdev) atmel_pioctrl->nbanks = atmel_pioctrl_data->nbanks; atmel_pioctrl->npins = atmel_pioctrl->nbanks * ATMEL_PIO_NPINS_PER_BANK; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - atmel_pioctrl->reg_base = devm_ioremap_resource(dev, res); + atmel_pioctrl->reg_base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(atmel_pioctrl->reg_base)) return -EINVAL; From patchwork Thu Oct 17 12:26:40 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 11195837 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 0C4F513BD for ; Thu, 17 Oct 2019 12:57:58 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id D0EC620854 for ; Thu, 17 Oct 2019 12:57:57 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="izEeVmGu" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org D0EC620854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=6lJsCdyEb86/MbYNfoxvPeCukXHjuSe5itlx/w8LqL8=; b=izEeVmGuN8xVEK 0LuLUE7TCbb1IQIw+KKbWkWBLTcLiz9aJLUyOKGRU8YAmKn4rmE4FC0aMTdAlH0So/15Xr8vA/s+E f6igCjSJ0h94W7g+22AlbeiVvwYX0uxCrX6yPyTQOKWSPLerx7MEbksGQkpSwF1htpIyetGIhMlFl xZVi2HMIPk2eyfbM6HoI6DdgjT7R7uQHplByoKFoxSqZa4c1SreeKDr2mbHqMexxyjI7PQjYKYrA1 5nwWbQq9/nY/UNFfi/9biIyA7Nm2GT4yNx62KmRGoAHtCOukSbCgG5Qg+nOQlibryrQACMlXRmbqt /n898Ly6uqAaTrwzSAvw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Lj-0006mj-31; Thu, 17 Oct 2019 12:57:51 +0000 Received: from szxga04-in.huawei.com ([45.249.212.190] helo=huawei.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL5Dg-0005GB-MX for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2019 12:49:34 +0000 Received: from DGGEMS411-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id 0E55BFE9EB7A70E105A5; Thu, 17 Oct 2019 20:49:24 +0800 (CST) Received: from localhost (10.133.213.239) by DGGEMS411-HUB.china.huawei.com (10.3.19.211) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 20:49:16 +0800 From: YueHaibing To: , , , , , , , , , , , , Subject: [PATCH -next 30/30] pinctrl: iproc: use devm_platform_ioremap_resource() to simplify code Date: Thu, 17 Oct 2019 20:26:40 +0800 Message-ID: <20191017122640.22976-31-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 In-Reply-To: <20191017122640.22976-1-yuehaibing@huawei.com> References: <20191017122640.22976-1-yuehaibing@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.133.213.239] X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191017_054932_912545_93E0B933 X-CRM114-Status: GOOD ( 10.32 ) X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [45.249.212.190 listed in list.dnswl.org] -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jonathanh@nvidia.com, geert+renesas@glider.be, narmstrong@baylibre.com, haojian.zhuang@gmail.com, linux-arm-msm@vger.kernel.org, agross@kernel.org, YueHaibing , linux-kernel@vger.kernel.org, linux-arm-kernel@axis.com, vz@mleia.com, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org, wens@csie.org, thierry.reding@gmail.com, daniel@zonque.org, linux-tegra@vger.kernel.org, linux-oxnas@groups.io, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing --- drivers/pinctrl/bcm/pinctrl-iproc-gpio.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c b/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c index 4d7d908..831a931 100644 --- a/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c +++ b/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c @@ -795,8 +795,7 @@ static int iproc_gpio_probe(struct platform_device *pdev) chip->dev = dev; platform_set_drvdata(pdev, chip); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - chip->base = devm_ioremap_resource(dev, res); + chip->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(chip->base)) { dev_err(dev, "unable to map I/O memory\n"); return PTR_ERR(chip->base);