From patchwork Sun Jul 16 06:41:53 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 9842773 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 1A7AE603B4 for ; Sun, 16 Jul 2017 06:42:00 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 01D302857B for ; Sun, 16 Jul 2017 06:42:00 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id EAD8C285A6; Sun, 16 Jul 2017 06:41: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=-6.5 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM 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 866762859E for ; Sun, 16 Jul 2017 06:41:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751229AbdGPGl6 (ORCPT ); Sun, 16 Jul 2017 02:41:58 -0400 Received: from mail-pg0-f47.google.com ([74.125.83.47]:34889 "EHLO mail-pg0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751219AbdGPGl5 (ORCPT ); Sun, 16 Jul 2017 02:41:57 -0400 Received: by mail-pg0-f47.google.com with SMTP id v190so6244513pgv.2 for ; Sat, 15 Jul 2017 23:41:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=reoU3j+OkLiKd0WioZU7oEExYEuEXvEvRRrD9DWjNs0=; b=LBm5fRE8xigCN+SiJSVBeEAV/udm6TmLvHCjDVFb6vj+6a/hXNkbw2+xOQG3e906p6 hZ6CTOvv9iGlVM0IxjUX3v4m3qne+6ZYLL7PyiTYmL9nn0sooK8O3o7uysACZK2Obhne 0Nh24h2NgjXylX306i5VH15Pmk2uGPWXUuABI= 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; bh=reoU3j+OkLiKd0WioZU7oEExYEuEXvEvRRrD9DWjNs0=; b=c9FXhHBPN+Ap4yi9Tc+nSwq0vLBU5G6tz7UeyvMuVf015ARClixYjLrdtKKeIUImW6 9yySgoxFTdb/Yu/5xht1+PfETVn/ZYj/olDJOGbFO4qQATPWCkAso/XdFOITzEYEEC4P 6uKlW74z2631jl7ShTFqiEs2zSNDanEnVsOyFm/fLWI0X2P7hiGolgqzOUKRKbbXZk5I VDo7+JDbmuFLG6W7f/YarDV2LUCpvI9INghKqPAhcUKq9rDvXU+ZaXx3ZXaJl4LGZLKQ VPILNYb1033ZI1EpaX/hZVyhDbv+uqx4kp3A2dzpYjJH/3+VVxZhrP5CDPFKeyHo3wC5 nk5Q== X-Gm-Message-State: AIVw112jC69+hYW3xcEZb44hxdbtUt2smXl+FYJobuSrhzfS1xGaa4YW oNiwZx+gFJ3w7oKe X-Received: by 10.99.4.3 with SMTP id 3mr406347pge.102.1500187316669; Sat, 15 Jul 2017 23:41:56 -0700 (PDT) Received: from localhost.localdomain (ip68-111-217-79.sd.sd.cox.net. [68.111.217.79]) by smtp.gmail.com with ESMTPSA id b25sm2927782pfl.44.2017.07.15.23.41.55 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 15 Jul 2017 23:41:56 -0700 (PDT) From: Bjorn Andersson To: Stanimir Varbanov , Bjorn Helgaas Cc: linux-pci@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/3] PCI: qcom: Don't unroll init if init fails Date: Sat, 15 Jul 2017 23:41:53 -0700 Message-Id: <20170716064153.3346-1-bjorn.andersson@linaro.org> X-Mailer: git-send-email 2.12.0 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 When the init op fails it will restore the state of the resources, so we should not disable them one more time when this happens. Signed-off-by: Bjorn Andersson --- drivers/pci/dwc/pcie-qcom.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/pci/dwc/pcie-qcom.c b/drivers/pci/dwc/pcie-qcom.c index d15657dc3990..7b703741a3fd 100644 --- a/drivers/pci/dwc/pcie-qcom.c +++ b/drivers/pci/dwc/pcie-qcom.c @@ -901,7 +901,7 @@ static int qcom_pcie_host_init(struct pcie_port *pp) ret = pcie->ops->init(pcie); if (ret) - goto err_deinit; + return ret; ret = phy_power_on(pcie->phy); if (ret)