Hey Sasha,
As discussed in the other thread, this patches makes perfquery error out
if the user requested port 255 and AllPortSelect is not supported.
Al
--
Albert Chu
[EMAIL PROTECTED]
Computer Scientist
High Performance Systems Division
Lawrence Livermore National Laboratory
>From 7802b9ade2270e5c6f0b7606f9243bbe2f551c29 Mon Sep 17 00:00:00 2001
From: Albert Chu <[EMAIL PROTECTED]>
Date: Thu, 9 Oct 2008 16:38:30 -0700
Subject: [PATCH] if user inputs port 255 error if AllPortSelect flag not supported
Signed-off-by: Albert Chu <[EMAIL PROTECTED]>
---
infiniband-diags/src/perfquery.c | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/infiniband-diags/src/perfquery.c b/infiniband-diags/src/perfquery.c
index 7674da4..05cc2d6 100644
--- a/infiniband-diags/src/perfquery.c
+++ b/infiniband-diags/src/perfquery.c
@@ -246,11 +246,12 @@ main(int argc, char **argv)
/* ClassPortInfo should be supported as part of libibmad */
memcpy(&cap_mask, pc+2, sizeof(cap_mask)); /* CapabilityMask */
cap_mask = ntohs(cap_mask);
- if (!(cap_mask & 0x100)) /* bit 8 is AllPortSelect */
- if (port == ALL_PORTS) {
+ if (!(cap_mask & 0x100)) { /* bit 8 is AllPortSelect */
+ if (!all && port == ALL_PORTS)
+ IBERROR("AllPortSelect not supported");
+ if (all)
allports = 1;
- IBWARN("AllPortSelect not supported");
- }
+ }
if (allports == 1) {
--
1.5.4.5
_______________________________________________
general mailing list
[email protected]
http://lists.openfabrics.org/cgi-bin/mailman/listinfo/general
To unsubscribe, please visit http://openib.org/mailman/listinfo/openib-general