svn commit: r319566 - stable/11/sys/ofed/drivers/net/mlx4
Hans Petter Selasky
hselasky at FreeBSD.org
Sun Jun 4 08:45:15 UTC 2017
Author: hselasky
Date: Sun Jun 4 08:45:13 2017
New Revision: 319566
URL: https://svnweb.freebsd.org/changeset/base/319566
Log:
MFC r319413:
Free hardware queue resource after port is stopped in the mlx4en(4)
driver. Else if the port is up the resource might still be busy and
the MTT free will fail.
PR: 216493
Approved by: re (kib)
Sponsored by: Mellanox Technologies
Modified:
stable/11/sys/ofed/drivers/net/mlx4/en_netdev.c
Directory Properties:
stable/11/ (props changed)
Modified: stable/11/sys/ofed/drivers/net/mlx4/en_netdev.c
==============================================================================
--- stable/11/sys/ofed/drivers/net/mlx4/en_netdev.c Sun Jun 4 08:30:55 2017 (r319565)
+++ stable/11/sys/ofed/drivers/net/mlx4/en_netdev.c Sun Jun 4 08:45:13 2017 (r319566)
@@ -1731,13 +1731,12 @@ void mlx4_en_destroy_netdev(struct net_device *dev)
mutex_unlock(&mdev->state_lock);
}
- if (priv->allocated)
- mlx4_free_hwq_res(mdev->dev, &priv->res, MLX4_EN_PAGE_SIZE);
-
mutex_lock(&mdev->state_lock);
mlx4_en_stop_port(dev);
mutex_unlock(&mdev->state_lock);
+ if (priv->allocated)
+ mlx4_free_hwq_res(mdev->dev, &priv->res, MLX4_EN_PAGE_SIZE);
cancel_delayed_work(&priv->stats_task);
cancel_delayed_work(&priv->service_task);
More information about the svn-src-stable
mailing list