IB/mlx5: Fix RC transport send queue overhead computation
authorEli Cohen <eli@dev.mellanox.co.il>
Tue, 28 Jan 2014 12:52:47 +0000 (14:52 +0200)
committerRoland Dreier <roland@purestorage.com>
Fri, 7 Feb 2014 07:00:48 +0000 (23:00 -0800)
Fix the RC QPs send queue overhead computation to take into account
two additional segments in the WQE which are needed for registration
operations.

Signed-off-by: Eli Cohen <eli@mellanox.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
drivers/infiniband/hw/mlx5/qp.c

index ae37fb9bf2627c7507dfb7b6a75e369e5b5fe29f..492dc330e907a527021052e62f7df372b9eead33 100644 (file)
@@ -216,7 +216,9 @@ static int sq_overhead(enum ib_qp_type qp_type)
 
        case IB_QPT_UC:
                size += sizeof(struct mlx5_wqe_ctrl_seg) +
-                       sizeof(struct mlx5_wqe_raddr_seg);
+                       sizeof(struct mlx5_wqe_raddr_seg) +
+                       sizeof(struct mlx5_wqe_umr_ctrl_seg) +
+                       sizeof(struct mlx5_mkey_seg);
                break;
 
        case IB_QPT_UD: