summaryrefslogtreecommitdiffstats
path: root/kiro-server.h
diff options
context:
space:
mode:
authorTimo Dritschler <timo.dritschler@kit.edu>2014-05-09 18:20:11 +0200
committerTimo Dritschler <timo.dritschler@kit.edu>2014-05-09 18:20:11 +0200
commitb39079922bb4288dee30dfcb89a0fa0d20e81632 (patch)
treebb9dd4bc6ec302ce696661b7066ac825866cc43c /kiro-server.h
parent18ae33837ee1451dddf265198b51ef3483e2029b (diff)
downloadkiro-b39079922bb4288dee30dfcb89a0fa0d20e81632.tar.gz
kiro-b39079922bb4288dee30dfcb89a0fa0d20e81632.tar.bz2
kiro-b39079922bb4288dee30dfcb89a0fa0d20e81632.tar.xz
kiro-b39079922bb4288dee30dfcb89a0fa0d20e81632.zip
Restructured kiro-server implementation to make it a bit more modular
Added interface to kiro-client to access the memory allocated for communication Added new 'kiro_destroy_connection' to kiro-rdma package Changed interface of 'kiro_destroy_connection_context' and updated server and client accordingly Started to implement a more visual testing routine in test-server Made test-client use commandline arguments for address and port Updated Makefile
Diffstat (limited to 'kiro-server.h')
-rw-r--r--kiro-server.h25
1 files changed, 24 insertions, 1 deletions
diff --git a/kiro-server.h b/kiro-server.h
index 1d85419..cb9b57c 100644
--- a/kiro-server.h
+++ b/kiro-server.h
@@ -76,7 +76,30 @@ GObject kiro_server_new (void);
/* server functions */
-int kiro_server_start (KiroServer* server, char* bind_addr, char* bind_port);
+/**
+ * kiro_server_start - Starts the server, providing the given memory
+ * @server: KIRO SERVER to perform the operation on
+ * @bind_addr: Local address to bind the server to
+ * @bind_port: Local port to listen for connections
+ * @mem: Pointer to the memory that is to be provided
+ * @mem_size: Size in bytes of the given memory
+ * Description:
+ * Starts the server to provide the given memory to any connecting
+ * client.
+ * Notes:
+ * If the bind_addr is NULL, the server will bind to the first device
+ * it can find on the machine and listen across all IPs. Otherwise it
+ * will try to bind to the device associated with the given address.
+ * Address is given as a string of either a hostname or a dot-seperated
+ * IPv4 address or a colon-seperated IPv6 hex-address.
+ * If bind_port is NULL the server will choose a free port randomly
+ * and return the chosen port as return value.
+ * If server creation fails, -1 is returned instead.
+ * See also:
+ * kiro_trb_reshape, kiro_trb_adopt,
+ * kiro_trb_clone
+ */
+int kiro_server_start (KiroServer* server, char* bind_addr, char* bind_port, void* mem, size_t mem_size);
G_END_DECLS