Received: by 2002:a05:6a10:f3d0:0:0:0:0 with SMTP id a16csp3837899pxv; Mon, 28 Jun 2021 14:18:15 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzMsxxiQRGeCZNBr8SthwLKtI9nDVBV2bC04TA24iHxvBdJV5p7omtkQGuR/xZeAhdrgQIN X-Received: by 2002:a05:6e02:1288:: with SMTP id y8mr19005846ilq.86.1624915095631; Mon, 28 Jun 2021 14:18:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1624915095; cv=none; d=google.com; s=arc-20160816; b=x5/nqYspVvvY6quKU5zQHyYtYWxmG6kCuP7VgmOdyTwbNpLvLPXCDPnj81RaoxDy9d CliXJ16d3ztjsLYVDBpzwxoVYmWcNAt+egI2vlE2Gt/8N+KWH4zMmofEv10d3ZZvglrw JimCC0GgB1EGik23dJoJ9+rGG1O6zCyhtJg7NwfSMgbCC6PT8xHiGpefcIXETL+h5GoY ZnZfirI3dUe+eSGXWWGuPKoHpIRSs2cZPc9xfaiWQZoH68FmRPUNezAnnARmHZg2XPEJ TiqNAfWlwq1yKGYTqokeTKXcIHc1yuURHfwlgCX0znCwnEHhU+zEaYaqUMqmsd2yY4Yq 3oqg== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=qOCFIHGVttGHb52MVMJR9PdiMIN4UOcFrepT7DVaBrs=; b=0eO6imKVsz1BA05KwJwZJVIH315W2I8vG7PQQVqpcRSbtQoSpTLjq+UYnONGu6HBf8 6vBWJvxzHau//2yH4Av4C8owj9QuiheEvf076Dk1A9pMcLGSBiSZnMV2qwOWtyUgguFr IiOLxebg/TGwlgVDqxU9jyuAWibMv/H4ny8/6nCmtx6oSV0Fh/72HrksO3pcCeNk5q7I p76g3tkPtVWb+LsGtv0MI7VaDNT8g+nvsrl+7ogbd+aywP1EXYsHNte2ydHOSsvf6zdQ UQU03CFizkAMQbOCPnCKHInJe9v3F++UMESRa7yQ+UI9lHBeGzRgjr+K4WndCya6Ctxr +l/Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=cqvJHOd+; 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=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d187si19851030iog.56.2021.06.28.14.18.00; Mon, 28 Jun 2021 14:18:15 -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=@kernel.org header.s=k20201202 header.b=cqvJHOd+; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238332AbhF1PUz (ORCPT + 99 others); Mon, 28 Jun 2021 11:20:55 -0400 Received: from mail.kernel.org ([198.145.29.99]:36468 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235240AbhF1O62 (ORCPT ); Mon, 28 Jun 2021 10:58:28 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 6206061D4D; Mon, 28 Jun 2021 14:40:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1624891228; bh=dbwtvw43FfxVeS5GEwXlil/V7Gggzt+mq5HXtzcBMFY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=cqvJHOd+ulwRPuz9nbx2psPBsUEJjVqkzeuU3p9BXEvIgNkCQWVqoyQrNOx+lrmUt P8v/VlCwlKzDVFVn0+lU37esFcXPxiyjAZO9gf2xuMJq6WiO1yUJsO1c8E1TnbtE/0 TjtBRG1n6ULoVxu8R9ni/IJED1EgLKbgCaHffC/UnufEpnoxrEzxcX1mE8H9Tf1Afl +mEdG6wvQFKhd4KuivfiTzANwXEREZvwE8ykGeFGuno4U0OjQJMHILmLHhqvjOiLqo 6T9K+yezm/EtdGjyEQ1En+7Ut/JASJqXk6zkYMhcxWCg6YGB4HR4K/Aqeh+TtrTxru YHXoqG2Etx87w== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Christophe JAILLET , "David S . Miller" , Sasha Levin Subject: [PATCH 4.9 27/71] netxen_nic: Fix an error handling path in 'netxen_nic_probe()' Date: Mon, 28 Jun 2021 10:39:19 -0400 Message-Id: <20210628144003.34260-28-sashal@kernel.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210628144003.34260-1-sashal@kernel.org> References: <20210628144003.34260-1-sashal@kernel.org> MIME-Version: 1.0 X-KernelTest-Patch: http://kernel.org/pub/linux/kernel/v4.x/stable-review/patch-4.9.274-rc1.gz X-KernelTest-Tree: git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git X-KernelTest-Branch: linux-4.9.y X-KernelTest-Patches: git://git.kernel.org/pub/scm/linux/kernel/git/stable/stable-queue.git X-KernelTest-Version: 4.9.274-rc1 X-KernelTest-Deadline: 2021-06-30T14:39+00:00 X-stable: review X-Patchwork-Hint: Ignore 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 a5ee3d328f3d..75e25a3fe4a7 100644 --- a/drivers/net/ethernet/qlogic/netxen/netxen_nic_main.c +++ b/drivers/net/ethernet/qlogic/netxen/netxen_nic_main.c @@ -1617,6 +1617,8 @@ netxen_nic_probe(struct pci_dev *pdev, const struct pci_device_id *ent) 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