public inbox for linux-rdma@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] mlx4: Fix bug in mlx4_ib_mcg_attach
@ 2009-12-08 15:14 Eli Cohen
  2009-12-09 22:33 ` Roland Dreier
  0 siblings, 1 reply; 5+ messages in thread
From: Eli Cohen @ 2009-12-08 15:14 UTC (permalink / raw)
  To: Roland Dreier; +Cc: Linux RDMA list, ewg

The "!" operator has precedence over the "&" operator so parenthesis are
required to properly evaluate the user's loopback requirement.

Signed-off-by: Eli Cohen <eli-VPRAkNaXOzVS1MOuV/RT9w@public.gmane.org>
---
 drivers/infiniband/hw/mlx4/main.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/infiniband/hw/mlx4/main.c b/drivers/infiniband/hw/mlx4/main.c
index 0f6ef38..736eea0 100644
--- a/drivers/infiniband/hw/mlx4/main.c
+++ b/drivers/infiniband/hw/mlx4/main.c
@@ -586,8 +586,8 @@ static int mlx4_ib_mcg_attach(struct ib_qp *ibqp, union ib_gid *gid, u16 lid)
 	struct mlx4_ib_dev *mdev = to_mdev(ibqp->device);
 	struct mlx4_ib_qp *mqp = to_mqp(ibqp);
 
-	err = mlx4_multicast_attach(mdev->dev, &mqp->mqp, gid->raw, !!mqp->flags &
-				    MLX4_IB_QP_BLOCK_MULTICAST_LOOPBACK);
+	err = mlx4_multicast_attach(mdev->dev, &mqp->mqp, gid->raw, !!(mqp->flags &
+				    MLX4_IB_QP_BLOCK_MULTICAST_LOOPBACK));
 	if (err)
 		return err;
 
-- 
1.6.5.5

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2009-12-10 11:37 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-08 15:14 [PATCH] mlx4: Fix bug in mlx4_ib_mcg_attach Eli Cohen
2009-12-09 22:33 ` Roland Dreier
     [not found]   ` <aday6lbpykk.fsf-BjVyx320WGW9gfZ95n9DRSW4+XlvGpQz@public.gmane.org>
2009-12-09 22:48     ` Eli Cohen
2009-12-09 22:49       ` Roland Dreier
     [not found]         ` <adad42npxtg.fsf-BjVyx320WGW9gfZ95n9DRSW4+XlvGpQz@public.gmane.org>
2009-12-10 11:37           ` Eli Cohen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox