diff mbox series

[PULL,02/12] target/hppa: Use only low 2 immediate bits for PROBEI

Message ID 20231113173237.48233-3-richard.henderson@linaro.org
State Accepted
Commit e5d487c9724e0fc62b1afca9f8ea11fd072643a8
Headers show
Series [PULL,01/12] target/hppa: Mask reserved PSW bits in expand_sm_imm | expand

Commit Message

Richard Henderson Nov. 13, 2023, 5:32 p.m. UTC
During the conversion to decodetree, the 2-bit mask was lost.

Fixes: deee69a19fd ("target/hppa: Convert memory management insns")
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
---
 target/hppa/translate.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/target/hppa/translate.c b/target/hppa/translate.c
index f3b17ba16d..bb1b65fef0 100644
--- a/target/hppa/translate.c
+++ b/target/hppa/translate.c
@@ -2297,7 +2297,7 @@  static bool trans_probe(DisasContext *ctx, arg_probe *a)
     form_gva(ctx, &addr, &ofs, a->b, 0, 0, 0, a->sp, 0, false);
 
     if (a->imm) {
-        level = tcg_constant_i32(a->ri);
+        level = tcg_constant_i32(a->ri & 3);
     } else {
         level = tcg_temp_new_i32();
         tcg_gen_extrl_i64_i32(level, load_gpr(ctx, a->ri));