[ofa-general] [PATCH] opensm: state default SM_Key value change in usage and man

Sasha Khapyorsky sashak at voltaire.com
Tue Jun 10 06:07:27 PDT 2008


State default SM_Key value change in usage massage, OpenSM man page and
generated config template file.

Signed-off-by: Sasha Khapyorsky <sashak at voltaire.com>
---
 opensm/man/opensm.8.in     |    3 +++
 opensm/opensm/main.c       |    8 +++++++-
 opensm/opensm/osm_subnet.c |    5 +++++
 3 files changed, 15 insertions(+), 1 deletions(-)

diff --git a/opensm/man/opensm.8.in b/opensm/man/opensm.8.in
index bb58f8a..b6a9fc7 100644
--- a/opensm/man/opensm.8.in
+++ b/opensm/man/opensm.8.in
@@ -99,6 +99,9 @@ is chosen by priority and GUID.  Range goes from 0
 \fB\-smkey\fR
 This option specifies the SM\'s SM_Key (64 bits).
 This will effect SM authentication.
+Note that OpenSM version 3.2.1 and below used the default value '1'
+in a host byte order, it is fixed now but you may need this option to
+interoperate with old OpenSM running on a little endian machine.
 .TP
 \fB\-r\fR, \fB\-\-reassign_lids\fR
 This option causes OpenSM to reassign LIDs to all
diff --git a/opensm/opensm/main.c b/opensm/opensm/main.c
index 040a0d7..48e9e47 100644
--- a/opensm/opensm/main.c
+++ b/opensm/opensm/main.c
@@ -163,7 +163,13 @@ static void show_usage(void)
 	       "          from 0 (lowest priority) to 15 (highest).\n\n");
 	printf("-smkey <SM_Key>\n"
 	       "          This option specifies the SM's SM_Key (64 bits).\n"
-	       "          This will effect SM authentication.\n\n");
+	       "          This will effect SM authentication.\n"
+	       "          Note that OpenSM version 3.2.1 and below used the\n"
+	       "          default value '1' in a host byte order, it is fixed\n"
+	       "          now but you may need this option to interoperate\n"
+	       "          with old OpenSM running on a little endian machine.\n"
+	       "\n");
+
 	printf("-r\n"
 	       "--reassign_lids\n"
 	       "          This option causes OpenSM to reassign LIDs to all\n"
diff --git a/opensm/opensm/osm_subnet.c b/opensm/opensm/osm_subnet.c
index e465565..dd71fa3 100644
--- a/opensm/opensm/osm_subnet.c
+++ b/opensm/opensm/osm_subnet.c
@@ -1403,6 +1403,11 @@ int osm_subn_write_conf_file(char *file_name, IN osm_subn_opt_t *const p_opts)
 		"sm_key 0x%016" PRIx64 "\n\n"
 		"# SM_Key value to qualify rcv SA queries as 'trusted'\n"
 		"sa_key 0x%016" PRIx64 "\n\n"
+		"# Note that for both values above (sm_key and sa_key)\n"
+		"# OpenSM version 3.2.1 and below used the default value '1'\n"
+		"# in a host byte order, it is fixed now but you may need to\n"
+		"# change the values to interoperate with old OpenSM running\n"
+		"# on a little endian machine.\n\n"
 		"# Subnet prefix used on this subnet\n"
 		"subnet_prefix 0x%016" PRIx64 "\n\n"
 		"# The LMC value used on this subnet\n"
-- 
1.5.5.1.178.g1f811




More information about the general mailing list