aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--linux-user/main.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/linux-user/main.c b/linux-user/main.c
index f2b83b0c27..6b5ed2af67 100644
--- a/linux-user/main.c
+++ b/linux-user/main.c
@@ -1052,8 +1052,12 @@ int main(int argc, char **argv)
cpu_x86_set_cpl(env, 3);
env->cr[0] = CR0_PG_MASK | CR0_WP_MASK | CR0_PE_MASK;
- env->hflags |= HF_PE_MASK | HF_OSFXSR_MASK;
-
+ env->hflags |= HF_PE_MASK;
+ if (env->cpuid_features & CPUID_SSE) {
+ env->cr[4] |= CR4_OSFXSR_MASK;
+ env->hflags |= HF_OSFXSR_MASK;
+ }
+
/* flags setup : we activate the IRQs by default as in user mode */
env->eflags |= IF_MASK;