@@ -87,6 +91,8 @@ static void virtio_blk_rw_complete(void
 {
     VirtIOBlockReq *req = opaque;

+    trace_virtio_blk_rw_complete(req, ret);
+
     if (ret) {
         int is_read = !(req->out->type & VIRTIO_BLK_T_OUT);
         if (virtio_blk_handle_rw_error(req, -ret, is_read))

What happens when CONFIG_QEMU_TRACE is not defined?  Linker error for missing
symbol trace_virtio_blk_rw_complete()?

This is handled by the tracing backends patchset I posted.  When
tracing is disabled the nop backend will make tracepoints empty inline
functions.  The compiler makes them disappear but the tracepoint
invocation is still parsed and type checked by the compiler.  It
shouldn't be hard to add your tracer as a backend.

Stefan

Reply via email to