]> git.proxmox.com Git - qemu.git/commitdiff
qemu-log: Add new log category for guest bugs
authorPeter Maydell <peter.maydell@linaro.org>
Thu, 18 Oct 2012 13:11:35 +0000 (14:11 +0100)
committerBlue Swirl <blauwirbel@gmail.com>
Sat, 20 Oct 2012 07:56:22 +0000 (07:56 +0000)
Add a new category for device models to log guest behaviour
which is likely to be a guest bug of some kind (accessing
nonexistent registers, reading 32 bit wide registers with
a byte access, etc). Making this its own log category allows
those who care (mostly guest OS authors) to see the complaints
without bothering most users.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
qemu-log.c
qemu-log.h

index 396aafdf6271ada276f4a6d2b170c465809ef0a1..a4c3d1f2e37f7ae23722d0acaeac690e9e48323c 100644 (file)
@@ -116,6 +116,9 @@ const CPULogItem cpu_log_items[] = {
       "show all i/o ports accesses" },
     { LOG_UNIMP, "unimp",
       "log unimplemented functionality" },
+    { LOG_GUEST_ERROR, "guest_errors",
+      "log when the guest OS does something invalid (eg accessing a\n"
+      "non-existent register)" },
     { 0, NULL, NULL },
 };
 
index 5ccecf30aff844e3f47c620f88fa32e4127663f7..ce6bb095b35693f56560e4b6d8a1a45b9adc5d32 100644 (file)
@@ -35,6 +35,7 @@ static inline bool qemu_log_enabled(void)
 #define CPU_LOG_TB_CPU     (1 << 8)
 #define CPU_LOG_RESET      (1 << 9)
 #define LOG_UNIMP          (1 << 10)
+#define LOG_GUEST_ERROR    (1 << 11)
 
 /* Returns true if a bit is set in the current loglevel mask
  */