Add new net command for text logging

Encapsulate the text in a payload, that also includes the
logging level and the time the event took place. The text
client will do as it always has done, but the gui client
can now do proper logging and knows if this is debug/info
or error messages.

No functional change in the GUI.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
diff --git a/server.h b/server.h
index 5c7c8db..299c7a0 100644
--- a/server.h
+++ b/server.h
@@ -38,7 +38,7 @@
 };
 
 enum {
-	FIO_SERVER_VER		= 8,
+	FIO_SERVER_VER		= 9,
 
 	FIO_SERVER_MAX_PDU	= 1024,
 
@@ -118,9 +118,16 @@
 	uint32_t group_reporting;
 };
 
+struct cmd_text_pdu {
+	uint32_t level;
+	uint32_t buf_len;
+	uint64_t log_sec;
+	uint64_t log_usec;
+	uint8_t buf[0];
+};
+
 extern int fio_start_server(char *);
-extern int fio_server_text_output(const char *, size_t);
-extern int fio_server_log(const char *format, ...);
+extern int fio_server_text_output(int, const char *, size_t);
 extern int fio_net_send_cmd(int, uint16_t, const void *, off_t, uint64_t);
 extern int fio_net_send_simple_cmd(int, uint16_t, uint64_t, struct flist_head *);
 extern void fio_server_set_arg(const char *);