From 76adb9f8293ce0057db9d9cfcb2f813d19a938de Mon Sep 17 00:00:00 2001 From: Mikhail Brinskii Date: Tue, 3 Dec 2019 14:58:50 +0200 Subject: [PATCH] UCT/TAG: Minor styling fixes --- src/uct/ib/rc/accel/rc_mlx5.inl | 2 +- src/uct/ib/rc/accel/rc_mlx5_common.c | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/uct/ib/rc/accel/rc_mlx5.inl b/src/uct/ib/rc/accel/rc_mlx5.inl index 2808a136276..1334ec195d8 100644 --- a/src/uct/ib/rc/accel/rc_mlx5.inl +++ b/src/uct/ib/rc/accel/rc_mlx5.inl @@ -1022,7 +1022,7 @@ uct_rc_mlx5_iface_common_tag_recv(uct_rc_mlx5_iface_common_t *iface, UCT_RC_MLX5_CHECK_TAG(iface); kh_put(uct_rc_mlx5_tag_addrs, &iface->tm.tag_addrs, iov->buffer, &ret); - if (ucs_unlikely(!ret)) { + if (ucs_unlikely(ret == 0)) { /* Do not post the same buffer more than once (even with different tags) * to avoid memory corruption. */ return UCS_ERR_ALREADY_EXISTS; diff --git a/src/uct/ib/rc/accel/rc_mlx5_common.c b/src/uct/ib/rc/accel/rc_mlx5_common.c index a396328e12f..2a68736b371 100644 --- a/src/uct/ib/rc/accel/rc_mlx5_common.c +++ b/src/uct/ib/rc/accel/rc_mlx5_common.c @@ -414,7 +414,7 @@ void uct_rc_mlx5_iface_common_tag_cleanup(uct_rc_mlx5_iface_common_t *iface) { uct_rc_mlx5_mp_hash_key_t key_gid; uint64_t key_lid; - void *tag_addr; + void *recv_buffer; if (!UCT_RC_MLX5_TM_ENABLED(iface)) { return; @@ -426,9 +426,9 @@ void uct_rc_mlx5_iface_common_tag_cleanup(uct_rc_mlx5_iface_common_t *iface) ucs_free(iface->tm.cmd_wq.ops); uct_rc_mlx5_tag_cleanup(iface); - kh_foreach_key(&iface->tm.tag_addrs, tag_addr, { - ucs_debug("destroying iface %p, with %p offloaded to the HW", - iface, tag_addr); + kh_foreach_key(&iface->tm.tag_addrs, recv_buffer, { + ucs_debug("destroying iface %p, with recv buffer %p offloaded to the HW", + iface, recv_buffer); }); kh_destroy_inplace(uct_rc_mlx5_tag_addrs, &iface->tm.tag_addrs);