Received: from list by lists.gnu.org with archive (Exim 4.90_1) id 1kx9TQ-0001t8-Fz for mharc-qemu-trivial@gnu.org; Wed, 06 Jan 2021 09:07:40 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:45610) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kx9TP-0001r7-1s for qemu-trivial@nongnu.org; Wed, 06 Jan 2021 09:07:39 -0500 Received: from us-smtp-delivery-124.mimecast.com ([63.128.21.124]:38393) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.90_1) (envelope-from ) id 1kx9TK-0007bc-Ob for qemu-trivial@nongnu.org; Wed, 06 Jan 2021 09:07:38 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1609942053; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Okjv9WQqSNyrIa21ExztnynhLifNVac34GIp1dK124U=; b=THULNcJI3gW01ADhLHwIcxgDgqVDJeOuB/KW1Urio/lLrnztT9Vi92VDU3O0CMFdn82nyR Dt4xU4/RjBXrqw28qaVegfSeQu5EoloTuLuNCDPgLMDe4kdGJdMOHbDgDNsH67V3dSES5s pBb5AGodHn2eP9SZc+k2qVw9trVQ7i4= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-492-E3fYobC_NmuxvKprxONqyg-1; Wed, 06 Jan 2021 09:07:32 -0500 X-MC-Unique: E3fYobC_NmuxvKprxONqyg-1 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 08E77107ACE3; Wed, 6 Jan 2021 14:07:31 +0000 (UTC) Received: from thuth.remote.csb (ovpn-112-219.ams2.redhat.com [10.36.112.219]) by smtp.corp.redhat.com (Postfix) with ESMTP id 40523608DB; Wed, 6 Jan 2021 14:07:20 +0000 (UTC) Subject: Re: [PATCH] hw/virtio-pci: Replace error_report() by qemu_log_mask(GUEST_ERROR) To: =?UTF-8?Q?Philippe_Mathieu-Daud=c3=a9?= , qemu-devel@nongnu.org Cc: qemu-trivial@nongnu.org, "Michael S. Tsirkin" References: <20201210172834.178052-1-philmd@redhat.com> From: Thomas Huth Message-ID: <7cf4d5fc-651a-eac5-6678-1ce49b68f087@redhat.com> Date: Wed, 6 Jan 2021 15:07:18 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.4.0 MIME-Version: 1.0 In-Reply-To: <20201210172834.178052-1-philmd@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=thuth@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=63.128.21.124; envelope-from=thuth@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -32 X-Spam_score: -3.3 X-Spam_bar: --- X-Spam_report: (-3.3 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.252, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, NICE_REPLY_A=-0.249, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-trivial@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 06 Jan 2021 14:07:39 -0000 On 10/12/2020 18.28, Philippe Mathieu-Daudé wrote: > Replace I/O write error reported with error_report() by > qemu_log_mask(GUEST_ERROR) which allow filtering. > > Signed-off-by: Philippe Mathieu-Daudé > --- > 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 f863f69ede4..094c36aa3ea 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; > } > } Reviewed-by: Thomas Huth