From patchwork Thu Apr 8 13:30:40 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yevgeny Kliteynik X-Patchwork-Id: 91272 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o38DUjEo009707 for ; Thu, 8 Apr 2010 13:30:45 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758623Ab0DHNao (ORCPT ); Thu, 8 Apr 2010 09:30:44 -0400 Received: from mail.mellanox.co.il ([194.90.237.43]:51569 "EHLO mellanox.co.il" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1750771Ab0DHNao (ORCPT ); Thu, 8 Apr 2010 09:30:44 -0400 Received: from Internal Mail-Server by MTLPINE1 (envelope-from kliteyn@dev.mellanox.co.il) with SMTP; 8 Apr 2010 16:30:40 +0300 Received: from [10.4.1.29] ([10.4.1.29]) by mtlexch01.mtl.com with Microsoft SMTPSVC(6.0.3790.3959); Thu, 8 Apr 2010 16:30:40 +0300 Message-ID: <4BBDDA80.9050808@dev.mellanox.co.il> Date: Thu, 08 Apr 2010 16:30:40 +0300 From: Yevgeny Kliteynik User-Agent: Thunderbird 1.5.0.5 (X11/20060719) MIME-Version: 1.0 To: Sasha Khapyorsky CC: Linux RDMA , Jim Schut Subject: [PATCH 4/4] opensm: add command line argument to dump PR file X-OriginalArrivalTime: 08 Apr 2010 13:30:40.0441 (UTC) FILETIME=[AE760A90:01CAD71F] X-TM-AS-Product-Ver: SMEX-8.0.0.1181-6.000.1038-17306.007 X-TM-AS-Result: No--12.214100-8.000000-31 X-TM-AS-User-Approved-Sender: No X-TM-AS-User-Blocked-Sender: No Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Thu, 08 Apr 2010 13:30:45 +0000 (UTC) diff --git a/opensm/man/opensm.8.in b/opensm/man/opensm.8.in index 7aca8f9..8d3ce97 100644 --- a/opensm/man/opensm.8.in +++ b/opensm/man/opensm.8.in @@ -1,4 +1,4 @@ -.TH OPENSM 8 "October 22, 2009" "OpenIB" "OpenIB Management" +.TH OPENSM 8 "April 8, 2010" "OpenIB" "OpenIB Management" .SH NAME opensm \- InfiniBand subnet manager and administration (SM/SA) @@ -28,6 +28,7 @@ opensm \- InfiniBand subnet manager and administration (SM/SA) [\-H | \-\-max_reverse_hops ] [\-X | \-\-guid_routing_order_file ] [\-m | \-\-ids_guid_file ] +[\-\-dump_path_records] [\-o(nce)] [\-s(weep) ] [\-t(imeout) ] @@ -218,6 +219,11 @@ Set the order port guids will be routed for the MinHop and Up/Down routing algorithms to the guids provided in the given file (one to a line). .TP +\fB\-\-dump_path_records\fR +This option causes OpenSM to dump Path Records file. +This file can be used by applications such as MPI to +eliminate the need to query SA. +.TP \fB\-o\fR, \fB\-\-once\fR This option causes OpenSM to configure the subnet once, then exit. Ports remain in the ACTIVE state. diff --git a/opensm/opensm/main.c b/opensm/opensm/main.c index f9a33af..9d5c886 100644 --- a/opensm/opensm/main.c +++ b/opensm/opensm/main.c @@ -231,6 +231,10 @@ static void show_usage(void) " Set the order port guids will be routed for the MinHop\n" " and Up/Down routing algorithms to the guids provided in the\n" " given file (one to a line)\n\n"); + printf("--dump_path_records\n" + " This option causes OpenSM to dump Path Records file.\n" + " This file can be used by applications such as MPI to\n" + " eliminate the need to query SA.\n\n"); printf("--once, -o\n" " This option causes OpenSM to configure the subnet\n" " once, then exit. Ports remain in the ACTIVE state.\n\n"); @@ -610,6 +614,7 @@ int main(int argc, char *argv[]) {"sm_sl", 1, NULL, 7}, {"retries", 1, NULL, 8}, {"log_prefix", 1, NULL, 9}, + {"dump_path_records", 0, NULL, 10}, {NULL, 0, NULL, 0} /* Required at the end of the array */ }; @@ -992,6 +997,10 @@ int main(int argc, char *argv[]) SET_STR_OPT(opt.log_prefix, optarg); printf("Log prefix = %s\n", opt.log_prefix); break; + case 10: + opt.path_rec_dump = TRUE; + printf(" Dumping Path Records file\n"); + break; case 'h': case '?': case ':':