summaryrefslogtreecommitdiff
path: root/file.h
diff options
context:
space:
mode:
authorJens Axboe <axboe@kernel.dk>2013-03-20 19:57:01 -0600
committerJens Axboe <axboe@kernel.dk>2013-03-20 19:57:01 -0600
commitd7df1d133b0c3daad4ae4c731e0dae7b0181fd62 (patch)
treeee98f9fa84039109f9d91d5cd22ed474d38e7da0 /file.h
parent25c42559e065f5a94a696b7bbefa32426d7b8925 (diff)
downloadfio-d7df1d133b0c3daad4ae4c731e0dae7b0181fd62.tar.gz
fio-d7df1d133b0c3daad4ae4c731e0dae7b0181fd62.tar.bz2
Rework lockfile= file lock handling
Get rid of the hand rolled rw semaphores, just use pthread rwlocks instead. Kill the batching too, it was broken by default, so nobody could have been using it. Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'file.h')
-rw-r--r--file.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/file.h b/file.h
index eb0688c5..d7e05f4f 100644
--- a/file.h
+++ b/file.h
@@ -102,10 +102,10 @@ struct fio_file {
/*
* if io is protected by a semaphore, this is set
*/
- struct fio_mutex *lock;
- void *lock_owner;
- unsigned int lock_batch;
- enum fio_ddir lock_ddir;
+ union {
+ struct fio_mutex *lock;
+ struct fio_rwlock *rwlock;
+ };
/*
* block map for random io