[openib-general] Re: port_num

Sean Hefty mshefty at ichips.intel.com
Wed Mar 15 15:00:37 PST 2006


Michael S. Tsirkin wrote:
>>>Sean, how come rdma_cm_id port_num field is only 8 bit?
>>>I think it must be at least 16 - I need to get at the port number
>>>after binding it with a wildcard 0 port.
>>
>>This is the port number of the rdma device, not the TCP port number.  The TCP
>>port number is part of the rdma_route::rdma_addr::src_addr.
> 
> 
> Wanted to make sure: will CMA let me bind to port 0, and select a port for me?

The CMA will let you bind to port 0, but it doesn't select a port for you.  This 
was something that James brought up earlier, but there's not a decent fix for 
this that can handle iWarp as well.

The issue is the current CMA port spaces may be distinct from real TCP/UPD/etc. 
port spaces.  So, port 0 can work fine from the CMA's perspective.

Are you wanting a port value for listening or connecting?

- Sean



More information about the general mailing list