From dec4c7014261a46fd3fdc9cc1114332a7ecb0684 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Fri, 5 Mar 2021 08:33:11 -0500 Subject: [PATCH] i386: Fix build --- qemu/target/i386/cpu.c | 22 ++++++++-------------- qemu/target/i386/fpu_helper.c | 2 +- 2 files changed, 9 insertions(+), 15 deletions(-) diff --git a/qemu/target/i386/cpu.c b/qemu/target/i386/cpu.c index 9d8b3d87..a8592d03 100644 --- a/qemu/target/i386/cpu.c +++ b/qemu/target/i386/cpu.c @@ -5904,24 +5904,18 @@ static void x86_cpu_common_class_init(struct uc_struct *uc, ObjectClass *oc, voi void x86_cpu_register_types(void *opaque) { const TypeInfo x86_cpu_type_info = { - TYPE_X86_CPU, - TYPE_CPU, + .name = TYPE_X86_CPU, + .parent = TYPE_CPU, - sizeof(X86CPUClass), - sizeof(X86CPU), - opaque, + .class_size = sizeof(X86CPUClass), + .instance_size = sizeof(X86CPU), + .instance_userdata = opaque, - x86_cpu_initfn, - NULL, - NULL, + .instance_init = x86_cpu_initfn, - NULL, + .class_init = x86_cpu_common_class_init, - x86_cpu_common_class_init, - NULL, - NULL, - - true, + .abstract = true, }; int i; diff --git a/qemu/target/i386/fpu_helper.c b/qemu/target/i386/fpu_helper.c index 013cff6f..2b5bb845 100644 --- a/qemu/target/i386/fpu_helper.c +++ b/qemu/target/i386/fpu_helper.c @@ -2942,7 +2942,7 @@ void update_mxcsr_status(CPUX86State *env) void update_mxcsr_from_sse_status(CPUX86State *env) { - if (tcg_enabled()) { + if (tcg_enabled(env->uc)) { uint8_t flags = get_float_exception_flags(&env->sse_status); /* * The MXCSR denormal flag has opposite semantics to