[openib-general] CMA IPv6 support

Talpey, Thomas Thomas.Talpey at netapp.com
Mon May 15 10:40:52 PDT 2006


At 01:26 PM 5/15/2006, Talpey, Thomas wrote:
>At 01:05 PM 5/15/2006, Sean Hefty wrote:
>>I came to the same conclusion a couple of weeks ago.  Rdma_create_id() will
>>likely need an address family parameter, or the user must explicitly 
>>bind before calling listen.
>
>Rdma_create_id() already takes a struct sockaddr *, which has an address
>family selector (sa_family) to define the contained address format. Why is
>that one not sufficient?

Scratch that, I was looking at our usage one layer up in the NFS/RDMA code,
which does have the struct sockaddr *.

Looking at rdma_listen(), the code I see checks for bound state before
proceeding to listen:

int rdma_listen(struct rdma_cm_id *id, int backlog)
{
        struct rdma_id_private *id_priv;
        int ret;

        id_priv = container_of(id, struct rdma_id_private, id);
        if (!cma_comp_exch(id_priv, CMA_ADDR_BOUND, CMA_LISTEN))
                return -EINVAL;
	...

This makes sense, because sockets work this way, and servers generally
want to listen on a port of their own choosing.

So, I think it's already there. Right?

Tom.




More information about the general mailing list