steadystate: move into its own header
authorJens Axboe <axboe@fb.com>
Fri, 12 Aug 2016 20:18:24 +0000 (14:18 -0600)
committerJens Axboe <axboe@fb.com>
Mon, 15 Aug 2016 15:44:52 +0000 (09:44 -0600)
Signed-off-by: Jens Axboe <axboe@fb.com>
fio.h
steadystate.h

diff --git a/fio.h b/fio.h
index ed2abe79618e210b3a316ec5edd0c94feacfd55b..4ab056aaf7467b9784ae358f445e141a2c6d7a1b 100644 (file)
--- a/fio.h
+++ b/fio.h
@@ -41,6 +41,7 @@
 #include "flow.h"
 #include "io_u_queue.h"
 #include "workqueue.h"
+#include "steadystate.h"
 
 #ifdef CONFIG_SOLARISAIO
 #include <sys/asynch.h>
@@ -122,43 +123,6 @@ struct zone_split_index {
        uint8_t size_perc_prev;
 };
 
-/*
- * For steady state detection
- */
-struct steadystate_data {
-       double limit;
-       unsigned long long dur;
-       unsigned long long ramp_time;
-       bool (*evaluate)(unsigned long, unsigned long, struct thread_data *);
-       bool check_iops;
-       bool check_slope;
-       bool pct;
-
-       int attained;
-       int last_in_group;
-       int ramp_time_over;
-
-       unsigned int head;
-       unsigned int tail;
-       unsigned long *iops_data;
-       unsigned long *bw_data;
-
-       double slope;
-       double criterion;
-       double deviation;
-
-       unsigned long long sum_y;
-       unsigned long long sum_x;
-       unsigned long long sum_x_sq;
-       unsigned long long sum_xy;
-       unsigned long long oldest_y;
-
-       struct timeval prev_time;
-       unsigned long long prev_iops;
-       unsigned long long prev_bytes;
-};
-
-
 /*
  * This describes a single thread/process executing a fio job.
  */
index 7a1fecdbfc074fe87cbcd0f1ebe2e392bc93a671..6cd2940908a52bfd1d2729c04171c7c10e9fe4d3 100644 (file)
@@ -6,4 +6,41 @@ extern void steadystate_setup(void);
 extern void steadystate_alloc(struct thread_data *);
 extern bool steadystate_deviation(unsigned long, unsigned long, struct thread_data *);
 extern bool steadystate_slope(unsigned long, unsigned long, struct thread_data *);
+
+/*
+ * For steady state detection
+ */
+struct steadystate_data {
+       double limit;
+       unsigned long long dur;
+       unsigned long long ramp_time;
+       bool (*evaluate)(unsigned long, unsigned long, struct thread_data *);
+       bool check_iops;
+       bool check_slope;
+       bool pct;
+
+       int attained;
+       int last_in_group;
+       int ramp_time_over;
+
+       unsigned int head;
+       unsigned int tail;
+       unsigned long *iops_data;
+       unsigned long *bw_data;
+
+       double slope;
+       double criterion;
+       double deviation;
+
+       unsigned long long sum_y;
+       unsigned long long sum_x;
+       unsigned long long sum_x_sq;
+       unsigned long long sum_xy;
+       unsigned long long oldest_y;
+
+       struct timeval prev_time;
+       unsigned long long prev_iops;
+       unsigned long long prev_bytes;
+};
+
 #endif