[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20240823140309.1974696-19-sashal@kernel.org>
Date: Fri, 23 Aug 2024 10:02:33 -0400
From: Sasha Levin <sashal@...nel.org>
To: linux-kernel@...r.kernel.org,
stable@...r.kernel.org
Cc: Peiyang Wang <wangpeiyang1@...wei.com>,
Jijie Shao <shaojijie@...wei.com>,
Paolo Abeni <pabeni@...hat.com>,
Sasha Levin <sashal@...nel.org>,
yisen.zhuang@...wei.com,
salil.mehta@...wei.com,
davem@...emloft.net,
edumazet@...gle.com,
kuba@...nel.org,
horms@...nel.org,
wangjie125@...wei.com,
liuyonglong@...wei.com,
lanhao@...wei.com,
chenhao418@...wei.com,
shenjian15@...wei.com,
netdev@...r.kernel.org
Subject: [PATCH AUTOSEL 6.6 19/20] net: hns3: use correct release function during uninitialization
From: Peiyang Wang <wangpeiyang1@...wei.com>
[ Upstream commit 7660833d217528c8f2385528951ab820a031e4e3 ]
pci_request_regions is called to apply for PCI I/O and memory resources
when the driver is initialized, Therefore, when the driver is uninstalled,
pci_release_regions should be used to release PCI I/O and memory resources
instead of pci_release_mem_regions is used to release memory reasouces
only.
Signed-off-by: Peiyang Wang <wangpeiyang1@...wei.com>
Signed-off-by: Jijie Shao <shaojijie@...wei.com>
Signed-off-by: Paolo Abeni <pabeni@...hat.com>
Signed-off-by: Sasha Levin <sashal@...nel.org>
---
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c
index c8059d96f64be..3b01447478159 100644
--- a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c
+++ b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c
@@ -11358,7 +11358,7 @@ static void hclge_pci_uninit(struct hclge_dev *hdev)
pcim_iounmap(pdev, hdev->hw.hw.io_base);
pci_free_irq_vectors(pdev);
- pci_release_mem_regions(pdev);
+ pci_release_regions(pdev);
pci_disable_device(pdev);
}
--
2.43.0
Powered by blists - more mailing lists