public inbox for lvm2-cvs@sourceware.org
help / color / mirror / Atom feed
From: pcaulfield@sourceware.org
To: lvm-devel@redhat.com, lvm2-cvs@sourceware.org
Subject: LVM2 ./WHATS_NEW daemons/clvmd/Makefile.in dae ...
Date: Mon, 25 Jun 2007 09:02:00 -0000	[thread overview]
Message-ID: <20070625090238.10127.qmail@sourceware.org> (raw)

CVSROOT:	/cvs/lvm2
Module name:	LVM2
Changes by:	pcaulfield@sourceware.org	2007-06-25 09:02:37

Modified files:
	.              : WHATS_NEW 
	daemons/clvmd  : Makefile.in clvmd-openais.c 

Log message:
	Use cpg_local_get() rather then Clm to get the local nodeid.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/WHATS_NEW.diff?cvsroot=lvm2&r1=1.639&r2=1.640
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/daemons/clvmd/Makefile.in.diff?cvsroot=lvm2&r1=1.19&r2=1.20
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/daemons/clvmd/clvmd-openais.c.diff?cvsroot=lvm2&r1=1.1&r2=1.2

--- LVM2/WHATS_NEW	2007/06/19 10:51:51	1.639
+++ LVM2/WHATS_NEW	2007/06/25 09:02:37	1.640
@@ -4,6 +4,7 @@
   Add vg_status function and clean up vg->status in tools directory.
   Add --ignoremonitoring to disable all dmeventd interaction.
   Remove get_ prefix from get_pv_* functions.
+  clvmd-openais now uses cpg_local_get() to get nodeid, rather than Clm.
 
 Version 2.02.26 - 15th June 2007
 ================================
--- LVM2/daemons/clvmd/Makefile.in	2007/06/14 10:16:34	1.19
+++ LVM2/daemons/clvmd/Makefile.in	2007/06/25 09:02:37	1.20
@@ -59,7 +59,7 @@
 
 ifeq ("$(OPENAIS)", "yes")
 	SOURCES += clvmd-openais.c
-	LMLIBS += -lSaLck -lSaClm -lcpg
+	LMLIBS += -lSaLck -lcpg
 	DEFS += -DUSE_OPENAIS
 endif
 
--- LVM2/daemons/clvmd/clvmd-openais.c	2007/05/21 10:52:01	1.1
+++ LVM2/daemons/clvmd/clvmd-openais.c	2007/06/25 09:02:37	1.2
@@ -98,9 +98,6 @@
         .saLckResourceUnlockCallback = lck_unlock_callback
 };
 
-/* We only call Clm to get our node id */
-SaClmCallbacksT clm_callbacks;
-
 struct node_info
 {
 	enum {NODE_UNKNOWN, NODE_DOWN, NODE_UP, NODE_CLVMD} state;
@@ -348,7 +345,6 @@
 {
 	SaAisErrorT err;
 	SaVersionT  ver = { 'B', 1, 1 };
-	SaClmHandleT clm_handle;
 	int select_fd;
 	SaClmClusterNodeT cluster_node;
 
@@ -387,26 +383,14 @@
 		return ais_to_errno(err);
 	}
 
-	/* A brief foray into Clm to get our node id */
-	err = saClmInitialize(&clm_handle, &clm_callbacks, &ver);
-	if (err != SA_AIS_OK) {
-		syslog(LOG_ERR, "Could not initialize OpenAIS membership service %d\n", err);
-		DEBUGLOG("Could not initialize OpenAIS Membership service %d\n", err);
-		return ais_to_errno(err);
-	}
-
-	err = saClmClusterNodeGet(clm_handle,
-				  SA_CLM_LOCAL_NODE_ID,
-				  TIMEOUT,
-				  &cluster_node);
+	err = cpg_local_get(cpg_handle,
+			    &cluster_node);
 	if (err != SA_AIS_OK) {
 		cpg_finalize(cpg_handle);
 		saLckFinalize(lck_handle);
-		saClmFinalize(clm_handle);
 		syslog(LOG_ERR, "Cannot get local node id\n");
 		return ais_to_errno(err);
 	}
-	saClmFinalize(clm_handle);
 	our_nodeid = cluster_node.nodeId;
 	DEBUGLOG("Our local node id is %d\n", our_nodeid);
 
@@ -424,7 +408,7 @@
 	unlock_all();
 
 	saLckFinalize(lck_handle);
-	cpg_inalize(cpg_handle);
+	cpg_finalize(cpg_handle);
 }
 
 static void _get_our_csid(char *csid)


             reply	other threads:[~2007-06-25  9:02 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-25  9:02 pcaulfield [this message]
  -- strict thread matches above, loose matches on Subject: below --
2009-02-11 10:13 ccaulfield
2009-02-02 14:34 ccaulfield
2009-01-22 10:21 ccaulfield
2007-06-14 10:16 pcaulfield
2007-05-21 10:52 pcaulfield
2006-10-04  8:22 pcaulfield
2006-03-14 14:18 pcaulfield
2005-02-21 15:58 pcaulfield

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20070625090238.10127.qmail@sourceware.org \
    --to=pcaulfield@sourceware.org \
    --cc=lvm-devel@redhat.com \
    --cc=lvm2-cvs@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).