ice: clear NAPI's IRQ numbers in ice_vsi_clear_napi_queues()
authorAhmed Zaki <ahmed.zaki@intel.com>
Mon, 24 Feb 2025 23:22:24 +0000 (16:22 -0700)
committerJakub Kicinski <kuba@kernel.org>
Thu, 27 Feb 2025 03:51:37 +0000 (19:51 -0800)
We set the NAPI's IRQ number in ice_vsi_set_napi_queues(). Clear the
NAPI's IRQ in ice_vsi_clear_napi_queues().

Signed-off-by: Ahmed Zaki <ahmed.zaki@intel.com>
Link: https://patch.msgid.link/20250224232228.990783-4-ahmed.zaki@intel.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/intel/ice/ice_lib.c

index 7f5b229cab059b143367ae8938d0035ef2ea7b70..ce30674abf8f122ec0eef75ba35015765e96da50 100644 (file)
@@ -2765,11 +2765,18 @@ void ice_vsi_set_napi_queues(struct ice_vsi *vsi)
 void ice_vsi_clear_napi_queues(struct ice_vsi *vsi)
 {
        struct net_device *netdev = vsi->netdev;
-       int q_idx;
+       int q_idx, v_idx;
 
        if (!netdev)
                return;
 
+       /* Clear the NAPI's interrupt number */
+       ice_for_each_q_vector(vsi, v_idx) {
+               struct ice_q_vector *q_vector = vsi->q_vectors[v_idx];
+
+               netif_napi_set_irq(&q_vector->napi, -1);
+       }
+
        ice_for_each_txq(vsi, q_idx)
                netif_queue_set_napi(netdev, q_idx, NETDEV_QUEUE_TYPE_TX, NULL);