aboutsummaryrefslogtreecommitdiff
path: root/block/file-posix.c
diff options
context:
space:
mode:
authorFam Zheng <famz@redhat.com>2018-07-10 14:31:16 +0800
committerKevin Wolf <kwolf@redhat.com>2018-07-10 16:01:52 +0200
commitecc983a507bec9d3130434702d7031bfd372ba74 (patch)
tree734a4bd48a2f8d33110172acd2ff045e2cdcaed4 /block/file-posix.c
parentf8a30874ca4dd6560b5827433f07877e60960946 (diff)
downloadqemu-ecc983a507bec9d3130434702d7031bfd372ba74.zip
qemu-ecc983a507bec9d3130434702d7031bfd372ba74.tar.gz
qemu-ecc983a507bec9d3130434702d7031bfd372ba74.tar.bz2
block: Add copy offloading trace points
A few trace points that can help reveal what is happening in a copy offloading I/O path. Signed-off-by: Fam Zheng <famz@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'block/file-posix.c')
-rw-r--r--block/file-posix.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/block/file-posix.c b/block/file-posix.c
index 1185c7c..09f6b93 100644
--- a/block/file-posix.c
+++ b/block/file-posix.c
@@ -1488,6 +1488,8 @@ static ssize_t handle_aiocb_copy_range(RawPosixAIOData *aiocb)
ssize_t ret = copy_file_range(aiocb->aio_fildes, &in_off,
aiocb->aio_fd2, &out_off,
bytes, 0);
+ trace_file_copy_file_range(aiocb->bs, aiocb->aio_fildes, in_off,
+ aiocb->aio_fd2, out_off, bytes, 0, ret);
if (ret == 0) {
/* No progress (e.g. when beyond EOF), let the caller fall back to
* buffer I/O. */