Branch: refs/heads/master Home: https://github.com/qemu/qemu Commit: 20ef66706020a874d03092a673a24ae74685cb4d https://github.com/qemu/qemu/commit/20ef66706020a874d03092a673a24ae74685cb4d Author: Max Filippov <jcmvb...@gmail.com> Date: 2018-03-31 (Sat, 31 Mar 2018)
Changed paths: M linux-user/signal.c Log Message: ----------- target/xtensa: fix flush_window_regs flush_window_regs uses wrong stack frame to save overflow registers in call8 and call12 frames, which results in wrong register values in callers of a function that received a signal. Reimplement flush_window_regs closely following window overflow sequence. Signed-off-by: Max Filippov <jcmvb...@gmail.com> Commit: 4a6bf7adb92d1b8b7cd3763740b4a5180c0147d5 https://github.com/qemu/qemu/commit/4a6bf7adb92d1b8b7cd3763740b4a5180c0147d5 Author: Max Filippov <jcmvb...@gmail.com> Date: 2018-03-31 (Sat, 31 Mar 2018) Changed paths: M linux-user/main.c Log Message: ----------- target/xtensa: linux-user: rewind pc for restarted syscall In case of syscall restart request set pc back to the syscall instruction. Reviewed-by: Laurent Vivier <laur...@vivier.eu> Signed-off-by: Max Filippov <jcmvb...@gmail.com> Commit: 73a988d957b9142e0a005f4dc87944574f02de51 https://github.com/qemu/qemu/commit/73a988d957b9142e0a005f4dc87944574f02de51 Author: Max Filippov <jcmvb...@gmail.com> Date: 2018-03-31 (Sat, 31 Mar 2018) Changed paths: M linux-user/syscall.c Log Message: ----------- linux-user: call cpu_copy under clone_lock cpu_copy adds newly created CPU object to container/machine/unattached, but does it w/o proper locking. As a result when multiple threads create threads rapidly QEMU may abort with the following message: GLib-CRITICAL **: g_hash_table_iter_next: assertion 'ri->version == ri->hash_table->version' failed ERROR:qemu/qom/object.c:1663:object_get_canonical_path_component: code should not be reached E.g. this issue is observed when running glibc test nptl/tst-eintr1. Move cpu_copy invocation under clone_lock to fix that. Reviewed-by: Laurent Vivier <laur...@vivier.eu> Signed-off-by: Max Filippov <jcmvb...@gmail.com> Commit: a23ea409824afb9bce3a4d54881310757811c218 https://github.com/qemu/qemu/commit/a23ea409824afb9bce3a4d54881310757811c218 Author: Max Filippov <jcmvb...@gmail.com> Date: 2018-03-31 (Sat, 31 Mar 2018) Changed paths: M linux-user/syscall.c Log Message: ----------- linux-user: fix mq_getsetattr implementation mq_getsetattr implementation does not set errno correctly in case of error. Also in the presence of both 2nd and 3rd arguments it calls both mq_getattr and mq_setattr, whereas only the latter call would suffice. Don't call mq_getattr in the presence of the 2nd argument. Don't copy output back to user in case of error. Use get_errno to set errno value. This fixes test rt/tst-mqueue2 from the glibc testsuite. Cc: Lionel Landwerlin <lionel.landwer...@openwide.fr> Cc: Kirill A. Shutemov <kirill.shute...@linux.intel.com> Cc: Riku Voipio <riku.voi...@iki.fi> Cc: Aurelien Jarno <aurel...@aurel32.net> Cc: Laurent Vivier <laur...@vivier.eu> Reviewed-by: Laurent Vivier <laur...@vivier.eu> Signed-off-by: Max Filippov <jcmvb...@gmail.com> Commit: a3da8be5126be0d17e8ebc76655f185aeb647f7a https://github.com/qemu/qemu/commit/a3da8be5126be0d17e8ebc76655f185aeb647f7a Author: Max Filippov <jcmvb...@gmail.com> Date: 2018-04-01 (Sun, 01 Apr 2018) Changed paths: M linux-user/xtensa/target_structs.h Log Message: ----------- target/xtensa: linux-user: fix sysv IPC structures - make target_ipc_perm fields match kernel definitions for xtensa; - add target_semid64_ds with proper order of times and reserved fields for little/big endian specific for xtensa; - add missing reserved fields after time fields to the target_shmid_ds; - fix types of shm_cpid, shm_lpid and shm_nattch fields of target_shmid_ds to match kernel definitions for xtensa. These changes fix guest ipcs output and fix glibc testsuite tests sysvipc/test-sysvsem and sysvipc/test-sysvshm. Reviewed-by: Laurent Vivier <laur...@vivier.eu> Signed-off-by: Max Filippov <jcmvb...@gmail.com> Commit: b9f9908e2ddd167eb88ce3457953a30f18d2a7aa https://github.com/qemu/qemu/commit/b9f9908e2ddd167eb88ce3457953a30f18d2a7aa Author: Max Filippov <jcmvb...@gmail.com> Date: 2018-04-01 (Sun, 01 Apr 2018) Changed paths: M linux-user/syscall.c Log Message: ----------- linux-user: fix error propagation in clock_gettime host_to_target_timespec may return error if target address could not be locked, but it is ignored. Propagate return value of host_to_target_timespec to the caller of clock_gettime. Reviewed-by: Laurent Vivier <laur...@vivier.eu> Signed-off-by: Max Filippov <jcmvb...@gmail.com> Commit: 12e3340c23972d7de6c2e306bafecd50abcbea1c https://github.com/qemu/qemu/commit/12e3340c23972d7de6c2e306bafecd50abcbea1c Author: Max Filippov <jcmvb...@gmail.com> Date: 2018-04-01 (Sun, 01 Apr 2018) Changed paths: M linux-user/syscall.c Log Message: ----------- linux-user: implement clock_settime This fixes glibc testsuite test rt/tst-clock2. Signed-off-by: Max Filippov <jcmvb...@gmail.com> Commit: 64a563dd8dd6ca2661d96a2e4b69f0a5465cab94 https://github.com/qemu/qemu/commit/64a563dd8dd6ca2661d96a2e4b69f0a5465cab94 Author: Max Filippov <jcmvb...@gmail.com> Date: 2018-04-02 (Mon, 02 Apr 2018) Changed paths: M linux-user/syscall.c Log Message: ----------- target/xtensa: linux-user: fix fadvise64 call fadvise64_64 on xtensa passes advice as the second argument and so must be handled similar to PPC. This fixes glibc testsuite tests posix/tst-posix_fadvise and posix/tst-posix_fadvise64. Reviewed-by: Laurent Vivier <laur...@vivier.eu> Signed-off-by: Max Filippov <jcmvb...@gmail.com> Commit: 9abfc88af3ffd3b33c7fab4471da86462ee71d95 https://github.com/qemu/qemu/commit/9abfc88af3ffd3b33c7fab4471da86462ee71d95 Author: Peter Maydell <peter.mayd...@linaro.org> Date: 2018-04-03 (Tue, 03 Apr 2018) Changed paths: M linux-user/main.c M linux-user/signal.c M linux-user/syscall.c M linux-user/xtensa/target_structs.h Log Message: ----------- Merge remote-tracking branch 'remotes/xtensa/tags/20180402-xtensa' into staging xtensa-specific fixes for linux-user: - fix flushing registers for signal processing in call8 and call12 frames; - fix PC value for restarted syscalls; - fix sysv IPC structures; - fix fadvise64 syscall; generic fixes for linux-user: - fix QEMU assertion in multithreaded application by calling cpu_copy under clone_lock; - fix mq_getsetattr implementation; - fix error propagation in clock_gettime; - implement clock_settime. # gpg: Signature made Mon 02 Apr 2018 18:07:08 BST # gpg: using RSA key 51F9CC91F83FA044 # gpg: Good signature from "Max Filippov <filip...@cadence.com>" # gpg: aka "Max Filippov <max.filip...@cogentembedded.com>" # gpg: aka "Max Filippov <jcmvb...@gmail.com>" # Primary key fingerprint: 2B67 854B 98E5 327D CDEB 17D8 51F9 CC91 F83F A044 * remotes/xtensa/tags/20180402-xtensa: target/xtensa: linux-user: fix fadvise64 call linux-user: implement clock_settime linux-user: fix error propagation in clock_gettime target/xtensa: linux-user: fix sysv IPC structures linux-user: fix mq_getsetattr implementation linux-user: call cpu_copy under clone_lock target/xtensa: linux-user: rewind pc for restarted syscall target/xtensa: fix flush_window_regs Signed-off-by: Peter Maydell <peter.mayd...@linaro.org> Compare: https://github.com/qemu/qemu/compare/13b65ec54dbf...9abfc88af3ff