aboutsummaryrefslogtreecommitdiff
path: root/target-sh4/cpu-qom.h
diff options
context:
space:
mode:
authorAndreas Färber <afaerber@suse.de>2012-11-19 02:42:18 +0100
committerAndreas Färber <afaerber@suse.de>2013-03-12 10:35:54 +0100
commitc1b382e77d8693955d8838c19b33aeb214724f9b (patch)
tree30d4c1ba5a13e2e5335e680a2fbc99217e31a403 /target-sh4/cpu-qom.h
parent151d1322a3a0c865089c09aeb50f18215121921a (diff)
target-sh4: Introduce SuperHCPU subclasses
Store legacy name in SuperHCPUClass for -cpu ? and for case-insensitive class lookup. List CPUs by iterating over TYPE_SUPERH_CPU subclasses. Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'target-sh4/cpu-qom.h')
-rw-r--r--target-sh4/cpu-qom.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/target-sh4/cpu-qom.h b/target-sh4/cpu-qom.h
index f4e8976478..19d8b084ff 100644
--- a/target-sh4/cpu-qom.h
+++ b/target-sh4/cpu-qom.h
@@ -24,6 +24,10 @@
#define TYPE_SUPERH_CPU "superh-cpu"
+#define TYPE_SH7750R_CPU "sh7750r-" TYPE_SUPERH_CPU
+#define TYPE_SH7751R_CPU "sh7751r-" TYPE_SUPERH_CPU
+#define TYPE_SH7785_CPU "sh7785-" TYPE_SUPERH_CPU
+
#define SUPERH_CPU_CLASS(klass) \
OBJECT_CLASS_CHECK(SuperHCPUClass, (klass), TYPE_SUPERH_CPU)
#define SUPERH_CPU(obj) \
@@ -35,6 +39,7 @@
* SuperHCPUClass:
* @parent_realize: The parent class' realize handler.
* @parent_reset: The parent class' reset handler.
+ * @name: The name.
*
* A SuperH CPU model.
*/
@@ -45,6 +50,8 @@ typedef struct SuperHCPUClass {
DeviceRealize parent_realize;
void (*parent_reset)(CPUState *cpu);
+
+ const char *name;
} SuperHCPUClass;
/**