On 5/8/26 10:12, James Hilliard wrote:
Implement the MIPS_ATOMIC_SET sysmips command as an aligned 32-bit atomic
exchange in target memory.

MIPS reports syscall errors through a separate register, so successful old
values can overlap the errno range.  Write the return value and error flag
directly and return -QEMU_ESIGRETURN so the common syscall path leaves the
registers unchanged.

Signed-off-by: James Hilliard<[email protected]>
---
Changes v2 -> v3:
   - Split MIPS_ATOMIC_SET out of the combined sysmips/MIPS_FIXADE patch.
     (suggested by Richard Henderson)
   - Always use the explicit MIPS return-register path for successful
     atomic_set results.  (suggested by Richard Henderson)
---
  linux-user/mips/target_syscall.h   |  1 +
  linux-user/mips64/target_syscall.h |  1 +
  linux-user/syscall.c               | 31 +++++++++++++++++++++++++++++++
  3 files changed, 33 insertions(+)

Reviewed-by: Richard Henderson <[email protected]>

r~

Reply via email to