Hey,
This tiny series changes the tracepoint to include the number of
dirty pages via the vfio_get_dirty_bitmap. I find it useful for
observability in general to understand the number of dirty pages in an
IOVA range. With dirty tracking supported by device or IOMMU it's specially
relevant data to include in the tracepoint.
First patch changes the return value to be the number of dirty pages in
the helper function setting dirty bits and the second patch expands the
VFIO tracepoint to include the dirty pages.
Thanks,
Joao
Changes since v1[1]:
* Make the nr of dirty pages a retval similar to sync variant of helper in
patch 1 (Cedric)
* Stash number of bits set in bitmap quad in a variable and reuse in
GLOBAL_DIRTY_RATE in patch 1
* Drop init to 0 given that we always initialize the @dirty used in the
tracepoint
[1]
https://lore.kernel.org/qemu-devel/[email protected]/
Joao Martins (2):
exec/ram_addr: return nr of dirty pages in
cpu_physical_memory_set_dirty_lebitmap()
hw/vfio: Add nr of dirty pages to vfio_get_dirty_bitmap tracepoint
hw/vfio/common.c | 7 ++++---
hw/vfio/trace-events | 2 +-
include/exec/ram_addr.h | 21 +++++++++++++++------
3 files changed, 20 insertions(+), 10 deletions(-)
--
2.31.1