[openib-general] question related to rdma_bind_addr

Or Gerlitz ogerlitz at voltaire.com
Wed Mar 22 05:36:57 PST 2006


Hi Sean,

int rdma_bind_addr(struct rdma_cm_id *id, struct sockaddr *addr)
...
        if (cma_any_addr(addr)) {
                ret = 0;
        } else if (cma_loopback_addr(addr)) {
                ret = cma_bind_loopback(id_priv);
        } else {
                dev_addr = &id->route.addr.dev_addr;
                ret = rdma_translate_ip(addr, dev_addr);
...


If my understanding is correct, the current code of rdma_bind_addr
assumes you supply it one of three (all are **src** address)

+1 ANY (0.0.0.0) addr 
+2 local loopback addr
+3 other local addr

Am i correct? so at the active side the flow must go

+1 rdma_create_id
+2 rdma_resolve_addr(cma_id, src_addr (possibly NULL), dst_addr)
+3 addr_resolved event(cma_id) - now the cma_id is bounded to an IB device 
   st the IB resources needed for this connection (eg PD/CQ/QP) can be created

So it is not possible to syncrously create and bind the cma id to
ib device based on the destination address (which is the typical info
the active side has).

At this point i see an actual need, it just related to some change we 
discuss in the open scsi model for iser integration, and i wanted to make 
sure that currently creating the IB resources in synchronous manner is 
impossible.

Or.
 







More information about the general mailing list