From: Jason Gunthorpe <jgg@xxxxxxxxxxxx> These constants are all the same in both endians so this is no functional change. Found by sparse. Signed-off-by: Jason Gunthorpe <jgg@xxxxxxxxxxxx> --- src/ibsendtrap.c | 2 +- src/smpdump.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/ibsendtrap.c b/src/ibsendtrap.c index 8a3a3e6fd0449d..98d2b8b6c880dc 100644 --- a/src/ibsendtrap.c +++ b/src/ibsendtrap.c @@ -127,7 +127,7 @@ static void build_trap256_local(ib_mad_notice_attr_t * n, ib_portid_t * port) n->g_or_v.generic.trap_num = htobe16(256); n->issuer_lid = htobe16((uint16_t) port->lid); n->data_details.ntc_256.lid = n->issuer_lid; - n->data_details.ntc_256.dr_slid = 0xffff; + n->data_details.ntc_256.dr_slid = htobe16(0xffff); n->data_details.ntc_256.method = 1; n->data_details.ntc_256.attr_id = htobe16(0x15); n->data_details.ntc_256.attr_mod = htobe32(0x12); diff --git a/src/smpdump.c b/src/smpdump.c index cdd783600b602b..039eca03418016 100644 --- a/src/smpdump.c +++ b/src/smpdump.c @@ -93,8 +93,8 @@ static void drsmp_get_init(void *umad, DRPath * path, int attr, int mod) smp->attr_id = htons(attr); smp->attr_mod = htonl(mod); smp->tid = htobe64(drmad_tid++); - smp->dr_slid = 0xffff; - smp->dr_dlid = 0xffff; + smp->dr_slid = htobe16(0xffff); + smp->dr_dlid = htobe16(0xffff); umad_set_addr(umad, 0xffff, 0, 0, 0); -- 2.21.0