Sfoglia il codice sorgente

defect 734
cleanup include files and exports from libraries



git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@731 fd59a12c-fef9-0310-b244-a6a79926bd2f

Steven Dake 20 anni fa
parent
commit
1bf4e3bb25
34 ha cambiato i file con 791 aggiunte e 530 eliminazioni
  1. 6 6
      exec/Makefile
  2. 45 1
      exec/amf.c
  3. 2 1
      exec/amf.h
  4. 104 0
      exec/ckpt.c
  5. 0 1
      exec/ckpt.h
  6. 9 1
      exec/clm.c
  7. 2 1
      exec/evs.c
  8. 0 1
      exec/main.c
  9. 34 0
      exec/main.h
  10. 1 1
      exec/sync.c
  11. 1 0
      exec/totem.h
  12. 1 2
      exec/totempg.h
  13. 5 196
      include/ipc_amf.h
  14. 3 102
      include/ipc_ckpt.h
  15. 0 5
      include/ipc_clm.h
  16. 139 0
      include/ipc_evs.h
  17. 45 33
      include/ipc_gen.h
  18. 11 11
      lib/Makefile
  19. 7 6
      lib/amf.c
  20. 3 2
      lib/ckpt.c
  21. 1 1
      lib/clm.c
  22. 2 2
      lib/evs.c
  23. 1 1
      lib/evt.c
  24. 180 0
      lib/libSaAis.versions
  25. 38 0
      lib/libSaAmf.versions
  26. 43 0
      lib/libSaCkpt.versions
  27. 29 0
      lib/libSaClm.versions
  28. 39 0
      lib/libSaEvt.versions
  29. 30 0
      lib/libevs.versions
  30. 1 114
      lib/util.c
  31. 1 36
      lib/util.h
  32. 6 4
      test/Makefile
  33. 1 1
      test/testamf.c
  34. 1 1
      test/testamfth.c

+ 6 - 6
exec/Makefile

@@ -100,22 +100,22 @@ crypto.o: crypto.c
 
 # DO NOT DELETE
 
-main.o: ../include/ais_types.h ../include/ais_msg.h ../include/ais_types.h
+main.o: ../include/ais_types.h ../include/ipc_evs.h ../include/ais_types.h
 main.o: evs.h ../include/saClm.h ../include/ipc_gen.h ../include/list.h
 main.o: ../include/queue.h totempg.h aispoll.h totemsrp.h mempool.h parse.h
 main.o: main.h clm.h ../include/saClm.h amf.h handlers.h ckpt.h evt.h hdb.h
 main.o: ../include/saEvt.h swab.h print.h
 clm.o: ../include/ais_types.h ../include/saClm.h ../include/ais_types.h
-clm.o: ../include/ais_msg.h evs.h ../include/saClm.h ../include/ipc_gen.h
+clm.o: ../include/ipc_evs.h evs.h ../include/saClm.h ../include/ipc_gen.h
 clm.o: ../include/ipc_clm.h ../include/list.h ../include/queue.h aispoll.h
 clm.o: totempg.h totemsrp.h parse.h main.h clm.h amf.h handlers.h ckpt.h
 clm.o: evt.h hdb.h ../include/saEvt.h mempool.h print.h
-amf.o: ../include/ais_types.h ../include/ais_msg.h ../include/ais_types.h
+amf.o: ../include/ais_types.h ../include/ipc_evs.h ../include/ais_types.h
 amf.o: evs.h ../include/saClm.h ../include/ipc_gen.h ../include/list.h
 amf.o: ../include/queue.h totempg.h aispoll.h totemsrp.h mempool.h util.h
 amf.o: parse.h main.h clm.h ../include/saClm.h amf.h handlers.h ckpt.h evt.h
 amf.o: hdb.h ../include/saEvt.h print.h
-ckpt.o: ../include/ais_types.h ../include/ais_msg.h ../include/ais_types.h
+ckpt.o: ../include/ais_types.h ../include/ipc_evs.h ../include/ais_types.h
 ckpt.o: evs.h ../include/saClm.h ../include/ipc_gen.h ../include/list.h
 ckpt.o: ../include/queue.h aispoll.h mempool.h util.h parse.h totempg.h
 ckpt.o: totemsrp.h main.h clm.h ../include/saClm.h amf.h handlers.h ckpt.h
@@ -124,9 +124,9 @@ evt.o: ../include/ipc_evt.h ../include/ais_types.h ../include/saEvt.h
 evt.o: ../include/saClm.h ../include/ipc_gen.h ../include/list.h
 evt.o: ../include/queue.h util.h ../include/ais_types.h aispoll.h mempool.h
 evt.o: parse.h totempg.h totemsrp.h main.h evs.h clm.h ../include/saClm.h
-evt.o: amf.h ../include/ais_msg.h handlers.h ckpt.h evt.h hdb.h
+evt.o: amf.h ../include/ipc_evs.h handlers.h ckpt.h evt.h hdb.h
 evt.o: ../include/saEvt.h swab.h print.h
-evs.o: ../include/ais_types.h ../include/ais_msg.h ../include/ais_types.h
+evs.o: ../include/ais_types.h ../include/ipc_evs.h ../include/ais_types.h
 evs.o: evs.h ../include/saClm.h ../include/ipc_gen.h ../include/list.h
 evs.o: ../include/queue.h aispoll.h totempg.h totemsrp.h parse.h main.h clm.h
 evs.o: ../include/saClm.h amf.h handlers.h ckpt.h evt.h hdb.h

+ 45 - 1
exec/amf.c

@@ -46,7 +46,8 @@
 #include <string.h>
 
 #include "../include/ais_types.h"
-#include "../include/ais_msg.h"
+#include "../include/ipc_gen.h"
+#include "../include/ipc_amf.h"
 #include "../include/list.h"
 #include "../include/queue.h"
 #include "totempg.h"
