qemu_print_log_usage(stdout);
exit(1);
}
- cpu_set_log(mask);
+ qemu_set_log(mask);
}
if (optind >= argc) {
qemu_print_log_usage(stdout);
exit(1);
}
- cpu_set_log(mask);
+ qemu_set_log(mask);
}
void list_cpus(FILE *f, fprintf_function cpu_fprintf, const char *optarg)
break;
case 2:
printf("Set loglevel to %04" PRIx32 "\n", val);
- cpu_set_log(val | 0x100);
+ qemu_set_log(val | 0x100);
break;
}
}
extern const CPULogItem cpu_log_items[];
-void qemu_set_log(int log_flags, bool use_own_buffers);
+/* This is the function that actually does the work of
+ * changing the log level; it should only be accessed via
+ * the qemu_set_log() wrapper.
+ */
+void do_qemu_set_log(int log_flags, bool use_own_buffers);
-static inline void cpu_set_log(int log_flags)
+static inline void qemu_set_log(int log_flags)
{
#ifdef CONFIG_USER_ONLY
- qemu_set_log(log_flags, true);
+ do_qemu_set_log(log_flags, true);
#else
- qemu_set_log(log_flags, false);
+ do_qemu_set_log(log_flags, false);
#endif
}
qemu_print_log_usage(stdout);
exit(1);
}
- cpu_set_log(mask);
+ qemu_set_log(mask);
}
static void handle_arg_log_filename(const char *arg)
return;
}
}
- cpu_set_log(mask);
+ qemu_set_log(mask);
}
static void do_singlestep(Monitor *mon, const QDict *qdict)
}
/* enable or disable low levels log */
-void qemu_set_log(int log_flags, bool use_own_buffers)
+void do_qemu_set_log(int log_flags, bool use_own_buffers)
{
const char *fname = logfilename ?: DEFAULT_LOGFILENAME;
fclose(qemu_logfile);
qemu_logfile = NULL;
}
- cpu_set_log(qemu_loglevel);
+ qemu_set_log(qemu_loglevel);
}
const CPULogItem cpu_log_items[] = {
#else
/* start debug */
tb_flush(env);
- cpu_set_log(CPU_LOG_INT | CPU_LOG_TB_IN_ASM);
+ qemu_set_log(CPU_LOG_INT | CPU_LOG_TB_IN_ASM);
#endif
break;
#endif
#if defined(CONFIG_DEBUG_TCG_INTERPRETER)
const char *envval = getenv("DEBUG_TCG");
if (envval) {
- cpu_set_log(strtol(envval, NULL, 0));
+ qemu_set_log(strtol(envval, NULL, 0));
}
#endif