Hello community, here is the log from the commit of package infinipath-psm for openSUSE:Factory checked in at 2016-05-02 10:43:14 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/infinipath-psm (Old) and /work/SRC/openSUSE:Factory/.infinipath-psm.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Package is "infinipath-psm" Changes: -------- --- /work/SRC/openSUSE:Factory/infinipath-psm/infinipath-psm.changes 2015-09-03 18:03:39.000000000 +0200 +++ /work/SRC/openSUSE:Factory/.infinipath-psm.new/infinipath-psm.changes 2016-05-02 10:43:16.000000000 +0200 @@ -1,0 +2,10 @@ +Mon Apr 25 07:41:38 UTC 2016 - p.drouand@gmail.com + +- Update to version 3.3-19 + * No Changelog available +- Build against system libuuid +- Split libraries into two separate subpackages +- Remove infinipath-non_executable_stack.patch; fixed on upstream + release + +------------------------------------------------------------------- Old: ---- infinipath-non_executable_stack.patch infinipath-psm-3.3-2_g6f42cdb_open.tar.gz New: ---- infinipath-psm-3.3-19_g67c0807_open.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ infinipath-psm.spec ++++++ --- /var/tmp/diff_new_pack.HrkSXJ/_old 2016-05-02 10:43:17.000000000 +0200 +++ /var/tmp/diff_new_pack.HrkSXJ/_new 2016-05-02 10:43:17.000000000 +0200 @@ -1,7 +1,7 @@ # # spec file for package infinipath-psm # -# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -16,7 +16,7 @@ # -%define my_release -2_g6f42cdb +%define my_release -19_g67c0807 Name: infinipath-psm Version: 3.3 @@ -32,14 +32,14 @@ Patch1: infinipath-psm-no_werror.patch # PATCH-FIX-UPSTREAM infinipath-psm-executable_headers.patch pth@suse.de Patch3: infinipath-psm-executable_headers.patch -# PATCH-FIX-UPSTREAM infinipath-non_executable_stack.patch pth@suse.de -Patch4: infinipath-non_executable_stack.patch -BuildRoot: %{_tmppath}/%{name}-%{version}-build +BuildRequires: libuuid-devel Conflicts: infinipath-libs ExclusiveArch: %ix86 x86_64 -%define so_major 1 -%define lname libpsm_infinipath%{so_major} +%define so_major 4 +%define psm_so_major 1 +%define lname libinfinipath%{so_major} +%define lnamepsm libpsm_infinipath%{psm_so_major} %description The PSM Messaging API, or PSM API, is QLogic's low-level @@ -52,17 +52,30 @@ Summary: Development files for QLogic PSM Group: Development/Libraries/C and C++ Requires: %{lname} = %{version} +Requires: %{lnamepsm} = %{version} +Requires: libuuid-devel Conflicts: infinipath-devel %description devel Development files for the libpsm_infinipath library -%package -n %{lname} +%package -n %{lnamepsm} Summary: Development files for QLogic PSM Group: System/Libraries Obsoletes: infinipath-psm < %{version} Provides: infinipath-psm = %{version} +%description -n %{lnamepsm} +The PSM Messaging API, or PSM API, is QLogic's low-level +user-level communications interface for the Truescale +family of products. PSM users are enabled with mechanisms +necessary to implement higher level communications +interfaces in parallel environments. + +%package -n %{lname} +Summary: Development files for QLogic PSM +Group: System/Libraries + %description -n %{lname} The PSM Messaging API, or PSM API, is QLogic's low-level user-level communications interface for the Truescale @@ -75,25 +88,28 @@ %patch0 %patch1 %patch3 -%patch4 %build -%if 0%{?suse_version} >= 1150 export RPM_OPT_FLAGS="%{optflags} -Wno-unused-but-set-variable" -%endif -make USE_PSM_UUID=1 libdir=%{_libdir} %{?_smp_mflags} +#make USE_PSM_UUID=1 libdir=%{_libdir} %{?_smp_mflags} +make libdir=%{_libdir} %{?_smp_mflags} %install -make USE_PSM_UUID=1 libdir=%{_libdir} DESTDIR=%{buildroot} install +make libdir=%{_libdir} DESTDIR=%{buildroot} install %post -n %{lname} -p /sbin/ldconfig +%post -n %{lnamepsm} -p /sbin/ldconfig %postun -n %{lname} -p /sbin/ldconfig +%postun -n %{lnamepsm} -p /sbin/ldconfig %files -n %{lname} %defattr(-,root,root,-) -%{_libdir}/libpsm_infinipath.so.* %{_libdir}/libinfinipath.so.* +%files -n %{lnamepsm} +%defattr(-,root,root,-) +%{_libdir}/libpsm_infinipath.so.* + %files devel %defattr(-,root,root,-) %{_libdir}/libpsm_infinipath.so ++++++ infinipath-psm-3.3-2_g6f42cdb_open.tar.gz -> infinipath-psm-3.3-19_g67c0807_open.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/COMMIT new/infinipath-psm-3.3-19_g67c0807_open/COMMIT --- old/infinipath-psm-3.3-2_g6f42cdb_open/COMMIT 2014-10-10 23:07:06.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/COMMIT 2016-03-16 18:16:48.000000000 +0100 @@ -1 +1 @@ -6f42cdb1bb8cc4f15149589ab5fa39775fa5470a \ No newline at end of file +67c0807c74e9d445900d5541358f0f575f22a630 \ No newline at end of file diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/Makefile.rej new/infinipath-psm-3.3-19_g67c0807_open/Makefile.rej --- old/infinipath-psm-3.3-2_g6f42cdb_open/Makefile.rej 2014-10-10 23:07:06.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/Makefile.rej 1970-01-01 01:00:00.000000000 +0100 @@ -1,25 +0,0 @@ ---- Makefile -+++ Makefile -@@ -44,3 +44,6 @@ - - clean: - rm -f *.o -+ -+install: -+ @echo "Nothing to do for install." ---- Makefile -+++ Makefile -@@ -54,3 +54,5 @@ - clean: - rm -f *.o - -+install: -+ @echo "Nothing to do for install." ---- Makefile -+++ Makefile -@@ -44,3 +44,5 @@ - clean: - rm -f *.o - -+install: -+ @echo "Nothing to do for install." diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/README new/infinipath-psm-3.3-19_g67c0807_open/README --- old/infinipath-psm-3.3-2_g6f42cdb_open/README 2014-10-10 23:07:04.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/README 2016-03-16 18:16:47.000000000 +0100 @@ -1,5 +1,5 @@ - Copyright (c) 2013 Intel Corporation. All rights reserved. + Copyright (c) 2013-2014, Intel Corporation. All rights reserved. Copyright (c) 2006-2011. QLogic Corporation. All rights reserved. Copyright (c) 2003-2006, PathScale, Inc. All rights reserved. @@ -42,24 +42,16 @@ Building PSM ------------ Build requires that GNU GCC compiler is installed on the machine doing the -build, if compiling code to mic card, the cross compiler x86_64-k1om-linux-gcc -must also installed. If compiling mic version or mic card version, scif must -installed on the system. Root privileges are required to install the runtime -libraries and development header files into standard system location. - -There are two mechanisms for building PSM: - 1. Use provided Makefiles to build and install - 2. Generate a tarball that can be used to build source and binary RPMs +build. If compiling code for MIC, SCIF must be present. Root privileges +are required to install the runtime libraries and development header files +into the standard system location. -The instructions below use $PRODUCT and $RELEASE to refer to the product -and release identifiers of the infinipath-psm RPM. - -Building from Makefiles +Building from Makefile ----------------------- 1. Untar the tarball: - $ tar zxvf intel-psm-$PRODUCT-$RELEASE.tar.gz + $ tar zxvf infinipath-psm-$PRODUCT-$RELEASE.tar.gz 2. Change directory into the untarred location: - $ cd intel-psm-$PRODUCT-$RELEASE + $ cd infinipath-psm-$PRODUCT-$RELEASE 3. Run make on the command line. This will build the libraries. By default, the Makefile will auto-detect whether libuuid and the uuid.h header file are installed. If so, it will use the system's libuuid. Otherwise, PSM @@ -70,9 +62,9 @@ build the SCIF enabled variant by default. Auto-detection of SCIF can be disabled by passing the PSM_HAVE_SCIF variable. - To compile the SCIF-enabled version, set the PSM_HAVE_SCIF variable: + To specify the SCIF-enabled version, set the PSM_HAVE_SCIF variable: $ make PSM_HAVE_SCIF=1 - To compile the non-SCIF version, even if SCIF is present, clear the variable: + To specify the non-SCIF version, even if SCIF is present, clear the variable: $ make PSM_HAVE_SCIF=0 To force compiling with the included libuuid, use the USE_PSM_UUID variable: @@ -96,43 +88,6 @@ "/tmp/psm-install/usr/include", and "make LIBDIR=/tmp/libs install" will install the libraries in "/tmp/libs" and the headers in "/usr/include". -Generating PSM source and binary RPMs --------------------------------------- -This is a two step process: Generate a PSM distribution tarball which can then -be used to generate source and binary RPMs using the rpmbuild command with the --ta option. -1. Untar the tarball: - $ tar zxvf intel-psm-$PRODUCT-$RELEASE.tar.gz -2. Change directory into the untarred location: - $ cd intel-psm-$PRODUCT-$RELEASE -3. Generate distribution tarball - $ make dist - To force compiling with the included libuuid, use the USE_PSM_UUID variable: - $ make dist USE_PSM_UUID=1 - Note: It is recommended if you are planning on doing cross distribution -builds to use the included libuuid i.e. If you are generating the distribution -tarball on a RHEL machine but may use rpmbuild on a SuSE SLES machine. This -minimized any cross distribution dependencies for the package. -4. Generate source and binary packages. - To generate a non-SCIF RPM: - $ rpmbuild -ta intel-psm-$PRODUCT-$RELEASE.tar.gz - This produces the infinipath-psm-$PRODUCT-$RELEASE set of RPMs. - To generate a SCIF-enabled RPM: - $ rpmbuild -ta intel-psm-$PRODUCT-$RELEASE.tar.gz -D 'PSM_HAVE_SCIF 1' - This produces the intel-psm-$PRODUCT-$RELEASE set of RPMs. - - Please refere to the man page of rpmbuild for other options in generating -RPMs. The generated RPMs are relocatable so one can provide the prefix option -to retarget the installation location. - -Please note, in any case, you can build debugging version of the code by -adding PSM_DEBUG=1 on make command line. - -If you run into any issues during build please post any questions with as much -information as possible to the psm-devel mailing list. Please include the -distribution you are building on, the compiler type and version as well as any -relevant error messages. - MPI Libraries supported ----------------------- A large number of open source (OpenMPI, MVAPICH, MVAPICH2) and Vendor MPI diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/dfaace420c1f3fdd646630122c5ae601aef6e4a0.patch new/infinipath-psm-3.3-19_g67c0807_open/dfaace420c1f3fdd646630122c5ae601aef6e4a0.patch --- old/infinipath-psm-3.3-2_g6f42cdb_open/dfaace420c1f3fdd646630122c5ae601aef6e4a0.patch 2014-10-10 23:07:06.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/dfaace420c1f3fdd646630122c5ae601aef6e4a0.patch 1970-01-01 01:00:00.000000000 +0100 @@ -1,51 +0,0 @@ -commit dfaace420c1f3fdd646630122c5ae601aef6e4a0 -Author: John Fleck <john.fleck@intel.com> -Date: Fri Apr 4 10:54:25 2014 -0400 - - Add make install action. - - INTERNAL: PR 124157 - hfi-psm has errors on make install - - Change-Id: I4ae51dd3a06d7150c3d422fe72886d89eb1d2ce0 - -diff --git a/libuuid/Makefile b/libuuid/Makefile -index fb62602..71fa643 100644 ---- a/libuuid/Makefile -+++ b/libuuid/Makefile -@@ -44,3 +44,6 @@ all: ${${TARGLIB}-objs} - - clean: - rm -f *.o -+ -+install: -+ @echo "Nothing to do for install." -diff --git a/ptl_am/Makefile b/ptl_am/Makefile -index 292feaf..95faf09 100644 ---- a/ptl_am/Makefile -+++ b/ptl_am/Makefile -@@ -44,3 +44,5 @@ all: ${${TARGLIB}-objs} - clean: - rm -f *.o - -+install: -+ @echo "Nothing to do for install." -diff --git a/ptl_ips/Makefile b/ptl_ips/Makefile -index fcd5313..1b845f4 100644 ---- a/ptl_ips/Makefile -+++ b/ptl_ips/Makefile -@@ -54,3 +54,5 @@ all: ${${TARGLIB}-objs} - clean: - rm -f *.o - -+install: -+ @echo "Nothing to do for install." -diff --git a/ptl_self/Makefile b/ptl_self/Makefile -index 9e6826d..7b16674 100644 ---- a/ptl_self/Makefile -+++ b/ptl_self/Makefile -@@ -44,3 +44,5 @@ all: ${${TARGLIB}-objs} - clean: - rm -f *.o - -+install: -+ @echo "Nothing to do for install." diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/include/ipath_common.h new/infinipath-psm-3.3-19_g67c0807_open/include/ipath_common.h --- old/infinipath-psm-3.3-2_g6f42cdb_open/include/ipath_common.h 2014-10-10 23:07:04.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/include/ipath_common.h 2016-03-16 18:16:47.000000000 +0100 @@ -673,6 +673,12 @@ /* K_PktFlags bits */ #define INFINIPATH_KPF_INTR 0x1 #define INFINIPATH_KPF_HDRSUPP 0x2 +#define INFINIPATH_KPF_INTR_HDRSUPP_MASK 0x3 +#define INFINIPATH_KPF_COMMIDX_MASK 0x003C +#define INFINIPATH_KPF_COMMIDX_SHIFT 2 +#define INFINIPATH_KPF_RESERVED_BITS(pktflags) \ + ((__le16_to_cpu(pktflags) & INFINIPATH_KPF_COMMIDX_MASK) \ + << IPS_EPSTATE_COMMIDX_SHIFT) \ #define INFINIPATH_MAX_SUBCONTEXT 4 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/infinipath-psm.spec new/infinipath-psm-3.3-19_g67c0807_open/infinipath-psm.spec --- old/infinipath-psm-3.3-2_g6f42cdb_open/infinipath-psm.spec 2014-10-10 23:07:06.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/infinipath-psm.spec 2016-03-16 18:16:48.000000000 +0100 @@ -33,7 +33,7 @@ Summary: Intel PSM Libraries Name: infinipath-psm Version: 3.3 -Release: 2_g6f42cdb_open +Release: 19_g67c0807_open Epoch: 4 License: GPL Group: System Environment/Libraries @@ -42,8 +42,11 @@ Prefix: /usr BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root Provides: infinipath-psm = %{version} +%if "%{PSM_HAVE_SCIF}" == "1" +Provides: intel-mic-psm = %{version} +%endif # MIC package -Conflicts: intel-mic-psm +Obsoletes: intel-mic-psm # OFED package Obsoletes: infinipath-libs <= %{version}-%{release} Conflicts: infinipath-libs <= %{version}-%{release} @@ -58,41 +61,11 @@ Group: System Environment/Development Requires: infinipath-psm = %{version}-%{release} Provides: infinipath-psm-devel = %{version} -# MIC package -Conflicts: intel-mic-devel -# OFED package -Obsoletes: infinipath-devel <= %{version}-%{release} -Conflicts: infinipath-devel <= %{version}-%{release} -# mpss package -Obsoletes: mpss-psm-dev <= %{version}-%{release} -Conflicts: mpss-psm-dev <= %{version}-%{release} -Requires(post): /sbin/ldconfig -Requires(postun): /sbin/ldconfig - -%package -n intel-mic-psm -Summary: Intel PSM Libraries -License: GPL -Group: System Environment/Libraries -Prefix: /usr -Provides: intel-mic-psm = %{version} -# non-MIC package -Conflicts: infinipath-psm -# OFED package -Obsoletes: infinipath-libs <= %{version}-%{release} -Conflicts: infinipath-libs <= %{version}-%{release} -# mpss package -Obsoletes: mpss-psm <= %{version}-%{release} -Conflicts: mpss-psm <= %{version}-%{release} -Requires(post): /sbin/ldconfig -Requires(postun): /sbin/ldconfig - -%package -n intel-mic-psm-devel -Summary: Development files for Intel PSM -Group: System Environment/Development -Requires: intel-mic-psm = %{version}-%{release} +%if "%{PSM_HAVE_SCIF}" == "1" Provides: intel-mic-psm-devel = %{version} -# non-MIC package -Conflicts: infinipath-psm-devel +%endif +# MIC package +Obsoletes: intel-mic-psm-devel # OFED package Obsoletes: infinipath-devel <= %{version}-%{release} Conflicts: infinipath-devel <= %{version}-%{release} @@ -141,16 +114,6 @@ %description -n infinipath-psm-devel Development files for the libpsm_infinipath library -%description -n intel-mic-psm -The PSM Messaging API, or PSM API, is Intel's low-level -user-level communications interface for the True Scale -family of products. PSM users are enabled with mechanisms -necessary to implement higher level communications -interfaces in parallel environments. - -%description -n intel-mic-psm-devel -Development files for the libpsm_infinipath library - %prep %setup -q -n %{name}-%{version}-%{release} @@ -171,39 +134,26 @@ %post devel -p /sbin/ldconfig %postun devel -p /sbin/ldconfig -%if "%{PSM_HAVE_SCIF}" == "1" -%files -n intel-mic-psm +%files %defattr(-,root,root,-) /usr/lib64/libpsm_infinipath.so.* /usr/lib64/libinfinipath.so.* +%if "%{PSM_HAVE_SCIF}" == "1" /usr/sbin/psmd - -%files -n intel-mic-psm-devel -%defattr(-,root,root,-) -/usr/lib64/libpsm_infinipath.so -/usr/lib64/libinfinipath.so -/usr/include/psm.h -/usr/include/psm_mq.h %endif - -%if "%{PSM_HAVE_SCIF}" == "0" -%files -%defattr(-,root,root,-) -/usr/lib64/libpsm_infinipath.so.* -/usr/lib64/libinfinipath.so.* - %files -n infinipath-psm-devel %defattr(-,root,root,-) /usr/lib64/libpsm_infinipath.so /usr/lib64/libinfinipath.so /usr/include/psm.h /usr/include/psm_mq.h -%endif %changelog +* Fri Sep 25 2015 Henry Estela <henry.r.estela@intel.com> - 3.3-1 +- Always build infinipath-psm with different Provides names. * Tue Nov 6 2012 Mitko Haralanov <mitko.haralanov@intel.com> - 3.3-1 - Add Intel Xeon Phi related changes * Tue May 11 2010 Mitko Haralanov <mitko@qlogic.com> - 3.3-1 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ipath/ipath_debug.c new/infinipath-psm-3.3-19_g67c0807_open/ipath/ipath_debug.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/ipath/ipath_debug.c 2014-10-10 23:07:04.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ipath/ipath_debug.c 2016-03-16 18:16:47.000000000 +0100 @@ -52,6 +52,7 @@ static void init_ipath_mylabel(void) __attribute__ ((constructor)); static void init_ipath_backtrace(void) __attribute__ ((constructor)); static void init_ipath_dbgfile(void) __attribute__ ((constructor)); +static void fini_ipath_backtrace(void) __attribute__ ((destructor)); static void init_ipath_mylabel(void) { @@ -140,6 +141,13 @@ exit(1); // not _exit(), want atexit handlers to get run } +static struct sigaction sigsegv_act; +static struct sigaction sigbus_act; +static struct sigaction sigill_act; +static struct sigaction sigabrt_act; +static struct sigaction sigint_act; +static struct sigaction sigterm_act; + // we do this as a constructor so any user program that sets signal // handlers for these will override our settings, but we still // get backtraces if they don't @@ -152,12 +160,24 @@ if(!getenv("IPATH_NO_BACKTRACE")) {// permanent, although probably // undocumented way to disable backtraces. - (void)sigaction(SIGSEGV, &act, NULL); - (void)sigaction(SIGBUS, &act, NULL); - (void)sigaction(SIGILL, &act, NULL); - (void)sigaction(SIGABRT, &act, NULL); - (void)sigaction(SIGINT, &act, NULL); - (void)sigaction(SIGTERM, &act, NULL); + (void)sigaction(SIGSEGV, &act, &sigsegv_act); + (void)sigaction(SIGBUS, &act, &sigbus_act); + (void)sigaction(SIGILL, &act, &sigill_act); + (void)sigaction(SIGABRT, &act, &sigabrt_act); + (void)sigaction(SIGINT, &act, &sigint_act); + (void)sigaction(SIGTERM, &act, &sigterm_act); + } +} + +static void fini_ipath_backtrace(void) +{ + if(!getenv("IPATH_NO_BACKTRACE")) { + (void)sigaction(SIGSEGV, &sigsegv_act, NULL); + (void)sigaction(SIGBUS, &sigbus_act, NULL); + (void)sigaction(SIGILL, &sigill_act, NULL); + (void)sigaction(SIGABRT, &sigabrt_act, NULL); + (void)sigaction(SIGINT, &sigint_act, NULL); + (void)sigaction(SIGTERM, &sigterm_act, NULL); } } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ipath/ipath_dwordcpy-i386.S new/infinipath-psm-3.3-19_g67c0807_open/ipath/ipath_dwordcpy-i386.S --- old/infinipath-psm-3.3-2_g6f42cdb_open/ipath/ipath_dwordcpy-i386.S 2014-10-10 23:07:04.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ipath/ipath_dwordcpy-i386.S 2016-03-16 18:16:47.000000000 +0100 @@ -56,3 +56,7 @@ mov %eax,%edi mov %edx,%esi ret + +#if defined(__linux__) && defined(__ELF__) +.section .note.GNU-stack,"",%progbits +#endif diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ipath/ipath_dwordcpy-x86_64-fast.S new/infinipath-psm-3.3-19_g67c0807_open/ipath/ipath_dwordcpy-x86_64-fast.S --- old/infinipath-psm-3.3-2_g6f42cdb_open/ipath/ipath_dwordcpy-x86_64-fast.S 2014-10-10 23:07:04.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ipath/ipath_dwordcpy-x86_64-fast.S 2016-03-16 18:16:47.000000000 +0100 @@ -49,3 +49,7 @@ rep movsd ret + +#if defined(__linux__) && defined(__ELF__) +.section .note.GNU-stack,"",%progbits +#endif diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ipath/ipath_proto.c new/infinipath-psm-3.3-19_g67c0807_open/ipath/ipath_proto.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/ipath/ipath_proto.c 2014-10-10 23:07:04.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ipath/ipath_proto.c 2016-03-16 18:16:47.000000000 +0100 @@ -460,7 +460,7 @@ _IPATH_DBG("chipstatus=0x%llx\n", (unsigned long long)*spctrl->__ipath_spi_status); - if(u->spu_subcontext_cnt) { + if(u->spu_subcontext_cnt > 0) { unsigned num_subcontexts = u->spu_subcontext_cnt; size_t size; int i; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ipath/ipath_service.c new/infinipath-psm-3.3-19_g67c0807_open/ipath/ipath_service.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/ipath/ipath_service.c 2014-10-10 23:07:04.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ipath/ipath_service.c 2016-03-16 18:16:47.000000000 +0100 @@ -718,7 +718,7 @@ unit, port, strerror(errno)); } else { - int gid[8]; + unsigned int gid[8]; if (sscanf(gid_str, "%4x:%4x:%4x:%4x:%4x:%4x:%4x:%4x", &gid[0], &gid[1], &gid[2], &gid[3], &gid[4], &gid[5], &gid[6], &gid[7]) != 8) { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/msg.txt new/infinipath-psm-3.3-19_g67c0807_open/msg.txt --- old/infinipath-psm-3.3-2_g6f42cdb_open/msg.txt 2014-10-10 23:07:06.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/msg.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1 +0,0 @@ -Add make install action. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/psm.c new/infinipath-psm-3.3-19_g67c0807_open/psm.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/psm.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/psm.c 2016-03-16 18:16:47.000000000 +0100 @@ -84,6 +84,7 @@ int iscompat = -1; switch (psmi_verno) { + case 0x0110: case 0x010f: /* Multi-rail is supported in this version, since the packet header * sequence number is shrunk from 24bits to 16bits, old version diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/psm.h new/infinipath-psm-3.3-19_g67c0807_open/psm.h --- old/infinipath-psm-3.3-2_g6f42cdb_open/psm.h 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/psm.h 2016-03-16 18:16:47.000000000 +0100 @@ -67,9 +67,9 @@ * psm_mq_init). */ typedef struct psm_mq *psm_mq_t; -#define PSM_VERNO 0x010f -#define PSM_VERNO_MAJOR 0x01 -#define PSM_VERNO_MINOR 0x0f +#define PSM_VERNO 0x0110 +#define PSM_VERNO_MAJOR 0x01 +#define PSM_VERNO_MINOR 0x10 enum psm_error { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/psm_context.c new/infinipath-psm-3.3-19_g67c0807_open/psm_context.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/psm_context.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/psm_context.c 2016-03-16 18:16:47.000000000 +0100 @@ -43,7 +43,6 @@ #endif #define PSMI_SHARED_CONTEXTS_ENABLED_BY_DEFAULT 1 -static int psmi_sharedcontext_params(int *nranks, int *rankid); static int psmi_get_hca_selection_algorithm(void); static psm_error_t psmi_init_userinfo_params(psm_ep_t ep, int unit_id, int port, @@ -381,7 +380,7 @@ else errmsg = "Hardware not found"; - psmi_handle_error(context->ep, err, errmsg); + psmi_handle_error(context->ep, err, errmsg, "%s"); } } } @@ -593,7 +592,6 @@ return err; } -static int psmi_sharedcontext_params(int *nranks, int *rankid) { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/psm_context.h new/infinipath-psm-3.3-19_g67c0807_open/psm_context.h --- old/infinipath-psm-3.3-2_g6f42cdb_open/psm_context.h 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/psm_context.h 2016-03-16 18:16:47.000000000 +0100 @@ -67,6 +67,7 @@ psm_error_t psmi_context_interrupt_set(psmi_context_t *context, int enable); int psmi_context_interrupt_isenabled(psmi_context_t *context); +int psmi_sharedcontext_params(int *nranks, int *rankid); /* Runtime flags describe what features are enabled in hw/sw and which * corresponding PSM features are being used. * diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/psm_diags.c new/infinipath-psm-3.3-19_g67c0807_open/psm_diags.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/psm_diags.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/psm_diags.c 2016-03-16 18:16:47.000000000 +0100 @@ -244,6 +244,7 @@ ((uintptr_t) dst ^ (uintptr_t) src ^ (uintptr_t) n); unsigned int state; size_t i; + psmi_assert_always(n > 0); memset(src, 0x55, n); memset(dst, 0xaa, n); srand(seed); @@ -288,8 +289,11 @@ else { void *src_p, *dst_p; if (posix_memalign(&src_p, 64, size) != 0 || - posix_memalign(&dst_p, 64, size) != 0) + posix_memalign(&dst_p, 64, size) != 0) { + if (src_p) psmi_free(src_p); + if (dst_p) psmi_free(dst_p); return -1; + } else { src = (uint8_t *) src_p; dst = (uint8_t *) dst_p; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/psm_ep.c new/infinipath-psm-3.3-19_g67c0807_open/psm_ep.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/psm_ep.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/psm_ep.c 2016-03-16 18:16:47.000000000 +0100 @@ -1394,7 +1394,7 @@ } } if (b_new != devstr) /* we parsed something, remove trailing comma */ - *(b_new - 1) = '\0'; + b_new[strlen(b_new) - 1] = '\0'; _IPATH_PRDBG("PSM Device allocation order: %s\n", devstr); fail: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/psm_ep_connect.c new/infinipath-psm-3.3-19_g67c0807_open/psm_ep_connect.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/psm_ep_connect.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/psm_ep_connect.c 2016-03-16 18:16:47.000000000 +0100 @@ -275,7 +275,7 @@ } } errbuf[sizeof errbuf - 1] = '\0'; - err = psmi_handle_error(ep, err, errbuf); + err = psmi_handle_error(ep, err, errbuf, "%s"); } fail: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/psm_stats.c new/infinipath-psm-3.3-19_g67c0807_open/psm_stats.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/psm_stats.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/psm_stats.c 2016-03-16 18:16:48.000000000 +0100 @@ -566,15 +566,15 @@ entries, nc+npc, ep); - return; bail: if (cnames != NULL) - infinipath_release_names(cnames); + psmi_free(cnames); if (pcnames != NULL) - infinipath_release_names(pcnames); + psmi_free(pcnames); if (entries != NULL) psmi_free(entries); + return; } static @@ -604,13 +604,13 @@ entries, ns, ep); - return; bail: if (snames != NULL) - infinipath_release_names(snames); + psmi_free(snames); if (entries != NULL) psmi_free(entries); + return; } #undef _SDECL diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/psm_utils.c new/infinipath-psm-3.3-19_g67c0807_open/psm_utils.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/psm_utils.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/psm_utils.c 2016-03-16 18:16:48.000000000 +0100 @@ -1202,7 +1202,7 @@ fail: /* Unrecognized/unknown option */ - return psmi_handle_error(NULL, PSM_PARAM_ERR, err_string); + return psmi_handle_error(NULL, PSM_PARAM_ERR, err_string, "%s"); } psm_error_t psmi_core_setopt(const void *core_obj, int optname, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_am/am_reqrep.c new/infinipath-psm-3.3-19_g67c0807_open/ptl_am/am_reqrep.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_am/am_reqrep.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ptl_am/am_reqrep.c 2016-03-16 18:16:48.000000000 +0100 @@ -44,7 +44,7 @@ psm_am_completion_fn_t completion_fn, void *completion_ctxt) { - psm_amarg_t req_args[NSHORT_ARGS]; + psm_amarg_t req_args[NSHORT_ARGS] = {}; /* All sends are synchronous. Ignore PSM_AM_FLAG_ASYNC. * TODO: Treat PSM_AM_FLAG_NOREPLY as "advisory". This was mainly @@ -76,7 +76,7 @@ psm_am_completion_fn_t completion_fn, void *completion_ctxt) { - psm_amarg_t rep_args[NSHORT_ARGS]; + psm_amarg_t rep_args[NSHORT_ARGS] = {}; /* For now less than NSHORT_ARGS-1. We use the first arg to carry the handler * index. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_am/am_reqrep_shmem.c new/infinipath-psm-3.3-19_g67c0807_open/ptl_am/am_reqrep_shmem.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_am/am_reqrep_shmem.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ptl_am/am_reqrep_shmem.c 2016-03-16 18:16:48.000000000 +0100 @@ -389,8 +389,20 @@ amsh_init_segment(), and physical memory is only allocated by the OS accordingly. So, it looks like this is consumes a lot of memory, but really it consumes as much as necessary for each active process. */ +#ifdef PSM_HAVE_SCIF segsz = psmi_amsh_segsize(PTL_AMSH_MAX_LOCAL_PROCS, PTL_AMSH_MAX_LOCAL_NODES); +#else + /* In the non-SCIF case we should be able to get away with just allocating + * enough shm for the number of mpi ranks, if the number of ranks is + * unavailable, then we will fallback to the number of online cpu cores. + * This will help cut back on virtual memory usage. + */ + int nranks, rankid, nprocs; + psmi_sharedcontext_params(&nranks, &rankid); + nprocs = (nranks <= 0) ? sysconf(_SC_NPROCESSORS_ONLN) : nranks; + segsz = psmi_amsh_segsize(nprocs, PTL_AMSH_MAX_LOCAL_NODES); +#endif ep->amsh_shmfd = shm_open(ep->amsh_keyname, O_RDWR | O_CREAT | O_EXCL | O_TRUNC, S_IRWXU); @@ -820,14 +832,23 @@ pthread_mutex_unlock((pthread_mutex_t *) &(ep->amsh_dirpage->lock)); /* Instead of dynamically shrinking the shared memory region, we always - leave it allocated for up to PTL_AMSH_MAX_LOCAL_PROCS processes. + leave it allocated for up to PTL_AMSH_MAX_LOCAL_PROCS or number + of processors online. Thus mremap() is never necessary, nor is ftruncate() here. However when the attached process count does go to 0, we should fully munmap() the entire region. */ +#ifdef PSM_HAVE_SCIF if (munmap((void *) ep->amsh_shmbase, psmi_amsh_segsize(PTL_AMSH_MAX_LOCAL_PROCS, PTL_AMSH_MAX_LOCAL_NODES))) { +#else + int nranks, rankid, nprocs; + psmi_sharedcontext_params(&nranks, &rankid); + nprocs = (nranks <= 0) ? sysconf(_SC_NPROCESSORS_ONLN) : nranks; + if (munmap((void *) ep->amsh_shmbase, + psmi_amsh_segsize(nprocs, PTL_AMSH_MAX_LOCAL_NODES))) { +#endif err = psmi_handle_error(NULL, PSM_SHMEM_SEGMENT_ERR, "Error with munamp of shared segment: %s", strerror(errno)); goto fail; @@ -2658,7 +2679,7 @@ amsh_mq_rndv(ptl_t *ptl, psm_mq_t mq, psm_mq_req_t req, psm_epaddr_t epaddr, uint64_t tag, const void *buf, uint32_t len) { - psm_amarg_t args[5]; + psm_amarg_t args[5] = {}; psm_error_t err = PSM_OK; args[0].u32w0 = MQ_MSG_RTS; @@ -2723,7 +2744,7 @@ amsh_mq_send_inner(psm_mq_t mq, psm_mq_req_t req, psm_epaddr_t epaddr, uint32_t flags, uint64_t tag, const void *ubuf, uint32_t len)) { - psm_amarg_t args[3]; + psm_amarg_t args[3] = {}; psm_error_t err = PSM_OK; int is_blocking = (req == NULL); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_am/ptl.c new/infinipath-psm-3.3-19_g67c0807_open/ptl_am/ptl.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_am/ptl.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ptl_am/ptl.c 2016-03-16 18:16:48.000000000 +0100 @@ -43,7 +43,7 @@ psm_error_t ptl_handle_rtsmatch_request(psm_mq_req_t req, int was_posted, amsh_am_token_t *tok) { - psm_amarg_t args[5]; + psm_amarg_t args[5] = {}; psm_epaddr_t epaddr = req->rts_peer; ptl_t *ptl = epaddr->ptl; int pid = 0; @@ -232,7 +232,7 @@ void *dest = (void *)(uintptr_t) args[2].u64w0; uint32_t msglen = args[3].u32w0; int pid = 0; - psm_amarg_t rarg[1]; + psm_amarg_t rarg[1] = {}; _IPATH_VDBG("[rndv][send] req=%p dest_req=%p src=%p dest=%p len=%d\n", sreq, (void*)(uintptr_t)args[1].u64w0, sreq->buf, dest, msglen); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_epstate.c new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_epstate.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_epstate.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_epstate.c 2016-03-16 18:16:48.000000000 +0100 @@ -49,7 +49,8 @@ { memset(eps, 0, sizeof(*eps)); eps->context = context; - eps->eps_base_idx = (ips_epstate_idx) get_cycles(); + eps->eps_base_idx = ((ips_epstate_idx)get_cycles()) & + (IPS_EPSTATE_COMMIDX_MAX-1); return PSM_OK; } @@ -102,8 +103,7 @@ } } psmi_assert_always(i != eps->eps_tabsize); - commidx = j; - commidx -= eps->eps_base_idx; + commidx = (j - eps->eps_base_idx) & (IPS_EPSTATE_COMMIDX_MAX-1); _IPATH_VDBG("node %s gets commidx=%d (table idx %d)\n", psmi_epaddr_get_name(ipsaddr->epaddr->epid), commidx, j); eps->eps_tab[j].epid = @@ -123,8 +123,9 @@ psm_error_t ips_epstate_del(struct ips_epstate *eps, ips_epstate_idx commidx) { - ips_epstate_idx idx = commidx; - idx += eps->eps_base_idx; /* actual table index */ + ips_epstate_idx idx; + /* actual table index */ + idx = (commidx + eps->eps_base_idx) & (IPS_EPSTATE_COMMIDX_MAX-1); psmi_assert_always(idx < eps->eps_tabsize); _IPATH_VDBG("commidx=%d, table_idx=%d\n", commidx, idx); eps->eps_tab[idx].epid = 0; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_epstate.h new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_epstate.h --- old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_epstate.h 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_epstate.h 2016-03-16 18:16:48.000000000 +0100 @@ -36,8 +36,13 @@ #include "psm_user.h" -typedef uint16_t ips_epstate_idx; -#define IPS_EPSTATE_COMMIDX_MAX 65535 +typedef uint32_t ips_epstate_idx; +#define IPS_EPSTATE_COMMIDX_MAX (1<<20) +#define IPS_EPSTATE_COMMIDX_MASK 0xF0000 +#define IPS_EPSTATE_COMMIDX_SHIFT 14 +#define IPS_EPSTATE_COMMIDX_PACK(ipscommidx) \ + ((ipscommidx & IPS_EPSTATE_COMMIDX_MASK) \ + >> IPS_EPSTATE_COMMIDX_SHIFT) struct ptl_epaddr; @@ -68,7 +73,7 @@ struct ips_epstate_entry * ips_epstate_lookup(const struct ips_epstate *eps, ips_epstate_idx idx)) { - idx += eps->eps_base_idx; + idx = (idx + eps->eps_base_idx) & (IPS_EPSTATE_COMMIDX_MAX-1); if (idx < eps->eps_tabsize) return &eps->eps_tab[idx]; else diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto.c new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto.c 2016-03-16 18:16:48.000000000 +0100 @@ -633,7 +633,8 @@ (union psmi_envvar_val) defval, &env_sdma); - proto->flags |= env_sdma.e_uint & IPS_PROTO_FLAGS_ALL_SDMA; + if(env_sdma.e_uint != 1) + proto->flags |= env_sdma.e_uint & IPS_PROTO_FLAGS_ALL_SDMA; /* If anything uses send dma, figure out our max packet threshold to call * send dma with */ @@ -761,7 +762,7 @@ uint32_t tot_paywords = sizeof(struct ips_message_header) >> 2; struct ips_epinfo *epinfo = &proto->epinfo; struct ips_epinfo_remote *epr = &ipsaddr->epr; - uint16_t pkt_flags = 0; + uint16_t pkt_flags = IPS_EPSTATE_COMMIDX_PACK(epr->epr_commidx_to); struct ips_message_header *p_hdr = &msg->pbc_hdr.hdr; ips_path_rec_t *ctrl_path = ipsaddr->epr.epr_path[IPS_PATH_HIGH_PRIORITY][ipsaddr->epr.epr_hpp_index]; int paylen = 0; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto.h new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto.h --- old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto.h 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto.h 2016-03-16 18:16:48.000000000 +0100 @@ -423,7 +423,7 @@ (((uint16_t)flowindex)&0x7) ) #define IPS_FLOWID_GET_PROTO(flow) (((flow)>>3)&0x7) -#define IPS_FLOWID_GET_INDEX(flow) ((flow)&0x7) +#define IPS_FLOWID_GET_INDEX(flow) ((flow) % 4) #define IPS_FLOWID2INDEX(flow) \ ((flow)&0x7) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto_am.c new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto_am.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto_am.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto_am.c 2016-03-16 18:16:48.000000000 +0100 @@ -298,7 +298,7 @@ else { /* Arguments and payload may split across header/eager_payload * boundaries. */ - psm_amarg_t args[8]; + psm_amarg_t args[8] = {}; int i; uint64_t *payload = (uint64_t *) ips_recvhdrq_event_payload(rcv_ev); uint32_t paylen = ips_recvhdrq_event_paylen(rcv_ev); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto_dump.c new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto_dump.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto_dump.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto_dump.c 2016-03-16 18:16:48.000000000 +0100 @@ -36,6 +36,7 @@ #include "ips_proto_internal.h" #include "ips_proto_header.h" #include "ips_proto_help.h" +#include "ips_epstate.h" void ips_proto_dump_frame(void *frame, int lenght, char *message) { @@ -99,7 +100,8 @@ printf("BTH: R8-DestQP24 %x\n", __be32_to_cpu(p_hdr->bth[1])); printf("BTH: AR1-Res7-PSN24 %x\n", __be32_to_cpu(p_hdr->bth[2])); printf("IPH: chksum %x\n", __le16_to_cpu(p_hdr->iph.chksum)); - printf("IPH: pkt_flags %x\n", __le16_to_cpu(p_hdr->iph.pkt_flags)); + printf("IPH: pkt_flags %x\n", __le16_to_cpu( + p_hdr->iph.pkt_flags) & INFINIPATH_KPF_INTR_HDRSUPP_MASK); printf("IPH: ver %i\n", (__le32_to_cpu(p_hdr->iph.ver_context_tid_offset) >> INFINIPATH_I_VERS_SHIFT) & INFINIPATH_I_VERS_MASK); @@ -126,7 +128,8 @@ printf("context %d (src_context %d src_context_ext %d) src_subcontext %d\n", IPS_HEADER_SRCCONTEXT_GET(p_hdr), p_hdr->src_context, p_hdr->src_context_ext, p_hdr->src_subcontext); - printf("src_rank/commidx %i\n", p_hdr->commidx); + printf("src_rank/commidx %i\n", p_hdr->commidx | + INFINIPATH_KPF_RESERVED_BITS(p_hdr->iph.pkt_flags)); if (tid != IPATH_EAGER_TID_ID) printf("expected_tid_session_id %i\n", p_hdr->data[0].u32w0); printf("flags %x\n", p_hdr->flags); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto_expected.c new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto_expected.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto_expected.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto_expected.c 2016-03-16 18:16:48.000000000 +0100 @@ -1035,7 +1035,7 @@ psm_error_t err; struct ips_protoexp *protoexp = tidsendc->protoexp; psm_mq_req_t req = tidsendc->mqreq; - ptl_arg_t desc_id[3]; + ptl_arg_t desc_id[3] = {}; uint64_t t_cyc; desc_id[0] = tidsendc->tid_list.tsess_descid; @@ -1117,7 +1117,7 @@ struct ips_protoexp *protoexp = tidsendc->protoexp; uint64_t t_cyc; psm_error_t err; - ptl_arg_t desc_id[3]; + ptl_arg_t desc_id[3] = {}; /* 0 contain's the receiver's desc_id, 1 contains the sender's desc_id */ desc_id[0] = tidsendc->tid_list.tsess_descid; @@ -2354,11 +2354,11 @@ struct ips_protoexp *protoexp = rcv_ev->proto->protoexp; struct ips_message_header *p_hdr = rcv_ev->p_hdr; struct ips_tid_recv_desc *tidrecvc; - ptl_arg_t desc_id = rcv_ev->p_hdr->data[0]; - ptl_arg_t send_descid = rcv_ev->p_hdr->data[1]; + ptl_arg_t desc_id = rcv_ev->p_hdr->hdr_data[0]; + ptl_arg_t send_descid = rcv_ev->p_hdr->hdr_data[1]; ptl_arg_t desc_tidrecvc; psmi_seqnum_t sequence_num; - ptl_arg_t args[3]; + ptl_arg_t args[3] = {}; psm_error_t err; psmi_assert_always(protoexp != NULL); @@ -2453,6 +2453,7 @@ struct ips_message_header *p_hdr = rcv_ev->p_hdr; int tid = IPS_HDR_TID(p_hdr); struct ips_tid_recv_desc *tidrecvc; + psmi_assert(rcv_ev->p_hdr->data != NULL); ptl_arg_t desc_id = rcv_ev->p_hdr->data[0]; ptl_arg_t desc_tidrecvc; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto_help.h new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto_help.h --- old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto_help.h 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto_help.h 2016-03-16 18:16:48.000000000 +0100 @@ -40,6 +40,7 @@ #include "ipserror.h" #include "psm_mq_internal.h" // psmi_mq_handle_tiny_envelope #include "ptl_ips.h" +#include "ips_epstate.h" /* Some tunable compile-time options */ #define IPS_TINY_PROCESS_MQTINY 1 /* whether mq processing of tiny pkts is @@ -78,7 +79,7 @@ PSMI_ALWAYS_INLINE( ptl_epaddr_flow_t ips_proto_flowid(struct ips_message_header *p_hdr)) { - ptl_epaddr_flow_t flowidx = IPS_FLOWID_GET_INDEX(p_hdr->flowid); + ptl_epaddr_flow_t flowidx = IPS_FLOWID2INDEX(p_hdr->flowid); psmi_assert(flowidx < EP_FLOW_LAST); return flowidx; } @@ -383,7 +384,7 @@ { uint32_t extra_bytes; uint32_t tot_paywords; - uint16_t pkt_flags = 0; + uint16_t pkt_flags = IPS_EPSTATE_COMMIDX_PACK(epr->epr_commidx_to); extra_bytes = scb->payload_size & 3; if (extra_bytes) { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto_mq.c new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto_mq.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto_mq.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto_mq.c 2016-03-16 18:16:48.000000000 +0100 @@ -167,6 +167,8 @@ if (do_flush) err = ips_recv_progress_if_busy(ipsaddr->ptl, err); + PSMI_BLOCKUNTIL(proto->ep,err, (scb->flags&IPS_SEND_FLAG_PENDING) == 0); + /* As per the PSM error model (or lack thereof), PSM clients expect to see * only PSM_OK as a recoverable error */ if (err == PSM_EP_NO_RESOURCES || err == PSM_OK_NO_PROGRESS) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto_recv.c new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto_recv.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_proto_recv.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_proto_recv.c 2016-03-16 18:16:48.000000000 +0100 @@ -789,7 +789,7 @@ ptl_arg_t desc_id = p_hdr->data[0]; ptl_arg_t send_desc_id = p_hdr->data[1]; ptl_arg_t desc_tidrecvc; - ptl_arg_t args[3]; + ptl_arg_t args[3] = {}; int16_t seq_off; uint8_t ack_type; @@ -1263,7 +1263,8 @@ /* Obtain ipsaddr for packet */ epstaddr = ips_epstate_lookup(rcv_ev->recvq->epstate, - rcv_ev->p_hdr->commidx); + rcv_ev->p_hdr->commidx + + INFINIPATH_KPF_RESERVED_BITS(p_hdr->iph.pkt_flags)); if_pf (epstaddr == NULL || epstaddr->epid != rcv_ev->epid) return 0; /* Unknown packet - drop */ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_recvhdrq.c new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_recvhdrq.c --- old/infinipath-psm-3.3-2_g6f42cdb_open/ptl_ips/ips_recvhdrq.c 2014-10-10 23:07:05.000000000 +0200 +++ new/infinipath-psm-3.3-19_g67c0807_open/ptl_ips/ips_recvhdrq.c 2016-03-16 18:16:48.000000000 +0100 @@ -367,7 +367,8 @@ uint32_t hd, tl; epstaddr = - ips_epstate_lookup(rcv_ev->recvq->epstate, rcv_ev->p_hdr->commidx); + ips_epstate_lookup(rcv_ev->recvq->epstate, rcv_ev->p_hdr->commidx + + INFINIPATH_KPF_RESERVED_BITS(rcv_ev->p_hdr->iph.pkt_flags)); epstaddr = (epstaddr && epstaddr->ipsaddr) ? epstaddr : NULL; lcontext = @@ -580,7 +581,9 @@ /* Classify packet from a known or unknown endpoint */ struct ips_epstate_entry *epstaddr; - epstaddr = ips_epstate_lookup(recvq->epstate, rcv_ev.p_hdr->commidx); + epstaddr = + ips_epstate_lookup(recvq->epstate, rcv_ev.p_hdr->commidx + + INFINIPATH_KPF_RESERVED_BITS(rcv_ev.p_hdr->iph.pkt_flags)); if_pf (epstaddr == NULL || epstaddr->epid != rcv_ev.epid) { rcv_ev.ipsaddr = NULL; recvq->recvq_callbacks.callback_packet_unknown(&rcv_ev);