engines: fixup fio_q_status style violations
authorJens Axboe <axboe@kernel.dk>
Fri, 20 Apr 2018 15:46:19 +0000 (09:46 -0600)
committerJens Axboe <axboe@kernel.dk>
Fri, 20 Apr 2018 15:46:19 +0000 (09:46 -0600)
Commit d3b07186b1d4 broke lines in an unconventional manner, and
not consistently. Fix those up.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
23 files changed:
engines/cpu.c
engines/dev-dax.c
engines/e4defrag.c
engines/falloc.c
engines/filecreate.c
engines/ftruncate.c
engines/guasi.c
engines/libaio.c
engines/libhdfs.c
engines/libpmem.c
engines/mmap.c
engines/mtd.c
engines/net.c
engines/null.c
engines/pmemblk.c
engines/rados.c
engines/rbd.c
engines/rdma.c
engines/sg.c
engines/skeleton_external.c
engines/splice.c
engines/sync.c
engines/windowsaio.c

index 37f9bbad501a113e0f4f4fc0c4ebcd22fca2bb5b..09872508e12129d1408040eadb40055c0ebb8181 100644 (file)
@@ -53,8 +53,8 @@ static struct fio_option options[] = {
 };
 
 
 };
 
 
-static enum fio_q_status
-fio_cpuio_queue(struct thread_data *td, struct io_u fio_unused *io_u)
+static enum fio_q_status fio_cpuio_queue(struct thread_data *td,
+                                        struct io_u fio_unused *io_u)
 {
        struct cpu_options *co = td->eo;
 
 {
        struct cpu_options *co = td->eo;
 
index 807d8505b21121999bb5f6b6626e7ab0aced1877..0660bba563e6a4a522ba5ace408b78ffe4744e3c 100644 (file)
@@ -182,8 +182,8 @@ done:
        return 0;
 }
 
        return 0;
 }
 
-static enum fio_q_status
-fio_devdax_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_devdax_queue(struct thread_data *td,
+                                         struct io_u *io_u)
 {
        fio_ro_check(td, io_u);
        io_u->error = 0;
 {
        fio_ro_check(td, io_u);
        io_u->error = 0;
index 22d523125875a872180d70a7cbdc2b3d8eb948e9..8f71d02caa947867339d980e0f2722c9a5751b8d 100644 (file)
@@ -127,8 +127,8 @@ static void fio_e4defrag_cleanup(struct thread_data *td)
 }
 
 
 }
 
 
