From d632e10f51b77b2a8aac4add3cd8d5691f6090bc Mon Sep 17 00:00:00 2001 From: Mike Frysinger Date: Sat, 9 Aug 2014 09:04:18 -0400 Subject: hppa: fix sigaction decoding Since the rt_sigaction syscall on hppa doesn't have a sa_restorer, do not include it in the kernel struct. We also have to undefine SA_RESTORER so that code doesn't try to use it. The headers will export this, but the syscall doesn't actually respect it. * signal.c (SA_RESTORER): Undefine when HPPA is defined. (struct new_sigaction): Disable sa_restorer on hppa. --- signal.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/signal.c b/signal.c index b501e31c7..6a565f5a9 100644 --- a/signal.c +++ b/signal.c @@ -100,6 +100,12 @@ struct sigcontext { # endif #endif +/* HPPA defines this in their headers, but doesn't actually have it, + so we have to delete the define. */ +#ifdef HPPA +# undef SA_RESTORER +#endif + #include "xlat/sigact_flags.h" #include "xlat/sigprocmaskcmds.h" @@ -1128,9 +1134,9 @@ struct new_sigaction #else void (*__sa_handler)(int); unsigned long sa_flags; -# ifndef ALPHA +# if !defined(ALPHA) || !defined(HPPA) void (*sa_restorer)(void); -# endif /* !ALPHA */ +# endif /* !ALPHA || !HPPA */ #endif /* !MIPS */ /* Kernel treats sa_mask as an array of longs. */ unsigned long sa_mask[NSIG / sizeof(long) ? NSIG / sizeof(long) : 1]; -- cgit v1.2.1