]> git.proxmox.com Git - mirror_qemu.git/commit
target/riscv: Remove atomic accesses to MIP CSR
authorAlistair Francis <alistair.francis@wdc.com>
Tue, 8 Oct 2019 22:04:18 +0000 (15:04 -0700)
committerPalmer Dabbelt <palmer@dabbelt.com>
Thu, 14 Nov 2019 17:53:28 +0000 (09:53 -0800)
commit7ec5d3030b9293ab631dd653f64bc933b6c82e65
treed296987c0cce26292ad67b885672f9104c2f7b4b
parentf480f6e8c5ca9a27c046e3a273a4693d2475bdc2
target/riscv: Remove atomic accesses to MIP CSR

Instead of relying on atomics to access the MIP register let's update
our helper function to instead just lock the IO mutex thread before
writing. This follows the same concept as used in PPC for handling
interrupts

Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Palmer Dabbelt <palmer@dabbelt.com>
Signed-off-by: Palmer Dabbelt <palmer@sifive.com>
Signed-off-by: Palmer Dabbelt <palmer@dabbelt.com>
target/riscv/cpu.c
target/riscv/cpu.h
target/riscv/cpu_helper.c
target/riscv/csr.c