target-mips: Allow DSP access to be disabled once enabled.
authorEric Johnson <ericj@mips.com>
Tue, 8 Jan 2013 06:26:44 +0000 (22:26 -0800)
committerAurelien Jarno <aurelien@aurel32.net>
Tue, 8 Jan 2013 10:49:01 +0000 (11:49 +0100)
Clear the DSP hflags at the start of compute_hflags.  Otherwise access
is not properly disabled once enabled.

Signed-off-by: Eric Johnson <ericj@mips.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
target-mips/cpu.h

index 31602ac8ede8156853897efb827ddad507c6f12c..5963d62973274a19ef43a3952e06c626b6b75067 100644 (file)
@@ -751,7 +751,7 @@ static inline void compute_hflags(CPUMIPSState *env)
 {
     env->hflags &= ~(MIPS_HFLAG_COP1X | MIPS_HFLAG_64 | MIPS_HFLAG_CP0 |
                      MIPS_HFLAG_F64 | MIPS_HFLAG_FPU | MIPS_HFLAG_KSU |
-                     MIPS_HFLAG_UX);
+                     MIPS_HFLAG_UX | MIPS_HFLAG_DSP | MIPS_HFLAG_DSPR2);
     if (!(env->CP0_Status & (1 << CP0St_EXL)) &&
         !(env->CP0_Status & (1 << CP0St_ERL)) &&
         !(env->hflags & MIPS_HFLAG_DM)) {