From patchwork Fri Jul 5 09:56:44 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Z.Q. Hou" X-Patchwork-Id: 11032793 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 25BF514F6 for ; Fri, 5 Jul 2019 14:40:08 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 13863219AC for ; Fri, 5 Jul 2019 14:40:08 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 082B928AB0; Fri, 5 Jul 2019 14:40:08 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 96AF9219AC for ; Fri, 5 Jul 2019 14:40:07 +0000 (UTC) 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:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: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=Q/xlO29HySFWo0Py58PTmo3RfHk4pAQQ5amjd2frAJ4=; b=B4BkdYBDxiLJkeS1dbStFcW19o WHmAOcuh32hN9ZTCu4VhqpTV+IO2fhA3szS4PTE8W0n0cPci9KBKbpbyg2A3MNsu5W639/RJVHGkD UEBGAkNrsPwYvtNqYu3B3sy0/jw1zVxJbr+Nyfgm9pUGoMILqdtAWS7rd/3JhQSHy2+6W0skoL26i K04ySfQNoZGOX3VZi7abo3SBlC0IiOSsCBKrIdn9P/iTN+b0NBFT3onfV+tk3uMZ5lVe48HCJEuKq 61GInaMGZSihGZNs3KzIqfKMoooSGKNnvxpKZJgBFpf4BhP9DN7bH2R6xDVWLc1AW25/L7FiVv8pj QMOB7CxQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92 #3 (Red Hat Linux)) id 1hjPNX-0001qg-81; Fri, 05 Jul 2019 14:39:59 +0000 Received: from casper.infradead.org ([2001:8b0:10b:1236::1]) by bombadil.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1hjPKG-0006LN-GI for linux-arm-kernel@bombadil.infradead.org; Fri, 05 Jul 2019 14:36:36 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=References:In-Reply-To:Message-Id:Date: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=AZTkwAKvu+YSvTEfYjt4PrBulSdtSrSRI8uddEwOfgE=; b=So3aAXP2Qi2limAUfDWNXX9Tr zParnHQ7pRSKh/I7EqXzMmi80l9D6mffYoe/dPoZUuV2jC/PXQIwjSmGTlEkcEnCY6oVY98tx9PHW 2lgMUCvu0wX3NwVnfzJ84XuVnHjDh9f5+3I5VUjCvNaoD4mnmvUP5IL4R5I115vE4pxf/PRMr+9nm P+WTC/fgF3HNVlE2hjuD11e/kFgULCgqkiSgdRYr2MCqyUnsACmlm6Lc8IA4bMXk457HkVYwnG6Y3 UL86uVknRZRCyLUyG8mVIF7OKzSv78VJgcEqJ+N20bzEjCgjgKUliVoJNRWII+Df7MGlNNnyxQUa7 8qV7U9XMg==; Received: from inva020.nxp.com ([92.121.34.13]) by casper.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1hjL7x-00022z-Su for linux-arm-kernel@lists.infradead.org; Fri, 05 Jul 2019 10:07:40 +0000 Received: from inva020.nxp.com (localhost [127.0.0.1]) by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id 72D771A077B; Fri, 5 Jul 2019 12:07:28 +0200 (CEST) Received: from invc005.ap-rdc01.nxp.com (invc005.ap-rdc01.nxp.com [165.114.16.14]) by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id E9F5B1A0EB9; Fri, 5 Jul 2019 12:07:19 +0200 (CEST) Received: from titan.ap.freescale.net (TITAN.ap.freescale.net [10.192.208.233]) by invc005.ap-rdc01.nxp.com (Postfix) with ESMTP id B0AA7402EB; Fri, 5 Jul 2019 18:07:09 +0800 (SGT) From: Hou Zhiqiang To: linux-pci@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, bhelgaas@google.com, robh+dt@kernel.org, mark.rutland@arm.com, l.subrahmanya@mobiveil.co.in, shawnguo@kernel.org, leoyang.li@nxp.com, lorenzo.pieralisi@arm.com, catalin.marinas@arm.com, will.deacon@arm.com Subject: [PATCHv6 16/28] PCI: mobiveil: Fix the returned error number Date: Fri, 5 Jul 2019 17:56:44 +0800 Message-Id: <20190705095656.19191-17-Zhiqiang.Hou@nxp.com> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20190705095656.19191-1-Zhiqiang.Hou@nxp.com> References: <20190705095656.19191-1-Zhiqiang.Hou@nxp.com> X-Virus-Scanned: ClamAV using ClamSMTP X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190705_110738_001563_35E17069 X-CRM114-Status: UNSURE ( 9.96 ) X-CRM114-Notice: Please train this message. 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: Minghuan.Lian@nxp.com, Hou Zhiqiang , Xiaowei.Bao@nxp.com, Mingkai.Hu@nxp.com MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP This patch modified the returned error number by convention. Signed-off-by: Hou Zhiqiang Reviewed-by: Minghuan Lian Reviewed-by: Subrahmanya Lingappa --- V6: - Splited from #3 of v5 patches, no functional change. drivers/pci/controller/pcie-mobiveil.c | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/pci/controller/pcie-mobiveil.c b/drivers/pci/controller/pcie-mobiveil.c index 965f89a..51cbe53 100644 --- a/drivers/pci/controller/pcie-mobiveil.c +++ b/drivers/pci/controller/pcie-mobiveil.c @@ -822,7 +822,7 @@ static int mobiveil_pcie_init_irq_domain(struct mobiveil_pcie *pcie) if (!pcie->intx_domain) { dev_err(dev, "Failed to get a INTx IRQ domain\n"); - return -ENODEV; + return -ENOMEM; } raw_spin_lock_init(&pcie->intx_mask_lock); @@ -848,7 +848,7 @@ static int mobiveil_pcie_probe(struct platform_device *pdev) /* allocate the PCIe port */ bridge = devm_pci_alloc_host_bridge(dev, sizeof(*pcie)); if (!bridge) - return -ENODEV; + return -ENOMEM; pcie = pci_host_bridge_priv(bridge); if (!pcie) @@ -869,7 +869,7 @@ static int mobiveil_pcie_probe(struct platform_device *pdev) &pcie->resources, &iobase); if (ret) { dev_err(dev, "Getting bridge resources failed\n"); - return -ENOMEM; + return ret; } /*