qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2 13/65] target/hppa: Introduce TYPE_HPPA64_CPU


From: Philippe Mathieu-Daudé
Subject: Re: [PATCH v2 13/65] target/hppa: Introduce TYPE_HPPA64_CPU
Date: Fri, 20 Oct 2023 23:19:21 +0200
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.15.1

On 20/10/23 22:42, Richard Henderson wrote:
Prepare for the qemu binary supporting both pa10 and pa20
at the same time.

Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
---
  target/hppa/cpu-qom.h   |  1 +
  target/hppa/cpu.h       |  5 +++++
  target/hppa/cpu.c       | 34 +++++++++++++++++++---------------
  target/hppa/translate.c |  2 ++
  4 files changed, 27 insertions(+), 15 deletions(-)


diff --git a/target/hppa/cpu.c b/target/hppa/cpu.c
index 1644297bf8..192aae268d 100644
--- a/target/hppa/cpu.c
+++ b/target/hppa/cpu.c
@@ -207,20 +207,24 @@ static void hppa_cpu_class_init(ObjectClass *oc, void 
*data)
      cc->tcg_ops = &hppa_tcg_ops;
  }
-static const TypeInfo hppa_cpu_type_info = {
-    .name = TYPE_HPPA_CPU,
-    .parent = TYPE_CPU,
-    .instance_size = sizeof(HPPACPU),
-    .instance_align = __alignof(HPPACPU),
-    .instance_init = hppa_cpu_initfn,
-    .abstract = false,
-    .class_size = sizeof(HPPACPUClass),
-    .class_init = hppa_cpu_class_init,
+static const TypeInfo hppa_cpu_type_infos[] = {
+    {
+        .name = TYPE_HPPA_CPU,
+        .parent = TYPE_CPU,
+        .instance_size = sizeof(HPPACPU),
+        .instance_align = __alignof(HPPACPU),
+        .instance_init = hppa_cpu_initfn,
+        .abstract = false,
+        .class_size = sizeof(HPPACPUClass),
+        .class_init = hppa_cpu_class_init,
+    },
+#ifdef TARGET_HPPA64
+    {
+        .name = TYPE_HPPA64_CPU,
+        .parent = TYPE_HPPA_CPU,
+        .instance_init = hppa64_cpu_initfn,

hppa64_cpu_initfn() is never declared and removed in patch #29,
remnant from old branch? Otherwise,

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>

(and thanks for converting to DEFINE_TYPES).

+    },
+#endif
  };




reply via email to

[Prev in Thread] Current Thread [Next in Thread]