]> git.proxmox.com Git - mirror_qemu.git/commitdiff
hw/char/xilinx_uartlite: Replace hw_error() by qemu_log_mask()
authorPhilippe Mathieu-Daudé <f4bug@amsat.org>
Mon, 18 May 2020 14:03:08 +0000 (16:03 +0200)
committerPeter Maydell <peter.maydell@linaro.org>
Thu, 21 May 2020 21:05:27 +0000 (22:05 +0100)
hw_error() calls exit(). This a bit overkill when we can log
the accesses as unimplemented or guest error.

When fuzzing the devices, we don't want the whole process to
exit. Replace some hw_error() calls by qemu_log_mask().

Reviewed-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com>
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Message-id: 20200518140309.5220-4-f4bug@amsat.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
hw/char/xilinx_uartlite.c

index c6512285d73a2b4ec0ed6753a96fbf402d3178f1..ae4ccd00c70e5bd194ff2e55907d3ec23b0a2fee 100644 (file)
@@ -23,7 +23,7 @@
  */
 
 #include "qemu/osdep.h"
-#include "hw/hw.h"
+#include "qemu/log.h"
 #include "hw/irq.h"
 #include "hw/qdev-properties.h"
 #include "hw/sysbus.h"
@@ -135,7 +135,8 @@ uart_write(void *opaque, hwaddr addr,
     switch (addr)
     {
         case R_STATUS:
-            hw_error("write to UART STATUS?\n");
+            qemu_log_mask(LOG_GUEST_ERROR, "%s: write to UART STATUS\n",
+                          __func__);
             break;
 
         case R_CTRL: