projects
/
fio.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Remove the file->last_completed_pos variable
[fio.git]
/
ioengines.c
diff --git
a/ioengines.c
b/ioengines.c
index 77c45f7ff05e1bc40224d2c4a784efa42add0a1c..879c5f1c1f438a20a5116bec93968fc0d4e0642f 100644
(file)
--- a/
ioengines.c
+++ b/
ioengines.c
@@
-226,10
+226,11
@@
int td_io_queue(struct thread_data *td, struct io_u *io_u)
if (io_u->ddir != DDIR_SYNC)
td->io_issues[io_u->ddir]++;
if (io_u->ddir != DDIR_SYNC)
td->io_issues[io_u->ddir]++;
- io_u_mark_depth(td, io_u);
-
ret = td->io_ops->queue(td, io_u);
ret = td->io_ops->queue(td, io_u);
+ if (ret != FIO_Q_BUSY)
+ io_u_mark_depth(td, io_u);
+
if (ret == FIO_Q_QUEUED) {
int r;
if (ret == FIO_Q_QUEUED) {
int r;
@@
-302,7
+303,6
@@
int td_io_open_file(struct thread_data *td, struct fio_file *f)
}
f->last_free_lookup = 0;
}
f->last_free_lookup = 0;
- f->last_completed_pos = 0;
f->last_pos = f->file_offset;
f->flags |= FIO_FILE_OPEN;
f->flags &= ~FIO_FILE_CLOSING;
f->last_pos = f->file_offset;
f->flags |= FIO_FILE_OPEN;
f->flags &= ~FIO_FILE_CLOSING;
@@
-343,7
+343,7
@@
err:
return 1;
}
return 1;
}
-
void
td_io_close_file(struct thread_data *td, struct fio_file *f)
+
int
td_io_close_file(struct thread_data *td, struct fio_file *f)
{
if (!(f->flags & FIO_FILE_CLOSING))
log_file(td, f, FIO_LOG_CLOSE_FILE);
{
if (!(f->flags & FIO_FILE_CLOSING))
log_file(td, f, FIO_LOG_CLOSE_FILE);
@@
-353,5
+353,5
@@
void td_io_close_file(struct thread_data *td, struct fio_file *f)
*/
f->flags |= FIO_FILE_CLOSING;
*/
f->flags |= FIO_FILE_CLOSING;
- put_file(td, f);
+
return
put_file(td, f);
}
}