Convert lmc to actual mask for use in slid comparisons. All SA
queries are initiated from the base lid, so set the src_path_bits
to 0. It is currently set incorrectly based on using the lmc as
a mask against the base lid.
Signed-off-by: Sean Hefty <sean.hefty@intel.com>
int gid_cnt;
uint16_t pkey_cnt;
uint16_t lid;
- uint8_t lmc;
+ uint16_t lid_mask;
uint8_t port_num;
};
break;
}
port->lid = attr.lid;
- port->lmc = attr.lmc;
+ port->lid_mask = 0xffff - (1 << attr.lmc) - 1;
acm_init_dest(&port->sa_dest, ACM_ADDRESS_LID,
(uint8_t *) &attr.sm_lid, sizeof(attr.sm_lid));
- port->sa_dest.av.src_path_bits = attr.lid & attr.lmc;
+ port->sa_dest.av.src_path_bits = 0;
port->sa_dest.av.dlid = attr.sm_lid;
port->sa_dest.av.sl = attr.sm_sl;
port->sa_dest.av.port_num = port->port_num;