diff mbox series

[1/4] target/xtensa: add translation for wsr.mpucfg

Message ID 20240112042128.3569220-2-jcmvbkbc@gmail.com (mailing list archive)
State New, archived
Headers show
Series target/xtensa: provide configuration with MPU | expand

Commit Message

Max Filippov Jan. 12, 2024, 4:21 a.m. UTC
Although MPUCFG is not writable, the opcode wsr.mpucfg is defined and it
just does nothing. Define wsr.mpucfg as nop.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
---
 target/xtensa/translate.c | 9 +++++++++
 1 file changed, 9 insertions(+)
diff mbox series

Patch

diff --git a/target/xtensa/translate.c b/target/xtensa/translate.c
index de899405994e..6a2f5d308e6a 100644
--- a/target/xtensa/translate.c
+++ b/target/xtensa/translate.c
@@ -5332,6 +5332,15 @@  static const XtensaOpcodeOps core_ops[] = {
             XTENSA_OPTION_TRACE_PORT,
         },
         .op_flags = XTENSA_OP_PRIVILEGED,
+    }, {
+        .name = "wsr.mpucfg",
+        .translate = translate_nop,
+        .test_exceptions = test_exceptions_sr,
+        .par = (const uint32_t[]){
+            MPUCFG,
+            XTENSA_OPTION_MPU,
+        },
+        .op_flags = XTENSA_OP_PRIVILEGED,
     }, {
         .name = "wsr.mpuenb",
         .translate = translate_wsr_mpuenb,