From: Vincent Fu Date: Wed, 15 May 2019 20:05:00 +0000 (-0400) Subject: client: handle disk util for all output formats X-Git-Tag: fio-3.14~5 X-Git-Url: https://git.kernel.dk/?p=fio.git;a=commitdiff_plain;h=fd200c6a7d51188815ca2bc80e517768877ebef6 client: handle disk util for all output formats Since fio allows multiple output formats, it should process the disk utilization data for each output format that was requested by the user when it is run in client/server mode. Signed-off-by: Jens Axboe --- diff --git a/client.c b/client.c index 43156854..7fe571ef 100644 --- a/client.c +++ b/client.c @@ -1219,12 +1219,13 @@ static void handle_du(struct fio_client *client, struct fio_net_cmd *cmd) json_array_add_disk_util(&du->dus, &du->agg, du_array); duobj = json_array_last_value_object(du_array); json_object_add_client_info(duobj, client); - } else if (output_format & FIO_OUTPUT_TERSE && terse_version >= 3) - print_disk_util(&du->dus, &du->agg, 1, &client->buf); - else if (output_format & FIO_OUTPUT_NORMAL) { + } + if (output_format & FIO_OUTPUT_NORMAL) { __log_buf(&client->buf, "\nDisk stats (read/write):\n"); print_disk_util(&du->dus, &du->agg, 0, &client->buf); } + if (output_format & FIO_OUTPUT_TERSE && terse_version >= 3) + print_disk_util(&du->dus, &du->agg, 1, &client->buf); } static void convert_jobs_eta(struct jobs_eta *je)