Skip to content
This repository was archived by the owner on Sep 30, 2022. It is now read-only.

Commit 37000f2

Browse files
committed
usnic: minor updates from code review
Three minor updates from the code review of #933: * Remove an extra blank line a show_help message * We no longer allow -1 for the MCA param btl_usnic_av_eq_num, so change the flag to REGINT_GE_ONE * Change "num_blocks" definition to be in terms of block_len (not eq_size) (cherry picked from commit open-mpi/ompi@9f3ed00)
1 parent fcad142 commit 37000f2

File tree

3 files changed

+2
-3
lines changed

3 files changed

+2
-3
lines changed

opal/mca/btl/usnic/btl_usnic_mca.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ int opal_btl_usnic_component_register(void)
237237
mca_btl_usnic_component.cq_num = (int32_t) cq_num;
238238

239239
CHECK(reg_int("av_eq_num", "Number of event queue entries for peer address resolution",
240-
1024, &av_eq_num, REGINT_NEG_ONE_OK, OPAL_INFO_LVL_5));
240+
1024, &av_eq_num, REGINT_GE_ONE, OPAL_INFO_LVL_5));
241241
mca_btl_usnic_component.av_eq_num = (int32_t) av_eq_num;
242242

243243
CHECK(reg_int("base_udp_port", "Base UDP port to use for usNIC communications. If 0, system will pick the port number. If non-zero, it will be added to each process' local rank to obtain the final port number (default: 0)",

opal/mca/btl/usnic/btl_usnic_module.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -411,7 +411,7 @@ static int add_procs_create_endpoints(struct opal_btl_usnic_module_t* module,
411411
size_t eq_size = module->av_eq_size - 8;
412412
size_t block_len = eq_size;
413413
size_t num_av_inserts = nprocs * USNIC_NUM_CHANNELS;
414-
size_t num_blocks = num_av_inserts / eq_size;
414+
size_t num_blocks = num_av_inserts / block_len;
415415
if (eq_size % num_av_inserts != 0) {
416416
++num_blocks;
417417
}

opal/mca/btl/usnic/help-mpi-btl-usnic.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,6 @@ abort.
241241
Current ARP timeout: %d (btl_usnic_arp_timeout MCA param)
242242
#
243243
[fi_av_eq too small]
244-
245244
The usnic BTL was told to create an address resolution queue that was
246245
too small via the mca_btl_usnic_av_eq_num MCA parameter. This
247246
parameter controls how many outstanding peer address resolutions can

0 commit comments

Comments
 (0)