server: document fio_server_parse_string()
authorJens Axboe <axboe@kernel.dk>
Mon, 24 Oct 2011 07:35:06 +0000 (09:35 +0200)
committerJens Axboe <axboe@kernel.dk>
Mon, 24 Oct 2011 07:35:06 +0000 (09:35 +0200)
Signed-off-by: Jens Axboe <axboe@kernel.dk>
server.c

index 6a5bc6ce937fcc24e0d6d135be6ac73335acb437..81ec6b0e07e49c12fddf37126536d62fbc63ae70 100644 (file)
--- a/server.c
+++ b/server.c
@@ -943,6 +943,18 @@ static int fio_init_server_connection(void)
        return sk;
 }
 
+/*
+ * Parse a host/ip/port string. Reads from 'str'.
+ *
+ * Outputs:
+ *
+ * For IPv4:
+ *     *ptr is the host, *port is the port, inp is the destination.
+ * For IPv6:
+ *     *ptr is the host, *port is the port, inp6 is the dest, and *ipv6 is 1.
+ * For local domain sockets:
+ *     *ptr is the filename, *is_sock is 1.
+ */
 int fio_server_parse_string(const char *str, char **ptr, int *is_sock,
                            int *port, struct in_addr *inp,
                            struct in6_addr *inp6, int *ipv6)