From patchwork Mon Jul 26 15:38:38 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 486606 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-19.5 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 21196C4320A for ; Mon, 26 Jul 2021 15:45:36 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 0B93060F8F for ; Mon, 26 Jul 2021 15:45:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236085AbhGZPFG (ORCPT ); Mon, 26 Jul 2021 11:05:06 -0400 Received: from mail.kernel.org ([198.145.29.99]:44870 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235221AbhGZPEh (ORCPT ); Mon, 26 Jul 2021 11:04:37 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id C8E3360F42; Mon, 26 Jul 2021 15:45:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1627314305; bh=hWZ2JdeJJ2OQ+tRZTWulW1WlG/yzAE9Bi3ncEK8GQPI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=UEw/fkDDi57sTQj5Dm7FY6OKGOPY8vH2uBFg+4KuMegdZA6i4/GLXlrDbrKnOp3C9 3o2G1o4g4N3KGAfuJaVin5gRFjIBOE9xhIH9KEE9mdiiLu0kbUIb64eTG8HP2+208K qAT3kCvPcgJH0wbAwbvxgMUTWOV2QP5RXD/a5TDc= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Christophe JAILLET , Tony Brelinski , Tony Nguyen , Sasha Levin Subject: [PATCH 4.9 24/60] ixgbe: Fix an error handling path in ixgbe_probe() Date: Mon, 26 Jul 2021 17:38:38 +0200 Message-Id: <20210726153825.631181770@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210726153824.868160836@linuxfoundation.org> References: <20210726153824.868160836@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Christophe JAILLET [ Upstream commit dd2aefcd5e37989ae5f90afdae44bbbf3a2990da ] If an error occurs after a 'pci_enable_pcie_error_reporting()' call, it must be undone by a corresponding 'pci_disable_pcie_error_reporting()' call, as already done in the remove function. Fixes: 6fabd715e6d8 ("ixgbe: Implement PCIe AER support") Signed-off-by: Christophe JAILLET Tested-by: Tony Brelinski Signed-off-by: Tony Nguyen Signed-off-by: Sasha Levin --- drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c index 8e2aaf774693..2266552532c4 100644 --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c @@ -9840,6 +9840,7 @@ err_ioremap: disable_dev = !test_and_set_bit(__IXGBE_DISABLED, &adapter->state); free_netdev(netdev); err_alloc_etherdev: + pci_disable_pcie_error_reporting(pdev); pci_release_mem_regions(pdev); err_pci_reg: err_dma: