qemu-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-commits] [qemu/qemu] 7f72cd: linux-user/signal.c: Correct error pa


From: GitHub
Subject: [Qemu-commits] [qemu/qemu] 7f72cd: linux-user/signal.c: Correct error path for AArch6...
Date: Wed, 19 Mar 2014 08:00:05 -0700

  Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: 7f72cd235fa33f2fc7a8d1cc4d621bf7db61e9eb
      
https://github.com/qemu/qemu/commit/7f72cd235fa33f2fc7a8d1cc4d621bf7db61e9eb
  Author: Peter Maydell <address@hidden>
  Date:   2014-03-17 (Mon, 17 Mar 2014)

  Changed paths:
    M linux-user/signal.c

  Log Message:
  -----------
  linux-user/signal.c: Correct error path for AArch64 do_rt_sigreturn

The error path in AArch64 do_rt_sigreturn() which fails before
attempting lock_user_struct() was doing an unlock_user_struct()
on an uninitialized variable. Initialize frame to NULL so we
can use the same error-exit path in all cases (unlock of NULL
is permitted and does nothing).

Signed-off-by: Peter Maydell <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: 3b899ea7d405dc7634ac629aa7b0e7639d506d9f
      
https://github.com/qemu/qemu/commit/3b899ea7d405dc7634ac629aa7b0e7639d506d9f
  Author: Peter Maydell <address@hidden>
  Date:   2014-03-17 (Mon, 17 Mar 2014)

  Changed paths:
    M linux-user/syscall.c

  Log Message:
  -----------
  linux-user: Don't return uninitialized value for atomic_barrier syscall

QEMU's implementation of the m68k atomic_barrier syscall, like the kernel's,
is just a no-op. However we still need to return a result code from it.

Signed-off-by: Peter Maydell <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: 8d5d30046b9aadfeee60e09fe79c063f419993db
      
https://github.com/qemu/qemu/commit/8d5d30046b9aadfeee60e09fe79c063f419993db
  Author: Andreas Schwab <address@hidden>
  Date:   2014-03-17 (Mon, 17 Mar 2014)

  Changed paths:
    M linux-user/syscall.c
    M linux-user/syscall_defs.h

  Log Message:
  -----------
  linux-user: implement F_[GS]ETOWN_EX

F_GETOWN is replaced by F_GETOWN_EX inside the glibc fcntl wrapper

Signed-off-by: Andreas Schwab <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: 6b1275ff15b205a7738aa8ba96fe355f097b5879
      
https://github.com/qemu/qemu/commit/6b1275ff15b205a7738aa8ba96fe355f097b5879
  Author: Peter Maydell <address@hidden>
  Date:   2014-03-17 (Mon, 17 Mar 2014)

  Changed paths:
    M linux-user/elfload.c

  Log Message:
  -----------
  linux-user: Don't reserve space for commpage for AArch64

AArch64 Linux, unlike AArch32, doesn't use a commpage. This means we
should not be reserving room in the guest address space for one.
Fixes LP:1287195.

Reported-by: Amanieu d'Antras <address@hidden>
Signed-off-by: Peter Maydell <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: 1c275925bfbbc2de84a8f0e09d1dd70bbefb6da3
      
https://github.com/qemu/qemu/commit/1c275925bfbbc2de84a8f0e09d1dd70bbefb6da3
  Author: Alex Barcelo <address@hidden>
  Date:   2014-03-17 (Mon, 17 Mar 2014)

  Changed paths:
    M linux-user/qemu.h
    M linux-user/signal.c
    M linux-user/syscall.c

  Log Message:
  -----------
  signal: added a wrapper for sigprocmask function

Create a wrapper for signal mask changes initiated by the guest;
(this includes syscalls and also the sigreturns from signal.c)
this will give us a place to put code which prevents the guest
from changing the handling of signals used by QEMU itself
internally.

The wrapper is called from all the guest-initiated sigprocmask, but
is not called from internal qemu sigprocmask calls.

Signed-off-by: Alex Barcelo <address@hidden>
[PMM: Added calls to wrapper for sigprocmask uses in signal.c
when setting the signal mask on entry and exit from signal
handlers, since these also are guest-provided signal masks.]
Signed-off-by: Peter Maydell <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: a7ec0f98e3a37a4d31c832cfa14dc2c1c0890421
      
https://github.com/qemu/qemu/commit/a7ec0f98e3a37a4d31c832cfa14dc2c1c0890421
  Author: Peter Maydell <address@hidden>
  Date:   2014-03-17 (Mon, 17 Mar 2014)

  Changed paths:
    M linux-user/qemu.h
    M linux-user/signal.c

  Log Message:
  -----------
  linux-user: Don't allow guest to block SIGSEGV

Don't allow the linux-user guest to block SIGSEGV -- QEMU needs this
signal to detect accesses to pages which it has marked read-only
because it has cached translated code from them.

We implement this by making the do_sigprocmask() wrapper suppress
SIGSEGV when doing the host process signal mask manipulation; instead
we store the current state of SIGSEGV in the TaskState struct.

If we get a SIGSEGV for the guest when the guest has blocked the
signal, we treat it as if the default SEGV handler was in place,
as the kernel does for forced SIGSEGV delivery.

This patch is based on an idea by Alex Barcelo, but rather than
simply lying to the guest about the SIGSEGV state we track it.

Signed-off-by: Peter Maydell <address@hidden>
Reported-by: Alex Barcelo <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: e0eb210ec0c1cd262e3f642133ee93acdaf60aa0
      
https://github.com/qemu/qemu/commit/e0eb210ec0c1cd262e3f642133ee93acdaf60aa0
  Author: Peter Maydell <address@hidden>
  Date:   2014-03-17 (Mon, 17 Mar 2014)

  Changed paths:
    M linux-user/syscall.c
    M linux-user/syscall_defs.h

  Log Message:
  -----------
  linux-user: Implement capget, capset

Implement the capget and capset syscalls. This is useful because
simple programs like 'ls' try to use it in AArch64, and otherwise
we emit a lot of noise about it being unimplemented.

Signed-off-by: Peter Maydell <address@hidden>
Signed-off-by: Riku Voipio <address@hidden>


  Commit: 4c8821d13405056776d0255bb78925dac91996c3
      
https://github.com/qemu/qemu/commit/4c8821d13405056776d0255bb78925dac91996c3
  Author: Peter Maydell <address@hidden>
  Date:   2014-03-19 (Wed, 19 Mar 2014)

  Changed paths:
    M linux-user/elfload.c
    M linux-user/qemu.h
    M linux-user/signal.c
    M linux-user/syscall.c
    M linux-user/syscall_defs.h

  Log Message:
  -----------
  Merge remote-tracking branch 'remotes/riku/linux-user-for-upstream' into 
staging

* remotes/riku/linux-user-for-upstream:
  linux-user: Implement capget, capset
  linux-user: Don't allow guest to block SIGSEGV
  signal: added a wrapper for sigprocmask function
  linux-user: Don't reserve space for commpage for AArch64
  linux-user: implement F_[GS]ETOWN_EX
  linux-user: Don't return uninitialized value for atomic_barrier syscall
  linux-user/signal.c: Correct error path for AArch64 do_rt_sigreturn

Signed-off-by: Peter Maydell <address@hidden>


Compare: https://github.com/qemu/qemu/compare/c1b94a0ed233...4c8821d13405

reply via email to

[Prev in Thread] Current Thread [Next in Thread]