官方API文档中只是说获取了一个 port,没有提及这个port是哪一层协议的port
rdma_get_src_port
retrieves the local port number for an rdma_cm_id (id) which has been
bound to a local address. If the id is not bound to a port, the routine will return 0.
rdma_get_dst_port
retrieves the port associated with the peer endpoint. If the rdma_cm_id, id,
is not connected, then the routine will return 0.
RoCE v2 是基于UDP的,那么猜测这里的port可能是UDP port即传输层的port,类似 ip:port 这种格式。但是通过抓包发现,这里的port是IB的port,不是udp的,如下图1红色部分是server port,图2是client port