On 4/28/25 04:50, Daniel Henrique Barboza wrote:
  static const TypeInfo riscv_kvm_cpu_type_infos[] = {
      {
          .name = TYPE_RISCV_CPU_HOST,
          .parent = TYPE_RISCV_CPU,
-        .class_init = riscv_host_cpu_class_init,
+#if defined(TARGET_RISCV32)
+        .class_data = &((const RISCVCPUDef) {
+            .misa_mxl_max = MXL_RV32,
+        },
+#elif defined(TARGET_RISCV64)
+        .class_data = &((const RISCVCPUDef) {
+            .misa_mxl_max = MXL_RV64,
+        },
+#endif
      }
  };

Are we sure this patch compiles? As I said in the v3 this except opening 2 
parentheses
and closing just one after RISCVCPUDef:


-        .class_init = riscv_host_cpu_class_init,
+#if defined(TARGET_RISCV32)
+        .class_data = &(( <-----
                        const RISCVCPUDef) {

I'll repeat that the parenthesis are completely unnecessary, just

  = &(const RISCVCPUDef){ ... }

The extras should be dropped everywhere.


r~


Reply via email to