From: Or Gerlitz <ogerlitz-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
To: Roland Dreier <roland-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
Cc: linux-rdma <linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
Roland Dreier <roland-BHEL68pLQRGGvPXPguhicg@public.gmane.org>,
Amir Vadai <amirv-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
Subject: Re: [PATCH] IB/mlx4: Fix wrong usage of IPv4 protocol for multicast attach/detach
Date: Wed, 18 Feb 2015 00:10:03 -0500 [thread overview]
Message-ID: <54E41EAB.3000403@mellanox.com> (raw)
In-Reply-To: <1418825854-30022-1-git-send-email-ogerlitz-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
On 12/17/2014 9:17 AM, Or Gerlitz wrote:
> The MLX4_PROT_IB_IPV4 protocol should only be used with RoCEv2 and such.
> Removing this wrong usage allows to run multicast applications over RoCE.
>
> Fixes: d487ee77740c ('IB/mlx4: Use IBoE (RoCE) IP based GIDs in the port GID table')
> Reported-by: Carol Soto <clsoto-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>
> Signed-off-by: Or Gerlitz <ogerlitz-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
> ---
Roland, you missed picking this one (was sent to you whole two months
ago) for 3.19 and meanwhile some code went into mlx4 from the net-next
tree which will cause a small collision here. I am traveling now and
can't send you the revised patch but it should be very easy to generate,
just 1-2 lines added. I would suggest for you to rebase against Dave's
net tree or Linus tree, you should also see it from 0-days builds if you
wait few hours.
> drivers/infiniband/hw/mlx4/main.c | 10 +++++-----
> 1 files changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/infiniband/hw/mlx4/main.c b/drivers/infiniband/hw/mlx4/main.c
> index e861330..ea69975 100644
> --- a/drivers/infiniband/hw/mlx4/main.c
> +++ b/drivers/infiniband/hw/mlx4/main.c
> @@ -1221,8 +1221,7 @@ static int mlx4_ib_mcg_attach(struct ib_qp *ibqp, union ib_gid *gid, u16 lid)
> struct mlx4_ib_qp *mqp = to_mqp(ibqp);
> u64 reg_id;
> struct mlx4_ib_steering *ib_steering = NULL;
> - enum mlx4_protocol prot = (gid->raw[1] == 0x0e) ?
> - MLX4_PROT_IB_IPV4 : MLX4_PROT_IB_IPV6;
> + enum mlx4_protocol prot = MLX4_PROT_IB_IPV6;
>
> if (mdev->dev->caps.steering_mode ==
> MLX4_STEERING_MODE_DEVICE_MANAGED) {
> @@ -1235,8 +1234,10 @@ static int mlx4_ib_mcg_attach(struct ib_qp *ibqp, union ib_gid *gid, u16 lid)
> !!(mqp->flags &
> MLX4_IB_QP_BLOCK_MULTICAST_LOOPBACK),
> prot, ®_id);
> - if (err)
> + if (err) {
> + pr_err("multicast attach op failed, err %d\n", err);
> goto err_malloc;
> + }
>
> err = add_gid_entry(ibqp, gid);
> if (err)
> @@ -1284,8 +1285,7 @@ static int mlx4_ib_mcg_detach(struct ib_qp *ibqp, union ib_gid *gid, u16 lid)
> struct net_device *ndev;
> struct mlx4_ib_gid_entry *ge;
> u64 reg_id = 0;
> - enum mlx4_protocol prot = (gid->raw[1] == 0x0e) ?
> - MLX4_PROT_IB_IPV4 : MLX4_PROT_IB_IPV6;
> + enum mlx4_protocol prot = MLX4_PROT_IB_IPV6;
>
> if (mdev->dev->caps.steering_mode ==
> MLX4_STEERING_MODE_DEVICE_MANAGED) {
--
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
prev parent reply other threads:[~2015-02-18 5:10 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-17 14:17 [PATCH] IB/mlx4: Fix wrong usage of IPv4 protocol for multicast attach/detach Or Gerlitz
[not found] ` <1418825854-30022-1-git-send-email-ogerlitz-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2015-02-18 5:10 ` Or Gerlitz [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=54E41EAB.3000403@mellanox.com \
--to=ogerlitz-vpraknaxozvwk0htik3j/w@public.gmane.org \
--cc=amirv-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org \
--cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=roland-BHEL68pLQRGGvPXPguhicg@public.gmane.org \
--cc=roland-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.