diff mbox

[PULL,02/30] target-mips: Make CP1.FIR read-only here too

Message ID 1418759356-14242-3-git-send-email-leon.alrae@imgtec.com
State New
Headers show

Commit Message

Leon Alrae Dec. 16, 2014, 7:48 p.m. UTC
From: "Maciej W. Rozycki" <macro@codesourcery.com>

CP1.FIR is read-only in hardware so gdbstub must respect it.  We already
respect it for CTC1 instructions, so do it here too.

Signed-off-by: Maciej W. Rozycki <macro@codesourcery.com>
Reviewed-by: Leon Alrae <leon.alrae@imgtec.com>
Signed-off-by: Leon Alrae <leon.alrae@imgtec.com>
---
 target-mips/gdbstub.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox

Patch

diff --git a/target-mips/gdbstub.c b/target-mips/gdbstub.c
index 7e3a604..e86df0e 100644
--- a/target-mips/gdbstub.c
+++ b/target-mips/gdbstub.c
@@ -105,7 +105,7 @@  int mips_cpu_gdb_write_register(CPUState *cs, uint8_t *mem_buf, int n)
             RESTORE_ROUNDING_MODE;
             break;
         case 71:
-            env->active_fpu.fcr0 = tmp;
+            /* FIR is read-only.  Ignore writes.  */
             break;
         }
         return sizeof(target_ulong);