7198889 with SRU12.1 all connections to my storage cells are lost
authorSharath M Srinivasan <sharath.srinivasan@oracle.com>
Mon, 01 Oct 2012 01:48:14 -0700
changeset 995 52ebc73c889f
parent 994 d4f57a8d40ca
child 996 0698123e4e6b
7198889 with SRU12.1 all connections to my storage cells are lost
components/open-fabrics/libibmad/patches/base.patch
--- a/components/open-fabrics/libibmad/patches/base.patch	Fri Sep 28 16:15:22 2012 -0700
+++ b/components/open-fabrics/libibmad/patches/base.patch	Mon Oct 01 01:48:14 2012 -0700
@@ -100,6 +100,38 @@
  	return next;
  }
  
+diff -r -u /tmp/libibmad-1.3.7/src/resolve.c libibmad-1.3.7/src/resolve.c
+--- /tmp/libibmad-1.3.7/src/resolve.c	Wed Feb 16 02:12:53 2011
++++ libibmad-1.3.7/src/resolve.c	Mon Oct  1 01:32:21 2012
[email protected]@ -40,6 +40,7 @@
+ #include <stdlib.h>
+ #include <string.h>
+ #include <arpa/inet.h>
++#include <errno.h>
+ 
+ #include <infiniband/umad.h>
+ #include <infiniband/mad.h>
[email protected]@ -104,12 +105,18 @@
+ 
+ 	if (!sm_id) {
+ 		sm_id = &sm_portid;
+-		if (ib_resolve_smlid_via(sm_id, timeout, srcport) < 0)
++		if (ib_resolve_smlid_via(sm_id, timeout, srcport) < 0) {
++			if (!errno)
++				errno = EIO;
+ 			return -1;
++		}
+ 	}
+ 
+-	if (!smp_query_via(nodeinfo, &self, IB_ATTR_NODE_INFO, 0, 0, srcport))
++	if (!smp_query_via(nodeinfo, &self, IB_ATTR_NODE_INFO, 0, 0, srcport)) {
++		if (!errno)
++			errno = EIO;
+ 		return -1;
++	}
+ 	mad_decode_field(nodeinfo, IB_NODE_PORT_GUID_F, &selfguid);
+ 	mad_set_field64(selfgid, 0, IB_GID_PREFIX_F, IB_DEFAULT_SUBN_PREFIX);
+ 	mad_set_field64(selfgid, 0, IB_GID_GUID_F, selfguid);
 diff -r -u /tmp/libibmad-1.3.7/src/dump.c libibmad-1.3.7/src/dump.c
 --- /tmp/libibmad-1.3.7/src/dump.c	Wed Feb 16 02:12:53 2011
 +++ libibmad-1.3.7/src/dump.c	Thu Feb 24 11:27:11 2011
@@ -216,6 +248,25 @@
  		break;
  	case 3:
  		snprintf(buf, bufsz, "%06x", *(uint32_t *) val & 0xffffff);
+diff -r -u /tmp/libibmad-1.3.7/src/sa.c libibmad-1.3.7/src/sa.c
+--- /tmp/libibmad-1.3.7/src/sa.c	Wed Feb 16 02:12:53 2011
++++ libibmad-1.3.7/src/sa.c	Mon Oct  1 01:32:21 2012
[email protected]@ -38,6 +38,7 @@
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>
++#include <errno.h>
+ 
+ #include <infiniband/mad.h>
+ #include "mad_internal.h"
[email protected]@ -56,6 +57,7 @@
+ 
+ 	if (portid->lid <= 0) {
+ 		IBWARN("only lid routes are supported");
++		errno = EIO;
+ 		return NULL;
+ 	}
+ 
 diff -r -u /tmp/libibmad-1.3.7/src/rpc.c libibmad-1.3.7/src/rpc.c
 --- /tmp/libibmad-1.3.7/src/rpc.c	Wed Feb 16 02:12:53 2011
 +++ libibmad-1.3.7/src/rpc.c	Thu Feb 24 11:27:14 2011