diff options
Diffstat (limited to 'target-sparc/translate.c')
-rw-r--r-- | target-sparc/translate.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/target-sparc/translate.c b/target-sparc/translate.c index 0812e95a37..645b414228 100644 --- a/target-sparc/translate.c +++ b/target-sparc/translate.c @@ -3301,7 +3301,6 @@ extern int ram_size; void cpu_reset(CPUSPARCState *env) { - memset(env, 0, sizeof(*env)); tlb_flush(env, 1); env->cwp = 0; env->wim = 1; @@ -3313,14 +3312,15 @@ void cpu_reset(CPUSPARCState *env) env->cansave = NWINDOWS - 1; #endif #else + env->psret = 0; env->psrs = 1; env->psrps = 1; - env->gregs[1] = ram_size; #ifdef TARGET_SPARC64 env->pstate = PS_PRIV; env->pc = 0x1fff0000000ULL; #else env->pc = 0xffd00000; + env->mmuregs[0] &= ~(MMU_E | MMU_NF); #endif env->npc = env->pc + 4; #endif |