zbd: Fix incorrect comments
[fio.git] / server.c
index 12c8d6841135437f4b3d06210aaa1ce74c9fd9b2..1c0750194be853af274e7257923210167edd1e31 100644 (file)
--- a/server.c
+++ b/server.c
@@ -296,6 +296,8 @@ static int verify_convert_cmd(struct fio_net_cmd *cmd)
        if (crc != cmd->cmd_crc16) {
                log_err("fio: server bad crc on command (got %x, wanted %x)\n",
                                cmd->cmd_crc16, crc);
+               fprintf(f_err, "fio: server bad crc on command (got %x, wanted %x)\n",
+                               cmd->cmd_crc16, crc);
                return 1;
        }
 
@@ -310,6 +312,8 @@ static int verify_convert_cmd(struct fio_net_cmd *cmd)
                break;
        default:
                log_err("fio: bad server cmd version %d\n", cmd->version);
+               fprintf(f_err, "fio: client/server version mismatch (%d != %d)\n",
+                               cmd->version, FIO_SERVER_VER);
                return 1;
        }
 
@@ -1594,7 +1598,7 @@ void fio_server_send_gs(struct group_run_stats *rs)
 }
 
 void fio_server_send_job_options(struct flist_head *opt_list,
-                                unsigned int groupid)
+                                unsigned int gid)
 {
        struct cmd_job_option pdu;
        struct flist_head *entry;
@@ -1609,12 +1613,12 @@ void fio_server_send_job_options(struct flist_head *opt_list,
                p = flist_entry(entry, struct print_option, list);
                memset(&pdu, 0, sizeof(pdu));
 
-               if (groupid == -1U) {
+               if (gid == -1U) {
                        pdu.global = __cpu_to_le16(1);
                        pdu.groupid = 0;
                } else {
                        pdu.global = 0;
-                       pdu.groupid = cpu_to_le32(groupid);
+                       pdu.groupid = cpu_to_le32(gid);
                }
                len = strlen(p->name);
                if (len >= sizeof(pdu.name)) {
@@ -1985,7 +1989,7 @@ int fio_send_iolog(struct thread_data *td, struct io_log *log, const char *name)
                        s->time         = cpu_to_le64(s->time);
                        s->data.val     = cpu_to_le64(s->data.val);
                        s->__ddir       = cpu_to_le32(s->__ddir);
-                       s->bs           = cpu_to_le32(s->bs);
+                       s->bs           = cpu_to_le64(s->bs);
 
                        if (log->log_offset) {
                                struct io_sample_offset *so = (void *) s;