Skip to contentSkip to conversation

mlx4: fix QP tree trashing

PATCH In review Yevgeny Petrilin 1 participant 1 message Feb 15, 2012

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 2/3 mlx4: fix QP tree trashing

From: Eugenia Emantayev <[email protected]>

When adding new unicast steer entry, before moving qp to state ready, actually before calling mlx4_RST2INIT_QP_wrapper(), there were added a lot of entries with local_qpn=0 into radix tree.
This fact impacted the get_res() function and proper functioning of resource tracker in addition to adding trash entries into radix tree.

---
 .../net/ethernet/mellanox/mlx4/resource_tracker.c  |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
drivers/net/ethernet/mellanox/mlx4/resource_tracker.c +1 -0
index 1420dbc..629cc30 100644
@@ -374,6 +374,7 @@ static struct res_common *alloc_qp_tr(int id)
 
 	ret->com.res_id = id;
 	ret->com.state = RES_QP_RESERVED;
+	ret->local_qpn = id;
 	INIT_LIST_HEAD(&ret->mcg_list);
 	spin_lock_init(&ret->mcg_spl);
 
Signature · 1 line
1.5.4.3