diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2014-08-15 16:37:17 +0100 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2014-08-15 16:37:17 +0100 |
commit | 5c6b3c50cca2106e5fbcbc6efa94c2f8b9d29fd8 (patch) | |
tree | 130b8de581b48b1bf1862b4f5f1e8001955cc47e /hw/virtio | |
parent | f2fb1da9412ae7b4cb512cfbd86c0185f191e2f9 (diff) | |
parent | 4ac4458076e1aaf3b01a6361154117df20e22215 (diff) | |
download | qemu-5c6b3c50cca2106e5fbcbc6efa94c2f8b9d29fd8.zip qemu-5c6b3c50cca2106e5fbcbc6efa94c2f8b9d29fd8.tar.gz qemu-5c6b3c50cca2106e5fbcbc6efa94c2f8b9d29fd8.tar.bz2 |
Merge remote-tracking branch 'remotes/stefanha/tags/tracing-pull-request' into staging
Tracing pull request
* remotes/stefanha/tags/tracing-pull-request:
virtio-rng: add some trace events
trace: add some tcg tracing support
trace: teach lttng backend to use format strings
trace: [tcg] Include TCG-tracing header on all targets
trace: [tcg] Include event definitions in "trace.h"
trace: [tcg] Generate TCG tracing routines
trace: [tcg] Include TCG-tracing helpers
trace: [tcg] Define TCG tracing helper routine wrappers
trace: [tcg] Define TCG tracing helper routines
trace: [tcg] Declare TCG tracing helper routines
trace: [tcg] Add 'tcg' event property
trace: [tcg] Argument type transformation machinery
trace: [tcg] Argument type transformation rules
trace: [tcg] Add documentation
trace: install simpletrace SystemTap tapset
simpletrace: add simpletrace.py --no-header option
trace: add tracetool simpletrace_stap format
trace: extract stap_escape() function for reuse
Conflicts:
Makefile.objs
Diffstat (limited to 'hw/virtio')
-rw-r--r-- | hw/virtio/virtio-rng.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/hw/virtio/virtio-rng.c b/hw/virtio/virtio-rng.c index 03fd04a..e85a979 100644 --- a/hw/virtio/virtio-rng.c +++ b/hw/virtio/virtio-rng.c @@ -16,6 +16,7 @@ #include "hw/virtio/virtio-rng.h" #include "sysemu/rng.h" #include "qom/object_interfaces.h" +#include "trace.h" static bool is_guest_ready(VirtIORNG *vrng) { @@ -24,6 +25,7 @@ static bool is_guest_ready(VirtIORNG *vrng) && (vdev->status & VIRTIO_CONFIG_S_DRIVER_OK)) { return true; } + trace_virtio_rng_guest_not_ready(vrng); return false; } @@ -62,6 +64,7 @@ static void chr_read(void *opaque, const void *buf, size_t size) offset += len; virtqueue_push(vrng->vq, &elem, len); + trace_virtio_rng_pushed(vrng, len); } virtio_notify(vdev, vrng->vq); } @@ -81,6 +84,9 @@ static void virtio_rng_process(VirtIORNG *vrng) quota = MIN((uint64_t)vrng->quota_remaining, (uint64_t)UINT32_MAX); } size = get_request_size(vrng->vq, quota); + + trace_virtio_rng_request(vrng, size, quota); + size = MIN(vrng->quota_remaining, size); if (size) { rng_backend_request_entropy(vrng->rng, size, chr_read, vrng); |