linux-rdma.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 2/2] infiniband-diags/libibnetdisc/chassis.c: In group_nodes, set fabric->chassis
@ 2010-06-02 13:04 Hal Rosenstock
       [not found] ` <20100602130415.GB4715-Wuw85uim5zDR7s880joybQ@public.gmane.org>
  0 siblings, 1 reply; 2+ messages in thread
From: Hal Rosenstock @ 2010-06-02 13:04 UTC (permalink / raw)
  To: sashak-smomgflXvOZWk0Htik3J/w
  Cc: weiny2-i2BcT+NCU+M, linux-rdma-u79uwXL29TY76Z2rM5mHXA


when grouping by SystemImageGUID

Without doing this, find_chassisguid will always return without
finding the already discovered chassis so no grouping occurs
when it should

Signed-off-by: Hal Rosenstock <hal.rosenstock-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
---
 infiniband-diags/libibnetdisc/src/chassis.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/infiniband-diags/libibnetdisc/src/chassis.c b/infiniband-diags/libibnetdisc/src/chassis.c
index f5f683e..25d7473 100644
--- a/infiniband-diags/libibnetdisc/src/chassis.c
+++ b/infiniband-diags/libibnetdisc/src/chassis.c
@@ -2,6 +2,7 @@
  * Copyright (c) 2004-2009 Voltaire Inc.  All rights reserved.
  * Copyright (c) 2007 Xsigo Systems Inc.  All rights reserved.
  * Copyright (c) 2008 Lawrence Livermore National Lab.  All rights reserved.
+ * Copyright (c) 2010 HNR Consulting.  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
@@ -1074,6 +1075,8 @@ int group_nodes(ibnd_fabric_t * fabric)
 				chassis_scan.current_chassis->chassisguid =
 				    get_chassisguid(node);
 				chassis_scan.current_chassis->nodecount = 1;
+				if (!fabric->chassis)
+					fabric->chassis = chassis_scan.first_chassis;
 			}
 		}
 	}
@@ -1107,5 +1110,6 @@ cleanup:
 		free(ch);
 		ch = ch_next;
 	}
+	fabric->chassis = NULL;
 	return -1;
 }
-- 
1.5.6.4

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH 2/2] infiniband-diags/libibnetdisc/chassis.c: In group_nodes, set fabric->chassis
       [not found] ` <20100602130415.GB4715-Wuw85uim5zDR7s880joybQ@public.gmane.org>
@ 2010-06-02 15:12   ` Sasha Khapyorsky
  0 siblings, 0 replies; 2+ messages in thread
From: Sasha Khapyorsky @ 2010-06-02 15:12 UTC (permalink / raw)
  To: Hal Rosenstock; +Cc: weiny2-i2BcT+NCU+M, linux-rdma-u79uwXL29TY76Z2rM5mHXA

On 09:04 Wed 02 Jun     , Hal Rosenstock wrote:
> 
> when grouping by SystemImageGUID
> 
> Without doing this, find_chassisguid will always return without
> finding the already discovered chassis so no grouping occurs
> when it should
> 
> Signed-off-by: Hal Rosenstock <hal.rosenstock-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>

Both applied. Thanks.

Sasha
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-06-02 15:12 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-06-02 13:04 [PATCH 2/2] infiniband-diags/libibnetdisc/chassis.c: In group_nodes, set fabric->chassis Hal Rosenstock
     [not found] ` <20100602130415.GB4715-Wuw85uim5zDR7s880joybQ@public.gmane.org>
2010-06-02 15:12   ` Sasha Khapyorsky

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).