aboutsummaryrefslogtreecommitdiff
path: root/block_int.h
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2011-11-10 17:25:44 +0100
committerKevin Wolf <kwolf@redhat.com>2011-11-11 14:02:59 +0100
commitc68b89acd636ff545bc7cb92739c41999291ce3c (patch)
treee0c937bf913260898bd312c0848be866bf5483fd /block_int.h
parent980bda8ba2322f665934913fbe6c4c202d61a9f9 (diff)
block: Rename bdrv_co_flush to bdrv_co_flush_to_disk
There are two different types of flush that you can do: Flushing one level up to the OS (i.e. writing data to the host page cache) or flushing it all the way down to the disk. The existing functions flush to the disk, reflect this in the function name. Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'block_int.h')
-rw-r--r--block_int.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/block_int.h b/block_int.h
index f4547f6d93..5aadc1fcee 100644
--- a/block_int.h
+++ b/block_int.h
@@ -84,10 +84,15 @@ struct BlockDriver {
int64_t sector_num, int nb_sectors, QEMUIOVector *qiov);
int coroutine_fn (*bdrv_co_writev)(BlockDriverState *bs,
int64_t sector_num, int nb_sectors, QEMUIOVector *qiov);
- int coroutine_fn (*bdrv_co_flush)(BlockDriverState *bs);
int coroutine_fn (*bdrv_co_discard)(BlockDriverState *bs,
int64_t sector_num, int nb_sectors);
+ /*
+ * Flushes all data that was already written to the OS all the way down to
+ * the disk (for example raw-posix calls fsync()).
+ */
+ int coroutine_fn (*bdrv_co_flush_to_disk)(BlockDriverState *bs);
+
int (*bdrv_aio_multiwrite)(BlockDriverState *bs, BlockRequest *reqs,
int num_reqs);
int (*bdrv_merge_requests)(BlockDriverState *bs, BlockRequest* a,