Add support for client timed out ops
Just opens a dialog window.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
diff --git a/client.c b/client.c
index a84b92c..feb1eba 100644
--- a/client.c
+++ b/client.c
@@ -984,7 +984,7 @@
return flist_empty(&client->cmd_list) && ret;
}
-static int fio_client_timed_out(void)
+static int fio_client_timed_out(struct client_ops *ops)
{
struct fio_client *client;
struct flist_head *entry, *tmp;
@@ -1002,7 +1002,11 @@
if (!client_check_cmd_timeout(client, &tv))
continue;
- log_err("fio: client %s timed out\n", client->hostname);
+ if (ops->timed_out)
+ ops->timed_out(client);
+ else
+ log_err("fio: client %s timed out\n", client->hostname);
+
remove_client(client);
ret = 1;
}
@@ -1055,7 +1059,7 @@
request_client_etas();
memcpy(&eta_tv, &tv, sizeof(tv));
- if (fio_client_timed_out())
+ if (fio_client_timed_out(ops))
break;
}