From: Aleksandar Markovic Date: Fri, 12 Jul 2019 11:37:46 +0000 (+0200) Subject: linux-user: Fix structure target_ucontext for MIPS X-Git-Tag: v4.1.0-rc2~12^2~2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=4ced996ffe3f08883fa5bd423bcfafdfd6f13189;p=thirdparty%2Fqemu.git linux-user: Fix structure target_ucontext for MIPS Structure ucontext for MIPS is defined in the following way in Linux kernel: (arch/mips/include/uapi/asm/ucontext.h, lines 54-64) struct ucontext { /* Historic fields matching asm-generic */ unsigned long uc_flags; struct ucontext *uc_link; stack_t uc_stack; struct sigcontext uc_mcontext; sigset_t uc_sigmask; /* Extended context structures may follow ucontext */ unsigned long long uc_extcontext[0]; }; Fix the structure target_ucontext for MIPS to reflect the definition above, except the correction for field uc_extcontext, which will follow at some later time. Fixes: 94c5495d Reported-by: Dragan Mladjenovic Signed-off-by: Aleksandar Markovic Reviewed-by: Laurent Vivier Message-Id: <1562931470-3700-2-git-send-email-aleksandar.markovic@rt-rk.com> Signed-off-by: Laurent Vivier --- diff --git a/linux-user/mips/signal.c b/linux-user/mips/signal.c index 6aa303ec9c1..455a8a229a8 100644 --- a/linux-user/mips/signal.c +++ b/linux-user/mips/signal.c @@ -71,10 +71,9 @@ struct sigframe { }; struct target_ucontext { - target_ulong tuc_flags; - target_ulong tuc_link; + abi_ulong tuc_flags; + abi_ulong tuc_link; target_stack_t tuc_stack; - target_ulong pad0; struct target_sigcontext tuc_mcontext; target_sigset_t tuc_sigmask; };