1
1

usnic: enusre that we only get "usnic"-named providers

Also, a minor update to a verbose message.
Этот коммит содержится в:
Jeff Squyres 2015-01-12 13:21:22 -08:00
родитель d2938a144f
Коммит 5ed688a074

Просмотреть файл

@ -12,7 +12,7 @@
* All rights reserved. * All rights reserved.
* Copyright (c) 2006 Sandia National Laboratories. All rights * Copyright (c) 2006 Sandia National Laboratories. All rights
* reserved. * reserved.
* Copyright (c) 2008-2014 Cisco Systems, Inc. All rights reserved. * Copyright (c) 2008-2015 Cisco Systems, Inc. All rights reserved.
* Copyright (c) 2012-2014 Los Alamos National Security, LLC. All rights * Copyright (c) 2012-2014 Los Alamos National Security, LLC. All rights
* reserved. * reserved.
* Copyright (c) 2014 Intel, Inc. All rights reserved. * Copyright (c) 2014 Intel, Inc. All rights reserved.
@ -610,7 +610,8 @@ static mca_btl_base_module_t** usnic_component_init(int* num_btl_modules,
int min_distance, num_local_procs; int min_distance, num_local_procs;
struct fi_info *info_list; struct fi_info *info_list;
struct fi_info *info; struct fi_info *info;
struct fi_info hints; struct fi_info hints = {0};
struct fi_fabric_attr fabric_attr = {0};
struct fid_fabric *fabric; struct fid_fabric *fabric;
struct fid_domain *domain; struct fid_domain *domain;
int ret; int ret;
@ -624,11 +625,15 @@ static mca_btl_base_module_t** usnic_component_init(int* num_btl_modules,
return NULL; return NULL;
} }
memset(&hints, 0, sizeof(hints)); /* We only want providers named "usnic */
fabric_attr.prov_name = "usnic";
hints.ep_type = FI_EP_DGRAM; hints.ep_type = FI_EP_DGRAM;
hints.caps = FI_MSG; hints.caps = FI_MSG;
hints.mode = FI_LOCAL_MR | FI_MSG_PREFIX; hints.mode = FI_LOCAL_MR | FI_MSG_PREFIX;
hints.addr_format = FI_SOCKADDR; hints.addr_format = FI_SOCKADDR;
hints.fabric_attr = &fabric_attr;
ret = fi_getinfo(FI_VERSION(1, 0), NULL, 0, 0, &hints, &info_list); ret = fi_getinfo(FI_VERSION(1, 0), NULL, 0, 0, &hints, &info_list);
if (0 != ret) { if (0 != ret) {
opal_output_verbose(5, USNIC_OUT, opal_output_verbose(5, USNIC_OUT,
@ -661,7 +666,7 @@ static mca_btl_base_module_t** usnic_component_init(int* num_btl_modules,
************************************************************************/ ************************************************************************/
opal_output_verbose(5, USNIC_OUT, opal_output_verbose(5, USNIC_OUT,
"btl:usnic: usNIC support found"); "btl:usnic: usNIC fabrics found");
/* Setup the connectivity checking agent and client. */ /* Setup the connectivity checking agent and client. */
if (mca_btl_usnic_component.connectivity_enabled) { if (mca_btl_usnic_component.connectivity_enabled) {