[Ocfs2-commits] mfasheh commits r2123 - trunk/fs/ocfs2

svn-commits at oss.oracle.com svn-commits at oss.oracle.com
Thu Apr 7 16:24:06 CDT 2005


Author: mfasheh
Signed-off-by: manish
Date: 2005-04-07 16:24:05 -0500 (Thu, 07 Apr 2005)
New Revision: 2123

Modified:
   trunk/fs/ocfs2/vote.c
Log:
* a little better handling of real network errors versus non zero
  votes.

Signed-off-by: manish



Modified: trunk/fs/ocfs2/vote.c
===================================================================
--- trunk/fs/ocfs2/vote.c	2005-04-07 21:22:29 UTC (rev 2122)
+++ trunk/fs/ocfs2/vote.c	2005-04-07 21:24:05 UTC (rev 2123)
@@ -496,7 +496,8 @@
 
 static int ocfs2_broadcast_vote(ocfs_super *osb,
 				ocfs2_vote_msg *request,
-				unsigned int response_id)
+				unsigned int response_id,
+				int *response)
 {
 	int status, i, remote_err;
 	ocfs2_net_wait_ctxt *w = NULL;
@@ -563,7 +564,7 @@
 
 	ocfs2_dequeue_net_wait_ctxt(osb, w);
 	dequeued = 1;
-	status = w->n_response;
+	*response = w->n_response;
 bail:
 	if (w) {
 		if (!dequeued)
@@ -580,7 +581,7 @@
 				 unsigned int generation,
 				 enum ocfs2_vote_request type)
 {
-	int status;
+	int status, response;
 	unsigned int response_id;
 	ocfs2_vote_msg *request = NULL;
 	ocfs2_msg_hdr *hdr;
@@ -604,13 +605,14 @@
 	hdr->h_generation = htonl(generation);
 	hdr->h_node_num = htonl((unsigned int) osb->node_num);
 
-	status = ocfs2_broadcast_vote(osb, request, response_id);
+	status = ocfs2_broadcast_vote(osb, request, response_id, &response);
 	if (status < 0) {
 		if (status != -EINTR)
 			LOG_ERROR_STATUS(status);
 		goto bail;
 	}
 
+	status = response;
 bail:
 	if (request)
 		kfree(request);



More information about the Ocfs2-commits mailing list