diff options
author | Dmitry V. Levin <ldv@altlinux.org> | 2015-11-28 02:58:29 +0000 |
---|---|---|
committer | Dmitry V. Levin <ldv@altlinux.org> | 2015-11-28 02:58:29 +0000 |
commit | 527b42ff8da3f52fa7c48eb766b2b57fb0f0b977 (patch) | |
tree | 286c6d24b773066efb0fbf9c6d84f93404dc55c4 /linux/mips | |
parent | 690235ab0fc2a4a6028ca66be0e49ebc4ab35158 (diff) | |
download | strace-527b42ff8da3f52fa7c48eb766b2b57fb0f0b977.tar.gz |
cleanup: make arch_sigreturn.c files more readable
Make arch_sigreturn.c files more self-sustained. While they are
still being included by sigreturn.c, the latter no longer defines
arch_sigreturn function.
* linux/alpha/arch_sigreturn.c (arch_sigreturn): Define.
* linux/arm/arch_sigreturn.c: Likewise.
* linux/crisv10/arch_sigreturn.c: Likewise.
* linux/i386/arch_sigreturn.c: Likewise.
* linux/ia64/arch_sigreturn.c: Likewise.
* linux/m68k/arch_sigreturn.c: Likewise.
* linux/microblaze/arch_sigreturn.c: Likewise.
* linux/mips/arch_sigreturn.c: Likewise.
* linux/powerpc/arch_sigreturn.c: Likewise.
* linux/s390/arch_sigreturn.c: Likewise.
* linux/sparc/arch_sigreturn.c: Likewise.
* linux/tile/arch_sigreturn.c: Likewise.
* linux/x32/arch_sigreturn.c: Remove code.
Include "x86_64/arch_sigreturn.c".
* linux/x86_64/arch_sigreturn.c: Stop including "x32/arch_sigreturn.c".
Include "i386/arch_sigreturn.c" with arch_sigreturn temporarily defined
to i386_arch_sigreturn.
(arch_sigreturn): Define. Add x32 personality support there.
* sigreturn.c: Remove arch_sigreturn header and footer.
Requested-by: Denys Vlasenko <dvlasenk@redhat.com>
Diffstat (limited to 'linux/mips')
-rw-r--r-- | linux/mips/arch_sigreturn.c | 40 |
1 files changed, 22 insertions, 18 deletions
diff --git a/linux/mips/arch_sigreturn.c b/linux/mips/arch_sigreturn.c index 687f871d..3095fe59 100644 --- a/linux/mips/arch_sigreturn.c +++ b/linux/mips/arch_sigreturn.c @@ -1,22 +1,26 @@ +static void +arch_sigreturn(struct tcb *tcp) +{ #if defined LINUX_MIPSO32 -/* - * offsetof(struct sigframe, sf_mask) == - * sizeof(sf_ass) + sizeof(sf_pad) + sizeof(struct sigcontext) - */ -const long addr = mips_REG_SP + 6 * 4 + - sizeof(struct sigcontext); + /* + * offsetof(struct sigframe, sf_mask) == + * sizeof(sf_ass) + sizeof(sf_pad) + sizeof(struct sigcontext) + */ + const long addr = mips_REG_SP + 6 * 4 + + sizeof(struct sigcontext); #else -/* - * This decodes rt_sigreturn. - * The 64-bit ABIs do not have sigreturn. - * - * offsetof(struct rt_sigframe, rs_uc) == - * sizeof(sf_ass) + sizeof(sf_pad) + sizeof(struct siginfo) - */ -const long addr = mips_REG_SP + 6 * 4 + 128 + - offsetof(struct ucontext, uc_sigmask); + /* + * This decodes rt_sigreturn. + * The 64-bit ABIs do not have sigreturn. + * + * offsetof(struct rt_sigframe, rs_uc) == + * sizeof(sf_ass) + sizeof(sf_pad) + sizeof(struct siginfo) + */ + const long addr = mips_REG_SP + 6 * 4 + 128 + + offsetof(struct ucontext, uc_sigmask); #endif -tprints("{mask="); -print_sigset_addr_len(tcp, addr, NSIG / 8); -tprints("}"); + tprints("{mask="); + print_sigset_addr_len(tcp, addr, NSIG / 8); + tprints("}"); +} |