[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-stable] [PATCH 41/56] target-sparc: fix register corruption in lds
From: |
Michael Roth |
Subject: |
[Qemu-stable] [PATCH 41/56] target-sparc: fix register corruption in ldstub if there is no write permission |
Date: |
Mon, 8 Aug 2016 16:04:12 -0500 |
From: Artyom Tarasenko <address@hidden>
Signed-off-by: Artyom Tarasenko <address@hidden>
Reviewed-by: Richard Henderson <address@hidden>
Signed-off-by: Mark Cave-Ayland <address@hidden>
(cherry picked from commit b64d2e57e704edbb56ae969de864292dd38379bf)
Signed-off-by: Michael Roth <address@hidden>
---
target-sparc/translate.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/target-sparc/translate.c b/target-sparc/translate.c
index 7998ff5..502510c 100644
--- a/target-sparc/translate.c
+++ b/target-sparc/translate.c
@@ -4668,12 +4668,15 @@ static void disas_sparc_insn(DisasContext * dc,
unsigned int insn)
case 0xd: /* ldstub -- XXX: should be atomically */
{
TCGv r_const;
+ TCGv tmp = tcg_temp_new();
gen_address_mask(dc, cpu_addr);
- tcg_gen_qemu_ld8u(cpu_val, cpu_addr, dc->mem_idx);
+ tcg_gen_qemu_ld8u(tmp, cpu_addr, dc->mem_idx);
r_const = tcg_const_tl(0xff);
tcg_gen_qemu_st8(r_const, cpu_addr, dc->mem_idx);
+ tcg_gen_mov_tl(cpu_val, tmp);
tcg_temp_free(r_const);
+ tcg_temp_free(tmp);
}
break;
case 0x0f:
--
1.9.1
- [Qemu-stable] [PATCH 28/56] vmsvga: shadow fifo registers, (continued)
- [Qemu-stable] [PATCH 28/56] vmsvga: shadow fifo registers, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 02/56] spice/gl: add & use qemu_spice_gl_monitor_config, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 34/56] qcow2: Avoid making the L1 table too big, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 32/56] net: fix qemu_announce_self not emitting packets, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 35/56] qapi: Fix crash on missing alternate member of QAPI struct, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 36/56] pci-assign: Move "Invalid ROM" error message to pci-assign-load-rom.c, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 37/56] vfio/pci: Fix VGA quirks, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 38/56] nbd: Allow larger requests, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 39/56] scsi-generic: Merge block max xfer len in INQUIRY response, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 40/56] scsi: Advertise limits by blocksize, not 512, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 41/56] target-sparc: fix register corruption in ldstub if there is no write permission,
Michael Roth <=
- [Qemu-stable] [PATCH 44/56] s390x/ipl: fix reboots for migration from different bios, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 46/56] qemu-iotests: Test naming of throttling groups, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 03/56] vl: change runstate only if new state is different from current state, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 45/56] blockdev: Fix regression with the default naming of throttling groups, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 42/56] virtio: set low features early on load, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 43/56] Revert "virtio-net: unbreak self announcement and guest offloads after migration", Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 47/56] util: Fix MIN_NON_ZERO, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 48/56] block/iscsi: fix rounding in iscsi_allocationmap_set, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 50/56] nbd: More debug typo fixes, use correct formats, Michael Roth, 2016/08/08
- [Qemu-stable] [PATCH 04/56] tools: kvm_stat: Powerpc related fixes, Michael Roth, 2016/08/08