diff options
Diffstat (limited to 'arch/arm64/include/uapi/asm/signal.h')
-rw-r--r-- | arch/arm64/include/uapi/asm/signal.h | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/arch/arm64/include/uapi/asm/signal.h b/arch/arm64/include/uapi/asm/signal.h index 8d1e7236431b..f378ff4f93d7 100644 --- a/arch/arm64/include/uapi/asm/signal.h +++ b/arch/arm64/include/uapi/asm/signal.h @@ -16,9 +16,43 @@ #ifndef __ASM_SIGNAL_H #define __ASM_SIGNAL_H +#include <asm/posix_types.h> + /* Required for AArch32 compatibility. */ #define SA_RESTORER 0x04000000 +/* + * Since sigset is a bitmask, we need the same size fields for ILP32 + * and LP64. With big-endian, 32bit bitmask does not match up to + * 64bit bitmask (unlike with little-endian). + */ +#ifdef __ILP32__ + +#define __SIGSET_INNER_TYPE __kernel_ulong_t +#define _NSIG_BPW 64 + +# ifdef __AARCH64EB__ +# define __SIGNAL_INNER(type, field) \ + int __pad_##field; \ + type field; +# else +# define __SIGNAL_INNER(type, field) \ + type field; \ + int __pad_##field; +# endif + +# define __SIGACTION_HANDLER(field) \ + __SIGNAL_INNER(__sighandler_t, field) + + +#define __SIGACTION_FLAGS(field) \ + __kernel_ulong_t field + +#define __SIGACTION_RESTORER(field) \ + __SIGNAL_INNER(__sigrestore_t, field) + +#endif + #include <asm-generic/signal.h> #endif |