From patchwork Fri Mar 10 02:46:14 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Brian Norris X-Patchwork-Id: 9614527 X-Patchwork-Delegate: bhelgaas@google.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id DFF68604DD for ; Fri, 10 Mar 2017 02:47:21 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D509A2846A for ; Fri, 10 Mar 2017 02:47:21 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id C96A9285A4; Fri, 10 Mar 2017 02:47:21 +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=-7.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 837102846A for ; Fri, 10 Mar 2017 02:47:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754190AbdCJCrU (ORCPT ); Thu, 9 Mar 2017 21:47:20 -0500 Received: from mail-pg0-f54.google.com ([74.125.83.54]:35659 "EHLO mail-pg0-f54.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752935AbdCJCrR (ORCPT ); Thu, 9 Mar 2017 21:47:17 -0500 Received: by mail-pg0-f54.google.com with SMTP id b129so33416999pgc.2 for ; Thu, 09 Mar 2017 18:46:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=aR7O5BPVonXI1xu+Sf1xkREiBLonT4unp8UioDvhWak=; b=GROolxhy/RX5U4xV3v9/peOLT1xUuXyGlApKqnkihPsC03toFIco8q4psfr4JitrQ7 hqYEVBzGmM3kLf8MO0RGctzQXBvSFVxWA12CMJKU72T/qoXzKO9mZstBfvwN2hnJz8it Bq9Wci9SkQARmo9y6CoEWwaWqewkJvo7AN6Xc= 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; bh=aR7O5BPVonXI1xu+Sf1xkREiBLonT4unp8UioDvhWak=; b=VRlhkvpl8BqLtApDq2L8Jvn2Lce8NQyJwpS2ArZRsHIIAUb9cD14lRQCZTQ/GP1nGI X8DfsYh7LGfabzqrOkDJlKumguSrUOj8xgV9DgMWMO/eY9Wxni5f57N0VR77vX8xk3Fd L3fPJ5NLVt0vyx9CXOkALPsTGqf0cSZU0xG8xpG4vzDoHrx++GCaYb/2UWr7wN34AO48 Dik7GE5XeEaKc5yyuvdt6RnPmXffmA8n5c4qeQFRsf/5RW60LKtgYz32bTWDXYvvyheK wDB0j71HYrkiB82wUstoUy0CVZAG1Tf7L3RK7JvMfP6Qsbkf9nlmyv8X76uZ5oPrQIXt ggPA== X-Gm-Message-State: AMke39lkPYnOmVT3zZFyDC29lGSy83G4KKGCbOdA1yIqJOwuDuNYTUrwDjxGSXvmF1Yci4D3 X-Received: by 10.84.241.69 with SMTP id u5mr21851993plm.107.1489113989941; Thu, 09 Mar 2017 18:46:29 -0800 (PST) Received: from ban.mtv.corp.google.com ([172.22.64.120]) by smtp.gmail.com with ESMTPSA id w29sm14830573pfi.131.2017.03.09.18.46.29 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 09 Mar 2017 18:46:29 -0800 (PST) From: Brian Norris To: Bjorn Helgaas Cc: , Shawn Lin , Jeffy Chen , Wenrui Li , linux-pci@vger.kernel.org, linux-rockchip@lists.infradead.org, Brian Norris Subject: [PATCH v2 2/5] PCI: rockchip: make 'return 0' more obvious in probe() Date: Thu, 9 Mar 2017 18:46:14 -0800 Message-Id: <20170310024617.67303-2-briannorris@chromium.org> X-Mailer: git-send-email 2.12.0.246.ga2ecc84866-goog In-Reply-To: <20170310024617.67303-1-briannorris@chromium.org> References: <20170310024617.67303-1-briannorris@chromium.org> Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP There's no way to get here with 'err != 0'. Just return 0 to be more obvious and prevent future changes from accidentally erroring out here without going through the right error paths. Signed-off-by: Brian Norris --- v2: no change --- drivers/pci/host/pcie-rockchip.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/pci/host/pcie-rockchip.c b/drivers/pci/host/pcie-rockchip.c index d785f64ec03b..5d7b27b1e941 100644 --- a/drivers/pci/host/pcie-rockchip.c +++ b/drivers/pci/host/pcie-rockchip.c @@ -1398,7 +1398,7 @@ static int rockchip_pcie_probe(struct platform_device *pdev) pcie_bus_configure_settings(child); pci_bus_add_devices(bus); - return err; + return 0; err_free_res: pci_free_resource_list(&res);