Skip to contentSkip to conversation

cluster/cmirror-kernel/src dm-cmirror-client.c

Cluster-devel [email protected] 1 participant 1 message Aug 23, 2007

lore
Share & tools
lore
#0 lore raw

CVSROOT: /cvs/cluster
Module name: cluster
Branch: RHEL4
Changes by: jbrassow at sourceware.org 2007-08-23 16:51:39

Modified files:
cmirror-kernel/src: dm-cmirror-client.c

Log message:
BUG 239856 Processed: failed server election due to suspended mirror...

When two logs are loaded that represent the same entity, the second log should start out suspended.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/cmirror-kernel/src/dm-cmirror-client.c.diff?cvsroot=cluster&only_with_tag=RHEL4&r1=1.1.2.49&r2=1.1.2.50

cmirror-kernel/src/Attic/dm-cmirror-client.c +5 -1
@@ -586,6 +586,11 @@
 		if(!strncmp(tmp_lc->uuid, lc->uuid, MAX_NAME_LEN)){
 			lc->uuid_ref = (lc->uuid_ref > tmp_lc->uuid_ref) ?
 				lc->uuid_ref : tmp_lc->uuid_ref + 1;
+			/*
+			 * A second instance of the same log
+			 * should start out suspended.
+			 */
+			atomic_set(&lc->suspended, 1);
 		}
 	}
 
@@ -601,7 +606,6 @@
 	INIT_LIST_HEAD(&lc->mark_logged);
 	spin_lock_init(&lc->state_lock);
 
-	atomic_set(&lc->suspended, 1);
 	lc->server_valid = 0;
 	lc->server_id = 0xDEAD;