qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [RFC PATCH 05/19] virtio-pci: add notification trace points


From: Philippe Mathieu-Daudé
Subject: Re: [RFC PATCH 05/19] virtio-pci: add notification trace points
Date: Fri, 25 Sep 2020 15:06:11 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.11.0

On 9/25/20 2:51 PM, Alex Bennée wrote:
> Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
> ---
>  hw/virtio/virtio-pci.c | 3 +++
>  hw/virtio/trace-events | 7 ++++++-
>  2 files changed, 9 insertions(+), 1 deletion(-)
> 
> diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c
> index 507cb57c410f..33a40e31d955 100644
> --- a/hw/virtio/virtio-pci.c
> +++ b/hw/virtio/virtio-pci.c
> @@ -36,6 +36,7 @@
>  #include "qemu/range.h"
>  #include "hw/virtio/virtio-bus.h"
>  #include "qapi/visitor.h"
> +#include "trace.h"
>  
>  #define VIRTIO_PCI_REGION_SIZE(dev)     
> VIRTIO_PCI_CONFIG_OFF(msix_present(dev))
>  
> @@ -1340,6 +1341,7 @@ static void virtio_pci_notify_write(void *opaque, 
> hwaddr addr,
>      unsigned queue = addr / virtio_pci_queue_mem_mult(proxy);
>  
>      if (vdev != NULL && queue < VIRTIO_QUEUE_MAX) {
> +        trace_virtio_pci_notify_write(addr, val, size);
>          virtio_queue_notify(vdev, queue);
>      }
>  }
> @@ -1353,6 +1355,7 @@ static void virtio_pci_notify_write_pio(void *opaque, 
> hwaddr addr,
>      unsigned queue = val;
>  
>      if (vdev != NULL && queue < VIRTIO_QUEUE_MAX) {
> +        trace_virtio_pci_notify_write_pio(addr, val, size);
>          virtio_queue_notify(vdev, queue);
>      }
>  }
> diff --git a/hw/virtio/trace-events b/hw/virtio/trace-events
> index 845200bf109d..189972b9213a 100644
> --- a/hw/virtio/trace-events
> +++ b/hw/virtio/trace-events
> @@ -55,7 +55,12 @@ virtio_mmio_guest_page(uint64_t size, int shift) "guest 
> page size 0x%" PRIx64 "
>  virtio_mmio_queue_write(uint64_t value, int max_size) "mmio_queue write 0x%" 
> PRIx64 " max %d"
>  virtio_mmio_setting_irq(int level) "virtio_mmio setting IRQ %d"
>  
> -# virtio-iommu.c
> +# virtio-pci.c
> +virtio_pci_notify(uint16_t vector) "virtio_pci_notify vec 0x%x"

Not used.

> +virtio_pci_notify_write(uint64_t addr, uint64_t val, unsigned int size) 
> "0x%" PRIx64" = 0x%" PRIx64 " (%d)"
> +virtio_pci_notify_write_pio(uint64_t addr, uint64_t val, unsigned int size) 
> "0x%" PRIx64" = 0x%" PRIx64 " (%d)"
> +
> +# hw/virtio/virtio-iommu.c

Probably left-over from automatic rename from patch #3
"move virtio-pci.h into shared include space", but please
keep the local name 'virtio-iommu.c'.

Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>

>  virtio_iommu_device_reset(void) "reset!"
>  virtio_iommu_get_features(uint64_t features) "device supports 
> features=0x%"PRIx64
>  virtio_iommu_device_status(uint8_t status) "driver status = %d"
> 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]