summaryrefslogtreecommitdiffstats
path: root/src/vlibmemory/socket_client.h
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2019-11-25 13:40:42 -0800
committerDave Barach <openvpp@barachs.net>2019-12-06 13:32:33 +0000
commit59cea1a9dff31ec9e735ea2764dbf958e95f6bd7 (patch)
tree4efa43c95b66e0d9722b27ab9ea6dd0eaf46340c /src/vlibmemory/socket_client.h
parentf1910326d537ad7692d4a9b807ebbef93106acea (diff)
api: multiple socket connections per single process
Type: feature Change-Id: Idea1857eb2225881d2982a7aa2ae7a79536b3f33 Signed-off-by: Florin Coras <fcoras@cisco.com>
Diffstat (limited to 'src/vlibmemory/socket_client.h')
-rw-r--r--src/vlibmemory/socket_client.h20
1 files changed, 19 insertions, 1 deletions
diff --git a/src/vlibmemory/socket_client.h b/src/vlibmemory/socket_client.h
index 68cd0f21994..231290088b3 100644
--- a/src/vlibmemory/socket_client.h
+++ b/src/vlibmemory/socket_client.h
@@ -51,14 +51,32 @@ extern socket_client_main_t socket_client_main;
int vl_socket_client_connect (char *socket_path, char *client_name,
u32 socket_buffer_size);
void vl_socket_client_disconnect (void);
+void vl_socket_client_enable_disable (int enable);
int vl_socket_client_read (int wait);
int vl_socket_client_write (void);
-void vl_socket_client_enable_disable (int enable);
void *vl_socket_client_msg_alloc (int nbytes);
int vl_socket_client_init_shm (vl_api_shm_elem_config_t * config,
int want_pthread);
clib_error_t *vl_socket_client_recv_fd_msg (int fds[], int n_fds, u32 wait);
+/*
+ * Socket client apis that explicitly pass socket main as an argument
+ */
+
+int vl_socket_client_connect2 (socket_client_main_t * scm, char *socket_path,
+ char *client_name, u32 socket_buffer_size);
+void vl_socket_client_disconnect2 (socket_client_main_t * scm);
+void vl_socket_client_enable_disable2 (socket_client_main_t * scm,
+ int enable);
+int vl_socket_client_read2 (socket_client_main_t * scm, int wait);
+int vl_socket_client_write2 (socket_client_main_t * scm);
+void *vl_socket_client_msg_alloc2 (socket_client_main_t * scm, int nbytes);
+int vl_socket_client_init_shm2 (socket_client_main_t * scm,
+ vl_api_shm_elem_config_t * config,
+ int want_pthread);
+clib_error_t *vl_socket_client_recv_fd_msg2 (socket_client_main_t * scm,
+ int fds[], int n_fds, u32 wait);
+
#endif /* SRC_VLIBMEMORY_SOCKET_CLIENT_H_ */
/*