• Implement setup_{,rt_}frame and do_{,rt_}sigreturn for PPC 32-bit.  Use
    the same TARGET_QEMU_ESIGRETURN hack as for MIPS to avoid clobbering
    register state on a sigreturn.
    
    Signed-off-by: Nathan Froyd <froydnj@codesourcery.com>
    Signed-off-by: malc <av1474@comtv.ru>
    Nathan Froyd authored
     
    Browse Code »

  • Also fixes a register corruption bug in do_sigreturn. When "returning"
    from sigreturn we are actually restoring the virtual cpu state from the
    signal frame.  This is actually surprisingly hard to observe in practice.
    
    Typically an thread be blocked in a FUTEX_WAIT call when the signal arrives,
    so the effect is a spurious syscall success and the introduction of a
    subtle race condition.
    
    On x86/arm a syscall modifies a single word sized register, so
    do_sigreturn can just return that value.  On MIPS a syscall clobbers
    multiple registers, so we need additional smarts.  My solution is to
    invent a magic errno value that means "don't touch CPU state".
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@7194 c046a42c-6fe2-441c-8c8c-71466251a162
    pbrook authored
     
    Browse Code »


  • The proper exit code for dieing from an uncaught signal is -<signal>.
    The kernel doesn't allow exit() or _exit() to pass a negative value.
    To get the proper exit code we need to actually die from an uncaught signal.
    
    A default signal handler is installed, we send ourself a signal
    and we wait for it to arrive.
    
    Patch originates from Scratchbox
    
    Signed-off-by: Riku Voipio <riku.voipio@iki.fi>
    Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@7119 c046a42c-6fe2-441c-8c8c-71466251a162
    aurel32 authored
     
    Browse Code »



  • This patch fixes:
    
    linux-user/signal.c:1403: warning: no previous prototype for 'do_sigreturn_v1'
    linux-user/signal.c:1473: warning: no previous prototype for 'do_sigreturn_v2'
    linux-user/signal.c:1511: warning: no previous prototype for 'do_rt_sigreturn_v1'
    linux-user/signal.c:1552: warning: no previous prototype for 'do_rt_sigreturn_v2'
    
    by making the appropriate functions static.
    
    Signed-off-by: Nathan Froyd <froydnj@codesourcery.com>
    Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6486 c046a42c-6fe2-441c-8c8c-71466251a162
    aurel32 authored
     
    Browse Code »

  • Introduce noreturn attribute and attach it to cpu_loop_exit as well as
    interrupt/exception helpers for i386. This avoids a bunch of gcc4
    warnings.
    
    [ Note that this patch comes with a workaround to include qemu-common.h
    even in cases where is currently causes conflicts with dyngen-exec.h.
    I've been told that these conflicts will get resolved in the future
    (/me will try to have a look as well - as time permits). ]
    
    Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6303 c046a42c-6fe2-441c-8c8c-71466251a162
    blueswir1 authored
     
    Browse Code »