[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20251024204746.3092277-10-anthony.l.nguyen@intel.com>
Date: Fri, 24 Oct 2025 13:47:44 -0700
From: Tony Nguyen <anthony.l.nguyen@...el.com>
To: davem@...emloft.net,
kuba@...nel.org,
pabeni@...hat.com,
edumazet@...gle.com,
andrew+netdev@...n.ch,
netdev@...r.kernel.org
Cc: Przemek Kitszel <przemyslaw.kitszel@...el.com>,
anthony.l.nguyen@...el.com,
jacob.e.keller@...el.com,
mschmidt@...hat.com,
poros@...hat.com,
horms@...nel.org,
kalesh-anakkur.purayil@...adcom.com,
Aleksandr Loktionov <aleksandr.loktionov@...el.com>,
Rinitha S <sx.rinitha@...el.com>
Subject: [PATCH net-next 9/9] ice: remove duplicate call to ice_deinit_hw() on error paths
From: Przemek Kitszel <przemyslaw.kitszel@...el.com>
Current unwinding code on error paths of ice_devlink_reinit_up() and
ice_probe() have manual call to ice_deinit_hw() (which is good, as there
is also manual call to ice_hw_init() there), which is then duplicated
(and was prior current series) in ice_deinit_dev().
Fix the above by removing ice_deinit_hw() from ice_deinit_dev().
Add a (now missing) call in ice_remove().
Reported-by: Jacob Keller <jacob.e.keller@...el.com>
Link: https://lore.kernel.org/intel-wired-lan/20250717-jk-ddp-safe-mode-issue-v1-1-e113b2baed79@intel.com/
Fixes: 4d3f59bfa2cd ("ice: split ice_init_hw() out from ice_init_dev()")
Signed-off-by: Przemek Kitszel <przemyslaw.kitszel@...el.com>
Reviewed-by: Aleksandr Loktionov <aleksandr.loktionov@...el.com>
Tested-by: Rinitha S <sx.rinitha@...el.com> (A Contingent worker at Intel)
Signed-off-by: Tony Nguyen <anthony.l.nguyen@...el.com>
---
drivers/net/ethernet/intel/ice/ice_main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/intel/ice/ice_main.c b/drivers/net/ethernet/intel/ice/ice_main.c
index a1fe2d363adb..1de3da7b3907 100644
--- a/drivers/net/ethernet/intel/ice/ice_main.c
+++ b/drivers/net/ethernet/intel/ice/ice_main.c
@@ -4784,7 +4784,6 @@ int ice_init_dev(struct ice_pf *pf)
void ice_deinit_dev(struct ice_pf *pf)
{
- ice_deinit_hw(&pf->hw);
ice_service_task_stop(pf);
/* Service task is already stopped, so call reset directly. */
@@ -5466,6 +5465,7 @@ static void ice_remove(struct pci_dev *pdev)
ice_set_wake(pf);
ice_adapter_put(pdev);
+ ice_deinit_hw(&pf->hw);
ice_deinit_dev(pf);
ice_aq_cancel_waiting_tasks(pf);
--
2.47.1
Powered by blists - more mailing lists