From: vincentfu@gmail.com
To: axboe@kernel.dk, fio@vger.kernel.org
Cc: Vincent Fu <vincent.fu@wdc.com>
Subject: [PATCH 2/5] client: handle disk util for all output formats
Date: Wed, 15 May 2019 16:05:00 -0400 [thread overview]
Message-ID: <20190515200503.23000-3-vincentfu@gmail.com> (raw)
In-Reply-To: <20190515200503.23000-1-vincentfu@gmail.com>
From: Vincent Fu <vincent.fu@wdc.com>
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.
---
client.c | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
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)
--
2.17.1
next prev parent reply other threads:[~2019-05-15 20:05 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-15 20:04 [PATCH 0/5] terse client/server output vincentfu
2019-05-15 20:04 ` [PATCH 1/5] client: do not print disk utilization for terse v2 vincentfu
2019-05-15 20:05 ` vincentfu [this message]
2019-05-15 20:05 ` [PATCH 3/5] client: add a newline after terse disk util vincentfu
2019-05-15 20:05 ` [PATCH 4/5] docs: improve terse output format documentation vincentfu
2019-05-15 20:05 ` [PATCH 5/5] stat: remove terse v2 blank lines with description not set vincentfu
2019-05-16 14:43 ` [PATCH 0/5] terse client/server output Jens Axboe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190515200503.23000-3-vincentfu@gmail.com \
--to=vincentfu@gmail.com \
--cc=axboe@kernel.dk \
--cc=fio@vger.kernel.org \
--cc=vincent.fu@wdc.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox