net/mlx5: set Tx queue affinity in round-robin
[dpdk.git] / drivers / net / mlx5 / linux / mlx5_os.c
index 7de60ac..e222720 100644 (file)
@@ -827,7 +827,6 @@ mlx5_representor_match(struct mlx5_dev_spawn_data *spawn,
        return false;
 }
 
-
 /**
  * Spawn an Ethernet device from Verbs information.
  *
@@ -1590,6 +1589,7 @@ err_secondary:
         */
        MLX5_ASSERT(spawn->ifindex);
        priv->if_index = spawn->ifindex;
+       priv->lag_affinity_idx = sh->refcnt - 1;
        eth_dev->data->dev_private = priv;
        priv->dev_data = eth_dev->data;
        eth_dev->data->mac_addrs = priv->mac;
@@ -2666,6 +2666,15 @@ mlx5_os_net_probe(struct mlx5_common_device *cdev)
                return mlx5_os_auxiliary_probe(cdev);
 }
 
+/**
+ * Cleanup resources when the last device is closed.
+ */
+void
+mlx5_os_net_cleanup(void)
+{
+       mlx5_pmd_socket_uninit();
+}
+
 /**
  * Install shared asynchronous device events handler.
  * This function is implemented to support event sharing