Commit ada388f7 authored by Eli Cohen's avatar Eli Cohen Committed by Roland Dreier

IB/mlx5: Make sure doorbell record is visible before doorbell

Put a wmb() to make sure the doorbell record is visible to the HCA before we
hit doorbell.
Signed-off-by: default avatarEli Cohen <eli@mellanox.com>
Signed-off-by: default avatarRoland Dreier <roland@purestorage.com>
parent 042b9ada
......@@ -2251,6 +2251,10 @@ int mlx5_ib_post_send(struct ib_qp *ibqp, struct ib_send_wr *wr,
qp->db.db[MLX5_SND_DBR] = cpu_to_be32(qp->sq.cur_post);
/* Make sure doorbell record is visible to the HCA before
* we hit doorbell */
wmb();
if (bf->need_lock)
spin_lock(&bf->lock);
......
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