Fix usr/sys/ctx/majf/minf for -USR1 usage
[fio.git] / fio.h
diff --git a/fio.h b/fio.h
index d18029a04af7b8fe20a854c723e588261170e7fc..a1b2a931e616179847928c8d145935b956d6432e 100644 (file)
--- a/fio.h
+++ b/fio.h
@@ -135,7 +135,6 @@ struct thread_options {
        unsigned int nr_files;
        unsigned int open_files;
        enum file_lock_mode file_lock_mode;
-       unsigned int lockfile_batch;
 
        unsigned int odirect;
        unsigned int invalidate_cache;
@@ -248,7 +247,7 @@ struct thread_options {
        unsigned int trim_zero;
        unsigned long long trim_backlog;
        unsigned int clat_percentiles;
-       unsigned int overwrite_plist;
+       unsigned int percentile_precision;      /* digits after decimal for percentiles */
        fio_fp64_t percentile_list[FIO_IO_U_LIST_MAX_LEN];
 
        char *read_iolog_file;
@@ -355,10 +354,13 @@ struct thread_data {
        uint64_t stat_io_blocks[DDIR_RWDIR_CNT];
        struct timeval iops_sample_time;
 
+       volatile int update_rusage;
+       struct fio_mutex *rusage_sem;
        struct rusage ru_start;
        struct rusage ru_end;
 
        struct fio_file **files;
+       unsigned char *file_locks;
        unsigned int files_size;
        unsigned int files_index;
        unsigned int nr_open_files;
@@ -454,22 +456,22 @@ struct thread_data {
        /*
         * Rate state
         */
-       unsigned long long rate_bps[DDIR_RWDIR_CNT];
+       uint64_t rate_bps[DDIR_RWDIR_CNT];
        long rate_pending_usleep[DDIR_RWDIR_CNT];
        unsigned long rate_bytes[DDIR_RWDIR_CNT];
        unsigned long rate_blocks[DDIR_RWDIR_CNT];
        struct timeval lastrate[DDIR_RWDIR_CNT];
 
-       unsigned long long total_io_size;
-       unsigned long long fill_device_size;
+       uint64_t total_io_size;
+       uint64_t fill_device_size;
 
        unsigned long io_issues[DDIR_RWDIR_CNT];
-       unsigned long long io_blocks[DDIR_RWDIR_CNT];
-       unsigned long long this_io_blocks[DDIR_RWDIR_CNT];
-       unsigned long long io_bytes[DDIR_RWDIR_CNT];
-       unsigned long long io_skip_bytes;
-       unsigned long long this_io_bytes[DDIR_RWDIR_CNT];
-       unsigned long long zone_bytes;
+       uint64_t io_blocks[DDIR_RWDIR_CNT];
+       uint64_t this_io_blocks[DDIR_RWDIR_CNT];
+       uint64_t io_bytes[DDIR_RWDIR_CNT];
+       uint64_t io_skip_bytes;
+       uint64_t this_io_bytes[DDIR_RWDIR_CNT];
+       uint64_t zone_bytes;
        struct fio_mutex *mutex;
 
        /*
@@ -594,6 +596,7 @@ extern unsigned long long mlock_size;
 extern uintptr_t page_mask, page_size;
 extern int read_only;
 extern int eta_print;
+extern int eta_new_line;
 extern unsigned long done_secs;
 extern char *job_section;
 extern int fio_gtod_offload;
@@ -606,7 +609,6 @@ extern int is_backend;
 extern int nr_clients;
 extern int log_syslog;
 extern const char fio_version_string[];
-extern const fio_fp64_t def_percentile_list[FIO_IO_U_LIST_MAX_LEN];
 
 extern struct thread_data *threads;
 
@@ -805,6 +807,14 @@ static inline int should_check_rate(struct thread_data *td,
        return ret;
 }
 
+static inline unsigned int td_max_bs(struct thread_data *td)
+{
+       unsigned int max_bs;
+
+       max_bs = max(td->o.max_bs[DDIR_READ], td->o.max_bs[DDIR_WRITE]);
+       return max(td->o.max_bs[DDIR_TRIM], max_bs);
+}
+
 static inline int is_power_of_2(unsigned int val)
 {
        return (val != 0 && ((val & (val - 1)) == 0));