Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1844195imu; Tue, 6 Nov 2018 05:20:23 -0800 (PST) X-Google-Smtp-Source: AJdET5cLJCpA4HbKYopGTDvxf7DM3FlHoBCSKfai3vlIWHxhCvFye8H1ovnrRSXCwmiiOKbk1pfX X-Received: by 2002:a62:f24f:: with SMTP id y15-v6mr26169342pfl.25.1541510423165; Tue, 06 Nov 2018 05:20:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541510423; cv=none; d=google.com; s=arc-20160816; b=pbOc6JNdF3sI4ZhYPLc2jIf1+/T18JJLk5EtwTO8koHHmjOl/qPz3qmr6P8HIp1dwj AQeWp8t5EImj4dvmpEVTZ7//Cmf+1rsYbp+H9EsTd47JzG3OfumzuvZr1aO7Hh8mK8qd YT9ewYb835VFiVv+5f6Bkd9OBh2caQl5BISaOfLAiYdCJ0aqpWACCRklDHIV/2wgNlFu btN7Su98lv5kjLDBySS20S/PxUVd+tZph0Rw5wyIrhaxTMVWWhuxIwd9pJJki83Er/LE QFWvWnMIrMh1DZhmo7Wv/7oevuOl/iz6VHaNpLHfgRzF+JqkcxTPONm46hkQDdcFfub/ qj0w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :spamdiagnosticmetadata:spamdiagnosticoutput:content-language :accept-language:in-reply-to:references:message-id:date:thread-index :thread-topic:subject:cc:to:from:dkim-signature; bh=9AC3UUG1F1PvvLngn7cYEsiSg64fPhRxYE3u5taIiX0=; b=Zx/WanGaY+V1SeIWNRyYhHRrOdOESi3bolMyge3QAO2tYu7ip4Kpnwn21QVbgK6gI3 u/5Nrzaq1z8NR0kwQFmQLAQFxhh49GqeG+TRgdwzYXNi8DdylielalwHyPkV1+7CPPFk r1QMZSFaTHe4KDoUVmMUvv8NvA0X7cpK/YOFPiIyu9ATISaO7HfbyvheSk+k9I4qbPEn fhBDmylGRBO5dmIXBmkooHNJsH2gi+zE3fb5PYiBR/bW93D8VXnOIkgClKF9bAH6Y3zm YyxnHqIVcVZG7EWOtXBPCRlSQkNcFUGhhvFBb4f/b4x8X3d6+yDVYLgaP3oReWIIq5xE FERg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nxp.com header.s=selector1 header.b=u3bzRr1h; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g11-v6si43551004pgs.179.2018.11.06.05.20.07; Tue, 06 Nov 2018 05:20:23 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@nxp.com header.s=selector1 header.b=u3bzRr1h; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388231AbeKFWom (ORCPT + 99 others); Tue, 6 Nov 2018 17:44:42 -0500 Received: from mail-ve1eur01on0042.outbound.protection.outlook.com ([104.47.1.42]:6144 "EHLO EUR01-VE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S2388144AbeKFWol (ORCPT ); Tue, 6 Nov 2018 17:44:41 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=9AC3UUG1F1PvvLngn7cYEsiSg64fPhRxYE3u5taIiX0=; b=u3bzRr1hhrhTHqw1BNhXj51o1rQaVjRvSO1GOnaRepJXtYW1Tjq3jbs1zJ2Z3iJLbOjHpx109quiZ1eFq28o0nIElvaVa2fqty8LuAn9pR+PisqWVToLz6Wb4GX+bBHnKSQoTfMLlXTSq4F9JElO0fp0hLtjLhOV+AKi9rTc9qU= Received: from DB5PR04MB1221.eurprd04.prod.outlook.com (10.162.155.27) by DB5PR04MB0984.eurprd04.prod.outlook.com (10.161.196.28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1294.21; Tue, 6 Nov 2018 13:19:25 +0000 Received: from DB5PR04MB1221.eurprd04.prod.outlook.com ([fe80::6c36:f4cb:26c2:e8cb]) by DB5PR04MB1221.eurprd04.prod.outlook.com ([fe80::6c36:f4cb:26c2:e8cb%2]) with mapi id 15.20.1273.035; Tue, 6 Nov 2018 13:19:25 +0000 From: "Z.q. Hou" 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" , Leo Li , "lorenzo.pieralisi@arm.com" CC: Mingkai Hu , "M.h. Lian" , Xiaowei Bao , "Z.q. Hou" Subject: [PATCH 03/23] PCI: mobiveil: correct the returned error number Thread-Topic: [PATCH 03/23] PCI: mobiveil: correct the returned error number Thread-Index: AQHUddNWBw9Y+2zWwUWykmDsJwZN2g== Date: Tue, 6 Nov 2018 13:19:25 +0000 Message-ID: <20181106131807.29951-4-Zhiqiang.Hou@nxp.com> References: <20181106131807.29951-1-Zhiqiang.Hou@nxp.com> In-Reply-To: <20181106131807.29951-1-Zhiqiang.Hou@nxp.com> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: HK0PR03CA0008.apcprd03.prod.outlook.com (2603:1096:203:2e::20) To DB5PR04MB1221.eurprd04.prod.outlook.com (2a01:111:e400:51c2::27) authentication-results: spf=none (sender IP is ) smtp.mailfrom=zhiqiang.hou@nxp.com; x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [119.31.174.73] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;DB5PR04MB0984;6:8QcC08GxecpxAHu+xkULTEFr2LgMh6/h/glf029Y9w5hJ5nzUTfYSdTPjBkNT7ebH5jk7K5qaufiuvSmC6+lhnJNxvQZzOkUzOX4wEaCYOvnp1aHmX/yXmdh5b5j8pjbsMCdMtXv1jJtLn+M30XZEz2DAzIZvo5p+1StykvPKS9pP8TejP3wE6dJnnLhRBrRR1lgtcZmJ2DClJD/oEIbMaQ3Wo7HYMLvFGwP44LpAOhTkUONoTLeAMdr10Ze1CdhGfKAq3mb2V+xfDzX/lX/bUOve55U1u6S/rHwFuG/ekDlWGfW17l2L0ZHXuyk0HqExp2ipycvBYLrEGKxOWRF23/sLec+TGAQ3xG8RXRy57k3vK4cwoKOl1d2gsPcSWnHodw6DjOqJ069kATMMOQ+jrWpLMiBXcg1Nmp7W3aJz9ZGxl81rKjKtCabsph5lcH+hvmkPXgYnyiXM4AKH6FxJQ==;5:l46jzSUURO7wuA8VmPerwbVZ9otX7BDzPzT8Iii5WsSRKpDNy6/irKlpYgo1CU+jceipj2Gt4ZS6skAymI83Nre5v1so+z/y0s3qC8DOZskAM3Pi0Z7/dct77EX6Kln6f52fkXweJSTtefvZMWw1kSou/c+dRpOQmJiOGW8a6No=;7:6xK8d2lK8tecnTfpW309Xiyu7GBtryU0K7fwGpNLQwLfAQlqfgz7ETaPqdNBKBJgk81ZDcPBS4wMuuwnJmNt+0WpAyPmv6+NoPHqrC0nJPxYBgyQZYGZcyZny+kXV+WXmcnsNRVYMmLAhiGZhdc1JQ== x-ms-office365-filtering-correlation-id: b37e4529-cc03-4fc3-f2a7-08d643ea78c4 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0;PCL:0;RULEID:(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600074)(711020)(4618075)(2017052603328)(7153060)(7193020);SRVR:DB5PR04MB0984; x-ms-traffictypediagnostic: DB5PR04MB0984: x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(269456686620040)(185117386973197); x-ms-exchange-senderadcheck: 1 x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(93006095)(93001095)(10201501046)(3002001)(3231382)(944501410)(52105095)(6055026)(148016)(149066)(150057)(6041310)(20161123558120)(20161123564045)(20161123562045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(201708071742011)(7699051)(76991095);SRVR:DB5PR04MB0984;BCL:0;PCL:0;RULEID:;SRVR:DB5PR04MB0984; x-forefront-prvs: 0848C1A6AA x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(376002)(346002)(39860400002)(366004)(136003)(396003)(199004)(189003)(68736007)(486006)(386003)(8936002)(3846002)(99286004)(71190400001)(81156014)(71200400001)(81166006)(53936002)(8676002)(105586002)(110136005)(54906003)(5660300001)(2616005)(446003)(11346002)(66066001)(97736004)(305945005)(7416002)(476003)(2900100001)(7736002)(106356001)(14444005)(2201001)(4326008)(2501003)(25786009)(1076002)(186003)(6486002)(26005)(2906002)(256004)(6512007)(36756003)(6116002)(6436002)(316002)(102836004)(52116002)(6506007)(86362001)(14454004)(76176011)(478600001)(921003)(1121003);DIR:OUT;SFP:1101;SCL:1;SRVR:DB5PR04MB0984;H:DB5PR04MB1221.eurprd04.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; received-spf: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) x-microsoft-antispam-message-info: dEJput1Ah59F2ebPX/TXauTSIxY1T3eUulFDh1zXL4Hcry5y7qWR2Ts7VAVSIYcww1O5qcGi3so4ddENNU/de0zHUcEzga/NhAa1N042gtfoGaTRiAjpE6ecIQJ/iih8Zfr0h+N1wJdWg8KNiIr/Gu7u1uqFv4dsy4wNBBMGulJ1pRKmgGF3xX062RYWzx3R5K+CmpwyFM3gRQF/gKiGVX9h7V03E7UEI2JTrgi6ytxGPb8tQ5CvUVjgWVTxLM8UL196jxAkA5uuI9TZ6g+7UCxBv74fQOkE42g0iNaNRiHQ0jEVBwlMEWEtScUqM9dbeirQeq/BVDxVYvJ1mwbFYOQgQacG4HyS/g+/FqA7GP4= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: b37e4529-cc03-4fc3-f2a7-08d643ea78c4 X-MS-Exchange-CrossTenant-originalarrivaltime: 06 Nov 2018 13:19:25.3020 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB5PR04MB0984 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Hou Zhiqiang This patch corrected the returned error number by convention, and removed a unnecessary error check. Signed-off-by: Hou Zhiqiang --- drivers/pci/controller/pcie-mobiveil.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/drivers/pci/controller/pcie-mobiveil.c b/drivers/pci/controlle= r/pcie-mobiveil.c index b87471f08a40..563210e731d3 100644 --- a/drivers/pci/controller/pcie-mobiveil.c +++ b/drivers/pci/controller/pcie-mobiveil.c @@ -819,7 +819,7 @@ static int mobiveil_pcie_init_irq_domain(struct mobivei= l_pcie *pcie) =20 if (!pcie->intx_domain) { dev_err(dev, "Failed to get a INTx IRQ domain\n"); - return -ENODEV; + return -ENOMEM; } =20 raw_spin_lock_init(&pcie->intx_mask_lock); @@ -845,11 +845,9 @@ static int mobiveil_pcie_probe(struct platform_device = *pdev) /* allocate the PCIe port */ bridge =3D devm_pci_alloc_host_bridge(dev, sizeof(*pcie)); if (!bridge) - return -ENODEV; + return -ENOMEM; =20 pcie =3D pci_host_bridge_priv(bridge); - if (!pcie) - return -ENOMEM; =20 pcie->pdev =3D pdev; =20 @@ -866,7 +864,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; } =20 /* --=20 2.17.1