diff options
author | Ralf Baechle <ralf@linux-mips.org> | 2009-03-05 11:45:48 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2009-03-16 17:53:07 -0700 |
commit | 187203ae140ba1f2b617c3e9671f9e1fcb125a68 (patch) | |
tree | dcd5eead08fdfa848b5cd7e992168cd3712cda4c | |
parent | 5b9c305d22fb08a6b62f407e187f8f2a5b91c54f (diff) |
MIPS: compat: Implement is_compat_task.
commit 4302e5d53b9166d45317e3ddf0a7a9dab3efd43b upstream.
This is a build fix required after "x86-64: seccomp: fix 32/64 syscall
hole" (commit 5b1017404aea6d2e552e991b3fd814d839e9cd67). MIPS doesn't
have the issue that was fixed for x86-64 by that patch.
This also doesn't solve the N32 issue which is that N32 seccomp processes
will be treated as non-compat processes thus only have access to N64
syscalls.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r-- | include/asm-mips/compat.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/asm-mips/compat.h b/include/asm-mips/compat.h index ac5d541368e..6c5b40905dd 100644 --- a/include/asm-mips/compat.h +++ b/include/asm-mips/compat.h @@ -3,6 +3,8 @@ /* * Architecture specific compatibility types */ +#include <linux/seccomp.h> +#include <linux/thread_info.h> #include <linux/types.h> #include <asm/page.h> #include <asm/ptrace.h> @@ -218,4 +220,9 @@ struct compat_shmid64_ds { compat_ulong_t __unused2; }; +static inline int is_compat_task(void) +{ + return test_thread_flag(TIF_32BIT); +} + #endif /* _ASM_COMPAT_H */ |