On 05/16/2016 07:32 PM, Eric Blake wrote:
On 05/14/2016 06:01 AM, Denis V. Lunev wrote:
Signed-off-by: Denis V. Lunev <d...@openvz.org>
CC: Kevin Wolf <kw...@redhat.com>
---
block/qcow2.c | 5 +++++
trace-events | 2 ++
2 files changed, 7 insertions(+)
diff --git a/block/qcow2.c b/block/qcow2.c
index 9a54bbd..97bf870 100644
--- a/block/qcow2.c
+++ b/block/qcow2.c
@@ -2435,6 +2435,9 @@ static coroutine_fn int
qcow2_co_write_zeroes(BlockDriverState *bs,
int head = sector_num % s->cluster_sectors;
int tail = (sector_num + nb_sectors) % s->cluster_sectors;
+ trace_qcow2_write_zeroes_start_req(qemu_coroutine_self(), sector_num,
+ nb_sectors);
+
Can we trace these by byte locations rather than by sector count?
Ultimately, I think we want to move write_zeroes to a byte-based
interface, even if we still assert internally that it is at least
sector-aligned.
we can, but this patches traces for qcow2_co_writev
static coroutine_fn int qcow2_co_writev(BlockDriverState *bs,
int64_t sector_num,
int remaining_sectors,
QEMUIOVector *qiov)
{
[...]
trace_qcow2_writev_start_req(qemu_coroutine_self(), sector_num,
remaining_sectors);
Thus I'd better either stick to this implementation or change
all tracepoints in QEMU code.