Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp3925475pxj; Mon, 21 Jun 2021 09:30:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwZf+9WsPk1IwTMMwKetHmR3CFcxqqJQo5TPfddTwEJrCDHFfKSZBbJZgf4gOE5tAZB0WsC X-Received: by 2002:a05:6602:204f:: with SMTP id z15mr21174945iod.172.1624293028275; Mon, 21 Jun 2021 09:30:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1624293028; cv=none; d=google.com; s=arc-20160816; b=Ivn2sx0m7H7BVvlcsQMczaxjs1RPAun90YIwYxxqFQltRPBBDecrjxkE/HEkEPC1Jg PzIVAyXmkgqsEkrr/tkN739Xf5W2H4ZWjUR3AYU6m6W8NrRDTRTy35TDLeIL9tFU3pd3 9HxpVEzPKsDiogXbkG73s/v3V6n9Hy1LKIGQckAneJfCBKNId5p6KVimjFDrzaBbt3Ro f86esZoJEBQn/0Awj90WMWTOQnlvJERg+8/q19Y42TkHGLlSJInR/at5NKm8EPn8fyRx oPa1PhPITztdNRyr+YJ7vlSI7TvuzA0Ero/lgWoijbIpB31qI5D9YYJwdgWtRHioPgdR Tbqw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=bZrtVq3fKCy1/4jgfFiRej08gVD2n6pOqV7c7eTUp5k=; b=Vglzv00I3ZKDg2zLB18CpARG5Km66/Pg+mOP7D34LWdEynqm8MLtW4M/Je6CDOutgv y6oV6uDhvdh/b6+llTK0+JUObzeqY4okpk+M1//Ij1FZlLOa6NBw+Caa8mMM5ED9yYFr imls/yQw+8H13ZrENSezmeCUZ4sTNTUu4pkMLFKkIHPfsouNXB3c8gXDdRpk5NSoh3xW cghWb3AWpqgREchecMOoz/ayRb1TUgckT4DflTVJ0+NU31KtQvPIpWYaPR5nlMhWAYVG J+WDbvTepzuS/PdWYrvwj6vmWfcQTJSvd8D4ptSWKMCW2ieGgoqm9VadL+lXiwMzuflP KO3w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=nvss4HQA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i17si11930462ilk.46.2021.06.21.09.30.16; Mon, 21 Jun 2021 09:30:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=nvss4HQA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230523AbhFUQb6 (ORCPT + 99 others); Mon, 21 Jun 2021 12:31:58 -0400 Received: from mail.kernel.org ([198.145.29.99]:49174 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232481AbhFUQ3d (ORCPT ); Mon, 21 Jun 2021 12:29:33 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 3E64361400; Mon, 21 Jun 2021 16:24:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1624292660; bh=vQa3WRUXBaoO0MDN369yEG3QL7O0qB3xPdu6boF6Vnw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=nvss4HQAo/EBgc7CnPQCX8qZ4GUzFlparNFhjRkkZpNG8X80uVsQCLpLfANC+wrFX 7oALTtzPGKkb/DoZv7ah7keD/UNHNxgHNxCTjjrMuAPjwOYMPaoV7EXYW/7etcmeV5 CYs/W2dfsrMzlTXwDwI948dmM6tS/77eZkOJ3cdE= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Christophe JAILLET , "David S. Miller" , Sasha Levin Subject: [PATCH 5.10 050/146] netxen_nic: Fix an error handling path in netxen_nic_probe() Date: Mon, 21 Jun 2021 18:14:40 +0200 Message-Id: <20210621154913.110589792@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210621154911.244649123@linuxfoundation.org> References: <20210621154911.244649123@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Christophe JAILLET [ Upstream commit 49a10c7b176295f8fafb338911cf028e97f65f4d ] 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: e87ad5539343 ("netxen: support pci error handlers") Signed-off-by: Christophe JAILLET Signed-off-by: David S. Miller Signed-off-by: Sasha Levin --- drivers/net/ethernet/qlogic/netxen/netxen_nic_main.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/ethernet/qlogic/netxen/netxen_nic_main.c b/drivers/net/ethernet/qlogic/netxen/netxen_nic_main.c index d258e0ccf946..e2046b6d65a3 100644 --- a/drivers/net/ethernet/qlogic/netxen/netxen_nic_main.c +++ b/drivers/net/ethernet/qlogic/netxen/netxen_nic_main.c @@ -1602,6 +1602,8 @@ err_out_free_netdev: free_netdev(netdev); err_out_free_res: + if (NX_IS_REVISION_P3(pdev->revision)) + pci_disable_pcie_error_reporting(pdev); pci_release_regions(pdev); err_out_disable_pdev: -- 2.30.2