[PATCH] Make io engines -W clean
authorJens Axboe <jens.axboe@oracle.com>
Wed, 18 Oct 2006 15:21:58 +0000 (17:21 +0200)
committerJens Axboe <jens.axboe@oracle.com>
Wed, 18 Oct 2006 15:21:58 +0000 (17:21 +0200)
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
engines/Makefile
engines/fio-engine-libaio.c
engines/fio-engine-mmap.c
engines/fio-engine-posixaio.c
engines/fio-engine-sg.c
engines/fio-engine-splice.c
engines/fio-engine-sync.c

index bffaff443bba0934ac5341b1cc5f1d263fd9a0d8..ce55894d171980f6ae62fde98e90cf8d391b1b72 100644 (file)
@@ -1,5 +1,5 @@
 CC     = gcc
-CFLAGS = -Wall -O2 -g -shared -rdynamic -fPIC
+CFLAGS = -W -Wall -O2 -g -shared -rdynamic -fPIC
 ALL_CFLAGS = $(CFLAGS) -I.. -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
 OBJS   = fio-engine-sync.o fio-engine-splice.o fio-engine-mmap.o fio-engine-libaio.o fio-engine-posixaio.o fio-engine-sg.o fio-engine-cpu.o
 
index 9197107cc65a8abfbfb1ab5b0e29ec4e4905f31f..c3fefdaccda7ea97cf660c0db4007b158807310e 100644 (file)
@@ -17,12 +17,13 @@ struct libaio_data {
        struct io_event *aio_events;
 };
 
-static int fio_libaio_sync(struct thread_data *td, struct fio_file *f)
+static int fio_libaio_sync(struct thread_data fio_unused *td,
+                          struct fio_file *f)
 {
        return fsync(f->fd);
 }
 
-static int fio_libaio_prep(struct thread_data *td, struct io_u *io_u)
+static int fio_libaio_prep(struct thread_data fio_unused *td, struct io_u *io_u)
 {
        struct fio_file *f = io_u->file;
 
index 0c79752ff17c3c61c33b2fc01a715b471f531566..d203d6afc40db3d4ccca1cbcdbdaff4f94c22aab 100644 (file)
@@ -67,7 +67,8 @@ static int fio_mmapio_queue(struct thread_data *td, struct io_u *io_u)
        return io_u->error;
 }
 
-static int fio_mmapio_sync(struct thread_data *td, struct fio_file *f)
+static int fio_mmapio_sync(struct thread_data fio_unused *td,
+                          struct fio_file *f)
 {
        return msync(f->mmap, f->file_size, MS_SYNC);
 }
index 8cd3cf465998cb6fca2c961130f3e09d56d5114c..260551a4ee8b506f9c1fa84cc30711bddf168255 100644 (file)
@@ -45,12 +45,14 @@ static unsigned long long ts_utime_since_now(struct timespec *t)
        return sec + nsec;
 }
 
-static int fio_posixaio_sync(struct thread_data *td, struct fio_file *f)
+static int fio_posixaio_sync(struct thread_data fio_unused *td,
+                            struct fio_file *f)
 {
        return fsync(f->fd);
 }
 
-static int fio_posixaio_cancel(struct thread_data *td, struct io_u *io_u)
+static int fio_posixaio_cancel(struct thread_data fio_unused *td,
+                              struct io_u *io_u)
 {
        struct fio_file *f = io_u->file;
        int r = aio_cancel(f->fd, &io_u->aiocb);
@@ -61,7 +63,8 @@ static int fio_posixaio_cancel(struct thread_data *td, struct io_u *io_u)
        return 1;
 }
 
-static int fio_posixaio_prep(struct thread_data *td, struct io_u *io_u)
+static int fio_posixaio_prep(struct thread_data fio_unused *td,
+                            struct io_u *io_u)
 {
        struct aiocb *aiocb = &io_u->aiocb;
        struct fio_file *f = io_u->file;
index 5337068bbb992d828d3e30e9a1b2979fdb41e85f..01eba8d58391ebe957f4213452946a5cef09bf93 100644 (file)
@@ -112,8 +112,8 @@ static int fio_sgio_getevents(struct thread_data *td, int min, int max,
        return r;
 }
 
-static int fio_sgio_ioctl_doio(struct thread_data *td, struct fio_file *f,
-                              struct io_u *io_u)
+static int fio_sgio_ioctl_doio(struct thread_data *td,
+                              struct fio_file *f, struct io_u *io_u)
 {
        struct sgio_data *sd = td->io_ops->data;
        struct sg_io_hdr *hdr = &io_u->hdr;
@@ -123,8 +123,7 @@ static int fio_sgio_ioctl_doio(struct thread_data *td, struct fio_file *f,
        return ioctl(f->fd, SG_IO, hdr);
 }
 
-static int fio_sgio_rw_doio(struct thread_data *td, struct fio_file *f,
-                           struct io_u *io_u, int sync)
+static int fio_sgio_rw_doio(struct fio_file *f, struct io_u *io_u, int sync)
 {
        struct sg_io_hdr *hdr = &io_u->hdr;
        int ret;
@@ -149,10 +148,10 @@ static int fio_sgio_doio(struct thread_data *td, struct io_u *io_u, int sync)
        if (td->filetype == FIO_TYPE_BD)
                return fio_sgio_ioctl_doio(td, f, io_u);
 
-       return fio_sgio_rw_doio(td, f, io_u, sync);
+       return fio_sgio_rw_doio(f, io_u, sync);
 }
 
-static int fio_sgio_sync(struct thread_data *td, struct fio_file *f)
+static int fio_sgio_sync(struct thread_data *td, struct fio_file fio_unused *f)
 {
        struct sgio_data *sd = td->io_ops->data;
        struct sg_io_hdr *hdr;
index 4f5b86cd220c182a84ae39fbd38bf49cd795bc2d..cb39b7225946fc55b618b8b65cf0bef8d2500de0 100644 (file)
@@ -16,7 +16,8 @@ struct spliceio_data {
        int pipe[2];
 };
 
-static int fio_spliceio_sync(struct thread_data *td, struct fio_file *f)
+static int fio_spliceio_sync(struct thread_data fio_unused *td,
+                            struct fio_file *f)
 {
        return fsync(f->fd);
 }
index 1806d4dfda01f9157511f4fba66f430c215e1d7b..d5be4c8256ecda8415cbe438883d141758acfda7 100644 (file)
@@ -14,7 +14,8 @@ struct syncio_data {
        struct io_u *last_io_u;
 };
 
-static int fio_syncio_sync(struct thread_data *td, struct fio_file *f)
+static int fio_syncio_sync(struct thread_data fio_unused *td,
+                          struct fio_file *f)
 {
        return fsync(f->fd);
 }