diff options
| author | Alexey Baturo | 2022-07-17 12:15:43 +0200 |
|---|---|---|
| committer | Alistair Francis | 2022-09-07 09:18:32 +0200 |
| commit | dec19f68130cda6c44c4eab4ed8c185c5ed40e5a (patch) | |
| tree | 3273f1e929aacd14e6f6788b2eec3c8b15577977 | |
| parent | roms/opensbi: Upgrade from v1.0 to v1.1 (diff) | |
| download | qemu-dec19f68130cda6c44c4eab4ed8c185c5ed40e5a.tar.gz qemu-dec19f68130cda6c44c4eab4ed8c185c5ed40e5a.tar.xz qemu-dec19f68130cda6c44c4eab4ed8c185c5ed40e5a.zip | |
target/riscv: Fix typo and restore Pointer Masking functionality for RISC-V
Fixes: 4302bef9e178 ("target/riscv: Calculate address according to XLEN")
Signed-off-by: Alexey Baturo <baturo.alexey@gmail.com>
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Message-Id: <20220717101543.478533-2-space.monkey.delivers@gmail.com>
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
| -rw-r--r-- | target/riscv/translate.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/target/riscv/translate.c b/target/riscv/translate.c index 6eeb728462..76da8db8a7 100644 --- a/target/riscv/translate.c +++ b/target/riscv/translate.c @@ -544,7 +544,7 @@ static TCGv get_address(DisasContext *ctx, int rs1, int imm) tcg_gen_addi_tl(addr, src1, imm); if (ctx->pm_mask_enabled) { - tcg_gen_and_tl(addr, addr, pm_mask); + tcg_gen_andc_tl(addr, addr, pm_mask); } else if (get_xl(ctx) == MXL_RV32) { tcg_gen_ext32u_tl(addr, addr); } |