-static enum fio_q_status
-fio_e4defrag_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_e4defrag_queue(struct thread_data *td,
+                                           struct io_u *io_u)
 {
 
        int ret;
 {
 
        int ret;
index a1f6a242b11bb60fe5742923105cfe394907145a..6382569b9a92c42c1ad5d76a75d9441808de6cc8 100644 (file)
@@ -65,9 +65,10 @@ open_again:
 #endif
 #ifndef FALLOC_FL_PUNCH_HOLE
 #define FALLOC_FL_PUNCH_HOLE    0x02 /* de-allocates range */
 #endif
 #ifndef FALLOC_FL_PUNCH_HOLE
 #define FALLOC_FL_PUNCH_HOLE    0x02 /* de-allocates range */
-#endif 
-static enum fio_q_status
-fio_fallocate_queue(struct thread_data *td, struct io_u *io_u)
+#endif
+
+static enum fio_q_status fio_fallocate_queue(struct thread_data *td,
+                                            struct io_u *io_u)
 {
        struct fio_file *f = io_u->file;
        int ret;
 {
        struct fio_file *f = io_u->file;
        int ret;
index fb3f389791d9c61a4f14ce4b68953b608ee20648..39a2950293f70b8e74e57624dfea5e1fb050d3c6 100644 (file)
@@ -55,8 +55,8 @@ static int open_file(struct thread_data *td, struct fio_file *f)
        return 0;
 }
 
        return 0;
 }
 
-static enum fio_q_status
-queue_io(struct thread_data *td, struct io_u fio_unused *io_u)
+static enum fio_q_status queue_io(struct thread_data *td,
+                                 struct io_u fio_unused *io_u)
 {
        return FIO_Q_COMPLETED;
 }
 {
        return FIO_Q_COMPLETED;
 }
index 4ff511ea7e2193eb3656eb841cb56c6ca3a4cc78..c7ad038c0a881ef2fbdc03aa8f15c15d22e2e49a 100644 (file)
 
 #include "../fio.h"
 
 
 #include "../fio.h"
 
-static enum fio_q_status
-fio_ftruncate_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_ftruncate_queue(struct thread_data *td,
+                                            struct io_u *io_u)
 {
        struct fio_file *f = io_u->file;
        int ret;
 {
        struct fio_file *f = io_u->file;
        int ret;
+
        fio_ro_check(td, io_u);
 
        if (io_u->ddir != DDIR_WRITE) {
                io_u->error = EINVAL;
                return FIO_Q_COMPLETED;
        }
        fio_ro_check(td, io_u);
 
        if (io_u->ddir != DDIR_WRITE) {
                io_u->error = EINVAL;
                return FIO_Q_COMPLETED;
        }
-       ret = ftruncate(f->fd, io_u->offset);
 
 
+       ret = ftruncate(f->fd, io_u->offset);
        if (ret)
                io_u->error = errno;
 
        if (ret)
                io_u->error = errno;
 
index 4d33290850efd25dfb0792f613c03a4342219e2f..cb26802cce8b8f8acbbb510d715262f9b48fa2a9 100644 (file)
@@ -113,8 +113,8 @@ static int fio_guasi_getevents(struct thread_data *td, unsigned int min,
        return n;
 }
 
        return n;
 }
 
-static enum fio_q_status
-fio_guasi_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_guasi_queue(struct thread_data *td,
+                                        struct io_u *io_u)
 {
        struct guasi_data *ld = td->io_ops_data;
 
 {
        struct guasi_data *ld = td->io_ops_data;
 
index 0e2263a743ad657244cc61a5a97ba0ba1b5d2e9a..f46b3314581ce008ed8ca6befcd2a754cdfd7732 100644 (file)
@@ -177,8 +177,8 @@ static int fio_libaio_getevents(struct thread_data *td, unsigned int min,
        return r < 0 ? r : events;
 }
 
        return r < 0 ? r : events;
 }
 
-static enum fio_q_status
-fio_libaio_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_libaio_queue(struct thread_data *td,
+                                         struct io_u *io_u)
 {
        struct libaio_data *ld = td->io_ops_data;
 
 {
        struct libaio_data *ld = td->io_ops_data;
 
index 37694fafcb0269231c34d1fba6b2d26ca0855cdf..6000160129402472385da53b478229b123db82b2 100644 (file)
@@ -165,8 +165,8 @@ static int fio_hdfsio_prep(struct thread_data *td, struct io_u *io_u)
        return 0;
 }
 
        return 0;
 }
 
-static enum fio_q_status
-fio_hdfsio_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_hdfsio_queue(struct thread_data *td,
+                                         struct io_u *io_u)
 {
        struct hdfsio_data *hd = td->io_ops_data;
        struct hdfsio_options *options = td->eo;
 {
        struct hdfsio_data *hd = td->io_ops_data;
        struct hdfsio_options *options = td->eo;
index c3abe2a05542700bf7625671d314739bde285383..21ff4f66d393c3cc9e71998c2137208c20fd5eac 100644 (file)
@@ -457,8 +457,8 @@ done:
        return 0;
 }
 
        return 0;
 }
 
-static enum fio_q_status
-fio_libpmem_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_libpmem_queue(struct thread_data *td,
+                                          struct io_u *io_u)
 {
        fio_ro_check(td, io_u);
        io_u->error = 0;
 {
        fio_ro_check(td, io_u);
        io_u->error = 0;
index 856547befda3dea5e42ece3a123ed35c70663f66..308b4665444cd619b73e6f5c3aeefbed78e56002 100644 (file)
@@ -177,8 +177,8 @@ done:
        return 0;
 }
 
        return 0;
 }
 
-static enum fio_q_status
-fio_mmapio_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_mmapio_queue(struct thread_data *td,
+                                         struct io_u *io_u)
 {
        struct fio_file *f = io_u->file;
        struct fio_mmap_data *fmd = FILE_ENG_DATA(f);
 {
        struct fio_file *f = io_u->file;
        struct fio_mmap_data *fmd = FILE_ENG_DATA(f);
index 9e154836a5a61094c51e5c74634d128a9fdcaec5..b9f431643f6d182eb65f59c0287ee127360fea32 100644 (file)
@@ -71,8 +71,8 @@ static int fio_mtd_is_bad(struct thread_data *td,
        return ret;
 }
 
        return ret;
 }
 
-static enum fio_q_status
-fio_mtd_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_mtd_queue(struct thread_data *td,
+                                      struct io_u *io_u)
 {
        struct fio_file *f = io_u->file;
        struct fio_mtd_data *fmd = FILE_ENG_DATA(f);
 {
        struct fio_file *f = io_u->file;
        struct fio_mtd_data *fmd = FILE_ENG_DATA(f);
index 8c25c4e5b12f254fbcd6d2eba1125f5d991f835a..ca6fb344b89786123e824dfa60eb913b4db33d6f 100644 (file)
@@ -642,8 +642,9 @@ static int fio_netio_recv(struct thread_data *td, struct io_u *io_u)
        return ret;
 }
 
        return ret;
 }
 
-static enum fio_q_status
-__fio_netio_queue(struct thread_data *td, struct io_u *io_u, enum fio_ddir ddir)
+static enum fio_q_status __fio_netio_queue(struct thread_data *td,
+                                          struct io_u *io_u,
+                                          enum fio_ddir ddir)
 {
        struct netio_data *nd = td->io_ops_data;
        struct netio_options *o = td->eo;
 {
        struct netio_data *nd = td->io_ops_data;
        struct netio_options *o = td->eo;
@@ -687,8 +688,8 @@ __fio_netio_queue(struct thread_data *td, struct io_u *io_u, enum fio_ddir ddir)
        return FIO_Q_COMPLETED;
 }
 
        return FIO_Q_COMPLETED;
 }
 
-static enum fio_q_status
-fio_netio_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_netio_queue(struct thread_data *td,
+                                        struct io_u *io_u)
 {
        struct netio_options *o = td->eo;
        int ret;
 {
        struct netio_options *o = td->eo;
        int ret;
index b1718e5c9a35fea7826fadcff340762e373c0e14..4cc0102b993e64a01e5f1804ea6a6ccfe7951a36 100644 (file)
@@ -56,8 +56,8 @@ static int null_commit(struct thread_data *td, struct null_data *nd)
        return 0;
 }
 
        return 0;
 }
 
-static enum fio_q_status
-null_queue(struct thread_data *td, struct null_data *nd, struct io_u *io_u)
+static enum fio_q_status null_queue(struct thread_data *td,
+                                   struct null_data *nd, struct io_u *io_u)
 {
        fio_ro_check(td, io_u);
 
 {
        fio_ro_check(td, io_u);
 
@@ -118,8 +118,8 @@ static int fio_null_commit(struct thread_data *td)
        return null_commit(td, td->io_ops_data);
 }
 
        return null_commit(td, td->io_ops_data);
 }
 
-static enum fio_q_status
-fio_null_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_null_queue(struct thread_data *td,
+                                       struct io_u *io_u)
 {
        return null_queue(td, td->io_ops_data, io_u);
 }
 {
        return null_queue(td, td->io_ops_data, io_u);
 }
index e2c558929ff22b883d7ae2d8abfbc787265e6695..45f6fb6501a216b78dbfdae34f7ef3807aa77669 100644 (file)
@@ -342,8 +342,8 @@ static int fio_pmemblk_get_file_size(struct thread_data *td, struct fio_file *f)
        return 0;
 }
 
        return 0;
 }
 
-static enum fio_q_status
-fio_pmemblk_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_pmemblk_queue(struct thread_data *td,
+                                          struct io_u *io_u)
 {
        struct fio_file *f = io_u->file;
        fio_pmemblk_file_t pmb = FILE_ENG_DATA(f);
 {
        struct fio_file *f = io_u->file;
        fio_pmemblk_file_t pmb = FILE_ENG_DATA(f);
index f3795c5742ecfd3bd36ebe5f321ce1450d3d4cff..c6aec730e3ac1eb125a5953af019221df90961a6 100644 (file)
@@ -251,8 +251,8 @@ static void fio_rados_cleanup(struct thread_data *td)
        }
 }
 
        }
 }
 
-static enum fio_q_status
-fio_rados_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_rados_queue(struct thread_data *td,
+                                        struct io_u *io_u)
 {
        struct rados_data *rados = td->io_ops_data;
        struct fio_rados_iou *fri = io_u->engine_data;
 {
        struct rados_data *rados = td->io_ops_data;
        struct fio_rados_iou *fri = io_u->engine_data;
index cf7337f00745198f21cd23379ea3362c8e6ee3cd..081b4a040f6425c1f0dad7c8884d7f163c87fad6 100644 (file)
@@ -462,8 +462,8 @@ static int fio_rbd_getevents(struct thread_data *td, unsigned int min,
        return events;
 }
 
        return events;
 }
 
-static enum fio_q_status
-fio_rbd_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_rbd_queue(struct thread_data *td,
+                                      struct io_u *io_u)
 {
        struct rbd_data *rbd = td->io_ops_data;
        struct fio_rbd_iou *fri = io_u->engine_data;
 {
        struct rbd_data *rbd = td->io_ops_data;
        struct fio_rbd_iou *fri = io_u->engine_data;
index 67c5aa7e23eb1f65b47ea5ad4b93886b630f2e82..2569a8e32e6a0d34f61fb3c9a46e13be56dfcf27 100644 (file)
@@ -791,8 +791,8 @@ static int fio_rdmaio_recv(struct thread_data *td, struct io_u **io_us,
        return i;
 }
 
        return i;
 }
 
-static enum fio_q_status
-fio_rdmaio_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_rdmaio_queue(struct thread_data *td,
+                                         struct io_u *io_u)
 {
        struct rdmaio_data *rd = td->io_ops_data;
 
 {
        struct rdmaio_data *rd = td->io_ops_data;
 
index 56e5d18ab60ba90edb05b69c079fae70a2fdc104..d4848bc582e0f05e8f1eeff5c68cb3decc26cb43 100644 (file)
@@ -236,9 +236,9 @@ re_read:
        return r;
 }
 
        return r;
 }
 
-static enum fio_q_status
-fio_sgio_ioctl_doio(struct thread_data *td, struct fio_file *f,
-                   struct io_u *io_u)
+static enum fio_q_status 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;
 {
        struct sgio_data *sd = td->io_ops_data;
        struct sg_io_hdr *hdr = &io_u->hdr;
@@ -378,8 +378,8 @@ static int fio_sgio_prep(struct thread_data *td, struct io_u *io_u)
        return 0;
 }
 
        return 0;
 }
 
-static enum fio_q_status
-fio_sgio_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_sgio_queue(struct thread_data *td,
+                                       struct io_u *io_u)
 {
        struct sg_io_hdr *hdr = &io_u->hdr;
        int ret, do_sync = 0;
 {
        struct sg_io_hdr *hdr = &io_u->hdr;
        int ret, do_sync = 0;
index 7e08afbb0fb34ed415d6a5548903c675baf97f70..21a3601824bc5d1db4cc9dd79ce6d7b03ac0e296 100644 (file)
@@ -90,8 +90,8 @@ static int fio_skeleton_cancel(struct thread_data *td, struct io_u *io_u)
  * io_u->xfer_buflen. Residual data count may be set in io_u->resid
  * for a short read/write.
  */
  * io_u->xfer_buflen. Residual data count may be set in io_u->resid
  * for a short read/write.
  */
-static enum fio_q_status
-fio_skeleton_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_skeleton_queue(struct thread_data *td,
+                                           struct io_u *io_u)
 {
        /*
         * Double sanity check to catch errant write on a readonly setup
 {
        /*
         * Double sanity check to catch errant write on a readonly setup
index 18403608cbc61276de93e96116020e071ab096ba..feb764feb2f4f4766275dd53e938cab1ce3e5292 100644 (file)
@@ -199,8 +199,8 @@ static int fio_splice_write(struct thread_data *td, struct io_u *io_u)
        return io_u->xfer_buflen;
 }
 
        return io_u->xfer_buflen;
 }
 
-static enum fio_q_status
-fio_spliceio_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_spliceio_queue(struct thread_data *td,
+                                           struct io_u *io_u)
 {
        struct spliceio_data *sd = td->io_ops_data;
        int ret = 0;
 {
        struct spliceio_data *sd = td->io_ops_data;
        int ret = 0;
index 722320ef6de6b5dd5dc0eb3246d9c75746786174..3f36da824ec30e1e95111561f480abadfa5780e8 100644 (file)
@@ -110,8 +110,8 @@ static int fio_io_end(struct thread_data *td, struct io_u *io_u, int ret)
 }
 
 #ifdef CONFIG_PWRITEV
 }
 
 #ifdef CONFIG_PWRITEV
-static enum fio_q_status
-fio_pvsyncio_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_pvsyncio_queue(struct thread_data *td,
+                                           struct io_u *io_u)
 {
        struct syncio_data *sd = td->io_ops_data;
        struct iovec *iov = &sd->iovecs[0];
 {
        struct syncio_data *sd = td->io_ops_data;
        struct iovec *iov = &sd->iovecs[0];
@@ -138,8 +138,8 @@ fio_pvsyncio_queue(struct thread_data *td, struct io_u *io_u)
 #endif
 
 #ifdef FIO_HAVE_PWRITEV2
 #endif
 
 #ifdef FIO_HAVE_PWRITEV2
-static enum fio_q_status
-fio_pvsyncio2_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_pvsyncio2_queue(struct thread_data *td,
+                                            struct io_u *io_u)
 {
        struct syncio_data *sd = td->io_ops_data;
        struct psyncv2_options *o = td->eo;
 {
        struct syncio_data *sd = td->io_ops_data;
        struct psyncv2_options *o = td->eo;
@@ -170,9 +170,8 @@ fio_pvsyncio2_queue(struct thread_data *td, struct io_u *io_u)
 }
 #endif
 
 }
 #endif
 
-
-static enum fio_q_status
-fio_psyncio_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_psyncio_queue(struct thread_data *td,
+                                          struct io_u *io_u)
 {
        struct fio_file *f = io_u->file;
        int ret;
 {
        struct fio_file *f = io_u->file;
        int ret;
@@ -192,8 +191,8 @@ fio_psyncio_queue(struct thread_data *td, struct io_u *io_u)
        return fio_io_end(td, io_u, ret);
 }
 
        return fio_io_end(td, io_u, ret);
 }
 
-static enum fio_q_status
-fio_syncio_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_syncio_queue(struct thread_data *td,
+                                         struct io_u *io_u)
 {
        struct fio_file *f = io_u->file;
        int ret;
 {
        struct fio_file *f = io_u->file;
        int ret;
@@ -264,8 +263,8 @@ static void fio_vsyncio_set_iov(struct syncio_data *sd, struct io_u *io_u,
        sd->queued++;
 }
 
        sd->queued++;
 }
 
-static enum fio_q_status
-fio_vsyncio_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_vsyncio_queue(struct thread_data *td,
+                                          struct io_u *io_u)
 {
        struct syncio_data *sd = td->io_ops_data;
 
 {
        struct syncio_data *sd = td->io_ops_data;
 
index 2b932f71460f196287e26b5f99d1509378ce3565..13d7f19402a1759fa8c28f7e11b6e13686098e93 100644 (file)
@@ -354,8 +354,8 @@ static int fio_windowsaio_getevents(struct thread_data *td, unsigned int min,
        return dequeued;
 }
 
        return dequeued;
 }
 
-static enum fio_q_status
-fio_windowsaio_queue(struct thread_data *td, struct io_u *io_u)
+static enum fio_q_status fio_windowsaio_queue(struct thread_data *td,
+                                             struct io_u *io_u)
 {
        struct fio_overlapped *o = io_u->engine_data;
        LPOVERLAPPED lpOvl = &o->o;
 {
        struct fio_overlapped *o = io_u->engine_data;
        LPOVERLAPPED lpOvl = &o->o;