From: Or Gerlitz <ogerlitz-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
To: "Hefty,
Sean" <sean.hefty-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>,
Christoph Lameter <cl-vYTEC60ixJUAvxtiuMwx3w@public.gmane.org>
Cc: "linux-rdma
(linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org)"
<linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>
Subject: Re: failure to get gid with rdma_bind_addr with >= 3.10 kernels
Date: Tue, 12 Nov 2013 09:08:16 +0200 [thread overview]
Message-ID: <5281D3E0.70203@mellanox.com> (raw)
In-Reply-To: <1828884A29C6694DAF28B7E6B8A8237388CF6FD0-P5GAC/sN6hkd3b2yrw5b5LfspsVTdybXVpNB7YpNyf8@public.gmane.org>
On 11/11/2013 20:46, Hefty, Sean wrote:
> Yes - something like this patch should help, but I don't think this is the correct behavior when the IP address is 'any' addresss.
>
> Retrieve SGID after calling rdma_bind_addr
>
> From: Sean Hefty<sean.hefty-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
>
> A change was made to rdma_bind_addr when AF_IB is enabled
> to only retrieve the resulting bound address. Previously,
> rdma_bind_addr would retrieve the corresponding SGID as
> well. This breaks some apps which were checking the
> SGID after binding to an IP address. Revert to the
> previous behavior of also retrieving the SGID after
> calling rdma_bind_addr.
> ---
> src/cma.c | 5 ++++-
> 1 files changed, 4 insertions(+), 1 deletions(-)
>
> diff --git a/src/cma.c b/src/cma.c
> index 4f41879..0cf4203 100644
> --- a/src/cma.c
> +++ b/src/cma.c
> @@ -753,7 +753,10 @@ static int rdma_bind_addr2(struct rdma_cm_id *id, struct sockaddr *addr,
> if (ret != sizeof cmd)
> return (ret >= 0) ? ERR(ENODATA) : -1;
>
> - return ucma_query_addr(id);
> + ret = ucma_query_addr(id);
> + if (!ret)
> + ret = ucma_query_gid(id);
> + return ret;
> }
>
> int rdma_bind_addr(struct rdma_cm_id *id, struct sockaddr *addr)
Sean, how do we continue here? the patch worked for Christoph, so are
going to merge it into librdmacm or it needs more work?
--
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 prev parent reply other threads:[~2013-11-12 7:08 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <527F6896.1080802@mellanox.com>
[not found] ` <527F6896.1080802-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2013-11-10 11:10 ` failure to get gid with rdma_bind_addr with >= 3.10 kernels Or Gerlitz
[not found] ` <527F69B1.9070701-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2013-11-10 11:14 ` Or Gerlitz
[not found] ` <527F6A8F.1030506-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2013-11-11 16:45 ` Hefty, Sean
[not found] ` <1828884A29C6694DAF28B7E6B8A8237388CF6F30-P5GAC/sN6hkd3b2yrw5b5LfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2013-11-11 17:09 ` Christoph Lameter
2013-11-11 17:40 ` Hefty, Sean
[not found] ` <1828884A29C6694DAF28B7E6B8A8237388CF6F78-P5GAC/sN6hkd3b2yrw5b5LfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2013-11-11 18:14 ` Christoph Lameter
[not found] ` <00000142485f86e5-c3027528-9892-4d5c-8d72-0ed5f98666c4-000000-p/GC64/jrecnJqMo6gzdpkEOCMrvLtNR@public.gmane.org>
2013-11-11 18:46 ` Hefty, Sean
[not found] ` <1828884A29C6694DAF28B7E6B8A8237388CF6FD0-P5GAC/sN6hkd3b2yrw5b5LfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2013-11-11 19:41 ` Christoph Lameter
2013-11-12 7:08 ` Or Gerlitz [this message]
[not found] ` <5281D3E0.70203-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2013-11-13 20:15 ` Hefty, Sean
[not found] ` <1828884A29C6694DAF28B7E6B8A8237388D02FEC-P5GAC/sN6hkd3b2yrw5b5LfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2013-11-13 22:38 ` Or Gerlitz
2014-01-02 9:39 ` Or Gerlitz
[not found] ` <52C533C0.3070103-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2014-01-02 15:17 ` Yann Droneaud
[not found] ` <1388675827.22995.7.camel-bi+AKbBUZKY6gyzm1THtWbp2dZbC/Bob@public.gmane.org>
2014-01-02 16:33 ` Hefty, Sean
[not found] ` <1828884A29C6694DAF28B7E6B8A8237388D0FBFA-P5GAC/sN6hkd3b2yrw5b5LfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2014-01-02 16:59 ` Yann Droneaud
2014-01-02 17:04 ` Hefty, Sean
[not found] ` <1828884A29C6694DAF28B7E6B8A8237388D0FCD0-P5GAC/sN6hkd3b2yrw5b5LfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2014-01-05 7:25 ` Or Gerlitz
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=5281D3E0.70203@mellanox.com \
--to=ogerlitz-vpraknaxozvwk0htik3j/w@public.gmane.org \
--cc=cl-vYTEC60ixJUAvxtiuMwx3w@public.gmane.org \
--cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@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