From patchwork Sun Aug 2 14:25:53 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= X-Patchwork-Id: 11696463 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 08EA2912 for ; Sun, 2 Aug 2020 14:26:25 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 C8E3C20759 for ; Sun, 2 Aug 2020 14:26:24 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="KzhEUt87" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org C8E3C20759 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.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=Om1ONRDMcEtwC7rYhEcitYebA7Z2aK9i4QjXnYJtwFg=; b=KzhEUt87aO6J6Iuo/C2A4Wqbo 2a6pSqPSx7OKKz0jnwEElGbN2OsufT/YnUBRpWx0ZkR/wyZWDcj1MiR+BZ1++x8bS4Q/E/mI6+l+7 9ej/5p1U0KbeZE4kDh+cExFef312aJGY8bFTrgv25gjbZXfN2Jcs0ROyVWRdNdUwL7+wAxoxrLKwj DB3nGE6v9SioZj58Q8FurMuvw2o+DfynEbzERp1hXXkQniNGshEr2xreGQD1cQxR2JP+oVsI+76Cp oW2GgrC9dH4ULtutCOO0+Ab4KoY3b/GsjfGkp+vf0vWvG2xH4zzufsQRuHrL8n2VpXiygZjDRS4ov BatFlplhg==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2EwR-000772-TB; Sun, 02 Aug 2020 14:26:23 +0000 Received: from mail-lj1-f195.google.com ([209.85.208.195]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2EwC-0006zF-Eh; Sun, 02 Aug 2020 14:26:09 +0000 Received: by mail-lj1-f195.google.com with SMTP id v9so2518269ljk.6; Sun, 02 Aug 2020 07:26:06 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=SHzQyIKtZT048lWcLoYtmM5+43kERVs82uFH/nxs4dE=; b=k2pcYRi+7E7uW442xq2GYSdDfs0TsfdKvFMqjbJNJZD4wwimV9HO3QuRddXwHTtMaq x4DMQezplxBD6H5g7pPZDPAFLvRJBMt/ugCmGi6BNPXMvZpXvCSSHrDL/Et//h48gMKq lJ6FzoAKjj+VXDeqRI9Pn0xaR+pX/FHaA8krA43XvlRFtAY5x2jiOc5q7JzeAZdbgIOc ShWqFe9w22Om7/mS6pad6S/Evp6oQxLbiKBxjEhMNY9qnhISjrcGd6R8GsHd/lYcf5VJ FfYbwEK3GmKtwGHKOgIhDMTJSjLgz3fnZFCaynbD7Tg4AYuYAO2twtVbGZm+qmyflwHs EsPg== X-Gm-Message-State: AOAM531Zgo7HuEJ5eTonpSuHm95/3YiZokdO3Tr94fuk8YlCA/zfBIy/ /BBXugWzpzmDrjp5T6nTILw= X-Google-Smtp-Source: ABdhPJw9KYywa8ZVGNdkCZs9dJSVD2eLeBxLICm3DHiWvDH9oOY7/rpOjkFQkoP+VW0PAFb9uso9fw== X-Received: by 2002:a2e:9dd3:: with SMTP id x19mr2085928ljj.459.1596378365310; Sun, 02 Aug 2020 07:26:05 -0700 (PDT) Received: from workstation.lan ([95.155.85.46]) by smtp.gmail.com with ESMTPSA id 193sm4214136lfa.90.2020.08.02.07.26.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Aug 2020 07:26:04 -0700 (PDT) From: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= To: Bjorn Helgaas Subject: [PATCH 01/10] PCI: dwc: Remove dev_err() when handing an error from platform_get_irq() Date: Sun, 2 Aug 2020 14:25:53 +0000 Message-Id: <20200802142601.1635926-2-kw@linux.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200802142601.1635926-1-kw@linux.com> References: <20200802142601.1635926-1-kw@linux.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200802_102608_591821_960D1295 X-CRM114-Status: GOOD ( 16.11 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [209.85.208.195 listed in list.dnswl.org] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider [kswilczynski[at]gmail.com] 0.0 HEADER_FROM_DIFFERENT_DOMAINS From and EnvelopeFrom 2nd level mail domains are different -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.208.195 listed in wl.mailspike.net] 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FORGED_FROMDOMAIN 2nd level domains in From and EnvelopeFrom freemail headers are different X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Heiko Stuebner , linux-pci@vger.kernel.org, Shawn Lin , Binghui Wang , linux-arm-kernel@axis.com, Ley Foon Tan , Thomas Petazzoni , Toan Le , Jesper Nilsson , linux-samsung-soc@vger.kernel.org, Kevin Hilman , Pratyush Anand , Krzysztof Kozlowski , linux-rockchip@lists.infradead.org, Kukjin Kim , Xiaowei Song , Hou Zhiqiang , Linus Walleij , Richard Zhu , Sascha Hauer , Yue Wang , Murali Karicheri , linux-tegra@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Jingoo Han , rfi@lists.rocketboards.org, Shawn Guo , Lucas Stach Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org There is no need to call the dev_err() function directly to print a custom message when handling an error from either the platform_get_irq() or platform_get_irq_byname() functions as both are going to display an appropriate error message in case of a failure. This change is as per suggestion from Coccinelle: drivers/pci/controller/dwc/pcie-armada8k.c:252:2-9: line 252 is redundant because platform_get_irq() already prints an error drivers/pci/controller/dwc/pcie-kirin.c:459:3-10: line 459 is redundant because platform_get_irq() already prints an error drivers/pci/controller/dwc/pci-imx6.c:872:3-10: line 872 is redundant because platform_get_irq() already prints an error drivers/pci/controller/dwc/pcie-artpec6.c:391:3-10: line 391 is redundant because platform_get_irq() already prints an error drivers/pci/controller/dwc/pcie-spear13xx.c:202:2-9: line 202 is redundant because platform_get_irq() already prints an error drivers/pci/controller/dwc/pci-keystone.c:1254:2-9: line 1254 is redundant because platform_get_irq() already prints an error drivers/pci/controller/dwc/pci-exynos.c:406:2-9: line 406 is redundant because platform_get_irq() already prints an error drivers/pci/controller/dwc/pci-exynos.c:419:3-10: line 419 is redundant because platform_get_irq() already prints an error drivers/pci/controller/dwc/pcie-tegra194.c:2193:2-9: line 2193 is redundant because platform_get_irq() already prints an error drivers/pci/controller/dwc/pcie-histb.c:406:3-10: line 406 is redundant because platform_get_irq() already prints an error drivers/pci/controller/dwc/pci-meson.c:492:3-10: line 492 is redundant because platform_get_irq() already prints an error drivers/pci/controller/dwc/pci-dra7xx.c:633:2-9: line 633 is redundant because platform_get_irq() already prints an error drivers/pci/controller/dwc/pci-dra7xx.c:875:2-9: line 875 is redundant because platform_get_irq() already prints an error Suggested-by: Bjorn Helgaas Signed-off-by: Krzysztof Wilczyński Acked-by: Jesper Nilsson --- drivers/pci/controller/dwc/pci-dra7xx.c | 8 ++------ drivers/pci/controller/dwc/pci-exynos.c | 9 +++------ drivers/pci/controller/dwc/pci-imx6.c | 4 +--- drivers/pci/controller/dwc/pci-keystone.c | 4 +--- drivers/pci/controller/dwc/pci-meson.c | 4 +--- drivers/pci/controller/dwc/pcie-armada8k.c | 4 +--- drivers/pci/controller/dwc/pcie-artpec6.c | 4 +--- drivers/pci/controller/dwc/pcie-histb.c | 4 +--- drivers/pci/controller/dwc/pcie-kirin.c | 5 +---- drivers/pci/controller/dwc/pcie-spear13xx.c | 5 ++--- drivers/pci/controller/dwc/pcie-tegra194.c | 4 +--- 11 files changed, 15 insertions(+), 40 deletions(-) diff --git a/drivers/pci/controller/dwc/pci-dra7xx.c b/drivers/pci/controller/dwc/pci-dra7xx.c index 6184ebc9392d..66465dd69858 100644 --- a/drivers/pci/controller/dwc/pci-dra7xx.c +++ b/drivers/pci/controller/dwc/pci-dra7xx.c @@ -629,10 +629,8 @@ static int __init dra7xx_add_pcie_port(struct dra7xx_pcie *dra7xx, struct resource *res; pp->irq = platform_get_irq(pdev, 1); - if (pp->irq < 0) { - dev_err(dev, "missing IRQ resource\n"); + if (pp->irq < 0) return pp->irq; - } ret = dra7xx_pcie_init_irq_domain(pp); if (ret < 0) @@ -871,10 +869,8 @@ static int __init dra7xx_pcie_probe(struct platform_device *pdev) pci->ops = &dw_pcie_ops; irq = platform_get_irq(pdev, 0); - if (irq < 0) { - dev_err(dev, "missing IRQ resource: %d\n", irq); + if (irq < 0) return irq; - } base = devm_platform_ioremap_resource_byname(pdev, "ti_conf"); if (IS_ERR(base)) diff --git a/drivers/pci/controller/dwc/pci-exynos.c b/drivers/pci/controller/dwc/pci-exynos.c index c5043d951e80..f721fddc521e 100644 --- a/drivers/pci/controller/dwc/pci-exynos.c +++ b/drivers/pci/controller/dwc/pci-exynos.c @@ -402,10 +402,9 @@ static int __init exynos_add_pcie_port(struct exynos_pcie *ep, int ret; pp->irq = platform_get_irq(pdev, 1); - if (pp->irq < 0) { - dev_err(dev, "failed to get irq\n"); + if (pp->irq < 0) return pp->irq; - } + ret = devm_request_irq(dev, pp->irq, exynos_pcie_irq_handler, IRQF_SHARED, "exynos-pcie", ep); if (ret) { @@ -415,10 +414,8 @@ static int __init exynos_add_pcie_port(struct exynos_pcie *ep, if (IS_ENABLED(CONFIG_PCI_MSI)) { pp->msi_irq = platform_get_irq(pdev, 0); - if (pp->msi_irq < 0) { - dev_err(dev, "failed to get msi irq\n"); + if (pp->msi_irq < 0) return pp->msi_irq; - } } pp->ops = &exynos_pcie_host_ops; diff --git a/drivers/pci/controller/dwc/pci-imx6.c b/drivers/pci/controller/dwc/pci-imx6.c index 8f08ae53f53e..aba0a1514a86 100644 --- a/drivers/pci/controller/dwc/pci-imx6.c +++ b/drivers/pci/controller/dwc/pci-imx6.c @@ -868,10 +868,8 @@ static int imx6_add_pcie_port(struct imx6_pcie *imx6_pcie, if (IS_ENABLED(CONFIG_PCI_MSI)) { pp->msi_irq = platform_get_irq_byname(pdev, "msi"); - if (pp->msi_irq < 0) { - dev_err(dev, "failed to get MSI irq\n"); + if (pp->msi_irq < 0) return pp->msi_irq; - } } pp->ops = &imx6_pcie_host_ops; diff --git a/drivers/pci/controller/dwc/pci-keystone.c b/drivers/pci/controller/dwc/pci-keystone.c index 790679fdfa48..99df9aeece1f 100644 --- a/drivers/pci/controller/dwc/pci-keystone.c +++ b/drivers/pci/controller/dwc/pci-keystone.c @@ -1250,10 +1250,8 @@ static int __init ks_pcie_probe(struct platform_device *pdev) pci->version = version; irq = platform_get_irq(pdev, 0); - if (irq < 0) { - dev_err(dev, "missing IRQ resource: %d\n", irq); + if (irq < 0) return irq; - } ret = request_irq(irq, ks_pcie_err_irq_handler, IRQF_SHARED, "ks-pcie-error-irq", ks_pcie); diff --git a/drivers/pci/controller/dwc/pci-meson.c b/drivers/pci/controller/dwc/pci-meson.c index ca59ba9e0ecd..4f183b96afbb 100644 --- a/drivers/pci/controller/dwc/pci-meson.c +++ b/drivers/pci/controller/dwc/pci-meson.c @@ -488,10 +488,8 @@ static int meson_add_pcie_port(struct meson_pcie *mp, if (IS_ENABLED(CONFIG_PCI_MSI)) { pp->msi_irq = platform_get_irq(pdev, 0); - if (pp->msi_irq < 0) { - dev_err(dev, "failed to get MSI IRQ\n"); + if (pp->msi_irq < 0) return pp->msi_irq; - } } pp->ops = &meson_pcie_host_ops; diff --git a/drivers/pci/controller/dwc/pcie-armada8k.c b/drivers/pci/controller/dwc/pcie-armada8k.c index 49596547e8c2..66ec21cd9487 100644 --- a/drivers/pci/controller/dwc/pcie-armada8k.c +++ b/drivers/pci/controller/dwc/pcie-armada8k.c @@ -248,10 +248,8 @@ static int armada8k_add_pcie_port(struct armada8k_pcie *pcie, pp->ops = &armada8k_pcie_host_ops; pp->irq = platform_get_irq(pdev, 0); - if (pp->irq < 0) { - dev_err(dev, "failed to get irq for port\n"); + if (pp->irq < 0) return pp->irq; - } ret = devm_request_irq(dev, pp->irq, armada8k_pcie_irq_handler, IRQF_SHARED, "armada8k-pcie", pcie); diff --git a/drivers/pci/controller/dwc/pcie-artpec6.c b/drivers/pci/controller/dwc/pcie-artpec6.c index 28d5a1095200..d429bd2b2406 100644 --- a/drivers/pci/controller/dwc/pcie-artpec6.c +++ b/drivers/pci/controller/dwc/pcie-artpec6.c @@ -387,10 +387,8 @@ static int artpec6_add_pcie_port(struct artpec6_pcie *artpec6_pcie, if (IS_ENABLED(CONFIG_PCI_MSI)) { pp->msi_irq = platform_get_irq_byname(pdev, "msi"); - if (pp->msi_irq < 0) { - dev_err(dev, "failed to get MSI irq\n"); + if (pp->msi_irq < 0) return pp->msi_irq; - } } pp->ops = &artpec6_pcie_host_ops; diff --git a/drivers/pci/controller/dwc/pcie-histb.c b/drivers/pci/controller/dwc/pcie-histb.c index 811b5c6d62ea..006437eadc31 100644 --- a/drivers/pci/controller/dwc/pcie-histb.c +++ b/drivers/pci/controller/dwc/pcie-histb.c @@ -402,10 +402,8 @@ static int histb_pcie_probe(struct platform_device *pdev) if (IS_ENABLED(CONFIG_PCI_MSI)) { pp->msi_irq = platform_get_irq_byname(pdev, "msi"); - if (pp->msi_irq < 0) { - dev_err(dev, "Failed to get MSI IRQ\n"); + if (pp->msi_irq < 0) return pp->msi_irq; - } } hipcie->phy = devm_phy_get(dev, "phy"); diff --git a/drivers/pci/controller/dwc/pcie-kirin.c b/drivers/pci/controller/dwc/pcie-kirin.c index c19617a912bd..2e0181ce6895 100644 --- a/drivers/pci/controller/dwc/pcie-kirin.c +++ b/drivers/pci/controller/dwc/pcie-kirin.c @@ -455,11 +455,8 @@ static int kirin_pcie_add_msi(struct dw_pcie *pci, if (IS_ENABLED(CONFIG_PCI_MSI)) { irq = platform_get_irq(pdev, 0); - if (irq < 0) { - dev_err(&pdev->dev, - "failed to get MSI IRQ (%d)\n", irq); + if (irq < 0) return irq; - } pci->pp.msi_irq = irq; } diff --git a/drivers/pci/controller/dwc/pcie-spear13xx.c b/drivers/pci/controller/dwc/pcie-spear13xx.c index 7d0cdfd8138b..ad5d08d19926 100644 --- a/drivers/pci/controller/dwc/pcie-spear13xx.c +++ b/drivers/pci/controller/dwc/pcie-spear13xx.c @@ -198,10 +198,9 @@ static int spear13xx_add_pcie_port(struct spear13xx_pcie *spear13xx_pcie, int ret; pp->irq = platform_get_irq(pdev, 0); - if (pp->irq < 0) { - dev_err(dev, "failed to get irq\n"); + if (pp->irq < 0) return pp->irq; - } + ret = devm_request_irq(dev, pp->irq, spear13xx_pcie_irq_handler, IRQF_SHARED | IRQF_NO_THREAD, "spear1340-pcie", spear13xx_pcie); diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c index 92b77f7d8354..70498689d0c0 100644 --- a/drivers/pci/controller/dwc/pcie-tegra194.c +++ b/drivers/pci/controller/dwc/pcie-tegra194.c @@ -2189,10 +2189,8 @@ static int tegra_pcie_dw_probe(struct platform_device *pdev) } pp->irq = platform_get_irq_byname(pdev, "intr"); - if (pp->irq < 0) { - dev_err(dev, "Failed to get \"intr\" interrupt\n"); + if (pp->irq < 0) return pp->irq; - } pcie->bpmp = tegra_bpmp_get(dev); if (IS_ERR(pcie->bpmp)) From patchwork Sun Aug 2 14:25:54 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= X-Patchwork-Id: 11696465 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 2D951912 for ; Sun, 2 Aug 2020 14:26:26 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 06EB820759 for ; Sun, 2 Aug 2020 14:26: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="IOl5//Qb" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 06EB820759 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.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=q6ISPdsrp2cCKeI0upYjEYrv4a/TnUR4v7uQ1CY4bjM=; b=IOl5//QbQqV6vV8xmvX8uZuO3 jeowPOIyRz0kRyCFI6nHbkeR2AYsm2iViMenlTsVj7VApCuSnAZFSifh2tlG49kk/zkSXTUgO3k+T t6E1VM6x+oUquL/CcIyHBG/qDvy4HT2/vA7l8XTBzUZIAFA6GWvobE1pMTRkhYk7ei5FiL4/ZmR71 049dDbdgQSR0NPC0Nsfzeccok2BabFsonI50o9zBs4sJ+YjOVaAw0/ANZLAQ4i1DwWTuNL+VwtB6F qnYBJd3tBUvPLk3m+pZE7mWyui+4y7lzZzq3XCX/VokTJo7m3+Mz2twnBGTtYf9M+uUDf5xsXGULW hNoindsmw==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2EwT-00077i-7S; Sun, 02 Aug 2020 14:26:25 +0000 Received: from mail-lj1-f196.google.com ([209.85.208.196]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2EwC-0006zI-Gz; Sun, 02 Aug 2020 14:26:09 +0000 Received: by mail-lj1-f196.google.com with SMTP id v4so27328565ljd.0; Sun, 02 Aug 2020 07:26:08 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=Gfkhr1q1ggPu0YMrYNRyEFtEoT09pWjfvzSHRK7KszI=; b=ZU7mUvS721uGpb2SPPOsPDB5XhUPBBKGqFcnBmjZZ1GKKNB8BXTfRsey2BjovktFOh wPbBEzDUzEuFOh16QpfW8/EJuoj/c3+XhIRwy+TqyV2SdyJhWk/rrra33gMLOsqZf5GR g1FpObtWgKIfHB/f4Lvd4olXtE+gLKjmTShwPJb1hauLttyyCkIyPwLQ1yMs8ZuAeyj9 py5VtbfuhMIIzwN/4VamxZZr0OW/RI+1XSzENjYWTk+N5hzqVVm42j2A3pv8N/H7oY8p rYETCIdo/+HZ6lYLQfDgikc/XzSnmcluTRDaBFom7eBHJrnevvxtbdRLC3IY39lh/c33 gycw== X-Gm-Message-State: AOAM533Pgnj527K+V9J4WqGFJKkFFbPqI4wJewmsWzMwDwg1AYu/PvPs 69aC+sUZfej7PeVDpA7VY+w= X-Google-Smtp-Source: ABdhPJwj8NNsaKX276AKW3jAXsmsgaGQgCsO/u2y94Zh7oXKJWpdLXn5GIGobnMNMMKuZhl66j8/uw== X-Received: by 2002:a2e:9d04:: with SMTP id t4mr5607399lji.184.1596378366828; Sun, 02 Aug 2020 07:26:06 -0700 (PDT) Received: from workstation.lan ([95.155.85.46]) by smtp.gmail.com with ESMTPSA id 193sm4214136lfa.90.2020.08.02.07.26.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Aug 2020 07:26:06 -0700 (PDT) From: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= To: Bjorn Helgaas Subject: [PATCH 02/10] PCI: mobiveil: Remove dev_err() when handing an error from platform_get_irq() Date: Sun, 2 Aug 2020 14:25:54 +0000 Message-Id: <20200802142601.1635926-3-kw@linux.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200802142601.1635926-1-kw@linux.com> References: <20200802142601.1635926-1-kw@linux.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200802_102608_640421_0A8BAD30 X-CRM114-Status: GOOD ( 16.08 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [209.85.208.196 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.208.196 listed in wl.mailspike.net] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider [kswilczynski[at]gmail.com] 0.0 HEADER_FROM_DIFFERENT_DOMAINS From and EnvelopeFrom 2nd level mail domains are different 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FORGED_FROMDOMAIN 2nd level domains in From and EnvelopeFrom freemail headers are different X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Heiko Stuebner , linux-pci@vger.kernel.org, Shawn Lin , Binghui Wang , linux-arm-kernel@axis.com, Ley Foon Tan , Thomas Petazzoni , Toan Le , Jesper Nilsson , linux-samsung-soc@vger.kernel.org, Kevin Hilman , Pratyush Anand , Krzysztof Kozlowski , linux-rockchip@lists.infradead.org, Kukjin Kim , Xiaowei Song , Hou Zhiqiang , Linus Walleij , Richard Zhu , Sascha Hauer , Yue Wang , Murali Karicheri , linux-tegra@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Jingoo Han , rfi@lists.rocketboards.org, Shawn Guo , Lucas Stach Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org There is no need to call the dev_err() function directly to print a custom message when handling an error from either the platform_get_irq() or platform_get_irq_byname() functions as both are going to display an appropriate error message in case of a failure. This change is as per suggestion from Coccinelle: drivers/pci/controller/mobiveil/pcie-layerscape-gen4.c:174:2-9: line 174 is redundant because platform_get_irq() already prints an error drivers/pci/controller/mobiveil/pcie-mobiveil-host.c:526:2-9: line 526 is redundant because platform_get_irq() already prints an error Suggested-by: Bjorn Helgaas Signed-off-by: Krzysztof Wilczyński --- drivers/pci/controller/mobiveil/pcie-layerscape-gen4.c | 5 ++--- drivers/pci/controller/mobiveil/pcie-mobiveil-host.c | 4 +--- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/drivers/pci/controller/mobiveil/pcie-layerscape-gen4.c b/drivers/pci/controller/mobiveil/pcie-layerscape-gen4.c index a6d2190a6753..ee0156921ebc 100644 --- a/drivers/pci/controller/mobiveil/pcie-layerscape-gen4.c +++ b/drivers/pci/controller/mobiveil/pcie-layerscape-gen4.c @@ -170,10 +170,9 @@ static int ls_pcie_g4_interrupt_init(struct mobiveil_pcie *mv_pci) int ret; pcie->irq = platform_get_irq_byname(pdev, "intr"); - if (pcie->irq < 0) { - dev_err(dev, "Can't get 'intr' IRQ, errno = %d\n", pcie->irq); + if (pcie->irq < 0) return pcie->irq; - } + ret = devm_request_irq(dev, pcie->irq, ls_pcie_g4_isr, IRQF_SHARED, pdev->name, pcie); if (ret) { diff --git a/drivers/pci/controller/mobiveil/pcie-mobiveil-host.c b/drivers/pci/controller/mobiveil/pcie-mobiveil-host.c index 5907baa9b1f2..fa321fcdd4bc 100644 --- a/drivers/pci/controller/mobiveil/pcie-mobiveil-host.c +++ b/drivers/pci/controller/mobiveil/pcie-mobiveil-host.c @@ -522,10 +522,8 @@ static int mobiveil_pcie_integrated_interrupt_init(struct mobiveil_pcie *pcie) mobiveil_pcie_enable_msi(pcie); rp->irq = platform_get_irq(pdev, 0); - if (rp->irq < 0) { - dev_err(dev, "failed to map IRQ: %d\n", rp->irq); + if (rp->irq < 0) return rp->irq; - } /* initialize the IRQ domains */ ret = mobiveil_pcie_init_irq_domain(pcie); From patchwork Sun Aug 2 14:25:55 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= X-Patchwork-Id: 11696467 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 BC70313B6 for ; Sun, 2 Aug 2020 14:26:29 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 95ED620759 for ; Sun, 2 Aug 2020 14:26:29 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="aQKGnUWT" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 95ED620759 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.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=9uRjWySERl2Ty6pdUECUPhZCE7RwaCUqGNsPJ+xRiXk=; b=aQKGnUWTymVuSPpO+vhbxeCou 3JCNMbXdTS26dqF6Fv2qaviGzZmWsiospSK9v5YcmwJ0/+Ui3C6CkKEod+VeHEPsBMYht19JU/PKc 4pabO4eX6GM8m9ZaDJB2uThCw6vtPbYMdAQl0ciKSIsY1jmgMTLGP2du6RwzEXEX+iNUOSBuPaXf9 E95NSsVz+0OGZbyqtppTRZAmCEi+uXeWyI3QTDBjnjurQ8ufm0UfGvGLqtf79ATertTiOVHTCJg0w pqz8AbbaD8NLmz9Xp9x4k5AQaVBxcqim+zmIWztCjW4O6MmRM25YLULycsxyG3Q1PRU7H7QNUOJnN wpS99nOxw==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2EwW-00079s-Sx; Sun, 02 Aug 2020 14:26:28 +0000 Received: from mail-lj1-f195.google.com ([209.85.208.195]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2EwD-000700-El; Sun, 02 Aug 2020 14:26:10 +0000 Received: by mail-lj1-f195.google.com with SMTP id h19so36998891ljg.13; Sun, 02 Aug 2020 07:26:09 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=VMzZQXjK0WMetVDGn0tUCy2JU8NUEkR2xnKheZa8ZWc=; b=OSgURStQtUQawkO0yRIaxPFakz61bVO4ToxEiY0hhEGuv5T2qkSdLJ4BN5o6F6KM+o wWQFYnElBltBJOGvjLQEG8mb2JDScsTdYL+lO0kOe73f40Lqglqe34eqHh1NuOLAAuDL c1vt+Kvb3ASXll2dpwJ4IYcOUN9f1E3+hJrC8cTzdKWOtvXeDaSPNpjSds9bXfjj0+xh EN2DS/vouri0gKrs4onrMou62ywKavrTSt78q3x6qRDnurUE9mg2vDKy6UsAFdIj4Ti/ eCGXlJNyYrWFCjFJssqZUsghFeTgRndLQY4+P/XExpaiHFJr6ZpSKeebYfZXTCiogEA7 u9GQ== X-Gm-Message-State: AOAM531ZJCsY9XgC7Zglo170wm5Ozo0vvWY9j21zxGtDT6DHB2BhMVVB oYHL8hCg7bEI08ZkoIb5+Rs= X-Google-Smtp-Source: ABdhPJyjgrQc0FDjQcMFVZPpVkua7bA294ZwM5k/dH6lFvq8PdcJNGDDSetrLxIi93uNdb0Ai2zdVg== X-Received: by 2002:a2e:752:: with SMTP id i18mr6183911ljd.428.1596378368431; Sun, 02 Aug 2020 07:26:08 -0700 (PDT) Received: from workstation.lan ([95.155.85.46]) by smtp.gmail.com with ESMTPSA id 193sm4214136lfa.90.2020.08.02.07.26.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Aug 2020 07:26:07 -0700 (PDT) From: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= To: Bjorn Helgaas Subject: [PATCH 03/10] PCI: tegra: Remove dev_err() when handing an error from platform_get_irq() Date: Sun, 2 Aug 2020 14:25:55 +0000 Message-Id: <20200802142601.1635926-4-kw@linux.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200802142601.1635926-1-kw@linux.com> References: <20200802142601.1635926-1-kw@linux.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200802_102609_531237_B3A9B506 X-CRM114-Status: GOOD ( 15.32 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [209.85.208.195 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.208.195 listed in wl.mailspike.net] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider [kswilczynski[at]gmail.com] 0.0 HEADER_FROM_DIFFERENT_DOMAINS From and EnvelopeFrom 2nd level mail domains are different 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FORGED_FROMDOMAIN 2nd level domains in From and EnvelopeFrom freemail headers are different X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Heiko Stuebner , linux-pci@vger.kernel.org, Shawn Lin , Binghui Wang , linux-arm-kernel@axis.com, Ley Foon Tan , Thomas Petazzoni , Toan Le , Jesper Nilsson , linux-samsung-soc@vger.kernel.org, Kevin Hilman , Pratyush Anand , Krzysztof Kozlowski , linux-rockchip@lists.infradead.org, Kukjin Kim , Xiaowei Song , Hou Zhiqiang , Linus Walleij , Richard Zhu , Sascha Hauer , Yue Wang , Murali Karicheri , linux-tegra@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Jingoo Han , rfi@lists.rocketboards.org, Shawn Guo , Lucas Stach Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org There is no need to call the dev_err() function directly to print a custom message when handling an error from either the platform_get_irq() or platform_get_irq_byname() functions as both are going to display an appropriate error message in case of a failure. This change is as per suggestion from Coccinelle: drivers/pci/controller/pci-tegra.c:1524:2-9: line 1524 is redundant because platform_get_irq() already prints an error drivers/pci/controller/pci-tegra.c:1742:2-9: line 1742 is redundant because platform_get_irq() already prints an error Suggested-by: Bjorn Helgaas Signed-off-by: Krzysztof Wilczyński --- drivers/pci/controller/pci-tegra.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/drivers/pci/controller/pci-tegra.c b/drivers/pci/controller/pci-tegra.c index 235b456698fc..b11397475a4d 100644 --- a/drivers/pci/controller/pci-tegra.c +++ b/drivers/pci/controller/pci-tegra.c @@ -1520,10 +1520,8 @@ static int tegra_pcie_get_resources(struct tegra_pcie *pcie) /* request interrupt */ err = platform_get_irq_byname(pdev, "intr"); - if (err < 0) { - dev_err(dev, "failed to get IRQ: %d\n", err); + if (err < 0) goto phys_put; - } pcie->irq = err; @@ -1738,10 +1736,8 @@ static int tegra_pcie_msi_setup(struct tegra_pcie *pcie) } err = platform_get_irq_byname(pdev, "msi"); - if (err < 0) { - dev_err(dev, "failed to get IRQ: %d\n", err); + if (err < 0) goto free_irq_domain; - } msi->irq = err; From patchwork Sun Aug 2 14:25:56 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= X-Patchwork-Id: 11696469 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 2EE9E912 for ; Sun, 2 Aug 2020 14:26:34 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 050AC20759 for ; Sun, 2 Aug 2020 14:26:34 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="e1EZUODT" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 050AC20759 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.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=TUSlt97z6ZCe/4sCZw/1LvLROQu/NYuXf89pZduPAkY=; b=e1EZUODTMGuwGSGYjJItgpIsU qRosxmgKajFBJpldN9NOEGjNycqeh4/6lmVQU6p8idNWmqQBqDKPs8V9RsEAO5+HF0r4B+gHm2FbT a8jwX63db7UrwLcI3/qLl5uIKK1eJ3pl5Prptnq6gp0qM0vjLLkmYMrnN/3fHIcOwAPDEkCo549MC +M41mbveXKJ2aUnwyDos9fW3g9jKfL6mvYs7nJeFB3UrzpvgtDSsjGgCaFTy/Du2asd4sDs2e18m6 MqnP3Pd9h/w1EHAtiqJ7hdBIGgCJZeUQV3ciuikcB36YwLUt5ZhHr9a7R9bYVtPeTi5xJ/wlW/Hvy b78bQxpDA==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2Ewb-0007C8-1z; Sun, 02 Aug 2020 14:26:33 +0000 Received: from mail-lj1-f195.google.com ([209.85.208.195]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2EwF-00070p-3N; Sun, 02 Aug 2020 14:26:12 +0000 Received: by mail-lj1-f195.google.com with SMTP id w14so7157011ljj.4; Sun, 02 Aug 2020 07:26:11 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=Vqz66jFdWkrqKdTPiLpnKqTLTv8a5tORVk+kvNATVNQ=; b=iSRz5veQ0xfSS79fi2c88mcCi6Tbz5+rOtKpBgb6O54WBpTfzBK0eyMQ4xJ4zD1qmx l+X341ypTSwFBhw/yyAkdcJGjqfsEFOItlBI9Vsn+DZUCeutAS3fG9DjkHcd323P6oeF C6mPmkYWIAQBr32eIwVYnqVWGhEDPs+Ghi8emEj/HP/+Lcbc1v/CBrutnRgxM0UGOGMY M1D8BlQvYM4FihE925OWhPiMltJBk0LloZnLW2jp8xDJjprqv5r0Eb2GvNl33JHlTCF1 imQzVCN0xeKtJLMQBPrd7EJIM+g4VF2e/71SVFIhvBFrodJ72hA3J+o7GKOZtABG4hXF csPA== X-Gm-Message-State: AOAM531X0uww7R31AQVVJfy4BFjzh85h/4ve12x0SVvVJypLhr/Cq0Bb +qrGdMGhdOEbkJ87IyCvVl8= X-Google-Smtp-Source: ABdhPJy4jSVIiW6PUqWFPiMQhKNWAsiM5j0yMAxbx3OUXIJ59hEmi0ME2i3lZ+iAJfoiqC9jsw91kA== X-Received: by 2002:a2e:85d1:: with SMTP id h17mr4003308ljj.341.1596378369981; Sun, 02 Aug 2020 07:26:09 -0700 (PDT) Received: from workstation.lan ([95.155.85.46]) by smtp.gmail.com with ESMTPSA id 193sm4214136lfa.90.2020.08.02.07.26.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Aug 2020 07:26:09 -0700 (PDT) From: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= To: Bjorn Helgaas Subject: [PATCH 04/10] PCI: altera: Remove dev_err() when handing an error from platform_get_irq() Date: Sun, 2 Aug 2020 14:25:56 +0000 Message-Id: <20200802142601.1635926-5-kw@linux.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200802142601.1635926-1-kw@linux.com> References: <20200802142601.1635926-1-kw@linux.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200802_102611_248843_0A39C446 X-CRM114-Status: GOOD ( 14.95 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [209.85.208.195 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.208.195 listed in wl.mailspike.net] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider [kswilczynski[at]gmail.com] 0.0 HEADER_FROM_DIFFERENT_DOMAINS From and EnvelopeFrom 2nd level mail domains are different 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FORGED_FROMDOMAIN 2nd level domains in From and EnvelopeFrom freemail headers are different X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Heiko Stuebner , linux-pci@vger.kernel.org, Shawn Lin , Binghui Wang , linux-arm-kernel@axis.com, Ley Foon Tan , Thomas Petazzoni , Toan Le , Jesper Nilsson , linux-samsung-soc@vger.kernel.org, Kevin Hilman , Pratyush Anand , Krzysztof Kozlowski , linux-rockchip@lists.infradead.org, Kukjin Kim , Xiaowei Song , Hou Zhiqiang , Linus Walleij , Richard Zhu , Sascha Hauer , Yue Wang , Murali Karicheri , linux-tegra@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Jingoo Han , rfi@lists.rocketboards.org, Shawn Guo , Lucas Stach Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org There is no need to call the dev_err() function directly to print a custom message when handling an error from either the platform_get_irq() or platform_get_irq_byname() functions as both are going to display an appropriate error message in case of a failure. This change is as per suggestion from Coccinelle: drivers/pci/controller/pcie-altera.c:717:2-9: line 717 is redundant because platform_get_irq() already prints an error Suggested-by: Bjorn Helgaas Signed-off-by: Krzysztof Wilczyński Reviewed-by: Ley Foon Tan --- drivers/pci/controller/pcie-altera.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pci/controller/pcie-altera.c b/drivers/pci/controller/pcie-altera.c index 24cb1c331058..f6d73d282230 100644 --- a/drivers/pci/controller/pcie-altera.c +++ b/drivers/pci/controller/pcie-altera.c @@ -713,10 +713,8 @@ static int altera_pcie_parse_dt(struct altera_pcie *pcie) /* setup IRQ */ pcie->irq = platform_get_irq(pdev, 0); - if (pcie->irq < 0) { - dev_err(dev, "failed to get IRQ: %d\n", pcie->irq); + if (pcie->irq < 0) return pcie->irq; - } irq_set_chained_handler_and_data(pcie->irq, altera_pcie_isr, pcie); return 0; From patchwork Sun Aug 2 14:25:57 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= X-Patchwork-Id: 11696475 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 9DEF6912 for ; Sun, 2 Aug 2020 14:26:45 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 6EE902075A for ; Sun, 2 Aug 2020 14:26:45 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="k2to41YT" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 6EE902075A Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.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=h6eY8DR3xOFexAtxrCDE4MA/uQGKD7uNY2vC1q4ZOlg=; b=k2to41YTuAER5DCZ8yCZKBo+E Yvv88lMCJ6zxHZI+I3lJtvabf23fQGa6NrLphZ/HcAXittvHT6z8qgNHAFVqHR53cYFJe+v2xL8/R yq27VvY/A306wPCxqFL/Sl5AaTVpBbT0KV1JtUP6zbUnpCarVpRdLf1DxvNk7TWhBBpm3fCjda7OD HQqI2qRCVHm7ZLbB7kupfsplATkh/JBDNxrsMvPuzxGkBe7suxPR5hbfw2ua7N6PkH/5hu72bZMF0 5FuPQjg1Y8f4Xj+OqR8VvQf6q3fOcfhZUDHap3yZ0BIgJeQC5L4Af9zQluz7sjCoBnBwv55fUNZad VD/DeYtGA==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2Ewl-0007Iv-NB; Sun, 02 Aug 2020 14:26:43 +0000 Received: from mail-lj1-f195.google.com ([209.85.208.195]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2EwG-00071j-HM; Sun, 02 Aug 2020 14:26:13 +0000 Received: by mail-lj1-f195.google.com with SMTP id g6so24376964ljn.11; Sun, 02 Aug 2020 07:26:12 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=eygfm9r/GaNHVAKMUv8+SfoTHGAl/cjm4d2m8xjT5bc=; b=YhZTNdRfqOrP4Cpw2Y+OX5TMwxqpQLbKCh9MtohEuVDJaqxGSqYTFoMBD1N+4Yhfcx PZOAqGlIj+OhaittUtTyBkdXR4rhU50Mb4pgkpV5N64C2P+IP6zGnQ0ACCmkWoJbtJjx 0q0FQ8dk7ffFpIVGRLHfPbz9Z6q49Z5a1dZ64qPhdvA/HfcP+ZAYZN0UqH02ndFODAFo K5wKzH4jf962yWhaZ5jr8EL0Dri5VGYGoyOV5Vapivf0mrLDXW9BrCHHjhvGW5BbyAH2 ENoZtjmJhNIDotecP9jVVpjw8rt/lBmOX1EdgZmOboDspIpKkLSgzCn3jOWYkAIJQSpf lnSA== X-Gm-Message-State: AOAM530v5+jlhrQPGHovw8nMSZPnGI0prQNd96+KMqaAhzBuNxPu2YUK 1zebrfjpktcG7So7GdpBt3w= X-Google-Smtp-Source: ABdhPJzSmhttbDUgORpKlM914FzAS2b2KYbghno6w3+rxNJphXxD2jUo/xd+iwrLQer40nK+OI29Pw== X-Received: by 2002:a05:651c:31b:: with SMTP id a27mr5541281ljp.455.1596378371517; Sun, 02 Aug 2020 07:26:11 -0700 (PDT) Received: from workstation.lan ([95.155.85.46]) by smtp.gmail.com with ESMTPSA id 193sm4214136lfa.90.2020.08.02.07.26.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Aug 2020 07:26:11 -0700 (PDT) From: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= To: Bjorn Helgaas Subject: [PATCH 05/10] PCI: host-generic: Remove dev_err() when handing an error from platform_get_irq() Date: Sun, 2 Aug 2020 14:25:57 +0000 Message-Id: <20200802142601.1635926-6-kw@linux.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200802142601.1635926-1-kw@linux.com> References: <20200802142601.1635926-1-kw@linux.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200802_102612_707789_777356A6 X-CRM114-Status: GOOD ( 14.77 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [209.85.208.195 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.208.195 listed in wl.mailspike.net] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider [kswilczynski[at]gmail.com] 0.0 HEADER_FROM_DIFFERENT_DOMAINS From and EnvelopeFrom 2nd level mail domains are different 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FORGED_FROMDOMAIN 2nd level domains in From and EnvelopeFrom freemail headers are different X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Heiko Stuebner , linux-pci@vger.kernel.org, Shawn Lin , Binghui Wang , linux-arm-kernel@axis.com, Ley Foon Tan , Thomas Petazzoni , Toan Le , Jesper Nilsson , linux-samsung-soc@vger.kernel.org, Kevin Hilman , Pratyush Anand , Krzysztof Kozlowski , linux-rockchip@lists.infradead.org, Kukjin Kim , Xiaowei Song , Hou Zhiqiang , Linus Walleij , Richard Zhu , Sascha Hauer , Yue Wang , Murali Karicheri , linux-tegra@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Jingoo Han , rfi@lists.rocketboards.org, Shawn Guo , Lucas Stach Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org There is no need to call the dev_err() function directly to print a custom message when handling an error from either the platform_get_irq() or platform_get_irq_byname() functions as both are going to display an appropriate error message in case of a failure. This change is as per suggestion from Coccinelle: drivers/pci/controller/pcie-tango.c:277:2-9: line 277 is redundant because platform_get_irq() already prints an error Suggested-by: Bjorn Helgaas Signed-off-by: Krzysztof Wilczyński --- drivers/pci/controller/pcie-tango.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/pci/controller/pcie-tango.c b/drivers/pci/controller/pcie-tango.c index 8f640c70f936..d093a8ce4bb1 100644 --- a/drivers/pci/controller/pcie-tango.c +++ b/drivers/pci/controller/pcie-tango.c @@ -273,10 +273,8 @@ static int tango_pcie_probe(struct platform_device *pdev) writel_relaxed(0, pcie->base + SMP8759_ENABLE + offset); virq = platform_get_irq(pdev, 1); - if (virq < 0) { - dev_err(dev, "Failed to map IRQ\n"); + if (virq < 0) return virq; - } irq_dom = irq_domain_create_linear(fwnode, MSI_MAX, &dom_ops, pcie); if (!irq_dom) { From patchwork Sun Aug 2 14:25:58 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= X-Patchwork-Id: 11696489 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 EBE6C14E3 for ; Sun, 2 Aug 2020 14:27:05 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 C4CE02075A for ; Sun, 2 Aug 2020 14:27: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="VUcnj02L" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org C4CE02075A Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.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=C6CgnDDPvMZhOWuL0HFX4jZ0WJfru97B4CYQTI0vnGY=; b=VUcnj02L9v83Qhb7g+uhe14IV dY7FKSS2LAiwn2m13rrR2BQ9znML6IL5+7oDKwfxmN7+SFBGthKwPCR5rbih8qrITnd1Z3TIrpbGu HaV0dc4NnI77UQrkoLSo8Yj1yK3jb2Fo5kr88NHzPc+XCBoi+T/5wSdFqenKc0vGlWuEUI+SBx+0C HXkxrirD2KiMa07BUMC0B/49VD8rUIjUNSIwJDkE79F3GT22/oL35G8dximPQw6ToBc7T8iGOTZT4 5G1Fri4ZAJdM1iNu+rsAPF2WexEZjLjsv8zmIhpErkiC5DyByZ0SwlztDewOuRjaxarvsthMTxS1/ sSDLZPlmg==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2Ex6-0007WB-Rn; Sun, 02 Aug 2020 14:27:04 +0000 Received: from mail-lj1-f194.google.com ([209.85.208.194]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2EwI-00072G-Ly; Sun, 02 Aug 2020 14:26:15 +0000 Received: by mail-lj1-f194.google.com with SMTP id w14so7157100ljj.4; Sun, 02 Aug 2020 07:26:14 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=B3KSoQD71byHkg+Qsnb1jzju+E/FIRrV3OAj8SbgT+c=; b=s34FRS5CC7hNxD9+EskX12iL4xgzKNlJzpy+nbtTUOQxO8EWLJsXRL0RLiwE/tlzam 2KBUflJAqTWaG4MuDX6R49jlpK5gLeHl46I37Zh5Ly4WLVrrAO6JW6uPzTRG8XZf8mfI tEu5RKffr+ea23LdFdgW+ObbUmJ4AmDR2MYGysIn7mAlFMr9l7hJ8vBSd9Iun4VCuIgx VjXF0+LrFShVKp2VOUeo86otQijmEmtc4ZB1uudBU6MWkw5iL7P3TLiLOPlLkrU4VGgZ CtzOkPHQvutwqomO/We88U4HuprOQFbkObZNnKAst9gh/y37X/ldqYPs1Oud3lat1nOi KJxQ== X-Gm-Message-State: AOAM532Sl5UdeGRMVVqlaMUgQBWsoaWbex6f1IeceKQa5Tn/sKpf8HGL kThXVaAVCYK/UOGPNunEoew= X-Google-Smtp-Source: ABdhPJy+xlZ4x5ScpsArHy4QaEW+arFDZ4OILOPVHDYUlBaUmY+RMdxu/xscCf5AhzmdVlScycAYuQ== X-Received: by 2002:a2e:9bc1:: with SMTP id w1mr6140877ljj.288.1596378373175; Sun, 02 Aug 2020 07:26:13 -0700 (PDT) Received: from workstation.lan ([95.155.85.46]) by smtp.gmail.com with ESMTPSA id 193sm4214136lfa.90.2020.08.02.07.26.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Aug 2020 07:26:12 -0700 (PDT) From: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= To: Bjorn Helgaas Subject: [PATCH 06/10] PCI: v3-semi: Remove dev_err() when handing an error from platform_get_irq() Date: Sun, 2 Aug 2020 14:25:58 +0000 Message-Id: <20200802142601.1635926-7-kw@linux.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200802142601.1635926-1-kw@linux.com> References: <20200802142601.1635926-1-kw@linux.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200802_102614_811427_8C872222 X-CRM114-Status: GOOD ( 14.60 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [209.85.208.194 listed in list.dnswl.org] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider [kswilczynski[at]gmail.com] 0.0 HEADER_FROM_DIFFERENT_DOMAINS From and EnvelopeFrom 2nd level mail domains are different -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.208.194 listed in wl.mailspike.net] 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FORGED_FROMDOMAIN 2nd level domains in From and EnvelopeFrom freemail headers are different X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Heiko Stuebner , linux-pci@vger.kernel.org, Shawn Lin , Binghui Wang , linux-arm-kernel@axis.com, Ley Foon Tan , Thomas Petazzoni , Toan Le , Jesper Nilsson , linux-samsung-soc@vger.kernel.org, Kevin Hilman , Pratyush Anand , Krzysztof Kozlowski , linux-rockchip@lists.infradead.org, Kukjin Kim , Xiaowei Song , Hou Zhiqiang , Linus Walleij , Richard Zhu , Sascha Hauer , Yue Wang , Murali Karicheri , linux-tegra@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Jingoo Han , rfi@lists.rocketboards.org, Shawn Guo , Lucas Stach Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org There is no need to call the dev_err() function directly to print a custom message when handling an error from either the platform_get_irq() or platform_get_irq_byname() functions as both are going to display an appropriate error message in case of a failure. This change is as per suggestion from Coccinelle: drivers/pci/controller/pci-v3-semi.c:781:2-9: line 781 is redundant because platform_get_irq() already prints an error Suggested-by: Bjorn Helgaas Signed-off-by: Krzysztof Wilczyński --- drivers/pci/controller/pci-v3-semi.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/pci/controller/pci-v3-semi.c b/drivers/pci/controller/pci-v3-semi.c index 3681e5af3878..2a19f2a98945 100644 --- a/drivers/pci/controller/pci-v3-semi.c +++ b/drivers/pci/controller/pci-v3-semi.c @@ -777,10 +777,9 @@ static int v3_pci_probe(struct platform_device *pdev) /* Get and request error IRQ resource */ irq = platform_get_irq(pdev, 0); - if (irq < 0) { - dev_err(dev, "unable to obtain PCIv3 error IRQ\n"); + if (irq < 0) return irq; - } + ret = devm_request_irq(dev, irq, v3_irq, 0, "PCIv3 error", v3); if (ret < 0) { From patchwork Sun Aug 2 14:25:59 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= X-Patchwork-Id: 11696493 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 2A17D13B6 for ; Sun, 2 Aug 2020 14:27:14 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 0392220759 for ; Sun, 2 Aug 2020 14:27:14 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="kLVVCQ5L" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 0392220759 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.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=TqVYJR9ReH8q6+GXHnjWDBiMIcGcuE6UOL3j+pOQUfs=; b=kLVVCQ5LoKB6GgRlalwu+EQB8 hgIPXTodn50ND9JV3QYHGxRFUWLuefvYEuJJVzTGLuW+7JLc8CDQ285Np7Hxlaeqz3hDTnrkDgmO5 U4F4p4il7Q9KpFL4mMMQE7HCr4zB0vu1kyaIP6IwW4Agjt7JVHiWEHvEzFrdDYo0YYbume+a5EHwr MSDGq68HCCeod7/grv7CK1hTS75lz5FVoDViwHiMojvMMX0LhiGdudeaWcoGVWtaZlC8W8NQyiE06 ROvXT4UylhKxv3tMUBWIBZ5hpSJl+qA2MNHy5TFy7gG4TrIg+rzPOGdFXStTmX3qZHZSeQkCWG4sR JIhpB5vOg==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2ExE-0007au-AT; Sun, 02 Aug 2020 14:27:12 +0000 Received: from mail-lf1-f65.google.com ([209.85.167.65]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2EwK-000736-BC; Sun, 02 Aug 2020 14:26:17 +0000 Received: by mail-lf1-f65.google.com with SMTP id 140so19147045lfi.5; Sun, 02 Aug 2020 07:26:15 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=VHFVVkyvJ26w5l6BjSHc4G0RPe7rT9aQTvdBpCkShCw=; b=PTvu1g3I59nz0fuTktyxAtUZIEyMNIwZSigVayXMWu5ORjUYfyH1EVS2l7c4bZ2UI3 P7y09hsGWYQ02VCNSb5C1EG3vAI1MDu1UiaIzXLxZ2WiFGo4ejT8q3yWn3DU+B5ItKWl AAiSpwCP9IEWRTrWyatUwogbKcckLuK42q0m8/EIqNpUJaNT1qSPo0uBf/3S11WgnuQj oMVx68k3Ow21xn3FdGuk/zhaHwnkuyTxiy7XJmLRvBhNkBwFoGlppEzDL+JUt2NOmv7i uQ3SMHNIxn13AkNOu8pCXbBgtaYOYKMWmAfuBrBN6X2OJFKAPsumCtC8mvLeTFXcnYSO Qj4A== X-Gm-Message-State: AOAM5322IYbFIKKB/KZghmmxAXZIRVF/KEtrwK2drzuce9HDV14X6MR0 jspggkKyRHzqFrMsh7lkQJE= X-Google-Smtp-Source: ABdhPJxe9uClF4yn8tZcunRWtxDlWuh9tR86znz+TOBPok/VIIe5Df/vBtq17m7kMyjbPjEFliar6Q== X-Received: by 2002:ac2:5933:: with SMTP id v19mr6202139lfi.94.1596378374688; Sun, 02 Aug 2020 07:26:14 -0700 (PDT) Received: from workstation.lan ([95.155.85.46]) by smtp.gmail.com with ESMTPSA id 193sm4214136lfa.90.2020.08.02.07.26.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Aug 2020 07:26:14 -0700 (PDT) From: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= To: Bjorn Helgaas Subject: [PATCH 07/10] PCI: altera-msi: Remove dev_err() when handing an error from platform_get_irq() Date: Sun, 2 Aug 2020 14:25:59 +0000 Message-Id: <20200802142601.1635926-8-kw@linux.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200802142601.1635926-1-kw@linux.com> References: <20200802142601.1635926-1-kw@linux.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200802_102616_454693_9FCE3540 X-CRM114-Status: GOOD ( 14.80 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [209.85.167.65 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.167.65 listed in wl.mailspike.net] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider [kswilczynski[at]gmail.com] 0.0 HEADER_FROM_DIFFERENT_DOMAINS From and EnvelopeFrom 2nd level mail domains are different 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FORGED_FROMDOMAIN 2nd level domains in From and EnvelopeFrom freemail headers are different X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Heiko Stuebner , linux-pci@vger.kernel.org, Shawn Lin , Binghui Wang , linux-arm-kernel@axis.com, Ley Foon Tan , Thomas Petazzoni , Toan Le , Jesper Nilsson , linux-samsung-soc@vger.kernel.org, Kevin Hilman , Pratyush Anand , Krzysztof Kozlowski , linux-rockchip@lists.infradead.org, Kukjin Kim , Xiaowei Song , Hou Zhiqiang , Linus Walleij , Richard Zhu , Sascha Hauer , Yue Wang , Murali Karicheri , linux-tegra@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Jingoo Han , rfi@lists.rocketboards.org, Shawn Guo , Lucas Stach Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org There is no need to call the dev_err() function directly to print a custom message when handling an error from either the platform_get_irq() or platform_get_irq_byname() functions as both are going to display an appropriate error message in case of a failure. This change is as per suggestion from Coccinelle: drivers/pci/controller/pcie-altera-msi.c:259:2-9: line 259 is redundant because platform_get_irq() already prints an error Suggested-by: Bjorn Helgaas Signed-off-by: Krzysztof Wilczyński --- drivers/pci/controller/pcie-altera-msi.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/pci/controller/pcie-altera-msi.c b/drivers/pci/controller/pcie-altera-msi.c index 16d938920ca5..bec666eda1eb 100644 --- a/drivers/pci/controller/pcie-altera-msi.c +++ b/drivers/pci/controller/pcie-altera-msi.c @@ -256,7 +256,6 @@ static int altera_msi_probe(struct platform_device *pdev) msi->irq = platform_get_irq(pdev, 0); if (msi->irq < 0) { - dev_err(&pdev->dev, "failed to map IRQ: %d\n", msi->irq); ret = msi->irq; goto err; } From patchwork Sun Aug 2 14:26:00 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= X-Patchwork-Id: 11696495 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 E41C713B6 for ; Sun, 2 Aug 2020 14:27:29 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 B566B20759 for ; Sun, 2 Aug 2020 14:27:29 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="O9XuINQF" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org B566B20759 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.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=YQe8JKw30Vn+TF4nxTedv6Xb2uBvrHat0NG3H9P47+s=; b=O9XuINQF9Z+fxMP8uzq7pWmuB Kp0M04PBeN8i5MO7P7xGNIxaH+Ip342EV+MDknfIVkqvVJvDKl+LC5VG0X4kzfcc7J/WdJo381wi9 vfzQHQ+/h+ZP0cenWo4p8NoLsQI9w6TpXzo7dx/Y1GVXl9CIkrdYdBGnKPMCitKEAacsxPzz7lRRl vgpUNw9fT/JEkRoLPEnqtFkqZZ7lsTEAKlBGdmPNi3XRI8aIsE/0CLmzvaDT5QHOXiI8KG7UjRGln MABl4ZDd2Dmipm6XzavmhBh8WIez++nTSpVLbc1a6emJm0QobFbB4PhGP/wqLxUuNxpVRGzZOT72E ht31CZ/Mw==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2ExU-0007lm-04; Sun, 02 Aug 2020 14:27:28 +0000 Received: from mail-lj1-f195.google.com ([209.85.208.195]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2EwL-00073p-Ie; Sun, 02 Aug 2020 14:26:18 +0000 Received: by mail-lj1-f195.google.com with SMTP id w14so7157189ljj.4; Sun, 02 Aug 2020 07:26:17 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=KctYFubeJoKLzzl613htWFeciTcF38lRZu1u0/Rl6M8=; b=RiwP7NOMnE5Q0pf5Y5GnckOZPIWdXVZ1KVaxHLEfFZ8YnZocpU3QsdcBkVLYojorzP 5+lhO/1mQkv3cwfQhhaR5XRDLCdKjh1ECTPtQ1cNTtWxBXT/wu0GP7pOv1qn2XfZ8BaI pJ29RJJms5sWQVEmEG5bqKbrLW6trwjNbTwDmM+g8ekRyuMUoOt5JzpD8SHu+ubXOdSI akM+c7Q2fsF4lfPzMD+edIwj+t/GkoTlDpBMzPNU0A4gn5LuiyxC2WwXE1mSODp2RfDX 2ABcPZX1B48CpIMESeBQPkPs8ZwW0e0eNX9JqktamDFYGBGB5wVEtoKIrbzC4CZZV473 qfsw== X-Gm-Message-State: AOAM530V5BAEGRmun1C+p16MiULad8rHuD1to+T/HUDWksv8PrT8UDzt OQ3Aw2EpsKx8dDpXapwSVP0= X-Google-Smtp-Source: ABdhPJzMcdshNqp2FVaeIW1qGszgg8tWQnvrwe+GCIZdRiYp+tWne0ejZ4gesGSqeO7GvTac2I4drw== X-Received: by 2002:a2e:9e89:: with SMTP id f9mr5229933ljk.212.1596378376233; Sun, 02 Aug 2020 07:26:16 -0700 (PDT) Received: from workstation.lan ([95.155.85.46]) by smtp.gmail.com with ESMTPSA id 193sm4214136lfa.90.2020.08.02.07.26.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Aug 2020 07:26:15 -0700 (PDT) From: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= To: Bjorn Helgaas Subject: [PATCH 08/10] PCI: xgene-msi: Remove dev_err() when handing an error from platform_get_irq() Date: Sun, 2 Aug 2020 14:26:00 +0000 Message-Id: <20200802142601.1635926-9-kw@linux.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200802142601.1635926-1-kw@linux.com> References: <20200802142601.1635926-1-kw@linux.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200802_102617_737676_A86A99F7 X-CRM114-Status: GOOD ( 14.10 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [209.85.208.195 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.208.195 listed in wl.mailspike.net] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider [kswilczynski[at]gmail.com] 0.0 HEADER_FROM_DIFFERENT_DOMAINS From and EnvelopeFrom 2nd level mail domains are different 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FORGED_FROMDOMAIN 2nd level domains in From and EnvelopeFrom freemail headers are different X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Heiko Stuebner , linux-pci@vger.kernel.org, Shawn Lin , Binghui Wang , linux-arm-kernel@axis.com, Ley Foon Tan , Thomas Petazzoni , Toan Le , Jesper Nilsson , linux-samsung-soc@vger.kernel.org, Kevin Hilman , Pratyush Anand , Krzysztof Kozlowski , linux-rockchip@lists.infradead.org, Kukjin Kim , Xiaowei Song , Hou Zhiqiang , Linus Walleij , Richard Zhu , Sascha Hauer , Yue Wang , Murali Karicheri , linux-tegra@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Jingoo Han , rfi@lists.rocketboards.org, Shawn Guo , Lucas Stach Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org There is no need to call the dev_err() function directly to print a custom message when handling an error from either the platform_get_irq() or platform_get_irq_byname() functions as both are going to display an appropriate error message in case of a failure. This change is as per suggestion from Coccinelle: drivers/pci/controller/pci-xgene-msi.c:481:3-10: line 481 is redundant because platform_get_irq() already prints an error Suggested-by: Bjorn Helgaas Signed-off-by: Krzysztof Wilczyński --- drivers/pci/controller/pci-xgene-msi.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/pci/controller/pci-xgene-msi.c b/drivers/pci/controller/pci-xgene-msi.c index f4c02da84e59..02271c6d17a1 100644 --- a/drivers/pci/controller/pci-xgene-msi.c +++ b/drivers/pci/controller/pci-xgene-msi.c @@ -478,8 +478,6 @@ static int xgene_msi_probe(struct platform_device *pdev) for (irq_index = 0; irq_index < NR_HW_IRQS; irq_index++) { virt_msir = platform_get_irq(pdev, irq_index); if (virt_msir < 0) { - dev_err(&pdev->dev, "Cannot translate IRQ index %d\n", - irq_index); rc = virt_msir; goto error; } From patchwork Sun Aug 2 14:26:01 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= X-Patchwork-Id: 11696501 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 56CB6912 for ; Sun, 2 Aug 2020 14:27:47 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 2FE3020759 for ; Sun, 2 Aug 2020 14:27:47 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="kArOFAtp" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 2FE3020759 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.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=bSKZDI87bjt/gWXI0fvhOK5KaUOXrRcmJeSH+GcTCZ4=; b=kArOFAtpZb9w3KQlQHE+4I06s JslIwhAq2Z2HB4xnlFdkGLdKOmP2Nr8wD3NsTRLzSIc2vx7kBhiSXWi3FbcK6ReeUOsQvNZV1DxzF YJP4lbS9MbyTRS0hnYsnATxYEz0sMzuCL5FfbgET6XEh3XGxXTXbARMu+7jqgPahVHZyOhXRvMUr6 SXiajztC+5fAqo9BcSd3kijPt7Tks5IUZGIdv9IE0J3zY2pl+kHX9Bogt58HZCzVOXd9TChd37HeF slplLmLjaMAxFHhmpCWNobPmmb+ZgjBKzVUcZ230uqUoXrvrueEFpZDBMD+iHg/ps/VkT23C1BznC BYEE/gd9w==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2Exl-0007z2-Dh; Sun, 02 Aug 2020 14:27:45 +0000 Received: from mail-lf1-f66.google.com ([209.85.167.66]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2EwN-00074T-6y; Sun, 02 Aug 2020 14:26:20 +0000 Received: by mail-lf1-f66.google.com with SMTP id k13so19179833lfo.0; Sun, 02 Aug 2020 07:26:18 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=/S75/rZPVtT/la0J520uvq4mcrCeNFGU2um+3tul+rI=; b=fTA/2RKakxRz0DygQCYsBOgwnZ9u/grv89kSsDh6QZnxmzPYLUGxY5e0hvyLVyf4qB Rxp1mhGjdabSxkNjNn0qdV3/Xcmsb/ZuhX7TvD/Eo7z33mbsZur+zQe8+qbhbbvzq2fx OQgIOJuAcC/krcioqAUVqTXVhMeqJVu6WyFKf3/ara9GuXrFc/hzFnar+xMacm4HkS9l 44/Kow3epT4Jlg9H0xRs27pStJmwBT3uVKNZGfyRGdeTjbX9UOYv0T3TPEGxyZT9TMbA LUx7wc+XuEDr6RAvPLxdo5aQ39SU9L8tQVHA7Z3L8yt+All9y0hpcdJS38S166FHoLW1 qtmA== X-Gm-Message-State: AOAM532F1JE3tEYO0xOb9f2nuE3uhyowHB8/t4BD5qlgzbtYPadd06a2 Z71AqUrszneAsy/sjiAQZfM= X-Google-Smtp-Source: ABdhPJzNpdAF9CCzGfP8sG9ncd25/FPuC6g6AByGverT5oAgx7TlVWh8xE/g3DI5YXBMEkYyIP2c8Q== X-Received: by 2002:a19:189:: with SMTP id 131mr6399805lfb.128.1596378377807; Sun, 02 Aug 2020 07:26:17 -0700 (PDT) Received: from workstation.lan ([95.155.85.46]) by smtp.gmail.com with ESMTPSA id 193sm4214136lfa.90.2020.08.02.07.26.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 02 Aug 2020 07:26:17 -0700 (PDT) From: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= To: Bjorn Helgaas Subject: [PATCH 09/10] PCI: rockchip: Remove dev_err() when handing an error from platform_get_irq() Date: Sun, 2 Aug 2020 14:26:01 +0000 Message-Id: <20200802142601.1635926-10-kw@linux.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200802142601.1635926-1-kw@linux.com> References: <20200802142601.1635926-1-kw@linux.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200802_102619_344882_F993CF83 X-CRM114-Status: GOOD ( 14.23 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [209.85.167.66 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.167.66 listed in wl.mailspike.net] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider [kswilczynski[at]gmail.com] 0.0 HEADER_FROM_DIFFERENT_DOMAINS From and EnvelopeFrom 2nd level mail domains are different 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FORGED_FROMDOMAIN 2nd level domains in From and EnvelopeFrom freemail headers are different X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Heiko Stuebner , linux-pci@vger.kernel.org, Shawn Lin , Binghui Wang , linux-arm-kernel@axis.com, Ley Foon Tan , Thomas Petazzoni , Toan Le , Jesper Nilsson , linux-samsung-soc@vger.kernel.org, Kevin Hilman , Pratyush Anand , Krzysztof Kozlowski , linux-rockchip@lists.infradead.org, Kukjin Kim , Xiaowei Song , Hou Zhiqiang , Linus Walleij , Richard Zhu , Sascha Hauer , Yue Wang , Murali Karicheri , linux-tegra@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Jingoo Han , rfi@lists.rocketboards.org, Shawn Guo , Lucas Stach Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org There is no need to call the dev_err() function directly to print a custom message when handling an error from either the platform_get_irq() or platform_get_irq_byname() functions as both are going to display an appropriate error message in case of a failure. This change is as per suggestion from Coccinelle: drivers/pci/controller/pcie-rockchip-host.c:553:2-9: line 553 is redundant because platform_get_irq() already prints an error drivers/pci/controller/pcie-rockchip-host.c:566:2-9: line 566 is redundant because platform_get_irq() already prints an error drivers/pci/controller/pcie-rockchip-host.c:576:2-9: line 576 is redundant because platform_get_irq() already prints an error Suggested-by: Bjorn Helgaas Signed-off-by: Krzysztof Wilczyński --- drivers/pci/controller/pcie-rockchip-host.c | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/drivers/pci/controller/pcie-rockchip-host.c b/drivers/pci/controller/pcie-rockchip-host.c index 94af6f5828a3..eebe05ab354f 100644 --- a/drivers/pci/controller/pcie-rockchip-host.c +++ b/drivers/pci/controller/pcie-rockchip-host.c @@ -549,10 +549,8 @@ static int rockchip_pcie_setup_irq(struct rockchip_pcie *rockchip) struct platform_device *pdev = to_platform_device(dev); irq = platform_get_irq_byname(pdev, "sys"); - if (irq < 0) { - dev_err(dev, "missing sys IRQ resource\n"); + if (irq < 0) return irq; - } err = devm_request_irq(dev, irq, rockchip_pcie_subsys_irq_handler, IRQF_SHARED, "pcie-sys", rockchip); @@ -562,20 +560,16 @@ static int rockchip_pcie_setup_irq(struct rockchip_pcie *rockchip) } irq = platform_get_irq_byname(pdev, "legacy"); - if (irq < 0) { - dev_err(dev, "missing legacy IRQ resource\n"); + if (irq < 0) return irq; - } irq_set_chained_handler_and_data(irq, rockchip_pcie_legacy_int_handler, rockchip); irq = platform_get_irq_byname(pdev, "client"); - if (irq < 0) { - dev_err(dev, "missing client IRQ resource\n"); + if (irq < 0) return irq; - } err = devm_request_irq(dev, irq, rockchip_pcie_client_irq_handler, IRQF_SHARED, "pcie-client", rockchip); From patchwork Mon Aug 3 07:10:40 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= X-Patchwork-Id: 11697465 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 5DD6B913 for ; Mon, 3 Aug 2020 07:10:49 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 370A0206D7 for ; Mon, 3 Aug 2020 07:10: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="M7HQuWZT" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 370A0206D7 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.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=narnm4lyhpgD07YMXsteo1SmgfBDvTYT9PsafgJ/Z80=; b=M7HQuWZTY4IGVgFMnaEfXDisG urF/t19sgZOZ/y1FvOVmNEOaNwh82w/MqkbRZgZxphq9IPhHF13MUiBUW9ypa+WhSjtM5LTbkszZ7 6DnJm8Qhyg2RIc3QngUDtYqwVynUVHVfsDXg20jpmMFsqD9beB7KmTroQtymTuWPsMOyZwixm7iAC 6t7gvC4w6nKLYc+Qih7d7Q6C9iZrmTXNQIQpWKul8WV2ki2emRdlau8Ps6HcBBfZnND39xjLTpQv6 MrlJ2Pwx3vNLNAd3v0L92JHrKU3xl8IMQyd6UjpukZP0Qek79jwsmlxE+49hRfYWuL6lirZNtMutD uGmV2XBkw==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2UcR-00070T-Pu; Mon, 03 Aug 2020 07:10:47 +0000 Received: from mail-lf1-f65.google.com ([209.85.167.65]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1k2UcO-0006zQ-8W; Mon, 03 Aug 2020 07:10:45 +0000 Received: by mail-lf1-f65.google.com with SMTP id c15so2609424lfi.3; Mon, 03 Aug 2020 00:10:43 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=Ay3Bi+IiWilbDlJUPitXEI+RuPwMq9ZiJzLYPsaopL8=; b=MsGSyCz4oCLHkEuVOrHbYgNFRsC8uvhOs9h87NNShyJr3L5M7eI9iJEpeh5fwK6ReY JEdgfa4AyOfYBqBqhNnjf8VPPUNJEVIf0sWeXVJbeqtDCuhRwHmloFA4sFX93nj1CCpj aGgiSGc6731emAk+GW990tOBZhAxxTuHhO/ZlbvzbcuazhppFTRtUcmDmlsx/+FFWt0J v+4BJraUfX3Cd7yFFMnP5JCWKiK0lizKLSujZ3OoRmurzuh5FMqqlpMNDC9qpwlHmYRO H1I+yAo2FYdZmscEUXj368qMH4VEviLLjnAW2qBgJgFF96J45Q7JqMeIPHULfUWLtU6A KL9g== X-Gm-Message-State: AOAM533i9LJn1+EGlvNg6j7RrGlolyZrpZb29pODy0NLcnWHN9tzhtta zbDi4MD8fGLlHuOOyN+3gZY= X-Google-Smtp-Source: ABdhPJzYw7yZDvJbTJfDGxm7OY2EE10qIOitHhsEhQ9czxB+hKmQdhCqIuug22Bs0Z17tX3e9sBetw== X-Received: by 2002:a19:a07:: with SMTP id 7mr7780618lfk.65.1596438642541; Mon, 03 Aug 2020 00:10:42 -0700 (PDT) Received: from workstation.lan ([95.155.85.46]) by smtp.gmail.com with ESMTPSA id r11sm3877560lji.104.2020.08.03.00.10.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 03 Aug 2020 00:10:41 -0700 (PDT) From: =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= To: Bjorn Helgaas Subject: [PATCH 10/10] PCI: xilinx-nwl: Remove dev_err() when handing an error from platform_get_irq() Date: Mon, 3 Aug 2020 07:10:40 +0000 Message-Id: <20200803071040.1663662-1-kw@linux.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200802142601.1635926-1-kw@linux.com> References: <20200802142601.1635926-1-kw@linux.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200803_031044_329238_FD3D65C2 X-CRM114-Status: GOOD ( 15.22 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.167.65 listed in wl.mailspike.net] -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [209.85.167.65 listed in list.dnswl.org] 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider [kswilczynski[at]gmail.com] 0.0 HEADER_FROM_DIFFERENT_DOMAINS From and EnvelopeFrom 2nd level mail domains are different 0.0 FREEMAIL_FORGED_FROMDOMAIN 2nd level domains in From and EnvelopeFrom freemail headers are different X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Heiko Stuebner , linux-pci@vger.kernel.org, Shawn Lin , Binghui Wang , linux-arm-kernel@axis.com, Ley Foon Tan , Thomas Petazzoni , Toan Le , Jesper Nilsson , linux-samsung-soc@vger.kernel.org, Kevin Hilman , Pratyush Anand , Krzysztof Kozlowski , linux-rockchip@lists.infradead.org, Kukjin Kim , Xiaowei Song , Hou Zhiqiang , Linus Walleij , Richard Zhu , Sascha Hauer , Yue Wang , Murali Karicheri , linux-tegra@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Jingoo Han , rfi@lists.rocketboards.org, Shawn Guo , Lucas Stach Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org There is no need to call the dev_err() function directly to print a custom message when handling an error from either the platform_get_irq() or platform_get_irq_byname() functions as both are going to display an appropriate error message in case of a failure. This change is as per suggestion from Coccinelle: drivers/pci/controller/pcie-xilinx-nwl.c:732:2-9: line 732 is redundant because platform_get_irq() already prints an error drivers/pci/controller/pcie-xilinx-nwl.c:589:2-9: line 589 is redundant because platform_get_irq() already prints an error drivers/pci/controller/pcie-xilinx-nwl.c:600:2-9: line 600 is redundant because platform_get_irq() already prints an error drivers/pci/controller/pcie-xilinx-nwl.c:801:2-9: line 801 is redundant because platform_get_irq() already prints an error Suggested-by: Bjorn Helgaas Signed-off-by: Krzysztof Wilczyński --- drivers/pci/controller/pcie-xilinx-nwl.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/drivers/pci/controller/pcie-xilinx-nwl.c b/drivers/pci/controller/pcie-xilinx-nwl.c index 9bd1427f2fd6..55489b728484 100644 --- a/drivers/pci/controller/pcie-xilinx-nwl.c +++ b/drivers/pci/controller/pcie-xilinx-nwl.c @@ -586,7 +586,6 @@ static int nwl_pcie_enable_msi(struct nwl_pcie *pcie) /* Get msi_1 IRQ number */ msi->irq_msi1 = platform_get_irq_byname(pdev, "msi1"); if (msi->irq_msi1 < 0) { - dev_err(dev, "failed to get IRQ#%d\n", msi->irq_msi1); ret = -EINVAL; goto err; } @@ -597,7 +596,6 @@ static int nwl_pcie_enable_msi(struct nwl_pcie *pcie) /* Get msi_0 IRQ number */ msi->irq_msi0 = platform_get_irq_byname(pdev, "msi0"); if (msi->irq_msi0 < 0) { - dev_err(dev, "failed to get IRQ#%d\n", msi->irq_msi0); ret = -EINVAL; goto err; } @@ -728,11 +726,8 @@ static int nwl_pcie_bridge_init(struct nwl_pcie *pcie) /* Get misc IRQ number */ pcie->irq_misc = platform_get_irq_byname(pdev, "misc"); - if (pcie->irq_misc < 0) { - dev_err(dev, "failed to get misc IRQ %d\n", - pcie->irq_misc); + if (pcie->irq_misc < 0) return -EINVAL; - } err = devm_request_irq(dev, pcie->irq_misc, nwl_pcie_misc_handler, IRQF_SHARED, @@ -797,10 +792,8 @@ static int nwl_pcie_parse_dt(struct nwl_pcie *pcie, /* Get intx IRQ number */ pcie->irq_intx = platform_get_irq_byname(pdev, "intx"); - if (pcie->irq_intx < 0) { - dev_err(dev, "failed to get intx IRQ %d\n", pcie->irq_intx); + if (pcie->irq_intx < 0) return pcie->irq_intx; - } irq_set_chained_handler_and_data(pcie->irq_intx, nwl_pcie_leg_handler, pcie);