Skip to content

[Question]: Why is the udp source port fixed to 45192? #56

@liuhe-spec

Description

@liuhe-spec

Question

#define IBGDA_ROCE_V2_UDP_SPORT_BASE 0xC000

assert(roce_version == 1 || roce_version == 2);
ah_attr.dlid = port_attr->lid | (roce_version == 1 ? IBGDA_ROCE_V1_UDP_SPORT_BASE
                                                   : IBGDA_ROCE_V2_UDP_SPORT_BASE);
ah = ftable.create_ah(device->pd, &ah_attr);
NVSHMEMI_NULL_ERROR_JMP(ah, status, NVSHMEMX_ERROR_INTERNAL, out, "Unable to create ah.\n");
dv.ah.in = ah;
dv.ah.out = &dah;
mlx5dv_init_obj(&dv, MLX5DV_OBJ_AH);
memcpy(DEVX_ADDR_OF(qpc, qpc, primary_address_path.rmac_47_32), &dah.av->rmac,
       sizeof(dah.av->rmac));
DEVX_SET(qpc, qpc, primary_address_path.hop_limit, IBGDA_GRH_HOP_LIMIT);
DEVX_SET(qpc, qpc, primary_address_path.src_addr_index,
         device->gid_info[portid - 1].local_gid_index);
DEVX_SET(qpc, qpc, primary_address_path.eth_prio, ibgda_state->options->IB_SL);
DEVX_SET(qpc, qpc, primary_address_path.udp_sport, ah_attr.dlid);

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions