Hello community,
here is the log from the commit of package infiniband-diags
checked in at Fri Aug 24 01:12:35 CEST 2007.
--------
--- infiniband-diags/infiniband-diags.changes 2007-07-19 17:08:30.000000000 +0200
+++ /mounts/work_src_done/STABLE/infiniband-diags/infiniband-diags.changes 2007-08-20 17:00:08.000000000 +0200
@@ -1,0 +2,5 @@
+Mon Aug 20 16:59:56 CEST 2007 - hvogel@suse.de
+
+- Updated to version from OFED 1.2.5
+
+-------------------------------------------------------------------
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ infiniband-diags.spec ++++++
--- /var/tmp/diff_new_pack.H23413/_old 2007-08-24 01:11:56.000000000 +0200
+++ /var/tmp/diff_new_pack.H23413/_new 2007-08-24 01:11:56.000000000 +0200
@@ -13,7 +13,7 @@
Name: infiniband-diags
Summary: OpenIB InfiniBand Diagnostic Tools
Version: 1.2.7
-Release: 6
+Release: 14
License: BSD 3-Clause, GPL v2 or later
Group: Productivity/Networking/Diagnostic
Source0: %{name}-%{version}.tar.bz2
@@ -32,7 +32,6 @@
%prep
%setup -q
%patch0
-./autogen.sh
%build
%configure --with-perl-installdir=%{perl_vendorarch}
@@ -53,6 +52,8 @@
%{perl_vendorarch}/IBswcountlimits.pm
%changelog
+* Mon Aug 20 2007 - hvogel@suse.de
+- Updated to version from OFED 1.2.5
* Thu Jul 19 2007 - hvogel@suse.de
- fix path in the shellscripts
* Wed Jul 04 2007 - hvogel@suse.de
++++++ infiniband-diags-1.2.7.tar.bz2 ++++++
++++ 42441 lines of diff (skipped)
++++ retrying with extended exclude list
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/infiniband-diags-1.2.7/autogen.sh new/infiniband-diags-1.2.7/autogen.sh
--- old/infiniband-diags-1.2.7/autogen.sh 2007-07-02 15:36:44.000000000 +0200
+++ new/infiniband-diags-1.2.7/autogen.sh 1970-01-01 01:00:00.000000000 +0100
@@ -1,11 +0,0 @@
-#! /bin/sh
-
-# create config dir if not exist
-test -d config || mkdir config
-
-set -x
-aclocal -I config
-libtoolize --force --copy
-autoheader
-automake --foreign --add-missing --copy
-autoconf
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/infiniband-diags-1.2.7/BUILD_ID new/infiniband-diags-1.2.7/BUILD_ID
--- old/infiniband-diags-1.2.7/BUILD_ID 1970-01-01 01:00:00.000000000 +0100
+++ new/infiniband-diags-1.2.7/BUILD_ID 2007-08-14 17:41:14.000000000 +0200
@@ -0,0 +1 @@
+1.2.7
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/infiniband-diags-1.2.7/config/compile new/infiniband-diags-1.2.7/config/compile
--- old/infiniband-diags-1.2.7/config/compile 1970-01-01 01:00:00.000000000 +0100
+++ new/infiniband-diags-1.2.7/config/compile 2007-08-14 17:39:46.000000000 +0200
@@ -0,0 +1,142 @@
+#! /bin/sh
+# Wrapper for compilers which do not understand `-c -o'.
+
+scriptversion=2005-05-14.22
+
+# Copyright (C) 1999, 2000, 2003, 2004, 2005 Free Software Foundation, Inc.
+# Written by Tom Tromey .
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
+# As a special exception to the GNU General Public License, if you
+# distribute this file as part of a program that contains a
+# configuration script generated by Autoconf, you may include it under
+# the same distribution terms that you use for the rest of that program.
+
+# This file is maintained in Automake, please report
+# bugs to or send patches to
+# .
+
+case $1 in
+ '')
+ echo "$0: No command. Try \`$0 --help' for more information." 1>&2
+ exit 1;
+ ;;
+ -h | --h*)
+ cat <<\EOF
+Usage: compile [--help] [--version] PROGRAM [ARGS]
+
+Wrapper for compilers which do not understand `-c -o'.
+Remove `-o dest.o' from ARGS, run PROGRAM with the remaining
+arguments, and rename the output as expected.
+
+If you are trying to build a whole package this is not the
+right script to run: please start by reading the file `INSTALL'.
+
+Report bugs to .
+EOF
+ exit $?
+ ;;
+ -v | --v*)
+ echo "compile $scriptversion"
+ exit $?
+ ;;
+esac
+
+ofile=
+cfile=
+eat=
+
+for arg
+do
+ if test -n "$eat"; then
+ eat=
+ else
+ case $1 in
+ -o)
+ # configure might choose to run compile as `compile cc -o foo foo.c'.
+ # So we strip `-o arg' only if arg is an object.
+ eat=1
+ case $2 in
+ *.o | *.obj)
+ ofile=$2
+ ;;
+ *)
+ set x "$@" -o "$2"
+ shift
+ ;;
+ esac
+ ;;
+ *.c)
+ cfile=$1
+ set x "$@" "$1"
+ shift
+ ;;
+ *)
+ set x "$@" "$1"
+ shift
+ ;;
+ esac
+ fi
+ shift
+done
+
+if test -z "$ofile" || test -z "$cfile"; then
+ # If no `-o' option was seen then we might have been invoked from a
+ # pattern rule where we don't need one. That is ok -- this is a
+ # normal compilation that the losing compiler can handle. If no
+ # `.c' file was seen then we are probably linking. That is also
+ # ok.
+ exec "$@"
+fi
+
+# Name of file we expect compiler to create.
+cofile=`echo "$cfile" | sed -e 's|^.*/||' -e 's/\.c$/.o/'`
+
+# Create the lock directory.
+# Note: use `[/.-]' here to ensure that we don't use the same name
+# that we are using for the .o file. Also, base the name on the expected
+# object file name, since that is what matters with a parallel build.
+lockdir=`echo "$cofile" | sed -e 's|[/.-]|_|g'`.d
+while true; do
+ if mkdir "$lockdir" >/dev/null 2>&1; then
+ break
+ fi
+ sleep 1
+done
+# FIXME: race condition here if user kills between mkdir and trap.
+trap "rmdir '$lockdir'; exit 1" 1 2 15
+
+# Run the compile.
+"$@"
+ret=$?
+
+if test -f "$cofile"; then
+ mv "$cofile" "$ofile"
+elif test -f "${cofile}bj"; then
+ mv "${cofile}bj" "$ofile"
+fi
+
+rmdir "$lockdir"
+exit $ret
+
+# Local Variables:
+# mode: shell-script
+# sh-indentation: 2
+# eval: (add-hook 'write-file-hooks 'time-stamp)
+# time-stamp-start: "scriptversion="
+# time-stamp-format: "%:y-%02m-%02d.%02H"
+# time-stamp-end: "$"
+# End:
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/infiniband-diags-1.2.7/config/missing new/infiniband-diags-1.2.7/config/missing
--- old/infiniband-diags-1.2.7/config/missing 1970-01-01 01:00:00.000000000 +0100
+++ new/infiniband-diags-1.2.7/config/missing 2007-08-14 17:39:46.000000000 +0200
@@ -0,0 +1,360 @@
+#! /bin/sh
+# Common stub for a few missing GNU programs while installing.
+
+scriptversion=2005-06-08.21
+
+# Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005
+# Free Software Foundation, Inc.
+# Originally by Fran,cois Pinard , 1996.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+# 02110-1301, USA.
+
+# As a special exception to the GNU General Public License, if you
+# distribute this file as part of a program that contains a
+# configuration script generated by Autoconf, you may include it under
+# the same distribution terms that you use for the rest of that program.
+
+if test $# -eq 0; then
+ echo 1>&2 "Try \`$0 --help' for more information"
+ exit 1
+fi
+
+run=:
+
+# In the cases where this matters, `missing' is being run in the
+# srcdir already.
+if test -f configure.ac; then
+ configure_ac=configure.ac
+else
+ configure_ac=configure.in
+fi
+
+msg="missing on your system"
+
+case "$1" in
+--run)
+ # Try to run requested program, and just exit if it succeeds.
+ run=
+ shift
+ "$@" && exit 0
+ # Exit code 63 means version mismatch. This often happens
+ # when the user try to use an ancient version of a tool on
+ # a file that requires a minimum version. In this case we
+ # we should proceed has if the program had been absent, or
+ # if --run hadn't been passed.
+ if test $? = 63; then
+ run=:
+ msg="probably too old"
+ fi
+ ;;
+
+ -h|--h|--he|--hel|--help)
+ echo "\
+$0 [OPTION]... PROGRAM [ARGUMENT]...
+
+Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an
+error status if there is no known handling for PROGRAM.
+
+Options:
+ -h, --help display this help and exit
+ -v, --version output version information and exit
+ --run try to run the given command, and emulate it if it fails
+
+Supported PROGRAM values:
+ aclocal touch file \`aclocal.m4'
+ autoconf touch file \`configure'
+ autoheader touch file \`config.h.in'
+ automake touch all \`Makefile.in' files
+ bison create \`y.tab.[ch]', if possible, from existing .[ch]
+ flex create \`lex.yy.c', if possible, from existing .c
+ help2man touch the output file
+ lex create \`lex.yy.c', if possible, from existing .c
+ makeinfo touch the output file
+ tar try tar, gnutar, gtar, then tar without non-portable flags
+ yacc create \`y.tab.[ch]', if possible, from existing .[ch]
+
+Send bug reports to ."
+ exit $?
+ ;;
+
+ -v|--v|--ve|--ver|--vers|--versi|--versio|--version)
+ echo "missing $scriptversion (GNU Automake)"
+ exit $?
+ ;;
+
+ -*)
+ echo 1>&2 "$0: Unknown \`$1' option"
+ echo 1>&2 "Try \`$0 --help' for more information"
+ exit 1
+ ;;
+
+esac
+
+# Now exit if we have it, but it failed. Also exit now if we
+# don't have it and --version was passed (most likely to detect
+# the program).
+case "$1" in
+ lex|yacc)
+ # Not GNU programs, they don't have --version.
+ ;;
+
+ tar)
+ if test -n "$run"; then
+ echo 1>&2 "ERROR: \`tar' requires --run"
+ exit 1
+ elif test "x$2" = "x--version" || test "x$2" = "x--help"; then
+ exit 1
+ fi
+ ;;
+
+ *)
+ if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
+ # We have it, but it failed.
+ exit 1
+ elif test "x$2" = "x--version" || test "x$2" = "x--help"; then
+ # Could not run --version or --help. This is probably someone
+ # running `$TOOL --version' or `$TOOL --help' to check whether
+ # $TOOL exists and not knowing $TOOL uses missing.
+ exit 1
+ fi
+ ;;
+esac
+
+# If it does not exist, or fails to run (possibly an outdated version),
+# try to emulate it.
+case "$1" in
+ aclocal*)
+ echo 1>&2 "\
+WARNING: \`$1' is $msg. You should only need it if
+ you modified \`acinclude.m4' or \`${configure_ac}'. You might want
+ to install the \`Automake' and \`Perl' packages. Grab them from
+ any GNU archive site."
+ touch aclocal.m4
+ ;;
+
+ autoconf)
+ echo 1>&2 "\
+WARNING: \`$1' is $msg. You should only need it if
+ you modified \`${configure_ac}'. You might want to install the
+ \`Autoconf' and \`GNU m4' packages. Grab them from any GNU
+ archive site."
+ touch configure
+ ;;
+
+ autoheader)
+ echo 1>&2 "\
+WARNING: \`$1' is $msg. You should only need it if
+ you modified \`acconfig.h' or \`${configure_ac}'. You might want
+ to install the \`Autoconf' and \`GNU m4' packages. Grab them
+ from any GNU archive site."
+ files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}`
+ test -z "$files" && files="config.h"
+ touch_files=
+ for f in $files; do
+ case "$f" in
+ *:*) touch_files="$touch_files "`echo "$f" |
+ sed -e 's/^[^:]*://' -e 's/:.*//'`;;
+ *) touch_files="$touch_files $f.in";;
+ esac
+ done
+ touch $touch_files
+ ;;
+
+ automake*)
+ echo 1>&2 "\
+WARNING: \`$1' is $msg. You should only need it if
+ you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'.
+ You might want to install the \`Automake' and \`Perl' packages.
+ Grab them from any GNU archive site."
+ find . -type f -name Makefile.am -print |
+ sed 's/\.am$/.in/' |
+ while read f; do touch "$f"; done
+ ;;
+
+ autom4te)
+ echo 1>&2 "\
+WARNING: \`$1' is needed, but is $msg.
+ You might have modified some files without having the
+ proper tools for further handling them.
+ You can get \`$1' as part of \`Autoconf' from any GNU
+ archive site."
+
+ file=`echo "$*" | sed -n 's/.*--output[ =]*\([^ ]*\).*/\1/p'`
+ test -z "$file" && file=`echo "$*" | sed -n 's/.*-o[ ]*\([^ ]*\).*/\1/p'`
+ if test -f "$file"; then
+ touch $file
+ else
+ test -z "$file" || exec >$file
+ echo "#! /bin/sh"
+ echo "# Created by GNU Automake missing as a replacement of"
+ echo "# $ $@"
+ echo "exit 0"
+ chmod +x $file
+ exit 1
+ fi
+ ;;
+
+ bison|yacc)
+ echo 1>&2 "\
+WARNING: \`$1' $msg. You should only need it if
+ you modified a \`.y' file. You may need the \`Bison' package
+ in order for those modifications to take effect. You can get
+ \`Bison' from any GNU archive site."
+ rm -f y.tab.c y.tab.h
+ if [ $# -ne 1 ]; then
+ eval LASTARG="\${$#}"
+ case "$LASTARG" in
+ *.y)
+ SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'`
+ if [ -f "$SRCFILE" ]; then
+ cp "$SRCFILE" y.tab.c
+ fi
+ SRCFILE=`echo "$LASTARG" | sed 's/y$/h/'`
+ if [ -f "$SRCFILE" ]; then
+ cp "$SRCFILE" y.tab.h
+ fi
+ ;;
+ esac
+ fi
+ if [ ! -f y.tab.h ]; then
+ echo >y.tab.h
+ fi
+ if [ ! -f y.tab.c ]; then
+ echo 'main() { return 0; }' >y.tab.c
+ fi
+ ;;
+
+ lex|flex)
+ echo 1>&2 "\
+WARNING: \`$1' is $msg. You should only need it if
+ you modified a \`.l' file. You may need the \`Flex' package
+ in order for those modifications to take effect. You can get
+ \`Flex' from any GNU archive site."
+ rm -f lex.yy.c
+ if [ $# -ne 1 ]; then
+ eval LASTARG="\${$#}"
+ case "$LASTARG" in
+ *.l)
+ SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'`
+ if [ -f "$SRCFILE" ]; then
+ cp "$SRCFILE" lex.yy.c
+ fi
+ ;;
+ esac
+ fi
+ if [ ! -f lex.yy.c ]; then
+ echo 'main() { return 0; }' >lex.yy.c
+ fi
+ ;;
+
+ help2man)
+ echo 1>&2 "\
+WARNING: \`$1' is $msg. You should only need it if
+ you modified a dependency of a manual page. You may need the
+ \`Help2man' package in order for those modifications to take
+ effect. You can get \`Help2man' from any GNU archive site."
+
+ file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'`
+ if test -z "$file"; then
+ file=`echo "$*" | sed -n 's/.*--output=\([^ ]*\).*/\1/p'`
+ fi
+ if [ -f "$file" ]; then
+ touch $file
+ else
+ test -z "$file" || exec >$file
+ echo ".ab help2man is required to generate this page"
+ exit 1
+ fi
+ ;;
+
+ makeinfo)
+ echo 1>&2 "\
+WARNING: \`$1' is $msg. You should only need it if
+ you modified a \`.texi' or \`.texinfo' file, or any other file
+ indirectly affecting the aspect of the manual. The spurious
+ call might also be the consequence of using a buggy \`make' (AIX,
+ DU, IRIX). You might want to install the \`Texinfo' package or
+ the \`GNU make' package. Grab either from any GNU archive site."
+ # The file to touch is that specified with -o ...
+ file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'`
+ if test -z "$file"; then
+ # ... or it is the one specified with @setfilename ...
+ infile=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'`
+ file=`sed -n '/^@setfilename/ { s/.* \([^ ]*\) *$/\1/; p; q; }' $infile`
+ # ... or it is derived from the source name (dir/f.texi becomes f.info)
+ test -z "$file" && file=`echo "$infile" | sed 's,.*/,,;s,.[^.]*$,,'`.info
+ fi
+ # If the file does not exist, the user really needs makeinfo;
+ # let's fail without touching anything.
+ test -f $file || exit 1
+ touch $file
+ ;;
+
+ tar)
+ shift
+
+ # We have already tried tar in the generic part.
+ # Look for gnutar/gtar before invocation to avoid ugly error
+ # messages.
+ if (gnutar --version > /dev/null 2>&1); then
+ gnutar "$@" && exit 0
+ fi
+ if (gtar --version > /dev/null 2>&1); then
+ gtar "$@" && exit 0
+ fi
+ firstarg="$1"
+ if shift; then
+ case "$firstarg" in
+ *o*)
+ firstarg=`echo "$firstarg" | sed s/o//`
+ tar "$firstarg" "$@" && exit 0
+ ;;
+ esac
+ case "$firstarg" in
+ *h*)
+ firstarg=`echo "$firstarg" | sed s/h//`
+ tar "$firstarg" "$@" && exit 0
+ ;;
+ esac
+ fi
+
+ echo 1>&2 "\
+WARNING: I can't seem to be able to run \`tar' with the given arguments.
+ You may want to install GNU tar or Free paxutils, or check the
+ command line arguments."
+ exit 1
+ ;;
+
+ *)
+ echo 1>&2 "\
+WARNING: \`$1' is needed, and is $msg.
+ You might have modified some files without having the
+ proper tools for further handling them. Check the \`README' file,
+ it often tells you about the needed prerequisites for installing
+ this package. You may also peek at any GNU archive site, in case
+ some other package would contain this missing \`$1' program."
+ exit 1
+ ;;
+esac
+
+exit 0
+
+# Local variables:
+# eval: (add-hook 'write-file-hooks 'time-stamp)
+# time-stamp-start: "scriptversion="
+# time-stamp-format: "%:y-%02m-%02d.%02H"
+# time-stamp-end: "$"
+# End:
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/infiniband-diags-1.2.7/config.h.in new/infiniband-diags-1.2.7/config.h.in
--- old/infiniband-diags-1.2.7/config.h.in 1970-01-01 01:00:00.000000000 +0100
+++ new/infiniband-diags-1.2.7/config.h.in 2007-08-14 17:39:39.000000000 +0200
@@ -0,0 +1,109 @@
+/* config.h.in. Generated from configure.in by autoheader. */
+
+/* Define to 1 if you have the header file. */
+#undef HAVE_DLFCN_H
+
+/* Define to 1 if you don't have `vprintf' but do have `_doprnt.' */
+#undef HAVE_DOPRNT
+
+/* Define to 1 if you have the header file. */
+#undef HAVE_FCNTL_H
+
+/* Define to 1 if you have the header file. */
+#undef HAVE_INTTYPES_H
+
+/* Define to 1 if you have the `ibcommon' library (-libcommon). */
+#undef HAVE_LIBIBCOMMON
+
+/* Define to 1 if you have the `ibmad' library (-libmad). */
+#undef HAVE_LIBIBMAD
+
+/* Define to 1 if you have the `ibumad' library (-libumad). */
+#undef HAVE_LIBIBUMAD
+
+/* Define to 1 if you have the `opensm' library (-lopensm). */
+#undef HAVE_LIBOPENSM
+
+/* Define to 1 if you have the `osmcomp' library (-losmcomp). */
+#undef HAVE_LIBOSMCOMP
+
+/* Define to 1 if you have the `osmvendor' library (-losmvendor). */
+#undef HAVE_LIBOSMVENDOR
+
+/* Define to 1 if you have the header file. */
+#undef HAVE_MEMORY_H
+
+/* Define to 1 if you have the `memset' function. */
+#undef HAVE_MEMSET
+
+/* Define to 1 if you have the header file. */
+#undef HAVE_NETINET_IN_H
+
+/* Define to 1 if you have the header file. */
+#undef HAVE_STDINT_H
+
+/* Define to 1 if you have the header file. */
+#undef HAVE_STDLIB_H
+
+/* Define to 1 if you have the `strchr' function. */
+#undef HAVE_STRCHR
+
+/* Define to 1 if you have the header file. */
+#undef HAVE_STRINGS_H
+
+/* Define to 1 if you have the header file. */
+#undef HAVE_STRING_H
+
+/* Define to 1 if you have the `strrchr' function. */
+#undef HAVE_STRRCHR
+
+/* Define to 1 if you have the `strtol' function. */
+#undef HAVE_STRTOL
+
+/* Define to 1 if you have the `strtoul' function. */
+#undef HAVE_STRTOUL
+
+/* Define to 1 if you have the header file. */
+#undef HAVE_SYSLOG_H
+
+/* Define to 1 if you have the header file. */
+#undef HAVE_SYS_IOCTL_H
+
+/* Define to 1 if you have the header file. */
+#undef HAVE_SYS_STAT_H
+
+/* Define to 1 if you have the header file. */
+#undef HAVE_SYS_TYPES_H
+
+/* Define to 1 if you have the header file. */
+#undef HAVE_UNISTD_H
+
+/* Define to 1 if you have the `vprintf' function. */
+#undef HAVE_VPRINTF
+
+/* Name of package */
+#undef PACKAGE
+
+/* Define to the address where bug reports for this package should be sent. */
+#undef PACKAGE_BUGREPORT
+
+/* Define to the full name of this package. */
+#undef PACKAGE_NAME
+
+/* Define to the full name and version of this package. */
+#undef PACKAGE_STRING
+
+/* Define to the one symbol short name of this package. */
+#undef PACKAGE_TARNAME
+
+/* Define to the version of this package. */
+#undef PACKAGE_VERSION
+
+/* Define to 1 if you have the ANSI C header files. */
+#undef STDC_HEADERS
+
+/* Version number of package */
+#undef VERSION
+
+/* Define to empty if `const' does not conform to ANSI C. */
+#undef const
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/infiniband-diags-1.2.7/diags.spec new/infiniband-diags-1.2.7/diags.spec
--- old/infiniband-diags-1.2.7/diags.spec 1970-01-01 01:00:00.000000000 +0100
+++ new/infiniband-diags-1.2.7/diags.spec 2007-08-14 17:40:10.000000000 +0200
@@ -0,0 +1,175 @@
+
+%define ver 1.2.7
+%define RELEASE 1
+%define rel %{?CUSTOM_RELEASE} %{!?CUSTOM_RELEASE:%RELEASE}
+
+Summary: OpenFabrics InfiniBand Diagnostic Tools
+Name: openib-diags
+Version: %ver
+Release: %rel%{?dist}
+License: GPL/BSD
+Group: System Environment/Libraries
+BuildRoot: %{_tmppath}/%{name}-%{version}-root
+Source: http://openib.org/downloads/%{name}-%{version}.tar.gz
+Url: http://openib.org/
+BuildRequires: libibmad-devel
+Provides: perl(IBswcountlimits)
+
+%description
+This package provides IB diagnostic programs and scripts needed to
+diagnose an IB subnet.
+
+%prep
+%setup -q
+
+%build
+%configure
+make
+
+%install
+rm -rf $RPM_BUILD_ROOT
+make DESTDIR=${RPM_BUILD_ROOT} install
+# remove unpackaged files from the buildroot
+rm -f $RPM_BUILD_ROOT%{_libdir}/*.la
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(-,root,root)
+%{_bindir}/ibdiscover.pl
+%{_bindir}/ib*
+%{_bindir}/perfquery
+%{_bindir}/saquery
+%{_bindir}/vendstat
+%{_bindir}/dump_mfts.sh
+%{_bindir}/dump_lfts.sh
+%{_bindir}/set_mthca_nodedesc.sh
+%{_bindir}/sm*
+/usr/lib/perl/IBswcountlimits.pm
+%{_mandir}/man8/*
+%doc README ChangeLog
+
+%changelog
+* Tue Jun 5 2007 Hal Rosenstock - 1.2.7
+- OpenFabrics 1.2.7 release
+- Add grouping info and topology file format to ibnetdiscover man page
+- Fix node description parsing for switches in IBswcountlimits.pm
+- Handle peer ports at 1x that should be wider and ports at 2.5 Gbps
+ that should be faster in ibportstate
+- Fixed list address in configure.in
+- Eliminated conditional compilation based on WORDSIZE in grouping.c
+- Add support for ISR2012 and ISR2004 in ibnetdiscover
+- Replace all uses of "/tmp" with "/var/cache/infiniband-diags" in
+ perl diag scripts
+- Add switch map support (for -O and -U options) in saquery
+
+* Fri Apr 13 2007 Hal Rosenstock - 1.2.6
+- OpenFabrics 1.2.6 release
+- Add support for isSMdisabled in saquery -s
+- Add get name queries (-O and -U) in saquery
+- Changes to scripts and perfquery man page for
+ Xmt/RcvBytes now being Xmt/RcvData (bytes divided by 4)
+
+* Thu Mar 29 2007 Hal Rosenstock - 1.2.5
+- OpenFabrics 1.2.5 release
+- Some extra debug information added to IBswcountlimits.pm
+- Send normal output to stdout in ibtracert
+- Don't truncate NodeDescriptions containing ctl characters in ibdiag_common
+- Fix ibnetdiscover grouping for Cisco SFS7000
+- Add support to query the GUIDInfo table in smpquery
+- Clean gcc-4.1 warnings in saquery and ibdiag_common
+
+* Fri Mar 2 2007 Hal Rosenstock - 1.2.4
+- OpenFabrics 1.2.4 release
+- Fix diag rpmbuild from make dist
+- Include set_mthca_nodedesc.sh and dump_lfts.sh in the rpm
+
+* Thu Mar 1 2007 Hal Rosenstock - 1.2.3
+- OpenFabrics 1.2.3 release
+- Fixed saquery timeout handling
+
+* Tue Feb 27 2007 Hal Rosenstock - 1.2.2
+- OpenFabrics 1.2.2 release
+- Minor changes to ibswitches and ibhosts output
+
+* Thu Feb 14 2007 Hal Rosenstock - 1.2.1
+- OpenFabrics 1.2.1 release
+- Initial release of vendstat tool
+
+* Fri Feb 2 2007 Hal Rosenstock - 1.2.0
+- OpenFabrics 1.2.0 release
+- Added brief option to ibcheckerrors and ibcheckerrs
+- Updated man pages
+- Added build version to saquery and updated build version tags of other tools
+- Added -N | nocolor to usage display of scripts
+- Fixed -nocolor and -G options on scripts
+- Fixed error return status in ibchecknet
+- Added exit code to ibcheckerrors
+- Added nodename to output of ibcheckerrs
+- ibqueryerrors.pl fixes and improvements
+- Removed use of tmpfile for ibroute data in ibfindnodeusing.pl
+- Fixed undefined subroutine error in iblinkinfo.pl
+- Added switch-map option to ibtracert and ibnetdiscover
+- Cleaned up node descriptions before printing in saquery
+- Clarified --src-to-dst option in saquery
+- Added peer NodeDescription and LID to output of inbetdiscover
+- For grouping, ordered Spine and Line Nodes (for Voltaire chassis) in ibnetdiscover
+- Cleaned up node descriptions before printing in ibtracert and ibroute
+- Added additional sematics to -m option of saquery
+- Added dump_mfts.sh similar to dump_lfts.sh
+- ibnetdiscover improvements (memory leaks, ports moving, etc.)
+- Converted iblinkspeed.pl into iblinkinfo.pl and added additional capabilities
+- Added 0x in front of GUID printing of ibtracert
+- Fixed loopback handling in ibnetdiscover
+- Added support for querying Service Records to saquery
+- Added support for PerfMgt IsExtendedWidthSupported IBA 1.2 erratum in perfquery
+- For query operations, added peer port checking of linkwidth and speed
+ active in ibportstate
+- Added support for DrSLID in smpquery
+- Added IB router support to ibnetdiscover and ibtracert
+- Added additional options to saquery
+- Added support to change LinkSpeedEnabled in ibportstate
+
+* Fri Sep 22 2006 Hal Rosenstock - 1.1.0
+- OpenFabrics 1.1 release
+
+* Wed Sep 13 2006 Hal Rosenstock - 1.1.0-rc5
+- OpenFabrics 1.1-rc5 release
+
+* Wed Sep 6 2006 Hal Rosenstock - 1.1.0-rc4
+- OpenFabrics 1.1-rc4 release
+
+* Wed Aug 23 2006 Hal Rosenstock - 1.1.0-rc3
+- OpenFabrics 1.1-rc3 release
+
+* Mon Aug 14 2006 Hal Rosenstock - 1.1.0-rc2
+- OpenFabrics 1.1-rc2 release
+- Added ibsysstat man page
+
+* Wed Jul 26 2006 Hal Rosenstock - 1.1.0-rc1
+- OpenFabrics 1.1-rc1 release
+- Added man pages
+- Made diag command/script options more consistent
+- saquery tool added
+- dump_lft.sh script added
+- Renamed discover.pl to ibdiscover.pl
+
+* Sun Jun 10 2006 Hal Rosenstock - 1.0-1
+- OpenFabrics 1.0 release
+
+* Tue May 30 2006 Hal Rosenstock - 1.0.0-rc6
+- Maintenance release
+
+* Fri May 12 2006 Hal Rosenstock - 1.0.0-rc5
+- Maintenance release
+
+* Thu Apr 27 2006 Hal Rosenstock - 1.0.0-rc4
+- Maintenance release
+- Note rc3 skipped to sync with OFED
+
+* Mon Apr 10 2006 Hal Rosenstock - 1.0.0-rc2
+- Maintenance release
+
+* Mon Feb 27 2006 Hal Rosenstock - 1.0.0-rc1
+- Initial spec file and release
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/infiniband-diags-1.2.7/src/mcm_rereg_test.c new/infiniband-diags-1.2.7/src/mcm_rereg_test.c
--- old/infiniband-diags-1.2.7/src/mcm_rereg_test.c 2007-07-02 15:36:44.000000000 +0200
+++ new/infiniband-diags-1.2.7/src/mcm_rereg_test.c 1970-01-01 01:00:00.000000000 +0100
@@ -1,485 +0,0 @@
-/*
- * Copyright (c) 2006 Voltaire, Inc. All rights reserved.
- *
- * This software is available to you under a choice of one of two
- * licenses. You may choose to be licensed under the terms of the GNU
- * General Public License (GPL) Version 2, available from the file
- * COPYING in the main directory of this source tree, or the
- * OpenIB.org BSD license below:
- *
- * Redistribution and use in source and binary forms, with or
- * without modification, are permitted provided that the following
- * conditions are met:
- *
- * - Redistributions of source code must retain the above
- * copyright notice, this list of conditions and the following
- * disclaimer.
- *
- * - Redistributions in binary form must reproduce the above
- * copyright notice, this list of conditions and the following
- * disclaimer in the documentation and/or other materials
- * provided with the distribution.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
- * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
- * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
- * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
- * SOFTWARE.
- *
- */
-
-#include
-#include
-#include
-#include
-
-#include
-#include
-
-#define info(fmt, arg...) fprintf(stderr, "INFO: " fmt, ##arg )
-#define err(fmt, arg...) fprintf(stderr, "ERR: " fmt, ##arg )
-#ifdef NOISY_DEBUG
-#define dbg(fmt, arg...) fprintf(stderr, "DBG: " fmt, ##arg )
-#else
-#define dbg(fmt, arg...)
-#endif
-
-#define TMO 100
-
-/* Multicast Member Record Component Masks */
-#define IB_MCR_COMPMASK_MGID (1ULL<<0)
-#define IB_MCR_COMPMASK_PORT_GID (1ULL<<1)
-#define IB_MCR_COMPMASK_QKEY (1ULL<<2)
-#define IB_MCR_COMPMASK_MLID (1ULL<<3)
-#define IB_MCR_COMPMASK_MTU_SEL (1ULL<<4)
-#define IB_MCR_COMPMASK_MTU (1ULL<<5)
-#define IB_MCR_COMPMASK_TCLASS (1ULL<<6)
-#define IB_MCR_COMPMASK_PKEY (1ULL<<7)
-#define IB_MCR_COMPMASK_RATE_SEL (1ULL<<8)
-#define IB_MCR_COMPMASK_RATE (1ULL<<9)
-#define IB_MCR_COMPMASK_LIFE_SEL (1ULL<<10)
-#define IB_MCR_COMPMASK_LIFE (1ULL<<11)
-#define IB_MCR_COMPMASK_SL (1ULL<<12)
-#define IB_MCR_COMPMASK_FLOW (1ULL<<13)
-#define IB_MCR_COMPMASK_HOP (1ULL<<14)
-#define IB_MCR_COMPMASK_SCOPE (1ULL<<15)
-#define IB_MCR_COMPMASK_JOIN_STATE (1ULL<<16)
-#define IB_MCR_COMPMASK_PROXY (1ULL<<17)
-
-static ib_gid_t mgid_ipoib = {
- 0xff, 0x12, 0x40, 0x1b, 0xff, 0xff, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff
-};
-
-uint64_t build_mcm_rec(uint8_t *data, ib_gid_t mgid, ib_gid_t port_gid)
-{
- memset(data, 0, IB_SA_DATA_SIZE);
- mad_set_array(data, 0, IB_SA_MCM_MGID_F, mgid);
- mad_set_array(data, 0, IB_SA_MCM_PORTGID_F, port_gid);
- mad_set_field(data, 0, IB_SA_MCM_JOIN_STATE_F, 1);
-
- return IB_MCR_COMPMASK_MGID|IB_MCR_COMPMASK_PORT_GID|
- IB_MCR_COMPMASK_JOIN_STATE;
-}
-
-static void build_mcm_rec_umad(void *umad, ib_portid_t *dport, int method,
- uint64_t comp_mask, uint8_t *data)
-{
- ib_rpc_t rpc;
-
- memset(&rpc, 0, sizeof(rpc));
- rpc.mgtclass = IB_SA_CLASS;
- rpc.method = method;
- rpc.attr.id = IB_SA_ATTR_MCRECORD;
- rpc.attr.mod = 0; // ???
- rpc.mask = comp_mask;
- rpc.datasz = IB_SA_DATA_SIZE;
- rpc.dataoffs = IB_SA_DATA_OFFS;
-
-
- mad_build_pkt(umad, &rpc, dport, NULL, data);
-}
-
-static int rereg_send(int port, int agent, ib_portid_t *dport,
- uint8_t *umad, int len, int method, ib_gid_t port_gid)
-{
- uint8_t data[IB_SA_DATA_SIZE];
- uint64_t comp_mask;
-
- comp_mask = build_mcm_rec(data, mgid_ipoib, port_gid);
-
- build_mcm_rec_umad(umad, dport, method, comp_mask, data);
- if(umad_send(port, agent, umad, len, TMO, 0) < 0) {
- err("umad_send leave failed: %s\n", strerror(errno));
- return -1;
- }
- dbg("umad_send %d: tid = 0x%016" PRIx64 "\n", method,
- mad_get_field64(umad_get_mad(umad), 0, IB_MAD_TRID_F));
-
- return 0;
-}
-
-static int rereg_port_gid(int port, int agent, ib_portid_t *dport,
- uint8_t *umad, int len, ib_gid_t port_gid)
-{
- uint8_t data[IB_SA_DATA_SIZE];
- uint64_t comp_mask;
-
- comp_mask = build_mcm_rec(data, mgid_ipoib, port_gid);
-
- build_mcm_rec_umad(umad, dport, IB_MAD_METHOD_DELETE,
- comp_mask, data);
- if(umad_send(port, agent, umad, len, TMO, 0) < 0) {
- err("umad_send leave failed: %s\n", strerror(errno));
- return -1;
- }
- dbg("umad_send leave: tid = 0x%016" PRIx64 "\n",
- mad_get_field64(umad_get_mad(umad), 0, IB_MAD_TRID_F));
-
- build_mcm_rec_umad(umad, dport, IB_MAD_METHOD_SET,
- comp_mask, data);
- if(umad_send(port, agent, umad, len, TMO, 0) < 0) {
- err("umad_send join failed: %s\n", strerror(errno));
- return -1;
- }
- dbg("umad_send join: tid = 0x%016" PRIx64 "\n",
- mad_get_field64(umad_get_mad(umad), 0, IB_MAD_TRID_F));
-
- return 0;
-}
-
-struct guid_trid {
- ib_gid_t gid;
- uint64_t guid;
- uint64_t trid;
-};
-
-static int rereg_send_all(int port, int agent, ib_portid_t *dport,
- struct guid_trid *list, unsigned cnt)
-{
- uint8_t *umad;
- int len = umad_size() + 256;
- int i, ret;
-
- info("rereg_send_all... cnt = %u\n", cnt);
-
- umad = calloc(1, len);
- if (!umad) {
- err("cannot alloc mem for umad: %s\n", strerror(errno));
- return -1;
- }
-
- for (i = 0; i < cnt; i++) {
- ret = rereg_port_gid(port, agent, dport, umad, len, list[i].gid);
- if (ret < 0) {
- err("rereg_send_all: rereg_port_gid 0x%016" PRIx64
- " failed\n", list[i].guid);
- continue;
- }
- list[i].trid = mad_get_field64(umad_get_mad(umad), 0,
- IB_MAD_TRID_F);
- }
-
- info("rereg_send_all: sent %u requests\n", cnt*2);
-
- free(umad);
-
- return 0;
-}
-
-#if 0
-static int rereg_mcm_rec_send(int port, int agent, ib_portid_t *dport, int cnt)
-{
- ib_portid_t portid;
- ib_gid_t port_gid;
- uint8_t *umad;
- int len, ret = 0;
-
- ib_resolve_self(&portid, NULL, &port_gid);
-
- len = umad_size() + 256;
- umad = calloc(1, len);
- if (!umad) {
- err("cannot alloc mem for umad: %s\n", strerror(errno));
- return -1;
- }
-
- while(cnt--) {
- if (!rereg_port_gid(port, agent, dport, umad, len, port_gid))
- ret += 2;
- }
-
- free(umad);
-
- return ret;
-}
-#endif
-
-static int rereg_recv(int port, int agent, ib_portid_t *dport,
- uint8_t *umad, int length, int tmo)
-{
- int ret, retry = 0;
- int len = length;
-
- while((ret = umad_recv(port, umad, &len, tmo)) < 0 &&
- errno == ETIMEDOUT) {
- if (retry++ > 3)
- return 0;
- }
- if (ret < 0) {
- err("umad_recv %d failed: %s\n", ret, strerror(errno));
- return -1;
- }
- dbg("umad_recv (retries %d), tid = 0x%016" PRIx64 ": len = %d, status = %d\n",
- retry,
- mad_get_field64(umad_get_mad(umad), 0, IB_MAD_TRID_F),
- len, umad_status(umad));
-
- return 1;
-}
-
-static int rereg_recv_all(int port, int agent, ib_portid_t *dport,
- struct guid_trid *list, unsigned cnt)
-{
- uint8_t *umad, *mad;
- int len = umad_size() + 256;
- uint64_t trid;
- unsigned n, method, status;
- int i;
-
- info("rereg_recv_all...\n");
-
- umad = calloc(1, len);
- if (!umad) {
- err("cannot alloc mem for umad: %s\n", strerror(errno));
- return -1;
- }
-
- n = 0;
- while (rereg_recv(port, agent, dport, umad, len, TMO) > 0) {
- dbg("rereg_recv_all: done %d\n", n);
- n++;
- mad = umad_get_mad(umad);
-
- method = mad_get_field(mad, 0, IB_MAD_METHOD_F);
- status = mad_get_field(mad, 0, IB_MAD_STATUS_F);
-
- if (status)
- dbg("MAD status %x, method %x\n", status, method);
-
- if (status &&
- (method&0x7f) == (IB_MAD_METHOD_GET_RESPONSE&0x7f)) {
- trid = mad_get_field64(mad, 0, IB_MAD_TRID_F);
- for (i = 0; i < cnt; i++)
- if (trid == list[i].trid)
- break;
- if (i == cnt) {
- err("cannot find trid 0x%016" PRIx64 "\n",
- trid);
- continue;
- }
- info("guid 0x%016" PRIx64 ": method = %x status = %x. Resending\n",
- ntohll(list[i].guid), method, status);
- rereg_port_gid(port, agent, dport, umad, len,
- list[i].gid);
- list[i].trid = mad_get_field64(umad_get_mad(umad), 0,
- IB_MAD_TRID_F);
- }
- }
-
- info("rereg_recv_all: got %u responses\n", n);
-
- free(umad);
- return 0;
-}
-
-static int rereg_query_all(int port, int agent, ib_portid_t *dport,
- struct guid_trid *list, unsigned cnt)
-{
- uint8_t *umad, *mad;
- int len = umad_size() + 256;
- unsigned method, status;
- int i, ret;
-
- info("rereg_query_all...\n");
-
- umad = calloc(1, len);
- if (!umad) {
- err("cannot alloc mem for umad: %s\n", strerror(errno));
- return -1;
- }
-
- for ( i = 0; i < cnt; i++ ) {
- ret = rereg_send(port, agent, dport, umad, len,
- IB_MAD_METHOD_GET, list[i].gid);
- if (ret < 0) {
- err("query_all: rereg_send failed.\n");
- continue;
- }
-
- ret = rereg_recv(port, agent, dport, umad, len, TMO);
- if (ret < 0) {
- err("query_all: rereg_recv failed.\n");
- continue;
- }
-
- mad = umad_get_mad(umad);
-
- method = mad_get_field(mad, 0, IB_MAD_METHOD_F);
- status = mad_get_field(mad, 0, IB_MAD_STATUS_F);
-
- if (status)
- info("guid 0x%016" PRIx64 ": status %x, method %x\n",
- ntohll(list[i].guid), status, method);
- }
-
- info("rereg_query_all: %u queried.\n", cnt);
-
- free(umad);
- return 0;
-}
-
-#if 0
-static int rereg_mcm_rec_recv(int port, int agent, int cnt)
-{
- uint8_t *umad, *mad;
- int len = umad_size() + 256;
- int i;
-
- umad = calloc(1, len);
- if (!umad) {
- err("cannot alloc mem for umad: %s\n", strerror(errno));
- return -1;
- }
-
- for ( i = 0; i < cnt; i++ ) {
- int retry;
- retry = 0;
- while (umad_recv(port, umad, &len, TMO) < 0 &&
- errno == ETIMEDOUT)
- if (retry++ > 3) {
- err("umad_recv %d failed: %s\n",
- i, strerror(errno));
- free(umad);
- return -1;
- }
- dbg("umad_recv %d (retries %d), tid = 0x%016" PRIx64 ": len = %d, status = %d\n",
- i, retry,
- mad_get_field64(umad_get_mad(umad), 0, IB_MAD_TRID_F),
- len, umad_status(umad));
- mad = umad_get_mad(umad);
- }
-
- free(umad);
- return 0;
-}
-#endif
-
-#define MAX_CLIENTS 50
-
-static int rereg_and_test_port(char *guid_file, int port, int agent, ib_portid_t *dport, int timeout)
-{
- char line[256];
- FILE *f;
- ib_gid_t port_gid;
- uint64_t prefix = htonll(0xfe80000000000000llu);
- uint64_t guid = htonll(0x0002c90200223825llu);
- struct guid_trid *list;
- int i = 0;
-
- list = calloc(MAX_CLIENTS, sizeof(*list));
- if (!list) {
- err("cannot alloc mem for guid/trid list: %s\n", strerror(errno));
- return -1;
- }
-
- f = fopen(guid_file, "r");
- while (fgets(line, sizeof(line), f)) {
- guid = strtoull(line, NULL, 0);
- guid = htonll(guid);
- memcpy(&port_gid[0], &prefix, 8);
- memcpy(&port_gid[8], &guid, 8);
-
- list[i].guid = guid;
- memcpy(list[i].gid, port_gid, sizeof(list[i].gid));
- list[i].trid = 0;
- if (++i >= MAX_CLIENTS)
- break;
- }
- fclose(f);
-
- rereg_send_all(port, agent, dport, list, i);
- rereg_recv_all(port, agent, dport, list, i);
-
- rereg_query_all(port, agent, dport, list, i);
-
- free(list);
- return 0;
-}
-
-int main(int argc, char **argv)
-{
- char *guid_file = "port_guids.list";
- int mgmt_classes[2] = {IB_SMI_CLASS, IB_SMI_DIRECT_CLASS};
- ib_portid_t dport_id;
- int port, agent;
- uint8_t *umad, *mad;
- int len;
-
- if (argc > 1)
- guid_file = argv[1];
-
- madrpc_init(NULL, 0, mgmt_classes, 2);
-
-#if 1
- ib_resolve_smlid(&dport_id, TMO);
-#else
- memset(&dport_id, 0, sizeof(dport_id));
- dport_id.lid = 1;
-#endif
- dport_id.qp = 1;
- if (!dport_id.qkey)
- dport_id.qkey = IB_DEFAULT_QP1_QKEY;
-
-
- len = umad_size() + 256;
- umad = calloc(1, len);
- if (!umad) {
- err("cannot alloc mem for umad: %s\n", strerror(errno));
- return -1;
- }
-
-#if 1
- port = madrpc_portid();
-#else
- ret = umad_init();
-
- port = umad_open_port(NULL, 0);
- if (port < 0) {
- err("umad_open_port failed: %s\n", strerror(errno));
- return port;
- }
-#endif
-
- agent = umad_register(port, IB_SA_CLASS, 2, 0, NULL);
-
-#if 0
- int cnt;
- cnt = rereg_mcm_rec_send(port, agent, &dport_id, cnt);
-
- rereg_recv_all(port, agent, &dport_id);
-#else
- rereg_and_test_port(guid_file, port, agent, &dport_id, TMO);
-#endif
- mad = umad_get_mad(umad);
-
- free(umad);
- umad_unregister(port, agent);
- umad_close_port(port);
- umad_done();
-
- return 0;
-}
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org