Received: from eggs.gnu.org ([209.51.188.92]:33709) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hMWLQ-0007Tx-Qk for qemu-devel@nongnu.org; Fri, 03 May 2019 07:27:13 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hMWLP-0002yR-W9 for qemu-devel@nongnu.org; Fri, 03 May 2019 07:27:12 -0400 From: Laurent Vivier Date: Fri, 3 May 2019 13:26:43 +0200 Message-Id: <20190503112654.4393-2-laurent@vivier.eu> In-Reply-To: <20190503112654.4393-1-laurent@vivier.eu> References: <20190503112654.4393-1-laurent@vivier.eu> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Subject: [Qemu-devel] [PULL v2 01/12] hw/net/pcnet: Use qemu_log_mask(GUEST_ERROR) instead of printf List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Laurent Vivier , Paolo Bonzini , Fabien Chouteau , qemu-trivial@nongnu.org, Richard Henderson , Jason Wang , =?UTF-8?q?Andreas=20F=C3=A4rber?= , Michael Tokarev , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , Gerd Hoffmann , Artyom Tarasenko , Michael Roth , Mark Cave-Ayland , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Thomas Huth From: Philippe Mathieu-Daudé Avoid to clutter stdout until explicitly requested (with -d guest_errors): $ qemu-system-mips -M malta -m 512 -kernel vmlinux-3.2.0-4-4kc-malta Bad SWSTYLE=0x04 Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth Message-Id: <20190311102712.8572-1-philmd@redhat.com> Signed-off-by: Laurent Vivier --- hw/net/pcnet.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/hw/net/pcnet.c b/hw/net/pcnet.c index d9ba04bdfc62..16683091c939 100644 --- a/hw/net/pcnet.c +++ b/hw/net/pcnet.c @@ -36,6 +36,7 @@ */ #include "qemu/osdep.h" +#include "qemu/log.h" #include "hw/qdev.h" #include "net/net.h" #include "net/eth.h" @@ -1501,7 +1502,8 @@ static void pcnet_bcr_writew(PCNetState *s, uint32_t rap, uint32_t val) val |= 0x0300; break; default: - printf("Bad SWSTYLE=0x%02x\n", val & 0xff); + qemu_log_mask(LOG_GUEST_ERROR, "pcnet: Bad SWSTYLE=0x%02x\n", + val & 0xff); val = 0x0200; break; } -- 2.20.1