From: Or Gerlitz <ogerlitz-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
To: "Hefty,
Sean" <sean.hefty-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>,
"linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
<linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>
Cc: Moni Shoua <monis-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>,
Oren Duer <oren-VPRAkNaXOzVS1MOuV/RT9w@public.gmane.org>
Subject: REQ GID enforcement in the CM
Date: Thu, 27 Oct 2011 16:14:07 +0200 [thread overview]
Message-ID: <4EA9672F.2010601@mellanox.com> (raw)
Hi Sean,
Looking on that case, I noted that the CM code (SB) checks that the GID
in the incoming
REQ is present in at least of one the ports of the relevant device, but
not specifically on
the port this request arrived to, is that following IBTA? I thought it
could be problematic
e.g in the case of RC QP being set by this establishment, later the RC
packets would be dropped
by the device if they have GRH and the GID isn't on that port table,
isn't that?
Or.
> ret = cm_init_av_by_path(&work->path[0], &cm_id_priv->av);
> if (ret) {
> ib_get_cached_gid(work->port->cm_dev->ib_device,
> work->port->port_num, 0,
> &work->path[0].sgid);
> ib_send_cm_rej(cm_id, IB_CM_REJ_INVALID_GID,
> &work->path[0].sgid, sizeof work->path[0].sgid,
> NULL, 0);
> goto rejected;
> }
> read_lock_irqsave(&cm.device_lock, flags);
> list_for_each_entry(cm_dev, &cm.device_list, list) {
> if (!ib_find_cached_gid(cm_dev->ib_device, &path->sgid,
> &p, NULL)) {
> port = cm_dev->port[p-1];
> break;
> }
> }
> read_unlock_irqrestore(&cm.device_lock, flags);
>
> if (!port)
> return -EINVAL;
--
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
next reply other threads:[~2011-10-27 14:14 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-27 14:14 Or Gerlitz [this message]
[not found] ` <4EA9672F.2010601-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2011-10-27 16:55 ` REQ GID enforcement in the CM Jason Gunthorpe
[not found] ` <20111027165522.GA16878-ePGOBjL8dl3ta4EC/59zMFaTQe2KTcn/@public.gmane.org>
2011-10-30 10:14 ` Or Gerlitz
[not found] ` <4EAD239A.2050702-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2011-10-31 18:19 ` Jason Gunthorpe
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=4EA9672F.2010601@mellanox.com \
--to=ogerlitz-vpraknaxozvwk0htik3j/w@public.gmane.org \
--cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=monis-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org \
--cc=oren-VPRAkNaXOzVS1MOuV/RT9w@public.gmane.org \
--cc=sean.hefty-ral2JQCrhuEAvxtiuMwx3w@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox