diff mbox series

[02/11] target/mips: R5900 LQ and SQ also belong to the Toshiba MMI ASE

Message ID a60d093678ab59a6a63c3d6e259f34363791be96.1540487815.git.noring@nocrew.org (mailing list archive)
State New, archived
Headers show
Series target/mips: Amend R5900 support | expand

Commit Message

Fredrik Noring Oct. 25, 2018, 5:30 p.m. UTC
Signed-off-by: Fredrik Noring <noring@nocrew.org>
---
 target/mips/translate.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/target/mips/translate.c b/target/mips/translate.c
index 8547a6e6f6..18167df26d 100644
--- a/target/mips/translate.c
+++ b/target/mips/translate.c
@@ -26100,7 +26100,8 @@  static void decode_opc(CPUMIPSState *env, DisasContext *ctx)
         }
         break;
     case OPC_SPECIAL3:
-        if (ctx->insn_flags & INSN_R5900) {
+        if ((ctx->insn_flags & INSN_R5900) &&
+            (ctx->insn_flags & ASE_TOSHIBA_MMI)) {
             decode_tx79_sq(env, ctx);    /* TX79_SQ */
         } else {
             decode_opc_special3(env, ctx);
@@ -26764,7 +26765,8 @@  static void decode_opc(CPUMIPSState *env, DisasContext *ctx)
         }
         break;
     case OPC_MSA: /* OPC_MDMX */
-        if (ctx->insn_flags & INSN_R5900) {
+        if ((ctx->insn_flags & INSN_R5900) &&
+            (ctx->insn_flags & ASE_TOSHIBA_MMI)) {
             decode_tx79_lq(env, ctx);    /* TX79_LQ */
         } else {
             /* MDMX: Not implemented. */