qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] Add m68k_cpu_list()
@ 2009-04-14 21:14 Laurent Vivier
  2009-04-30 17:44 ` Paul Brook
  0 siblings, 1 reply; 4+ messages in thread
From: Laurent Vivier @ 2009-04-14 21:14 UTC (permalink / raw)
  To: qemu-devel

[-- Attachment #1: Type: text/plain, Size: 196 bytes --]

This patch adds to m68k target the missing m68k_cpu_list():

$ ./m68k-softmmu/qemu-system-m68k -cpu ?
m68k m5206
m68k m5208
m68k cfv4e
m68k any

Signed-off-by: Laurent Vivier <Laurent@vivier.eu>


[-- Attachment #2: Type: text/x-vhdl, Size: 1419 bytes --]

---
 target-m68k/cpu.h    |    3 +++
 target-m68k/helper.c |    9 +++++++++
 2 files changed, 12 insertions(+)

Index: trunk/target-m68k/cpu.h
===================================================================
--- trunk.orig/target-m68k/cpu.h	2009-04-14 22:40:48.000000000 +0200
+++ trunk/target-m68k/cpu.h	2009-04-14 22:42:16.000000000 +0200
@@ -199,6 +199,8 @@
     return (env->features & (1u << feature)) != 0;
 }
 
+void m68k_cpu_list(FILE *f, int (*cpu_fprintf)(FILE *f, const char *fmt, ...));
+
 void register_m68k_insns (CPUM68KState *env);
 
 #ifdef CONFIG_USER_ONLY
@@ -213,6 +215,7 @@
 #define cpu_exec cpu_m68k_exec
 #define cpu_gen_code cpu_m68k_gen_code
 #define cpu_signal_handler cpu_m68k_signal_handler
+#define cpu_list m68k_cpu_list
 
 /* MMU modes definitions */
 #define MMU_MODE0_SUFFIX _kernel
Index: trunk/target-m68k/helper.c
===================================================================
--- trunk.orig/target-m68k/helper.c	2009-04-14 22:42:21.000000000 +0200
+++ trunk/target-m68k/helper.c	2009-04-14 22:59:56.000000000 +0200
@@ -54,6 +54,15 @@
     {NULL, 0},
 };
 
+void m68k_cpu_list(FILE *f, int (*cpu_fprintf)(FILE *f, const char *fmt, ...))
+{
+    unsigned int i;
+
+    for (i = 0; m68k_cpu_defs[i].name; i++) {
+        (*cpu_fprintf)(f, "m68k %s\n", m68k_cpu_defs[i].name);
+    }
+}
+
 static int fpu_gdb_get_reg(CPUState *env, uint8_t *mem_buf, int n)
 {
     if (n < 8) {

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Qemu-devel] [PATCH] Add m68k_cpu_list()
  2009-04-14 21:14 [Qemu-devel] [PATCH] Add m68k_cpu_list() Laurent Vivier
@ 2009-04-30 17:44 ` Paul Brook
  2009-04-30 18:09   ` Laurent Vivier
  0 siblings, 1 reply; 4+ messages in thread
From: Paul Brook @ 2009-04-30 17:44 UTC (permalink / raw)
  To: qemu-devel; +Cc: Laurent Vivier

On Tuesday 14 April 2009, Laurent Vivier wrote:
> This patch adds to m68k target the missing m68k_cpu_list():

The "m68k" prefix is bogus.

Paul

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Qemu-devel] [PATCH] Add m68k_cpu_list()
  2009-04-30 17:44 ` Paul Brook
@ 2009-04-30 18:09   ` Laurent Vivier
  2009-05-09 20:21     ` [Qemu-devel] [PATCH][v2] " Laurent Vivier
  0 siblings, 1 reply; 4+ messages in thread
From: Laurent Vivier @ 2009-04-30 18:09 UTC (permalink / raw)
  To: Paul Brook; +Cc: qemu-devel

Le jeudi 30 avril 2009 à 18:44 +0100, Paul Brook a écrit :
> On Tuesday 14 April 2009, Laurent Vivier wrote:
> > This patch adds to m68k target the missing m68k_cpu_list():
> 
> The "m68k" prefix is bogus.

So should I remove it or replace it by something else ?

(i386/x86_64, powerpc, mips, sparc use "x86", "PowerPC", "MIPS",
"Sparc")

Thank you,
Laurent

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Qemu-devel] [PATCH][v2] Add m68k_cpu_list()
  2009-04-30 18:09   ` Laurent Vivier
@ 2009-05-09 20:21     ` Laurent Vivier
  0 siblings, 0 replies; 4+ messages in thread
From: Laurent Vivier @ 2009-05-09 20:21 UTC (permalink / raw)
  To: qemu-devel; +Cc: Paul Brook, Laurent Vivier

This patch adds to m68k target the missing m68k_cpu_list():

$ ./m68k-softmmu/qemu-system-m68k -cpu ?
m5206
m5208
cfv4e
any

Signed-off-by: Laurent Vivier <laurent@vivier.eu>
---
 target-m68k/cpu.h    |    3 +++
 target-m68k/helper.c |    9 +++++++++
 2 files changed, 12 insertions(+), 0 deletions(-)

 Changelog:
 v2- remove "m68k" prefix

diff --git a/target-m68k/cpu.h b/target-m68k/cpu.h
index e2529eb..feffb6b 100644
--- a/target-m68k/cpu.h
+++ b/target-m68k/cpu.h
@@ -199,6 +199,8 @@ static inline int m68k_feature(CPUM68KState *env, int feature)
     return (env->features & (1u << feature)) != 0;
 }
 
+void m68k_cpu_list(FILE *f, int (*cpu_fprintf)(FILE *f, const char *fmt, ...));
+
 void register_m68k_insns (CPUM68KState *env);
 
 #ifdef CONFIG_USER_ONLY
@@ -213,6 +215,7 @@ void register_m68k_insns (CPUM68KState *env);
 #define cpu_exec cpu_m68k_exec
 #define cpu_gen_code cpu_m68k_gen_code
 #define cpu_signal_handler cpu_m68k_signal_handler
+#define cpu_list m68k_cpu_list
 
 /* MMU modes definitions */
 #define MMU_MODE0_SUFFIX _kernel
diff --git a/target-m68k/helper.c b/target-m68k/helper.c
index ad28322..af9ce22 100644
--- a/target-m68k/helper.c
+++ b/target-m68k/helper.c
@@ -54,6 +54,15 @@ static m68k_def_t m68k_cpu_defs[] = {
     {NULL, 0},
 };
 
+void m68k_cpu_list(FILE *f, int (*cpu_fprintf)(FILE *f, const char *fmt, ...))
+{
+    unsigned int i;
+
+    for (i = 0; m68k_cpu_defs[i].name; i++) {
+        (*cpu_fprintf)(f, "%s\n", m68k_cpu_defs[i].name);
+    }
+}
+
 static int fpu_gdb_get_reg(CPUState *env, uint8_t *mem_buf, int n)
 {
     if (n < 8) {
-- 
1.5.6.5

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-05-09 20:21 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-04-14 21:14 [Qemu-devel] [PATCH] Add m68k_cpu_list() Laurent Vivier
2009-04-30 17:44 ` Paul Brook
2009-04-30 18:09   ` Laurent Vivier
2009-05-09 20:21     ` [Qemu-devel] [PATCH][v2] " Laurent Vivier

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).