1. 02 4月, 2018 1 次提交
    • M
      target/xtensa: linux-user: fix sysv IPC structures · a3da8be5
      Max Filippov 提交于
      - 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: NLaurent Vivier <laurent@vivier.eu>
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      a3da8be5
  2. 01 4月, 2018 4 次提交
    • M
      linux-user: fix mq_getsetattr implementation · a23ea409
      Max Filippov 提交于
      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.landwerlin@openwide.fr>
      Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
      Cc: Riku Voipio <riku.voipio@iki.fi>
      Cc: Aurelien Jarno <aurelien@aurel32.net>
      Cc: Laurent Vivier <laurent@vivier.eu>
      Reviewed-by: NLaurent Vivier <laurent@vivier.eu>
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      a23ea409
    • M
      linux-user: call cpu_copy under clone_lock · 73a988d9
      Max Filippov 提交于
      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: NLaurent Vivier <laurent@vivier.eu>
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      73a988d9
    • M
      target/xtensa: linux-user: rewind pc for restarted syscall · 4a6bf7ad
      Max Filippov 提交于
      In case of syscall restart request set pc back to the syscall
      instruction.
      Reviewed-by: NLaurent Vivier <laurent@vivier.eu>
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      4a6bf7ad
    • M
      target/xtensa: fix flush_window_regs · 20ef6670
      Max Filippov 提交于
      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: NMax Filippov <jcmvbkbc@gmail.com>
      20ef6670
  3. 27 3月, 2018 16 次提交
  4. 26 3月, 2018 19 次提交