@@ -288,6 +289,9 @@ static int message_handler_req_amf_response (struct conn_info *conn_info, void *
 
 static int message_handler_req_amf_componentcapabilitymodelget (struct conn_info *conn_info, void *message);
 
+/*
+ * Service Handler Definition
+ */
 struct libais_handler amf_libais_handlers[] =
 {
 	{ /* 0 */
@@ -382,6 +386,46 @@ struct service_handler amf_service_handler = {
 	.exec_dump_fn				= amf_dump
 };
 
+struct req_exec_amf_componentregister {
+	struct req_header header;
+	struct message_source source;
+	struct req_lib_amf_componentregister req_lib_amf_componentregister;
+	SaAmfReadinessStateT currentReadinessState;
+	SaAmfReadinessStateT newReadinessState;
+	SaAmfHAStateT currentHAState;
+	SaAmfHAStateT newHAState;
+} __attribute__((packed));
+
+struct req_exec_amf_componentunregister {
+	struct req_header header;
+	struct message_source source;
+	struct req_lib_amf_componentunregister req_lib_amf_componentunregister;
+};
+
+struct req_exec_amf_readinessstateset {
+	struct req_header header;
+	SaNameT compName;
+	SaAmfReadinessStateT readinessState;
+};
+
+struct req_exec_amf_hastateset {
+	struct req_header header;
+	SaNameT compName;
+	SaAmfHAStateT haState;
+};
+
+struct req_exec_amf_errorreport {
+	struct req_header header;
+	struct message_source source;
+	struct req_lib_amf_errorreport req_lib_amf_errorreport;
+};
+
+struct req_exec_amf_errorcancelall {
+	struct req_header header;
+	struct message_source source;
+	struct req_lib_amf_errorcancelall req_lib_amf_errorcancelall;
+};
+
 static void grow_amf_track_table (struct conn_info *conn_info, int growby)
 {
 	struct libamf_ci_trackentry *tracks;

+ 2 - 1
exec/amf.h

@@ -31,7 +31,8 @@
  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
  * THE POSSIBILITY OF SUCH DAMAGE.
  */
-#include "../include/ais_msg.h"
+#include "../include/ipc_gen.h"
+#include "../include/ipc_amf.h"
 #include "aispoll.h"
 #include "parse.h"
 #include "handlers.h"

+ 104 - 0
exec/ckpt.c

@@ -193,6 +193,9 @@ static int ckpt_confchg_fn(
 		struct in_addr *joined_list, int joined_list_entries,
 		struct memb_ring_id *ring_id);
 
+/*
+ * Executive Handler Definition
+ */
 struct libais_handler ckpt_libais_handlers[] =
 {
 	{ /* 0 */
@@ -332,6 +335,107 @@ struct service_handler ckpt_service_handler = {
 	.sync_abort					= ckpt_recovery_abort,
 };
 
+/*
+ * All data types used for executive messages
+ */
+struct req_exec_ckpt_checkpointclose {
+	struct req_header header;
+	struct message_source source;
+	SaNameT checkpointName;
+};
+
+struct req_exec_ckpt_checkpointretentiondurationset {
+	struct req_header header;
+	struct message_source source;
+	SaNameT checkpointName;
+	SaTimeT retentionDuration;
+};
+
+struct req_exec_ckpt_checkpointretentiondurationexpire {
+	struct req_header header;
+	SaNameT checkpointName;
+};
+
+struct req_exec_ckpt_checkpointopen {
+	struct req_header header;
+	struct message_source source;
+	struct req_lib_ckpt_checkpointopen req_lib_ckpt_checkpointopen;
+	SaCkptCheckpointHandleT checkpointHandle;
+	SaInvocationT invocation;
+	int async_call;
+	SaAisErrorT fail_with_error;
+};
+
+struct req_exec_ckpt_checkpointunlink {
+	struct req_header header;
+	struct message_source source;
+	struct req_lib_ckpt_checkpointunlink req_lib_ckpt_checkpointunlink;
+};
+
+struct req_exec_ckpt_sectioncreate {
+	struct req_header header;
+	struct message_source source;
+	SaNameT checkpointName;
+	struct req_lib_ckpt_sectioncreate req_lib_ckpt_sectioncreate; /* this must be last */
+};
+
+struct req_exec_ckpt_sectiondelete {
+	struct req_header header;
+	struct message_source source;
+	SaNameT checkpointName;
+	struct req_lib_ckpt_sectiondelete req_lib_ckpt_sectiondelete; /* this must be last */
+};
+
+struct req_exec_ckpt_sectionexpirationtimeset {
+	struct req_header header;
+	struct message_source source;
+	SaNameT checkpointName;
+	struct req_lib_ckpt_sectionexpirationtimeset req_lib_ckpt_sectionexpirationtimeset;
+};
+
+struct req_exec_ckpt_sectionwrite {
+	struct req_header header;
+	struct message_source source;
+	SaNameT checkpointName;
+	struct req_lib_ckpt_sectionwrite req_lib_ckpt_sectionwrite;
+};
+
+struct req_exec_ckpt_sectionoverwrite {
+	struct req_header header;
+	struct message_source source;
+	SaNameT checkpointName;
+	struct req_lib_ckpt_sectionoverwrite req_lib_ckpt_sectionoverwrite;
+};
+
+struct req_exec_ckpt_sectionread {
+	struct req_header header;
+	struct message_source source;
+	SaNameT checkpointName;
+	struct req_lib_ckpt_sectionread req_lib_ckpt_sectionread;
+};
+
+struct req_exec_ckpt_synchronize_state {
+	struct req_header header;
+	struct memb_ring_id previous_ring_id;
+	SaNameT checkpointName;
+	SaCkptCheckpointCreationAttributesT checkpointCreationAttributes;
+	SaCkptSectionDescriptorT sectionDescriptor;	
+	struct in_addr source_addr;
+	struct ckpt_refcnt ckpt_refcount[PROCESSOR_COUNT_MAX];
+};
+
+struct req_exec_ckpt_synchronize_section {
+	struct req_header header;
+	struct memb_ring_id previous_ring_id;
+	SaNameT checkpointName;
+	SaCkptSectionIdT sectionId;	
+	SaUint32T dataOffSet;
+	SaUint32T dataSize;	
+};
+
+/* 
+ * Implementation
+ */
 static int processor_index_set(struct in_addr *proc_addr, 
 								struct ckpt_refcnt *ckpt_refcount) 
 {

+ 0 - 1
exec/ckpt.h

@@ -34,7 +34,6 @@
 #include "../include/ais_types.h"
 #include "../include/saCkpt.h"
 #include "aispoll.h"
-#include "parse.h"
 #include "totemsrp.h"
 
 #ifndef CKPT_H_DEFINED

+ 9 - 1
exec/clm.c

@@ -53,7 +53,7 @@
 
 #include "../include/ais_types.h"
 #include "../include/saClm.h"
-#include "../include/ais_msg.h"
+#include "../include/ipc_gen.h"
 #include "../include/ipc_clm.h"
 #include "../include/list.h"
 #include "../include/queue.h"
@@ -136,6 +136,9 @@ static int message_handler_req_clm_nodegetasync (struct conn_info *conn_info,
 
 static int clm_exit_fn (struct conn_info *conn_info);
 
+/*
+ * Executive Handler Definition
+ */
 struct libais_handler clm_libais_handlers[] =
 {
 	{ /* 0 */
@@ -184,6 +187,11 @@ struct service_handler clm_service_handler = {
 	.sync_abort					= clm_sync_abort,
 };
 
+struct req_exec_clm_nodejoin {
+	struct req_header header;
+	SaClmClusterNodeT clusterNode;
+};
+
 static int clm_exec_init_fn (struct openais_config *openais_config)
 {
 	memset (clusterNodes, 0, sizeof (SaClmClusterNodeT) * NODE_MAX);

+ 2 - 1
exec/evs.c

@@ -51,7 +51,8 @@
 #include <arpa/inet.h>
 
 #include "../include/ais_types.h"
-#include "../include/ais_msg.h"
+#include "../include/ipc_gen.h"
+#include "../include/ipc_evs.h"
 #include "../include/list.h"
 #include "../include/queue.h"
 #include "aispoll.h"

+ 0 - 1
exec/main.c

@@ -57,7 +57,6 @@
 #include <time.h>
 
 #include "../include/ais_types.h"
-#include "../include/ais_msg.h"
 #include "../include/list.h"
 #include "../include/queue.h"
 #include "poll.h"

+ 34 - 0
exec/main.h

@@ -36,6 +36,7 @@
 #define FALSE 0
 #include <sys/un.h>
 #include "../include/ais_types.h"
+#include "../include/queue.h"
 #include "poll.h"
 #include "evs.h"
 #include "clm.h"
@@ -108,6 +109,39 @@ struct conn_info {
 	int should_exit_fn;			/* Should call the exit function when closing this ipc */
 };
 
+
+enum nodeexec_message_types {
+	MESSAGE_REQ_EXEC_SYNC_BARRIER = 0,
+	MESSAGE_REQ_EXEC_EVS_MCAST = 1,
+	MESSAGE_REQ_EXEC_CLM_NODEJOIN = 2,
+	MESSAGE_REQ_EXEC_AMF_COMPONENTREGISTER = 3,
+	MESSAGE_REQ_EXEC_AMF_COMPONENTUNREGISTER = 4,
+	MESSAGE_REQ_EXEC_AMF_ERRORREPORT = 5,
+	MESSAGE_REQ_EXEC_AMF_ERRORCANCELALL = 6,
+	MESSAGE_REQ_EXEC_AMF_READINESSSTATESET = 7,
+	MESSAGE_REQ_EXEC_AMF_HASTATESET = 8,
+	MESSAGE_REQ_EXEC_CKPT_CHECKPOINTOPEN = 9,
+	MESSAGE_REQ_EXEC_CKPT_CHECKPOINTCLOSE = 10,
+	MESSAGE_REQ_EXEC_CKPT_CHECKPOINTUNLINK = 11,
+	MESSAGE_REQ_EXEC_CKPT_CHECKPOINTRETENTIONDURATIONSET = 12,
+	MESSAGE_REQ_EXEC_CKPT_CHECKPOINTRETENTIONDURATIONEXPIRE = 13,
+	MESSAGE_REQ_EXEC_CKPT_SECTIONCREATE = 14,
+	MESSAGE_REQ_EXEC_CKPT_SECTIONDELETE = 15,
+	MESSAGE_REQ_EXEC_CKPT_SECTIONEXPIRATIONTIMESET = 16,
+	MESSAGE_REQ_EXEC_CKPT_SECTIONWRITE = 17,
+	MESSAGE_REQ_EXEC_CKPT_SECTIONOVERWRITE = 18,
+	MESSAGE_REQ_EXEC_CKPT_SECTIONREAD = 19,
+	MESSAGE_REQ_EXEC_CKPT_SYNCHRONIZESTATE = 20,
+	MESSAGE_REQ_EXEC_CKPT_SYNCHRONIZESECTION = 21,
+	MESSAGE_REQ_EXEC_EVT_EVENTDATA = 22,
+	MESSAGE_REQ_EXEC_EVT_CHANCMD = 23,
+	MESSAGE_REQ_EXEC_EVT_RECOVERY_EVENTDATA = 24
+};
+
+struct message_source {
+    struct conn_info *conn_info;
+    struct in_addr in_addr;
+} __attribute__((packed));
 extern struct sockaddr_in *this_ip;
 
 poll_handle aisexec_poll_handle;

+ 1 - 1
exec/sync.c

@@ -50,7 +50,7 @@
 #include <arpa/inet.h>
 
 #include "../include/ais_types.h"
-#include "../include/ipc_gen.h"
+#include "main.h"
 #include "sync.h"
 #include "totempg.h"
 #include "print.h"

+ 1 - 0
exec/totem.h

@@ -34,6 +34,7 @@
 #ifndef TOTEM_H_DEFINED
 #define TOTEM_H_DEFINED
 
+#define MESSAGE_SIZE_MAX			256000
 #define PROCESSOR_COUNT_MAX			16
 
 enum totem_configuration_type {

+ 1 - 2
exec/totempg.h

@@ -39,8 +39,7 @@
 #include "aispoll.h"
 #include "totemsrp.h"
 #include "parse.h"
-
-#define MESSAGE_SIZE_MAX		256000
+#include "totem.h"
 
 #define TOTEMPG_AGREED			0
 #define TOTEMPG_SAFE			1

+ 5 - 196
include/ais_msg.h → include/ipc_amf.h

@@ -31,14 +31,13 @@
  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
  * THE POSSIBILITY OF SUCH DAMAGE.
  */
-#ifndef AIS_MSG_H_DEFINED
-#define AIS_MSG_H_DEFINED
+#ifndef AIS_IPC_AMF_H_DEFINED
+#define AIS_IPC_AMF_H_DEFINED
 
 #include <netinet/in.h>
-#include "ais_types.h"
-#include "evs.h"
-#include "saClm.h"
 #include "ipc_gen.h"
+#include "ais_types.h"
+#include "ais_amf.h"
 
 enum req_amf_response_interfaces {
 	MESSAGE_REQ_AMF_RESPONSE_SAAMFHEALTHCHECKCALLBACK = 1,
@@ -51,24 +50,6 @@ enum req_amf_response_interfaces {
 	MESSAGE_REQ_AMF_RESPONSE_SAAMFPENDINGOPERATIONCONFIRMCALLBACK
 };
 
-enum req_lib_evs_types {
-	MESSAGE_REQ_EVS_JOIN = 0,
-	MESSAGE_REQ_EVS_LEAVE = 1,
-	MESSAGE_REQ_EVS_MCAST_JOINED = 2,
-	MESSAGE_REQ_EVS_MCAST_GROUPS = 3,
-	MESSAGE_REQ_EVS_MEMBERSHIP_GET = 4
-};
-
-enum res_lib_evs_types {
-	MESSAGE_RES_EVS_DELIVER_CALLBACK = 0,
-	MESSAGE_RES_EVS_CONFCHG_CALLBACK = 1,
-	MESSAGE_RES_EVS_JOIN = 2,
-	MESSAGE_RES_EVS_LEAVE = 3,
-	MESSAGE_RES_EVS_MCAST_JOINED = 4,
-	MESSAGE_RES_EVS_MCAST_GROUPS = 5,
-	MESSAGE_RES_EVS_MEMBERSHIP_GET = 6
-};
-
 enum req_amf_types {
 	MESSAGE_REQ_AMF_COMPONENTREGISTER = 0,
 	MESSAGE_REQ_AMF_COMPONENTUNREGISTER,
@@ -103,146 +84,12 @@ enum res_lib_amf_types {
 	MESSAGE_RES_AMF_RESPONSE
 };
 
-struct res_evs_deliver_callback {
-	struct res_header header;
-	struct in_addr source_addr;
-	int msglen;
-	char msg[0];
-};
-
-struct res_evs_confchg_callback {
-	struct res_header header;
-	int member_list_entries;
-	int left_list_entries;
-	int joined_list_entries;
-	struct in_addr member_list[16];
-	struct in_addr left_list[16];
-	struct in_addr joined_list[16];
-};
-
-struct req_lib_evs_join {
-	struct res_header header;
-	int group_entries;
-	struct evs_group groups[0];
-};
-
-struct res_lib_evs_join {
-	struct res_header header;
-};
-
-struct req_lib_evs_leave {
-	struct res_header header;
-	int group_entries;
-	struct evs_group groups[0];
-};
-
-struct res_lib_evs_leave {
-	struct res_header header;
-};
-
-struct req_lib_evs_mcast_joined {
-	struct res_header header;
-	evs_guarantee_t guarantee;
-	int msg_len;
-	char msg[0];
-};
-
-struct res_lib_evs_mcast_joined {
-	struct res_header header;
-};
-
-struct req_lib_evs_mcast_groups {
-	struct res_header header;
-	evs_guarantee_t guarantee;
-	int msg_len;
-	int group_entries;
-	struct evs_group groups[0];
-};
-
-struct res_lib_evs_mcast_groups {
-	struct res_header header;
-};
-
-
-struct req_exec_evs_mcast {
-	struct req_header header;
-	int group_entries;
-	int msg_len;
-	struct evs_group groups[0];
-	/* data goes here */
-};
-
-struct req_lib_evs_membership_get {
-	struct req_header header;
-};
-
-struct res_lib_evs_membership_get {
-	struct res_header header;
-	struct in_addr local_addr;
-	struct in_addr member_list[16];
-	int member_list_entries;
-};
-
-struct req_lib_resdis_init {
-	int size;
-	int id;
-	int service;
-};
-
-// TODO REMOVE THIS
-enum req_init_types_a {
-    MESSAGE_REQ_EVS_INIT,
-    MESSAGE_REQ_CLM_INIT,
-    MESSAGE_REQ_AMF_INIT,
-    MESSAGE_REQ_CKPT_INIT,
-    MESSAGE_REQ_CKPT_CHECKPOINT_INIT,
-    MESSAGE_REQ_CKPT_SECTIONITERATOR_INIT,
-    MESSAGE_REQ_EVT_INIT
-};
-
-struct req_lib_response_init {
-	struct req_lib_resdis_init resdis_header;
-};
-
-struct req_lib_dispatch_init {
-	struct req_lib_resdis_init resdis_header;
-	unsigned long conn_info;
-};
-
-	
-struct req_lib_init {
-	struct res_header header;
-};
-
-struct res_lib_init {
-	struct res_header header;
-};
-
-struct res_lib_response_init {
-	struct res_header header;
-	unsigned long conn_info;
-};
-
-struct res_lib_dispatch_init {
-	struct res_header header;
-};
-
 struct req_lib_amf_componentregister {
 	struct req_header header;
 	SaNameT compName;
 	SaNameT proxyCompName;
 } __attribute__((packed));
 
-struct req_exec_amf_componentregister {
-	struct req_header header;
-	struct message_source source;
-	struct req_lib_amf_componentregister req_lib_amf_componentregister;
-	SaAmfReadinessStateT currentReadinessState;
-	SaAmfReadinessStateT newReadinessState;
-	SaAmfHAStateT currentHAState;
-	SaAmfHAStateT newHAState;
-} __attribute__((packed));
-
 struct res_lib_amf_componentregister {
 	struct res_header header;
 };
@@ -253,12 +100,6 @@ struct req_lib_amf_componentunregister {
 	SaNameT proxyCompName;
 };
 
-struct req_exec_amf_componentunregister {
-	struct req_header header;
-	struct message_source source;
-	struct req_lib_amf_componentunregister req_lib_amf_componentunregister;
-};
-
 struct res_lib_amf_componentunregister {
 	struct res_header header;
 };
@@ -288,18 +129,6 @@ struct res_lib_amf_readinessstatesetcallback {
 	SaAmfReadinessStateT readinessState;
 };
 
-struct req_exec_amf_readinessstateset {
-	struct req_header header;
-	SaNameT compName;
-	SaAmfReadinessStateT readinessState;
-};
-
-struct req_exec_amf_hastateset {
-	struct req_header header;
-	SaNameT compName;
-	SaAmfHAStateT haState;
-};
-
 struct res_lib_amf_componentterminatecallback {
 	struct res_header header;
 	SaInvocationT invocation;
@@ -377,12 +206,6 @@ struct req_lib_amf_errorreport {
 	SaAmfAdditionalDataT additionalData;
 };
 
-struct req_exec_amf_errorreport {
-	struct req_header header;
-	struct message_source source;
-	struct req_lib_amf_errorreport req_lib_amf_errorreport;
-};
-
 struct res_lib_amf_errorreport {
 	struct res_header header;
 };
@@ -392,12 +215,6 @@ struct req_lib_amf_errorcancelall {
 	SaNameT compName;
 };
 
-struct req_exec_amf_errorcancelall {
-	struct req_header header;
-	struct message_source source;
-	struct req_lib_amf_errorcancelall req_lib_amf_errorcancelall;
-};
-	
 struct res_lib_amf_errorcancelall {
 	struct res_header header;
 };
@@ -432,12 +249,4 @@ struct res_lib_amf_componentcapabilitymodelget {
 	SaAmfComponentCapabilityModelT componentCapabilityModel;
 };
 
-struct req_lib_activatepoll {
-	struct req_header header;
-};
-
-struct res_lib_activatepoll {
-	struct res_header header;
-};
-
-#endif /* AIS_MSG_H_DEFINED */
+#endif /* AIS_IPC_AMF_H_DEFINED */

+ 3 - 102
include/ipc_ckpt.h

@@ -34,11 +34,9 @@
 #ifndef IPC_CKPT_H_DEFINED
 #define IPC_CKPT_H_DEFINED
 
-#include "../include/ipc_gen.h"
-#include "../include/ais_types.h"
-#include "../include/saCkpt.h"
-#include "../exec/totemsrp.h"
-#include "../exec/ckpt.h"
+#include "ais_types.h"
+#include "saCkpt.h"
+#include "ipc_gen.h"
 
 enum req_lib_ckpt_checkpoint_types {
 	MESSAGE_REQ_CKPT_CHECKPOINT_CHECKPOINTOPEN = 0,
@@ -80,24 +78,6 @@ enum res_lib_ckpt_checkpoint_types {
 	MESSAGE_RES_CKPT_SECTIONITERATOR_SECTIONITERATORNEXT = 16
 };
 
-struct req_exec_ckpt_checkpointclose {
-	struct req_header header;
-	struct message_source source;
-	SaNameT checkpointName;
-};
-
-struct req_exec_ckpt_checkpointretentiondurationset {
-	struct req_header header;
-	struct message_source source;
-	SaNameT checkpointName;
-	SaTimeT retentionDuration;
-};
-
-struct req_exec_ckpt_checkpointretentiondurationexpire {
-	struct req_header header;
-	SaNameT checkpointName;
-};
-
 struct req_lib_ckpt_checkpointopen {
 	struct req_header header;
 	SaNameT checkpointName;
@@ -110,17 +90,6 @@ struct res_lib_ckpt_checkpointopen {
 	struct res_header header;
 };
 
-struct req_exec_ckpt_checkpointopen {
-	struct req_header header;
-	struct message_source source;
-	struct req_lib_ckpt_checkpointopen req_lib_ckpt_checkpointopen;
-	SaCkptCheckpointHandleT checkpointHandle;
-	SaInvocationT invocation;
-	int async_call;
-	SaAisErrorT fail_with_error;
-};
-
-
 struct req_lib_ckpt_checkpointopenasync {
 	struct req_header header;
 	SaNameT checkpointName;
@@ -156,12 +125,6 @@ struct res_lib_ckpt_checkpointunlink {
 	struct res_header header;
 };
 
-struct req_exec_ckpt_checkpointunlink {
-	struct req_header header;
-	struct message_source source;
-	struct req_lib_ckpt_checkpointunlink req_lib_ckpt_checkpointunlink;
-};
-
 struct req_lib_ckpt_checkpointretentiondurationset {
 	struct req_header header;
 	SaNameT checkpointName;
@@ -202,13 +165,6 @@ struct res_lib_ckpt_sectioncreate {
 	struct res_header header;
 };
 
-struct req_exec_ckpt_sectioncreate {
-	struct req_header header;
-	struct message_source source;
-	SaNameT checkpointName;
-	struct req_lib_ckpt_sectioncreate req_lib_ckpt_sectioncreate; /* this must be last */
-};
-
 struct req_lib_ckpt_sectiondelete {
 	struct req_header header;
 	SaNameT checkpointName;
@@ -218,12 +174,6 @@ struct req_lib_ckpt_sectiondelete {
 struct res_lib_ckpt_sectiondelete {
 	struct res_header header;
 };
-struct req_exec_ckpt_sectiondelete {
-	struct req_header header;
-	struct message_source source;
-	SaNameT checkpointName;
-	struct req_lib_ckpt_sectiondelete req_lib_ckpt_sectiondelete; /* this must be last */
-};
 
 struct req_lib_ckpt_sectionexpirationtimeset {
 	struct req_header header;
@@ -236,13 +186,6 @@ struct res_lib_ckpt_sectionexpirationtimeset {
 	struct res_header header;
 };
 
-struct req_exec_ckpt_sectionexpirationtimeset {
-	struct req_header header;
-	struct message_source source;
-	SaNameT checkpointName;
-	struct req_lib_ckpt_sectionexpirationtimeset req_lib_ckpt_sectionexpirationtimeset;
-};
-
 struct req_lib_ckpt_sectioniteratorinitialize {
 	struct req_header header;
 	SaNameT checkpointName;
@@ -275,13 +218,6 @@ struct res_lib_ckpt_sectionwrite {
 	struct res_header header;
 };
 
-struct req_exec_ckpt_sectionwrite {
-	struct req_header header;
-	struct message_source source;
-	SaNameT checkpointName;
-	struct req_lib_ckpt_sectionwrite req_lib_ckpt_sectionwrite;
-};
-
 struct req_lib_ckpt_sectionoverwrite {
 	struct req_header header;
 	SaNameT checkpointName;
@@ -293,13 +229,6 @@ struct res_lib_ckpt_sectionoverwrite {
 	struct res_header header;
 };
 	
-struct req_exec_ckpt_sectionoverwrite {
-	struct req_header header;
-	struct message_source source;
-	SaNameT checkpointName;
-	struct req_lib_ckpt_sectionoverwrite req_lib_ckpt_sectionoverwrite;
-};
-
 struct req_lib_ckpt_sectionread {
 	struct req_header header;
 	SaNameT checkpointName;
@@ -313,13 +242,6 @@ struct res_lib_ckpt_sectionread {
 	SaSizeT dataRead;
 };
 
-struct req_exec_ckpt_sectionread {
-	struct req_header header;
-	struct message_source source;
-	SaNameT checkpointName;
-	struct req_lib_ckpt_sectionread req_lib_ckpt_sectionread;
-};
-
 struct req_lib_ckpt_checkpointsynchronize {
 	struct req_header header;
 };
@@ -337,25 +259,4 @@ struct res_lib_ckpt_checkpointsynchronizeasync {
 	struct res_header header;
 };
 
-struct req_exec_ckpt_synchronize_state {
-	struct req_header header;
-	struct memb_ring_id previous_ring_id;
-	SaNameT checkpointName;
-	SaCkptCheckpointCreationAttributesT checkpointCreationAttributes;
-	SaCkptSectionDescriptorT sectionDescriptor;	
-	struct in_addr source_addr;
-	struct ckpt_refcnt ckpt_refcount[PROCESSOR_COUNT_MAX];
-};
-
-struct req_exec_ckpt_synchronize_section {
-	struct req_header header;
-	struct memb_ring_id previous_ring_id;
-	SaNameT checkpointName;
-	SaCkptSectionIdT sectionId;	
-	SaUint32T dataOffSet;
-	SaUint32T dataSize;	
-};
-
-
-
 #endif /* IPC_CKPT_H_DEFINED */

+ 0 - 5
include/ipc_clm.h

@@ -110,9 +110,4 @@ struct res_clm_nodegetcallback {
 	SaClmClusterNodeT clusterNode;
 };
 
-struct req_exec_clm_nodejoin {
-	struct req_header header;
-	SaClmClusterNodeT clusterNode;
-};
-
 #endif /* IPC_CLM_H_DEFINED */

+ 139 - 0
include/ipc_evs.h

@@ -0,0 +1,139 @@
+/*
+ * Copyright (c) 2002-2004 MontaVista Software, Inc.
+ *
+ * All rights reserved.
+ *
+ * Author: Steven Dake (sdake@mvista.com)
+ *
+ * This software licensed under BSD license, the text of which follows:
+ * 
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *
+ * - Redistributions of source code must retain the above copyright notice,
+ *   this list of conditions and the following disclaimer.
+ * - Redistributions in binary form must reproduce the above copyright notice,
+ *   this list of conditions and the following disclaimer in the documentation
+ *   and/or other materials provided with the distribution.
+ * - Neither the name of the MontaVista Software, Inc. nor the names of its
+ *   contributors may be used to endorse or promote products derived from this
+ *   software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+#ifndef IPC_EVS_H_DEFINED
+#define IPC_EVS_H_DEFINED
+
+#include <netinet/in.h>
+#include "ais_types.h"
+#include "evs.h"
+#include "ipc_gen.h"
+
+enum req_lib_evs_types {
+	MESSAGE_REQ_EVS_JOIN = 0,
+	MESSAGE_REQ_EVS_LEAVE = 1,
+	MESSAGE_REQ_EVS_MCAST_JOINED = 2,
+	MESSAGE_REQ_EVS_MCAST_GROUPS = 3,
+	MESSAGE_REQ_EVS_MEMBERSHIP_GET = 4
+};
+
+enum res_lib_evs_types {
+	MESSAGE_RES_EVS_DELIVER_CALLBACK = 0,
+	MESSAGE_RES_EVS_CONFCHG_CALLBACK = 1,
+	MESSAGE_RES_EVS_JOIN = 2,
+	MESSAGE_RES_EVS_LEAVE = 3,
+	MESSAGE_RES_EVS_MCAST_JOINED = 4,
+	MESSAGE_RES_EVS_MCAST_GROUPS = 5,
+	MESSAGE_RES_EVS_MEMBERSHIP_GET = 6
+};
+
+struct res_evs_deliver_callback {
+	struct res_header header;
+	struct in_addr source_addr;
+	int msglen;
+	char msg[0];
+};
+
+struct res_evs_confchg_callback {
+	struct res_header header;
+	int member_list_entries;
+	int left_list_entries;
+	int joined_list_entries;
+	struct in_addr member_list[16];
+	struct in_addr left_list[16];
+	struct in_addr joined_list[16];
+};
+
+struct req_lib_evs_join {
+	struct res_header header;
+	int group_entries;
+	struct evs_group groups[0];
+};
+
+struct res_lib_evs_join {
+	struct res_header header;
+};
+
+struct req_lib_evs_leave {
+	struct res_header header;
+	int group_entries;
+	struct evs_group groups[0];
+};
+
+struct res_lib_evs_leave {
+	struct res_header header;
+};
+
+struct req_lib_evs_mcast_joined {
+	struct res_header header;
+	evs_guarantee_t guarantee;
+	int msg_len;
+	char msg[0];
+};
+
+struct res_lib_evs_mcast_joined {
+	struct res_header header;
+};
+
+struct req_lib_evs_mcast_groups {
+	struct res_header header;
+	evs_guarantee_t guarantee;
+	int msg_len;
+	int group_entries;
+	struct evs_group groups[0];
+};
+
+struct res_lib_evs_mcast_groups {
+	struct res_header header;
+};
+
+
+struct req_exec_evs_mcast {
+	struct req_header header;
+	int group_entries;
+	int msg_len;
+	struct evs_group groups[0];
+	/* data goes here */
+};
+
+struct req_lib_evs_membership_get {
+	struct req_header header;
+};
+
+struct res_lib_evs_membership_get {
+	struct res_header header;
+	struct in_addr local_addr;
+	struct in_addr member_list[16];
+	int member_list_entries;
+};
+#endif /* IPC_EVS_H_DEFINED */

+ 45 - 33
include/ipc_gen.h

@@ -51,34 +51,6 @@ enum res_init_types {
 	MESSAGE_RES_INIT
 };
 
-enum nodeexec_message_types {
-		MESSAGE_REQ_EXEC_SYNC_BARRIER = 0,
-		MESSAGE_REQ_EXEC_EVS_MCAST = 1,
-		MESSAGE_REQ_EXEC_CLM_NODEJOIN = 2,
-		MESSAGE_REQ_EXEC_AMF_COMPONENTREGISTER = 3,
-		MESSAGE_REQ_EXEC_AMF_COMPONENTUNREGISTER = 4,
-		MESSAGE_REQ_EXEC_AMF_ERRORREPORT = 5,
-		MESSAGE_REQ_EXEC_AMF_ERRORCANCELALL = 6,
-		MESSAGE_REQ_EXEC_AMF_READINESSSTATESET = 7,
-		MESSAGE_REQ_EXEC_AMF_HASTATESET = 8,
-		MESSAGE_REQ_EXEC_CKPT_CHECKPOINTOPEN = 9,
-		MESSAGE_REQ_EXEC_CKPT_CHECKPOINTCLOSE = 10,
-		MESSAGE_REQ_EXEC_CKPT_CHECKPOINTUNLINK = 11,
-		MESSAGE_REQ_EXEC_CKPT_CHECKPOINTRETENTIONDURATIONSET = 12,
-		MESSAGE_REQ_EXEC_CKPT_CHECKPOINTRETENTIONDURATIONEXPIRE = 13,
-		MESSAGE_REQ_EXEC_CKPT_SECTIONCREATE = 14,
-		MESSAGE_REQ_EXEC_CKPT_SECTIONDELETE = 15,
-		MESSAGE_REQ_EXEC_CKPT_SECTIONEXPIRATIONTIMESET = 16,
-		MESSAGE_REQ_EXEC_CKPT_SECTIONWRITE = 17,
-		MESSAGE_REQ_EXEC_CKPT_SECTIONOVERWRITE = 18,
-		MESSAGE_REQ_EXEC_CKPT_SECTIONREAD = 19,
-		MESSAGE_REQ_EXEC_CKPT_SYNCHRONIZESTATE = 20,
-		MESSAGE_REQ_EXEC_CKPT_SYNCHRONIZESECTION = 21,
-		MESSAGE_REQ_EXEC_EVT_EVENTDATA = 22,
-		MESSAGE_REQ_EXEC_EVT_CHANCMD = 23,
-		MESSAGE_REQ_EXEC_EVT_RECOVERY_EVENTDATA = 24
-};
-
 struct req_header {
 	int size;
 	int id;
@@ -87,12 +59,52 @@ struct req_header {
 struct res_header {
 	int size;
 	int id;
-	SaErrorT error;
+	SaAisErrorT error;
 };
 
-struct message_source {
-    struct conn_info *conn_info;
-    struct in_addr in_addr;
-} __attribute__((packed));
+#ifdef CMPILE_OUT
+// TODO REMOVE THIS
+enum req_init_types_a {
+    MESSAGE_REQ_EVS_INIT,
+    MESSAGE_REQ_CLM_INIT,
+    MESSAGE_REQ_AMF_INIT,
+    MESSAGE_REQ_CKPT_INIT,
+    MESSAGE_REQ_CKPT_CHECKPOINT_INIT,
+    MESSAGE_REQ_CKPT_SECTIONITERATOR_INIT,
+    MESSAGE_REQ_EVT_INIT
+};
+#endif
+
+struct req_lib_resdis_init {
+	int size;
+	int id;
+	int service;
+};
+
+struct req_lib_response_init {
+	struct req_lib_resdis_init resdis_header;
+};
 
+struct req_lib_dispatch_init {
+	struct req_lib_resdis_init resdis_header;
+	unsigned long conn_info;
+};
+
+	
+struct req_lib_init {
+	struct res_header header;
+};
+
+struct res_lib_init {
+	struct res_header header;
+};
+
+struct res_lib_response_init {
+	struct res_header header;
+	unsigned long conn_info;
+};
+
+struct res_lib_dispatch_init {
+	struct res_header header;
+};
 #endif /* IPC_GEN_H_DEFINED */

+ 11 - 11
lib/Makefile

@@ -55,7 +55,7 @@ libSaClm.a: util.o clm.o
 	$(AR) -rc libSaClm.a util.o clm.o
 
 libSaClm.so.1.0: util.o clm.o
-	$(CC) -shared -Wl,-soname,libSaClm.so.1 util.o clm.o -o $@
+	$(CC) -shared -Wl,-soname,libSaClm.so.1,-version-script=libSaClm.versions util.o clm.o -o $@
 	rm -f libSaClm.so.1 libSaClm.so
 	ln -s libSaClm.so.1.0 libSaClm.so.1
 	ln -s libSaClm.so.1.0 libSaClm.so
@@ -64,7 +64,7 @@ libSaAmf.a: util.o amf.o
 	$(AR) -rc libSaAmf.a util.o amf.o
 
 libSaAmf.so.1.0: util.o amf.o
-	$(CC) -shared -Wl,-soname,libSaAmf.so.1 util.o amf.o -o $@
+	$(CC) -shared -Wl,-soname,libSaAmf.so.1,-version-script=libSaAmf.versions util.o amf.o -o $@
 	rm -f libSaAmf.so.1 libSaAmf.so
 	ln -s libSaAmf.so.1.0 libSaAmf.so.1
 	ln -s libSaAmf.so.1.0 libSaAmf.so
@@ -73,7 +73,7 @@ libSaCkpt.a: util.o ckpt.o
 	$(AR) -rc libSaCkpt.a util.o ckpt.o
 
 libSaCkpt.so.1.0: util.o ckpt.o
-	$(CC) -shared -Wl,-soname,libSaCkpt.so.1 util.o ckpt.o -o $@
+	$(CC) -shared -Wl,-soname,libSaCkpt.so.1,-version-script=libSaCkpt.versions util.o ckpt.o -o $@
 	rm -f libSaCkpt.so.1 libSaCkpt.so
 	ln -s libSaCkpt.so.1.0 libSaCkpt.so.1
 	ln -s libSaCkpt.so.1.0 libSaCkpt.so
@@ -82,7 +82,7 @@ libSaEvt.a: util.o evt.o
 	$(AR) -rc libSaEvt.a util.o evt.o
 
 libSaEvt.so.1.0: util.o evt.o
-	$(CC) -shared -Wl,-soname,libSaEvt.so.1 util.o evt.o -o $@
+	$(CC) -shared -Wl,-soname,libSaEvt.so.1,-version-script=libSaEvt.versions util.o evt.o -o $@
 	rm -f libSaEvt.so.1 libSaEvt.so
 	ln -s libSaEvt.so.1.0 libSaEvt.so.1
 	ln -s libSaEvt.so.1.0 libSaEvt.so
@@ -91,7 +91,7 @@ libais.a: util.o amf.o clm.o ckpt.o evt.o
 	$(AR) -rc libais.a util.o amf.o clm.o ckpt.o evt.o
 
 libais.so.1.0: util.o amf.o clm.o ckpt.o evt.o
-	$(CC) -shared -Wl,-soname,libais.so.1 util.o amf.o clm.o ckpt.o \
+	$(CC) -shared -Wl,-soname,libais.so.1,-version-script=libSaAis.versions util.o amf.o clm.o ckpt.o \
 								evt.o -o $@
 	rm -f libais.so.1 libais.so
 	ln -s libais.so.1.0 libais.so.1
@@ -101,7 +101,7 @@ libevs.a: util.o evs.o
 	$(AR) -rc libevs.a util.o evs.o
 
 libevs.so.1.0: util.o evs.o
-	$(CC) -shared -Wl,-soname,libevs.so.1 util.o evs.o -o $@
+	$(CC) -shared -Wl,-soname,libevs.so.1,-version-script=libevs.versions util.o evs.o -o $@
 	rm -f libevs.so.1 libevs.so
 	ln -s libevs.so.1.0 libevs.so.1
 	ln -s libevs.so.1.0 libevs.so
@@ -119,18 +119,18 @@ depend:
 	makedepend -Y -- $(CFLAGS) $(LIBAIS_SRC) > /dev/null 2>&1
 # DO NOT DELETE
 
-util.o: ../include/ais_types.h ../include/ais_msg.h ../include/ais_types.h
+util.o: ../include/ais_types.h ../include/ipc_evs.h ../include/ais_types.h
 util.o: ../include/evs.h ../include/saClm.h ../include/ipc_gen.h util.h
 amf.o: ../include/ais_types.h ../include/ais_amf.h ../include/ais_types.h
-amf.o: ../include/ais_msg.h ../include/evs.h ../include/saClm.h
+amf.o: ../include/ipc_evs.h ../include/evs.h ../include/saClm.h
 amf.o: ../include/ipc_gen.h util.h
 clm.o: ../include/ais_types.h ../include/saClm.h ../include/ais_types.h
-clm.o: ../include/ais_msg.h ../include/evs.h ../include/saClm.h
+clm.o: ../include/ipc_evs.h ../include/evs.h ../include/saClm.h
 clm.o: ../include/ipc_gen.h ../include/ipc_clm.h util.h
 ckpt.o: ../include/list.h ../include/ais_types.h ../include/saCkpt.h
-ckpt.o: ../include/ais_types.h ../include/ais_msg.h ../include/evs.h
+ckpt.o: ../include/ais_types.h ../include/ipc_evs.h ../include/evs.h
 ckpt.o: ../include/saClm.h ../include/ipc_gen.h util.h
 evt.o: ../include/ipc_evt.h ../include/ais_types.h ../include/saEvt.h
-evt.o: ../include/saClm.h ../include/ipc_gen.h util.h ../include/ais_msg.h
+evt.o: ../include/saClm.h ../include/ipc_gen.h util.h ../include/ipc_evs.h
 evt.o: ../include/evs.h ../exec/totempg.h ../exec/aispoll.h
 evt.o: ../exec/totemsrp.h

+ 7 - 6
lib/amf.c

@@ -47,7 +47,8 @@
 
 #include "../include/ais_types.h"
 #include "../include/ais_amf.h"
-#include "../include/ais_msg.h"
+#include "../include/ipc_gen.h"
+#include "../include/ipc_amf.h"
 #include "util.h"
 
 struct res_overlay {
@@ -576,7 +577,7 @@ saAmfStoppingComplete (
 	int fd;
 	SaErrorT errorResult;
 
-	errorResult = saServiceConnect (&fd, MESSAGE_REQ_AMF_INIT);
+	errorResult = saServiceConnect (&fd, AMF_SERVICE);
 	if (errorResult != SA_OK) {
 		goto exit_noclose;
 	}
@@ -610,7 +611,7 @@ saAmfHAStateGet (
 	int fd;
 	SaErrorT error;
 
-	error = saServiceConnect (&fd, MESSAGE_REQ_AMF_INIT);
+	error = saServiceConnect (&fd, AMF_SERVICE);
 	if (error != SA_OK) {
 		goto exit_noclose;
 	}
@@ -732,7 +733,7 @@ saAmfErrorReport (
 	int fd;
 	SaErrorT error;
 
-	error = saServiceConnect (&fd, MESSAGE_REQ_AMF_INIT);
+	error = saServiceConnect (&fd, AMF_SERVICE);
 	if (error != SA_OK) {
 		goto exit_noclose;
 	}
@@ -772,7 +773,7 @@ saAmfErrorCancelAll (
 	int fd;
 	SaErrorT error;
 
-	error = saServiceConnect (&fd, MESSAGE_REQ_AMF_INIT);
+	error = saServiceConnect (&fd, AMF_SERVICE);
 	if (error != SA_OK) {
 		goto exit_noclose;
 	}
@@ -806,7 +807,7 @@ saAmfComponentCapabilityModelGet (
 	struct req_amf_componentcapabilitymodelget req_amf_componentcapabilitymodelget;
 	struct res_lib_amf_componentcapabilitymodelget res_lib_amf_componentcapabilitymodelget;
 
-	error = saServiceConnect (&fd, MESSAGE_REQ_AMF_INIT);
+	error = saServiceConnect (&fd, AMF_SERVICE);
 	if (error != SA_OK) {
 		goto exit_noclose;
 	}

+ 3 - 2
lib/ckpt.c

@@ -45,13 +45,14 @@
 #include <sys/select.h>
 #include <sys/un.h>
 
-#include "util.h"
-
+#include "../include/ais_types.h"
 #include "../include/list.h"
 #include "../include/saCkpt.h"
 #include "../include/ipc_gen.h"
 #include "../include/ipc_ckpt.h"
 
+#include "util.h"
+
 struct message_overlay {
 	struct res_header header;
 	char data[4096];

+ 1 - 1
lib/clm.c

@@ -46,7 +46,7 @@
 
 #include "../include/ais_types.h"
 #include "../include/saClm.h"
-#include "../include/ais_msg.h"
+#include "../include/ipc_gen.h"
 #include "../include/ipc_clm.h"
 
 #include "util.h"

+ 2 - 2
lib/evs.c

@@ -44,11 +44,11 @@
 #include <sys/types.h>
 #include <sys/socket.h>
 #include <errno.h>
-#include "util.h"
 
-#include "../include/ais_msg.h"
 #include "../include/ais_types.h"
 #include "../include/evs.h"
+#include "../include/ipc_evs.h"
+#include "util.h"
 
 struct evs_inst {
 	int response_fd;

+ 1 - 1
lib/evt.c

@@ -41,7 +41,7 @@
 #include <sys/socket.h>
 #include "../include/ipc_evt.h"
 #include "util.h"
-#include "../exec/totempg.h"
+#include "../exec/totem.h"
 #include "../include/list.h"
 
 static void evtHandleInstanceDestructor(void *instance);

+ 180 - 0
lib/libSaAis.versions

@@ -0,0 +1,180 @@
+# Version and symbol export for libSaClm.so
+
+OPENAIS_CLM_B.01.01 {
+	global:
+		saClmInitialize;
+		saClmSelectionObjectGet;
+		saClmDispatch;
+		saClmFinalize;
+		saClmClusterTrack;
+		saClmClusterTrackStop;
+		saClmClusterNodeGet;
+		saClmClusterNodeGetAsync;
+
+	local:
+		saHandleCreate;
+		saHandleDestroy;
+		saHandleInstanceGet;
+		saHandleInstancePut;
+		saPollRetry;
+		saQueueInit;
+		saQueueIsEmpty;
+		saQueueIsFull;
+		saQueueItemAdd;
+		saQueueItemGet;
+		saQueueItemRemove;
+		saRecvRetry;
+		saSelectRetry;
+		saSendMsgReceiveReply;
+		saSendMsgRetry;
+		saSendReceiveReply;
+		saSendRetry;
+		saServiceConnect;
+		saServiceConnectTwo;
+		saVersionVerify;
+		clustTimeNow;
+};
+
+# Version and symbol export for libSaClm.so
+
+OPENAIS_AMF_A.01.01 {
+	global:
+		saAmfInitialize;
+		saAmfSelectionObjectGet;
+		saAmfDispatch;
+		saAmfFinalize;
+		saAmfComponentRegister;
+		saAmfComponentUnregister;
+		saAmfCompNameGet;
+		saAmfReadinessStateGet;
+		saAmfStoppingComplete;
+		saAmfHAStateGet;
+		saAmfProtectionGroupTrackStart;
+		saAmfProtectionGroupTrackStop;
+		saAmfErrorReport;
+		saAmfErrorCancelAll;
+		saAmfComponentCapabilityModelGet;
+		saAmfPendingOperationGet;
+		saAmfResponse;
+
+	local:
+		saHandleCreate;
+		saHandleDestroy;
+		saHandleInstanceGet;
+		saHandleInstancePut;
+		saPollRetry;
+		saQueueInit;
+		saQueueIsEmpty;
+		saQueueIsFull;
+		saQueueItemAdd;
+		saQueueItemGet;
+		saQueueItemRemove;
+		saRecvRetry;
+		saSelectRetry;
+		saSendMsgReceiveReply;
+		saSendMsgRetry;
+		saSendReceiveReply;
+		saSendRetry;
+		saServiceConnect;
+		saServiceConnectTwo;
+		saVersionVerify;
+		clustTimeNow;
+};
+
+# Version and symbol export for libSaCkpt.so
+
+OPENAIS_CKPT_B.01.01 {
+	global:
+		saCkptInitialize;
+		saCkptSelectionObjectGet;
+		saCkptDispatch;
+		saCkptFinalize;
+		saCkptCheckpointOpen;
+		saCkptCheckpointOpenAsync;
+		saCkptCheckpointClose;
+		saCkptCheckpointUnlink;
+		saCkptCheckpointRetentionDurationSet;
+		saCkptActiveReplicaSet;
+		saCkptCheckpointStatusGet;
+		saCkptSectionCreate;
+		saCkptSectionDelete;
+		saCkptSectionExpirationTimeSet;
+		saCkptSectionIterationInitialize;
+		saCkptSectionIterationNext;
+		saCkptSectionIterationFinalize;
+		saCkptCheckpointWrite;
+		saCkptCheckpointOverwrite;
+		saCkptCheckpointRead;
+		saCkptCheckpointSynchronize;
+		saCkptCheckpointSynchronizeAsync;
+		
+	local:
+		saHandleCreate;
+		saHandleDestroy;
+		saHandleInstanceGet;
+		saHandleInstancePut;
+		saPollRetry;
+		saQueueInit;
+		saQueueIsEmpty;
+		saQueueIsFull;
+		saQueueItemAdd;
+		saQueueItemGet;
+		saQueueItemRemove;
+		saRecvRetry;
+		saSelectRetry;
+		saSendMsgReceiveReply;
+		saSendMsgRetry;
+		saSendReceiveReply;
+		saSendRetry;
+		saServiceConnect;
+		saServiceConnectTwo;
+		saVersionVerify;
+		clustTimeNow;
+};
+
+# Version and symbol export for libSaClm.so
+
+OPENAIS_EVT_B.01.01 {
+	global:
+		
+		saEvtInitialize;
+		saEvtSelectionObjectGet;
+		saEvtDispatch;
+		saEvtFinalize;
+		saEvtChannelOpen;
+		saEvtChannelClose;
+		saEvtChannelOpenAsync;
+		saEvtChannelUnlink;
+		saEvtChannelAllocate;
+		saEvtEventFree;
+		saEvtEventAttributesSet;
+		saEvtEventAttributesGet;
+		saEvtEventDataGet;
+		saEvtEventPublish;
+		saEvtEventSubscribe;
+		saEvtEventUnsubscribe;
+		saEvtEventRetentionTimeClear;
+
+	local:
+		saHandleCreate;
+		saHandleDestroy;
+		saHandleInstanceGet;
+		saHandleInstancePut;
+		saPollRetry;
+		saQueueInit;
+		saQueueIsEmpty;
+		saQueueIsFull;
+		saQueueItemAdd;
+		saQueueItemGet;
+		saQueueItemRemove;
+		saRecvRetry;
+		saSelectRetry;
+		saSendMsgReceiveReply;
+		saSendMsgRetry;
+		saSendReceiveReply;
+		saSendRetry;
+		saServiceConnect;
+		saServiceConnectTwo;
+		saVersionVerify;
+		clustTimeNow;
+};

+ 38 - 0
lib/libSaAmf.versions

@@ -0,0 +1,38 @@
+# Version and symbol export for libSaClm.so
+
+OPENAIS_AMF_A.01.01 {
+	global:
+		saAmfInitialize;
+		saAmfSelectionObjectGet;
+		saAmfDispatch;
+		saAmfFinalize;
+		saAmfComponentRegister;
+		saAmfComponentUnregister;
+		saAmfCompNameGet;
+		saAmfReadinessStateGet;
+		saAmfStoppingComplete;
+		saAmfHAStateGet;
+		saAmfProtectionGroupTrackStart;
+		saAmfProtectionGroupTrackStop;
+		saAmfErrorReport;
+		saAmfErrorCancelAll;
+		saAmfComponentCapabilityModelGet;
+		saAmfPendingOperationGet;
+		saAmfResponse;
+
+	local:
+		saHandleCreate;
+		saHandleDestroy;
+		saHandleInstanceGet;
+		saHandleInstancePut;
+		saPollRetry;
+		saRecvRetry;
+		saSendMsgReceiveReply;
+		saSendMsgRetry;
+		saSendReceiveReply;
+		saSendRetry;
+		saServiceConnect;
+		saServiceConnectTwo;
+		saVersionVerify;
+		clustTimeNow;
+};

+ 43 - 0
lib/libSaCkpt.versions

@@ -0,0 +1,43 @@
+# Version and symbol export for libSaCkpt.so
+
+OPENAIS_CKPT_B.01.01 {
+	global:
+		saCkptInitialize;
+		saCkptSelectionObjectGet;
+		saCkptDispatch;
+		saCkptFinalize;
+		saCkptCheckpointOpen;
+		saCkptCheckpointOpenAsync;
+		saCkptCheckpointClose;
+		saCkptCheckpointUnlink;
+		saCkptCheckpointRetentionDurationSet;
+		saCkptActiveReplicaSet;
+		saCkptCheckpointStatusGet;
+		saCkptSectionCreate;
+		saCkptSectionDelete;
+		saCkptSectionExpirationTimeSet;
+		saCkptSectionIterationInitialize;
+		saCkptSectionIterationNext;
+		saCkptSectionIterationFinalize;
+		saCkptCheckpointWrite;
+		saCkptCheckpointOverwrite;
+		saCkptCheckpointRead;
+		saCkptCheckpointSynchronize;
+		saCkptCheckpointSynchronizeAsync;
+		
+	local:
+		saHandleCreate;
+		saHandleDestroy;
+		saHandleInstanceGet;
+		saHandleInstancePut;
+		saPollRetry;
+		saRecvRetry;
+		saSendMsgReceiveReply;
+		saSendMsgRetry;
+		saSendReceiveReply;
+		saSendRetry;
+		saServiceConnect;
+		saServiceConnectTwo;
+		saVersionVerify;
+		clustTimeNow;
+};

+ 29 - 0
lib/libSaClm.versions

@@ -0,0 +1,29 @@
+# Version and symbol export for libSaClm.so
+
+OPENAIS_CLM_B.01.01 {
+	global:
+		saClmInitialize;
+		saClmSelectionObjectGet;
+		saClmDispatch;
+		saClmFinalize;
+		saClmClusterTrack;
+		saClmClusterTrackStop;
+		saClmClusterNodeGet;
+		saClmClusterNodeGetAsync;
+
+	local:
+		saHandleCreate;
+		saHandleDestroy;
+		saHandleInstanceGet;
+		saHandleInstancePut;
+		saPollRetry;
+		saRecvRetry;
+		saSendMsgReceiveReply;
+		saSendMsgRetry;
+		saSendReceiveReply;
+		saSendRetry;
+		saServiceConnect;
+		saServiceConnectTwo;
+		saVersionVerify;
+		clustTimeNow;
+};

+ 39 - 0
lib/libSaEvt.versions

@@ -0,0 +1,39 @@
+# Version and symbol export for libSaClm.so
+
+OPENAIS_EVT_B.01.01 {
+	global:
+		
+		saEvtInitialize;
+		saEvtSelectionObjectGet;
+		saEvtDispatch;
+		saEvtFinalize;
+		saEvtChannelOpen;
+		saEvtChannelClose;
+		saEvtChannelOpenAsync;
+		saEvtChannelUnlink;
+		saEvtChannelAllocate;
+		saEvtEventFree;
+		saEvtEventAttributesSet;
+		saEvtEventAttributesGet;
+		saEvtEventDataGet;
+		saEvtEventPublish;
+		saEvtEventSubscribe;
+		saEvtEventUnsubscribe;
+		saEvtEventRetentionTimeClear;
+
+	local:
+		saHandleCreate;
+		saHandleDestroy;
+		saHandleInstanceGet;
+		saHandleInstancePut;
+		saPollRetry;
+		saRecvRetry;
+		saSendMsgReceiveReply;
+		saSendMsgRetry;
+		saSendReceiveReply;
+		saSendRetry;
+		saServiceConnect;
+		saServiceConnectTwo;
+		saVersionVerify;
+		clustTimeNow;
+};

+ 30 - 0
lib/libevs.versions

@@ -0,0 +1,30 @@
+# Version and symbol export for libSaClm.so
+
+OPENAIS_EVS_1.0 {
+	global:
+		evs_initialize;
+		evs_finalize;
+		evs_fd_get;
+		evs_dispatch;
+		evs_join;
+		evs_leave;
+		evs_mcast_joined;
+		evs_mcast_groups;
+		evs_membership_get;
+
+	local:
+		saHandleCreate;
+		saHandleDestroy;
+		saHandleInstanceGet;
+		saHandleInstancePut;
+		saRecvRetry;
+		saSelectRetry;
+		saSendMsgReceiveReply;
+		saSendMsgRetry;
+		saSendReceiveReply;
+		saSendRetry;
+		saServiceConnect;
+		saServiceConnectTwo;
+		saVersionVerify;
+		clustTimeNow;
+};

+ 1 - 114
lib/util.c

@@ -51,7 +51,7 @@
 #include <assert.h>
 
 #include "../include/ais_types.h"
-#include "../include/ais_msg.h"
+#include "../include/ipc_gen.h"
 #include "util.h"
 
 enum SA_HANDLE_STATE {
@@ -397,29 +397,6 @@ error_exit:
 	return (error);
 }
 
-SaErrorT
-saSelectRetry (
-	int s,
-	fd_set *readfds,
-	fd_set *writefds,
-	fd_set *exceptfds,
-	struct timeval *timeout)
-{
-	SaErrorT error = SA_AIS_OK;
-	int result;
-
-retry_select:
-	result = select (s, readfds, writefds, exceptfds, timeout);
-	if (result == -1 && errno == EINTR) {
-		goto retry_select;
-	}
-	if (result == -1) {
-		error = SA_AIS_ERR_LIBRARY;
-	}
-
-	return (error);
-}
-
 SaErrorT
 saPollRetry (
         struct pollfd *ufds,
@@ -625,96 +602,6 @@ saVersionVerify (
 	return (error);
 }
 
-
-SaErrorT
-saQueueInit (
-	struct queue *queue,
-	int queueItems,
-	int bytesPerItem)
-{
-	queue->head = 0;
-	queue->tail = queueItems - 1;
-	queue->used = 0;
-	queue->usedhw = 0;
-	queue->size = queueItems;
-	queue->bytesPerItem = bytesPerItem;
-	queue->items = (void *)malloc (queueItems * bytesPerItem);
-	if (queue->items == 0) {
-		return (SA_AIS_ERR_NO_MEMORY);
-	}
-	memset (queue->items, 0, queueItems * bytesPerItem);
-	return (SA_AIS_OK);
-}
-
-SaErrorT
-saQueueIsFull (
-	struct queue *queue,
-	int *isFull)
-{
-	*isFull = ((queue->size - 1) == queue->used);
-	return (SA_AIS_OK);
-}
-
-
-SaErrorT
-saQueueIsEmpty (
-	struct queue *queue,
-	int *isEmpty)
-{
-	*isEmpty = (queue->used == 0);
-	return (SA_AIS_OK);
-}
-
-
-SaErrorT
-saQueueItemAdd (
-	struct queue *queue,
-	void *item)
-{
-	char *queueItem;
-	int queuePosition;
-
-	queuePosition = queue->head;
-	queueItem = queue->items;
-	queueItem += queuePosition * queue->bytesPerItem;
-	memcpy (queueItem, item, queue->bytesPerItem);
-
-	assert (queue->tail != queue->head);
-	if (queue->tail == queue->head) {
-		return (SA_AIS_ERR_LIBRARY);
-	}
-	queue->head = (queue->head + 1) % queue->size;
-	queue->used++;
-	if (queue->used > queue->usedhw) {
-		queue->usedhw = queue->used;
-	}
-	return (SA_AIS_OK);
-}
-
-SaErrorT
-saQueueItemGet (struct queue *queue, void **item)
-{
-	char *queueItem;
-	int queuePosition;
-
-	queuePosition = (queue->tail + 1) % queue->size;
-	queueItem = queue->items;
-	queueItem += queuePosition * queue->bytesPerItem;
-	*item = (void *)queueItem;
-	return (SA_AIS_OK);
-}
-
-SaErrorT
-saQueueItemRemove (struct queue *queue)
-{
-	queue->tail = (queue->tail + 1) % queue->size;
-	if (queue->tail == queue->head) {
-		return (SA_AIS_ERR_LIBRARY);
-	}
-	queue->used--;
-	return (SA_AIS_OK);
-}
-
 /*
  * Get the time of day and convert to nanoseconds
  */

+ 1 - 36
lib/util.h

@@ -38,7 +38,7 @@
 
 #include <pthread.h>
 #include <sys/poll.h>
-#include "../include/ais_msg.h"
+#include "../include/ipc_gen.h"
 
 struct saHandleDatabase {
 	unsigned int handleCount;
@@ -114,14 +114,6 @@ SaErrorT saSendReceiveReply (
 	void *responseMessage,
 	int responseLen);
 
-SaErrorT
-saSelectRetry (
-	int s,
-	fd_set *readfds,
-	fd_set *writefds,
-	fd_set *exceptfds,
-	struct timeval *timeout);
-
 SaErrorT
 saPollRetry (
 	struct pollfd *ufds,
@@ -155,33 +147,6 @@ saVersionVerify (
 	struct saVersionDatabase *versionDatabase,
 	SaVersionT *version);
 
-SaErrorT
-saQueueInit (
-	struct queue *queue,
-	int queueItems,
-	int sizePerItem);
-
-SaErrorT
-saQueueIsFull (
-	struct queue *queue,
-	int *isFull);
-
-SaErrorT
-saQueueIsEmpty (
-	struct queue *queue,
-	int *isEmpty);
-
-SaErrorT
-saQueueItemAdd (
-	struct queue *queue,
-	void *item);
-
-SaErrorT
-saQueueItemGet (struct queue *queue, void **item);
-
-SaErrorT
-saQueueItemRemove (struct queue *queue);
-
 #define offset_of(type,member) (int)(&(((type *)0)->member))
 
 SaTimeT

+ 6 - 4
test/Makefile

@@ -39,7 +39,8 @@
 CFLAGS = -c -g -Wall -DDEBUG -I../include
 CPPFLAGS = -c -g -Wall -DDEBUG -I../include
 LDFLAGS = -g -L../lib
-LIBRARIES= ../lib/libSaClm.a ../lib/libSaAmf.a ../lib/libSaCkpt.a ../lib/libSaEvt.a ../lib/libevs.a
+#LIBRARIES= /lib/libSaClm.a ../lib/libSaAmf.a ../lib/libSaCkpt.a ../lib/libSaEvt.a ../lib/libevs.a
+LIBRARIES= ../lib/libSaAmf.a ../lib/libSaCkpt.a ../lib/libSaEvt.a ../lib/libevs.a
 LIBS = $(LIBRARIES) -lpthread
 
 # Profile mode flags
@@ -104,7 +105,8 @@ evsbench: evsbench.o $(LIBS)
 	$(CC) $(LDFLAGS) -o evsbench evsbench.o $(LIBS)
 
 testclm: testclm.o $(LIBRARIES)
-	$(CC) $(LDFLAGS) -o testclm testclm.o $(LIBS)
+	$(CC) $(LDFLAGS) -o testclm testclm.o -lais
+# $(LIBS) -lSaClm
 
 testckpt: testckpt.o sa_error.o $(LIBRARIES)
 	$(CC) $(LDFLAGS) -o testckpt testckpt.o sa_error.o $(LIBS)
@@ -149,7 +151,7 @@ depend:
 # DO NOT DELETE
 
 testclm.o: ../include/ais_types.h ../include/saClm.h
-testamf.o: ../include/ais_types.h ../include/ais_amf.h ../include/ais_msg.h
+testamf.o: ../include/ais_types.h ../include/ais_amf.h ../include/ipc_evs.h
 testamf.o: ../include/evs.h ../include/saClm.h ../include/ipc_gen.h
 testamf1.o: ../include/ais_types.h ../include/ais_amf.h
 testamf2.o: ../include/ais_types.h ../include/ais_amf.h
@@ -157,7 +159,7 @@ testamf3.o: ../include/ais_types.h ../include/ais_amf.h
 testamf4.o: ../include/ais_types.h ../include/ais_amf.h
 testamf5.o: ../include/ais_types.h ../include/ais_amf.h
 testamf6.o: ../include/ais_types.h ../include/ais_amf.h
-testamfth.o: ../include/ais_types.h ../include/ais_amf.h ../include/ais_msg.h
+testamfth.o: ../include/ais_types.h ../include/ais_amf.h ../include/ipc_evs.h
 testamfth.o: ../include/evs.h ../include/saClm.h ../include/ipc_gen.h
 testckpt.o: ../include/ais_types.h ../include/saCkpt.h
 ckptstress.o: ../include/ais_types.h ../include/saCkpt.h

+ 1 - 1
test/testamf.c

@@ -43,7 +43,7 @@
 
 #include "ais_types.h"
 #include "ais_amf.h"
-#include "ais_msg.h"
+#include "saClm.h"
 
 void printSaClmNodeAddressT (SaClmNodeAddressT *nodeAddress) {
 	int i;

+ 1 - 1
test/testamfth.c

@@ -43,7 +43,7 @@
 
 #include "ais_types.h"
 #include "ais_amf.h"
-#include "ais_msg.h"
+#include "saClm.h"
 
 void printSaNameT (SaNameT *name)
 {