aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2013-02-11 16:41:20 +0000
committerBlue Swirl <blauwirbel@gmail.com>2013-02-16 10:43:58 +0000
commit9a7e54242910d26d280589e1f5c7ec8814d02a6b (patch)
tree84c7050c7ae1b984738441ebbf7d5c702135f765
parent5e5f07e08f7ed8c8eb9b02d9f9c3c79cf95d65ee (diff)
qemu-log: Unify {cpu_set,set_cpu}_log_filename as qemu_set_log_filename
The qemu_log() functionality is no longer specific to TCG CPU debug logs. Rename cpu_set_log_filename() to qemu_set_log_filename() and drop the pointless wrapper set_cpu_log_filename(). Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
-rw-r--r--bsd-user/main.c2
-rw-r--r--cpus.c5
-rw-r--r--include/qemu/log.h2
-rw-r--r--include/sysemu/cpus.h1
-rw-r--r--linux-user/main.c4
-rw-r--r--monitor.c2
-rw-r--r--qemu-log.c2
-rw-r--r--vl.c2
8 files changed, 7 insertions, 13 deletions
diff --git a/bsd-user/main.c b/bsd-user/main.c
index ae24723710..76ab35909c 100644
--- a/bsd-user/main.c
+++ b/bsd-user/main.c
@@ -861,7 +861,7 @@ int main(int argc, char **argv)
}
/* init debug */
- cpu_set_log_filename(log_file);
+ qemu_set_log_filename(log_file);
if (log_mask) {
int mask;
const CPULogItem *item;
diff --git a/cpus.c b/cpus.c
index 41779eb02e..2155441b35 100644
--- a/cpus.c
+++ b/cpus.c
@@ -1191,11 +1191,6 @@ void set_cpu_log(const char *optarg)
cpu_set_log(mask);
}
-void set_cpu_log_filename(const char *optarg)
-{
- cpu_set_log_filename(optarg);
-}
-
void list_cpus(FILE *f, fprintf_function cpu_fprintf, const char *optarg)
{
/* XXX: implement xxx_cpu_list for targets that still miss it */
diff --git a/include/qemu/log.h b/include/qemu/log.h
index 58f69cb494..4760e04c5e 100644
--- a/include/qemu/log.h
+++ b/include/qemu/log.h
@@ -154,7 +154,7 @@ static inline void cpu_set_log(int log_flags)
#endif
}
-void cpu_set_log_filename(const char *filename);
+void qemu_set_log_filename(const char *filename);
int cpu_str_to_log_mask(const char *str);
#endif
diff --git a/include/sysemu/cpus.h b/include/sysemu/cpus.h
index f7f6854259..60e44bb70c 100644
--- a/include/sysemu/cpus.h
+++ b/include/sysemu/cpus.h
@@ -25,7 +25,6 @@ extern int smp_threads;
void set_numa_modes(void);
void set_cpu_log(const char *optarg);
-void set_cpu_log_filename(const char *optarg);
void list_cpus(FILE *f, fprintf_function cpu_fprintf, const char *optarg);
#endif
diff --git a/linux-user/main.c b/linux-user/main.c
index 7902f3beb2..4beb5c9ae5 100644
--- a/linux-user/main.c
+++ b/linux-user/main.c
@@ -3113,7 +3113,7 @@ static void handle_arg_log(const char *arg)
static void handle_arg_log_filename(const char *arg)
{
- cpu_set_log_filename(arg);
+ qemu_set_log_filename(arg);
}
static void handle_arg_set_env(const char *arg)
@@ -3480,7 +3480,7 @@ int main(int argc, char **argv, char **envp)
#endif
/* init debug */
- cpu_set_log_filename(log_file);
+ qemu_set_log_filename(log_file);
optind = parse_args(argc, argv);
/* Zero out regs */
diff --git a/monitor.c b/monitor.c
index 20bd19b05f..578a31803f 100644
--- a/monitor.c
+++ b/monitor.c
@@ -964,7 +964,7 @@ static int client_migrate_info(Monitor *mon, const QDict *qdict,
static void do_logfile(Monitor *mon, const QDict *qdict)
{
- cpu_set_log_filename(qdict_get_str(qdict, "filename"));
+ qemu_set_log_filename(qdict_get_str(qdict, "filename"));
}
static void do_log(Monitor *mon, const QDict *qdict)
diff --git a/qemu-log.c b/qemu-log.c
index 30c9ab01bd..9a7e5675a1 100644
--- a/qemu-log.c
+++ b/qemu-log.c
@@ -86,7 +86,7 @@ void qemu_set_log(int log_flags, bool use_own_buffers)
}
}
-void cpu_set_log_filename(const char *filename)
+void qemu_set_log_filename(const char *filename)
{
g_free(logfilename);
logfilename = g_strdup(filename);
diff --git a/vl.c b/vl.c
index 1355f6959e..f9f4dda2d7 100644
--- a/vl.c
+++ b/vl.c
@@ -3865,7 +3865,7 @@ int main(int argc, char **argv, char **envp)
*/
if (log_mask) {
if (log_file) {
- set_cpu_log_filename(log_file);
+ qemu_set_log_filename(log_file);
}
set_cpu_log(log_mask);
}