opensm: Always set enabled speed and width
PATCH 1/1 opensm: Always set enabled speed and width
Initialize default link speed and width to "No State Change" and always set in SubnSet(PortInfo)
--- infiniband-diags/src/ibportstate.c | 17 ++++++++--------- 1 files changed, 8 insertions(+), 9 deletions(-)
infiniband-diags/src/ibportstate.c +8 -9
@@ -64,13 +64,13 @@ enum port_ops { };struct ibmad_port *srcport; -int speed =15 ; -int width =255 ; +int speed =0 ;/* no state change */ +int width =0 ;/* no state change */ int lid;int smlid;int lmc;int mtu; -int vls; +int vls =0 ;/* no state change */ struct {const char *name;
@@ -394,12 +394,11 @@ int main(int argc, char **argv)mad_set_field (data,0 ,IB_PORT_STATE_F ,4 );break ; } -if (port_args[SPEED ].set) -mad_set_field (data,0 ,IB_PORT_LINK_SPEED_ENABLED_F , - speed); -if (port_args[WIDTH ].set) -mad_set_field (data,0 ,IB_PORT_LINK_WIDTH_ENABLED_F , - width); + +/* always set enabled speed/width - defaults to NOP */ +mad_set_field (data,0 ,IB_PORT_LINK_SPEED_ENABLED_F , speed); +mad_set_field (data,0 ,IB_PORT_LINK_WIDTH_ENABLED_F , width); +if (port_args[VLS ].set)mad_set_field (data,0 ,IB_PORT_OPER_VLS_F , vls);if (port_args[MTU ].set)
Signature · 6 lines
1.5.5 -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): [email protected]
Sasha Khapyorsky
AppliedQuoted 4 lines · Eli Dorfman (Voltaire)
Initialize default link speed and width to "No State Change" and always set in SubnSet(PortInfo)
Applied. Thanks.
Sasha
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html