diff options
| author | Peter Maydell <peter.maydell@linaro.org> | 2020-11-05 21:23:14 +0000 |
|---|---|---|
| committer | Laurent Vivier <laurent@vivier.eu> | 2020-11-10 07:54:22 +0100 |
| commit | c3ab5df2f5c466d998917f2c707e206322063dcd (patch) | |
| tree | bc045a48f8b8403d900ddcd2934366e03efab91a /hw/ssi/xilinx_spi.c | |
| parent | 266b41582e0de8c30707614d6733ecf6485c7677 (diff) | |
| download | focaccia-qemu-c3ab5df2f5c466d998917f2c707e206322063dcd.tar.gz focaccia-qemu-c3ab5df2f5c466d998917f2c707e206322063dcd.zip | |
linux-user/sparc: Don't zero high half of PC, NPC, PSR in sigreturn
The function do_sigreturn() tries to store the PC, NPC and PSR in uint32_t local variables, which implicitly drops the high half of these fields for 64-bit guests. The usual effect was that a guest which used signals would crash on return from a signal unless it was lucky enough to take it while the PC was in the low 4GB of the address space. In particular, Debian /bin/dash and /bin/bash would segfault after executing external commands. Use abi_ulong, which is the type these fields all have in the __siginfo_t struct. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-Id: <20201105212314.9628-4-peter.maydell@linaro.org> Signed-off-by: Laurent Vivier <laurent@vivier.eu>
Diffstat (limited to 'hw/ssi/xilinx_spi.c')
0 files changed, 0 insertions, 0 deletions