Get rid of O_ATOMIC
[fio.git] / backend.c
index 928e524a370c21abb0a6cf1a232e29525a55185b..9e981bf408016aadb40f30dd5ca06db87febd0c6 100644 (file)
--- a/backend.c
+++ b/backend.c
@@ -1333,7 +1333,7 @@ int init_io_u_buffers(struct thread_data *td)
         * overflow later. this adjustment may be too much if we get
         * lucky and the allocator gives us an aligned address.
         */
-       if (td->o.odirect || td->o.mem_align || td->o.oatomic ||
+       if (td->o.odirect || td->o.mem_align ||
            td_ioengine_flagged(td, FIO_RAWIO))
                td->orig_buffer_size += page_mask + td->o.mem_align;
 
@@ -1352,7 +1352,7 @@ int init_io_u_buffers(struct thread_data *td)
        if (data_xfer && allocate_io_mem(td))
                return 1;
 
-       if (td->o.odirect || td->o.mem_align || td->o.oatomic ||
+       if (td->o.odirect || td->o.mem_align ||
            td_ioengine_flagged(td, FIO_RAWIO))
                p = PTR_ALIGN(td->orig_buffer, page_mask) + td->o.mem_align;
        else
@@ -1796,7 +1796,7 @@ static void *thread_main(void *data)
        if (td_io_init(td))
                goto err;
 
-       if (td_ioengine_flagged(td, FIO_SYNCIO) && td->o.iodepth > 1) {
+       if (td_ioengine_flagged(td, FIO_SYNCIO) && td->o.iodepth > 1 && td->o.io_submit_mode != IO_MODE_OFFLOAD) {
                log_info("note: both iodepth >= 1 and synchronous I/O engine "
                         "are selected, queue depth will be capped at 1\n");
        }
@@ -1919,7 +1919,8 @@ static void *thread_main(void *data)
                        }
                } while (1);
 
-               if (td_read(td) && td->io_bytes[DDIR_READ])
+               if (td->io_bytes[DDIR_READ] && (td_read(td) ||
+                       ((td->flags & TD_F_VER_BACKLOG) && td_write(td))))
                        update_runtime(td, elapsed_us, DDIR_READ);
                if (td_write(td) && td->io_bytes[DDIR_WRITE])
                        update_runtime(td, elapsed_us, DDIR_WRITE);