Patchwork [net,2/3] mlx4: fix QP tree trashing

mail settings
Submitter Yevgeny Petrilin
Date Feb. 15, 2012, 4:22 p.m.
Message ID <>
Download mbox | patch
Permalink /patch/141337/
State Accepted
Delegated to: David Miller
Headers show


Yevgeny Petrilin - Feb. 15, 2012, 4:22 p.m.
From: Eugenia Emantayev <>

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.

Signed-off-by: Eugenia Emantayev <>
Reviewed-by: Yevgeny Petrilin <>
 .../net/ethernet/mellanox/mlx4/resource_tracker.c  |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)


diff --git a/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c b/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c
index 1420dbc..629cc30 100644
--- a/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c
+++ b/drivers/net/ethernet/mellanox/mlx4/resource_tracker.c
@@ -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;