Commit eaf559bf authored by Roland Dreier's avatar Roland Dreier

mlx4_core: Don't free special QPs in QP number bitmap

Special QPs are not allocated using the regular QP number bitmap, so
when they are destroyed, their QP number should not be freed in the
bitmap.

Found by Dotan Barak of Mellanox.
Signed-off-by: default avatarRoland Dreier <rolandd@cisco.com>
parent 36ce10d3
...@@ -240,7 +240,8 @@ void mlx4_qp_free(struct mlx4_dev *dev, struct mlx4_qp *qp) ...@@ -240,7 +240,8 @@ void mlx4_qp_free(struct mlx4_dev *dev, struct mlx4_qp *qp)
mlx4_table_put(dev, &qp_table->auxc_table, qp->qpn); mlx4_table_put(dev, &qp_table->auxc_table, qp->qpn);
mlx4_table_put(dev, &qp_table->qp_table, qp->qpn); mlx4_table_put(dev, &qp_table->qp_table, qp->qpn);
mlx4_bitmap_free(&qp_table->bitmap, qp->qpn); if (qp->qpn < dev->caps.sqp_start + 8)
mlx4_bitmap_free(&qp_table->bitmap, qp->qpn);
} }
EXPORT_SYMBOL_GPL(mlx4_qp_free); EXPORT_SYMBOL_GPL(mlx4_qp_free);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment