Add default membership (limited or full) to partition definition.

Signed-off-by: Philippe Gregoire <philippe.gregoire@cea.fr>

--- osm_prtn_config.old.c	2007-05-15 16:35:32.197097194 +0200
+++ osm_prtn_config.c	2007-05-15 16:37:58.870261412 +0200
@@ -70,6 +70,7 @@
 	osm_subn_t *p_subn;
 	osm_prtn_t *p_prtn;
 	unsigned    is_ipoib, mtu, rate, sl, scope;
+	boolean_t   full;
 };
 
 extern osm_prtn_t *osm_prtn_make_new(osm_log_t *p_log, osm_subn_t *p_subn,
@@ -163,6 +164,14 @@
 				" - skipped\n", lineno);
 		else
 			conf->sl = sl;
+	} else if (!strncmp(flag, "defmember", len)) {
+		if (!val || (strncmp(val, "limited", strlen(val)) && strncmp(val, "full", strlen(val))))
+			osm_log(conf->p_log, OSM_LOG_VERBOSE,
+				"PARSE WARN: line %d: "
+				"flag \'defmember\' requires valid value (limited or full)"
+				" - skipped\n", lineno);
+		else
+			conf->full = strncmp(val, "full", strlen(val)) == 0;
 	} else {
 			osm_log(conf->p_log, OSM_LOG_VERBOSE,
 					  "PARSE WARN: line %d: "
@@ -177,12 +186,14 @@
 {
 	osm_prtn_t *p = conf->p_prtn;
 	ib_net64_t guid;
-	boolean_t full = FALSE;
+	boolean_t full = conf->full;
 
 	if (!name || !*name || !strncmp(name, "NONE", strlen(name)))
 		return 0;
 
 	if (flag) {
+		/* reset default membership to limited */
+		full = FALSE;
 		if (!strncmp(flag, "full", strlen(flag)))
 			full = TRUE;
 		else if (strncmp(flag, "limited", strlen(flag))) {
@@ -275,6 +286,7 @@
 	conf->p_prtn = NULL;
 	conf->is_ipoib = 0;
 	conf->sl = OSM_DEFAULT_SL;
+	conf->full = FALSE;
 	return conf;
 }
 
