Message ID | 20170310024617.67303-2-briannorris@chromium.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org> 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 95BB060417 for <patchwork-linux-rockchip@patchwork.kernel.org>; Fri, 10 Mar 2017 02:46:59 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7E3C52846A for <patchwork-linux-rockchip@patchwork.kernel.org>; Fri, 10 Mar 2017 02:46:59 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 70233285B0; Fri, 10 Mar 2017 02:46:59 +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=-1.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.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 C9C1C2846A for <patchwork-linux-rockchip@patchwork.kernel.org>; Fri, 10 Mar 2017 02:46:58 +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=ec6I1dae7zZE93fU2/TWPhHhkDzbbVEchpuHsKuIpzQ=; b=VrUp+4d+WWhf8rDLhvMyqBX0SN CCcGe5bARMgit+TXa9Gr8MZVe7SZzwLgPkclXV7EGCPWVtFYIGjiR87Z0J8iKRDOiZXT1YavWW5+G ufQsO8u08PROelxdLcBKlIZzwGlReTvTtXnX6HPm1fP+Bw9iILVLwL0vb+WEiZ1NnG/Sj/AGVfa0X lhB8PgU0MKSvz0D+x6XdpISVIW9inV+DIn2fGT34ojkNJt2mZyQ9W3nye5SyYJkDjYcvras8uWslJ mhpxT8KYiFz5r9Y0E/1yZ28fInr5aXbnpVBv3QP92ojs4qkVnuENrhDxmQwpjRQZbBqTUJ9ibvE7E CsC2fuRw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1cmAa1-0006QV-5s; Fri, 10 Mar 2017 02:46:57 +0000 Received: from mail-pg0-x232.google.com ([2607:f8b0:400e:c05::232]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1cmAZw-0006Mp-SP for linux-rockchip@lists.infradead.org; Fri, 10 Mar 2017 02:46:54 +0000 Received: by mail-pg0-x232.google.com with SMTP id 25so33442647pgy.0 for <linux-rockchip@lists.infradead.org>; 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=gfRQ/WANXsrZd+4cvqaio03rTTl18FDLKfJW9YSKdMD7NQ2bI5QoKm451yceRZH15/ hTkbx95qjDggoV3UXaEIVdXtYxB63fLDuO25jDVV3Z2lqEfvjrbT/SOFaXNQrPV1S6nQ z+FYgZR5cn+wL5d49PIat4nX61rXMCIXYbkxxA5anq9Y/i+iKX0Jfd23wEFYaGrKzWHZ ygbFsvORD+izvHk0jaxNVlMNkOMpW6Pkg4vsyqwWAkyBdWIo403WFF891C/u+p0kXgGM RyIHwOQ0rJMXsIlMJp1zTLO0HaaYpO/fjntSAziX+Oc0eaScEjesMHEw4/XKxWhQT8wI aqfA== X-Gm-Message-State: AMke39lamCf+C7iXxif+V3rnMisAFsU67PXLjg92niEQzrDs/2ShJ7VO1wB07LRSwH7cUnmg 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 <briannorris@chromium.org> To: Bjorn Helgaas <bhelgaas@google.com> 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> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170309_184652_958812_480CA51B X-CRM114-Status: UNSURE ( 8.81 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Upstream kernel work for Rockchip platforms <linux-rockchip.lists.infradead.org> List-Unsubscribe: <http://lists.infradead.org/mailman/options/linux-rockchip>, <mailto:linux-rockchip-request@lists.infradead.org?subject=unsubscribe> List-Archive: <http://lists.infradead.org/pipermail/linux-rockchip/> List-Post: <mailto:linux-rockchip@lists.infradead.org> List-Help: <mailto:linux-rockchip-request@lists.infradead.org?subject=help> List-Subscribe: <http://lists.infradead.org/mailman/listinfo/linux-rockchip>, <mailto:linux-rockchip-request@lists.infradead.org?subject=subscribe> Cc: Jeffy Chen <jeffy.chen@rock-chips.com>, linux-pci@vger.kernel.org, Shawn Lin <shawn.lin@rock-chips.com>, Wenrui Li <wenrui.li@rock-chips.com>, linux-kernel@vger.kernel.org, Brian Norris <briannorris@chromium.org>, linux-rockchip@lists.infradead.org MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "Linux-rockchip" <linux-rockchip-bounces@lists.infradead.org> Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP |
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);
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 <briannorris@chromium.org> --- v2: no change --- drivers/pci/host/pcie-rockchip.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)