From a82185880e62ca11e52332b9d14971fad31bc6e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Date: Thu, 10 Dec 2020 18:28:34 +0100 Subject: [PATCH] hw/virtio-pci: Replace error_report() by qemu_log_mask(GUEST_ERROR) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replace I/O write error reported with error_report() by qemu_log_mask(GUEST_ERROR) which allow filtering. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth Reviewed-by: Stefano Garzarella Message-Id: <20201210172834.178052-1-philmd@redhat.com> Signed-off-by: Laurent Vivier --- hw/virtio/virtio-pci.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c index f863f69ede4f..094c36aa3ea3 100644 --- a/hw/virtio/virtio-pci.c +++ b/hw/virtio/virtio-pci.c @@ -27,6 +27,7 @@ #include "hw/qdev-properties.h" #include "qapi/error.h" #include "qemu/error-report.h" +#include "qemu/log.h" #include "qemu/module.h" #include "hw/pci/msi.h" #include "hw/pci/msix.h" @@ -365,8 +366,9 @@ static void virtio_ioport_write(void *opaque, uint32_t addr, uint32_t val) virtio_queue_set_vector(vdev, vdev->queue_sel, val); break; default: - error_report("%s: unexpected address 0x%x value 0x%x", - __func__, addr, val); + qemu_log_mask(LOG_GUEST_ERROR, + "%s: unexpected address 0x%x value 0x%x\n", + __func__, addr, val); break; } }