As Jeff said in his commit message for r29059: >> Turns out that AC_CHECK_DECLS is one of the "new style" Autoconf >> macros that #defines the output to be 0 or 1 (vs. #define'ing or >> #undef'ing it). So don't check for "#if defined(..."; just check for >> "#if ...".
On Aug 23, 2013, at 8:10 AM, "Steve Wise" <sw...@opengridcomputing.com> wrote: > Why is the 1.7 changeset different from the trunk changeset? Specifically, > > #if defined(HAVE_IBV_LINK_LAYER_ETHERENET) > > Is changed to > > #if HAVE_DECL_IBV_LINK_LAYER_ETHERNET > > Instead of > > #if defined(HAVE_DECL_IBV_LINK_LAYER_ETHERNET) > > > >> -----Original Message----- >> From: svn [mailto:svn-boun...@open-mpi.org] On Behalf Of >> svn-commit-mai...@open-mpi.org >> Sent: Thursday, August 22, 2013 1:25 PM >> To: s...@open-mpi.org >> Subject: [OMPI svn] svn:open-mpi r29060 - in branches/v1.7: . ompi/mca/btl >> ompi/mca/btl/openib >> ompi/mca/btl/openib/connect ompi/mca/common/verbs >> >> Author: rhc (Ralph Castain) >> Date: 2013-08-22 14:24:55 EDT (Thu, 22 Aug 2013) >> New Revision: 29060 >> URL: https://svn.open-mpi.org/trac/ompi/changeset/29060 >> >> Log: >> Fixes #3730: Move r29053 to v1.7 branch (Use the >> HAVE_DECL_IBV_LINK_LAYER_ETHERNET macro.) >> >> ---svn-pre-commit-ignore-below--- >> >> r29053 [[BR]] >> Use the HAVE_DECL_IBV_LINK_LAYER_ETHERNET macro. >> >> Commit r27211 added ifdef checks for #define >> HAVE_IBV_LINK_LAYER_ETHERNET, which is incorrect. The correct #define >> is HAVE_DECL_IBV_LINK_LAYER_ETHERNET. This broke OMPI over iWARP. >> >> This fixes #3726 and should be added to cmr:v1.7.3:reviewer=jsquyres >> >> >> r29059 [[BR]] >> Refs #3730 >> >> Turns out that AC_CHECK_DECLS is one of the "new style" Autoconf >> macros that #defines the output to be 0 or 1 (vs. #define'ing or >> #undef'ing it). So don't check for "#if defined(..."; just check for >> "#if ...". >> >> Properties modified: >> branches/v1.7/ (props changed) >> branches/v1.7/ompi/mca/btl/ (props changed) >> Text files modified: >> branches/v1.7/ompi/mca/btl/openib/btl_openib.c | >> 2 +- >> branches/v1.7/ompi/mca/btl/openib/btl_openib_component.c | >> 2 +- >> branches/v1.7/ompi/mca/btl/openib/connect/btl_openib_connect_oob.c | >> 2 +- >> branches/v1.7/ompi/mca/btl/openib/connect/btl_openib_connect_udcm.c | >> 2 +- >> branches/v1.7/ompi/mca/common/verbs/common_verbs_find_ports.c | >> 4 ++-- >> 5 files changed, 6 insertions(+), 6 deletions(-) >> >> Modified: branches/v1.7/ompi/mca/btl/openib/btl_openib.c >> ============================================================================== >> --- branches/v1.7/ompi/mca/btl/openib/btl_openib.c Thu Aug 22 13:44:20 >> 2013 (r29059) >> +++ branches/v1.7/ompi/mca/btl/openib/btl_openib.c 2013-08-22 14:24:55 EDT >> (Thu, 22 Aug 2013) >> (r29060) >> @@ -447,7 +447,7 @@ >> #ifdef HAVE_STRUCT_IBV_DEVICE_TRANSPORT_TYPE >> switch(openib_btl->device->ib_dev->transport_type) { >> case IBV_TRANSPORT_IB: >> -#if defined(HAVE_IBV_LINK_LAYER_ETHERNET) >> +#if HAVE_DECL_IBV_LINK_LAYER_ETHERNET >> switch(openib_btl->ib_port_attr.link_layer) { >> case IBV_LINK_LAYER_ETHERNET: >> return MCA_BTL_OPENIB_TRANSPORT_RDMAOE; >> >> Modified: branches/v1.7/ompi/mca/btl/openib/btl_openib_component.c >> ============================================================================== >> --- branches/v1.7/ompi/mca/btl/openib/btl_openib_component.c Thu Aug 22 >> 13:44:20 2013 >> (r29059) >> +++ branches/v1.7/ompi/mca/btl/openib/btl_openib_component.c 2013-08-22 >> 14:24:55 EDT (Thu, >> 22 Aug 2013) (r29060) >> @@ -719,7 +719,7 @@ >> return OMPI_ERR_NOT_FOUND; >> } >> >> -#if defined(HAVE_IBV_LINK_LAYER_ETHERNET) >> +#if HAVE_DECL_IBV_LINK_LAYER_ETHERNET >> if (IBV_LINK_LAYER_ETHERNET == ib_port_attr->link_layer) { >> subnet_id = mca_btl_openib_get_ip_subnet_id(device->ib_dev, >> port_num); >> >> Modified: branches/v1.7/ompi/mca/btl/openib/connect/btl_openib_connect_oob.c >> ============================================================================== >> --- branches/v1.7/ompi/mca/btl/openib/connect/btl_openib_connect_oob.c >> Thu Aug 22 13:44:20 >> 2013 (r29059) >> +++ branches/v1.7/ompi/mca/btl/openib/connect/btl_openib_connect_oob.c >> 2013-08-22 14:24:55 >> EDT (Thu, 22 Aug 2013) (r29060) >> @@ -127,7 +127,7 @@ >> IB (this CPC will not work with iWarp). If we do not have the >> transport_type member, then we must be < OFED v1.2, and >> therefore we must be IB. */ >> -#if defined(HAVE_STRUCT_IBV_DEVICE_TRANSPORT_TYPE) && >> defined(HAVE_IBV_LINK_LAYER_ETHERNET) >> +#if defined(HAVE_STRUCT_IBV_DEVICE_TRANSPORT_TYPE) && >> HAVE_DECL_IBV_LINK_LAYER_ETHERNET >> if (BTL_OPENIB_CONNECT_BASE_CHECK_IF_NOT_IB(btl)) { >> opal_output_verbose(5, ompi_btl_base_framework.framework_output, >> "openib BTL: oob CPC only supported on >> InfiniBand; skipped on > %s:%d", >> >> Modified: branches/v1.7/ompi/mca/btl/openib/connect/btl_openib_connect_udcm.c >> ============================================================================== >> --- branches/v1.7/ompi/mca/btl/openib/connect/btl_openib_connect_udcm.c >> Thu Aug 22 13:44:20 >> 2013 (r29059) >> +++ branches/v1.7/ompi/mca/btl/openib/connect/btl_openib_connect_udcm.c >> 2013-08-22 14:24:55 >> EDT (Thu, 22 Aug 2013) (r29060) >> @@ -405,7 +405,7 @@ >> /* If we do not have struct ibv_device.transport_device, then >> we're in an old version of OFED that is IB only (i.e., no >> iWarp), so we can safely assume that we can use this CPC. */ >> -#if defined(HAVE_STRUCT_IBV_DEVICE_TRANSPORT_TYPE) && >> defined(HAVE_IBV_LINK_LAYER_ETHERNET) >> +#if defined(HAVE_STRUCT_IBV_DEVICE_TRANSPORT_TYPE) && >> HAVE_DECL_IBV_LINK_LAYER_ETHERNET >> if (BTL_OPENIB_CONNECT_BASE_CHECK_IF_NOT_IB(btl)) { >> BTL_VERBOSE(("UD CPC only supported on InfiniBand; skipped on >> %s:%d", >> ibv_get_device_name(btl->device->ib_dev), >> >> Modified: branches/v1.7/ompi/mca/common/verbs/common_verbs_find_ports.c >> ============================================================================== >> --- branches/v1.7/ompi/mca/common/verbs/common_verbs_find_ports.c Thu Aug >> 22 13:44:20 >> 2013 (r29059) >> +++ branches/v1.7/ompi/mca/common/verbs/common_verbs_find_ports.c >> 2013-08-22 14:24:55 >> EDT (Thu, 22 Aug 2013) (r29060) >> @@ -170,7 +170,7 @@ >> } >> } >> >> -#if defined(HAVE_IBV_LINK_LAYER_ETHERNET) >> +#if HAVE_DECL_IBV_LINK_LAYER_ETHERNET >> static const char *link_layer_to_str(int link_type) >> { >> switch(link_type) { >> @@ -416,7 +416,7 @@ >> /* If they specified neither link layer, then we want this >> port */ >> want = true; >> } >> -#if defined(HAVE_IBV_LINK_LAYER_ETHERNET) >> +#if HAVE_DECL_IBV_LINK_LAYER_ETHERNET >> else if (flags & OMPI_COMMON_VERBS_FLAGS_LINK_LAYER_IB) { >> if (IBV_LINK_LAYER_INFINIBAND == port_attr.link_layer) { >> want = true; >> _______________________________________________ >> svn mailing list >> s...@open-mpi.org >> http://www.open-mpi.org/mailman/listinfo.cgi/svn > > _______________________________________________ > devel mailing list > de...@open-mpi.org > http://www.open-mpi.org/mailman/listinfo.cgi/devel