From 6796209a7e3d39522b0f5599aba277809786335e Mon Sep 17 00:00:00 2001 From: Jens Axboe Date: Wed, 7 Jun 2006 08:45:01 +0200 Subject: [PATCH 1/1] [PATCH] Shorten the file names, stupid to prefix everything with fio- --- Makefile | 2 +- fio-log.h | 11 ----------- fio-stat.h | 12 ------------ fio-time.h | 12 ------------ fio.c | 4 ---- fio.h | 32 ++++++++++++++++++++++++++++++++ fio-ini.c => init.c | 0 fio-io.c => ioengines.c | 0 fio-log.c => log.c | 0 fio-stat.c => stat.c | 1 - fio-time.c => time.c | 0 11 files changed, 33 insertions(+), 41 deletions(-) delete mode 100644 fio-log.h delete mode 100644 fio-stat.h delete mode 100644 fio-time.h rename fio-ini.c => init.c (100%) rename fio-io.c => ioengines.c (100%) rename fio-log.c => log.c (100%) rename fio-stat.c => stat.c (99%) rename fio-time.c => time.c (100%) diff --git a/Makefile b/Makefile index 16c84136..684e8e04 100644 --- a/Makefile +++ b/Makefile @@ -5,7 +5,7 @@ SCRIPTS = fio_generate_plots all: depend $(PROGS) $(SCRIPTS) -fio: fio.o fio-io.o fio-ini.o fio-stat.o fio-log.o fio-time.o md5.o crc32.o +fio: fio.o ioengines.o init.o stat.o log.o time.o md5.o crc32.o $(CC) $(CFLAGS) -o $@ $(filter %.o,$^) -lpthread -laio -lm -lrt clean: diff --git a/fio-log.h b/fio-log.h deleted file mode 100644 index 99bb9f7f..00000000 --- a/fio-log.h +++ /dev/null @@ -1,11 +0,0 @@ -#ifndef FIO_LOG_H -#define FIO_LOG_H - -extern int read_iolog_get(struct thread_data *, struct io_u *); -extern void write_iolog_put(struct thread_data *, struct io_u *); -extern int init_iolog(struct thread_data *td); -extern void log_io_piece(struct thread_data *, struct io_u *); -extern void prune_io_piece_log(struct thread_data *); -extern void write_iolog_close(struct thread_data *); - -#endif diff --git a/fio-stat.h b/fio-stat.h deleted file mode 100644 index b1ce6777..00000000 --- a/fio-stat.h +++ /dev/null @@ -1,12 +0,0 @@ -#ifndef FIO_STAT_H -#define FIO_STAT_H - -extern void add_clat_sample(struct thread_data *, int, unsigned long); -extern void add_slat_sample(struct thread_data *, int, unsigned long); -extern void add_bw_sample(struct thread_data *, int); -extern void show_run_stats(void); -extern void init_disk_util(struct thread_data *); -extern void update_rusage_stat(struct thread_data *); -extern void update_io_ticks(void); -extern void disk_util_timer_arm(void); -#endif diff --git a/fio-time.h b/fio-time.h deleted file mode 100644 index 4be3c4fe..00000000 --- a/fio-time.h +++ /dev/null @@ -1,12 +0,0 @@ -#ifndef FIO_TIME_H -#define FIO_TIME_H - -extern unsigned long utime_since(struct timeval *, struct timeval *); -extern unsigned long mtime_since(struct timeval *, struct timeval *); -extern unsigned long mtime_since_now(struct timeval *); -extern unsigned long time_since_now(struct timeval *); -extern void usec_sleep(struct thread_data *, unsigned long); - -extern void rate_throttle(struct thread_data *, unsigned long, unsigned int); - -#endif diff --git a/fio.c b/fio.c index 1eeb1ccc..8ac44522 100644 --- a/fio.c +++ b/fio.c @@ -34,10 +34,6 @@ #include "fio.h" #include "os.h" -#include "fio-time.h" -#include "fio-stat.h" -#include "fio-log.h" - #define MASK (4095) #define ALIGN(buf) (char *) (((unsigned long) (buf) + MASK) & ~(MASK)) diff --git a/fio.h b/fio.h index 58fabbdb..045fd012 100644 --- a/fio.h +++ b/fio.h @@ -353,4 +353,36 @@ struct io_completion_data { #define min(a, b) ((a) < (b) ? (a) : (b)) #endif +/* + * Log exports + */ +extern int read_iolog_get(struct thread_data *, struct io_u *); +extern void write_iolog_put(struct thread_data *, struct io_u *); +extern int init_iolog(struct thread_data *td); +extern void log_io_piece(struct thread_data *, struct io_u *); +extern void prune_io_piece_log(struct thread_data *); +extern void write_iolog_close(struct thread_data *); + +/* + * Logging + */ +extern void add_clat_sample(struct thread_data *, int, unsigned long); +extern void add_slat_sample(struct thread_data *, int, unsigned long); +extern void add_bw_sample(struct thread_data *, int); +extern void show_run_stats(void); +extern void init_disk_util(struct thread_data *); +extern void update_rusage_stat(struct thread_data *); +extern void update_io_ticks(void); +extern void disk_util_timer_arm(void); + +/* + * Time functions + */ +extern unsigned long utime_since(struct timeval *, struct timeval *); +extern unsigned long mtime_since(struct timeval *, struct timeval *); +extern unsigned long mtime_since_now(struct timeval *); +extern unsigned long time_since_now(struct timeval *); +extern void usec_sleep(struct thread_data *, unsigned long); +extern void rate_throttle(struct thread_data *, unsigned long, unsigned int); + #endif diff --git a/fio-ini.c b/init.c similarity index 100% rename from fio-ini.c rename to init.c diff --git a/fio-io.c b/ioengines.c similarity index 100% rename from fio-io.c rename to ioengines.c diff --git a/fio-log.c b/log.c similarity index 100% rename from fio-log.c rename to log.c diff --git a/fio-stat.c b/stat.c similarity index 99% rename from fio-stat.c rename to stat.c index 70c653db..54527169 100644 --- a/fio-stat.c +++ b/stat.c @@ -7,7 +7,6 @@ #include #include "fio.h" -#include "fio-time.h" static struct itimerval itimer; static LIST_HEAD(disk_list); diff --git a/fio-time.c b/time.c similarity index 100% rename from fio-time.c rename to time.c -- 2.25.1