diff options
Diffstat (limited to 'include/asm-parisc/compat.h')
-rw-r--r-- | include/asm-parisc/compat.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/include/asm-parisc/compat.h b/include/asm-parisc/compat.h index 289624d8b2d4..71b4eeea205a 100644 --- a/include/asm-parisc/compat.h +++ b/include/asm-parisc/compat.h | |||
@@ -5,6 +5,7 @@ | |||
5 | */ | 5 | */ |
6 | #include <linux/types.h> | 6 | #include <linux/types.h> |
7 | #include <linux/sched.h> | 7 | #include <linux/sched.h> |
8 | #include <linux/personality.h> | ||
8 | 9 | ||
9 | #define COMPAT_USER_HZ 100 | 10 | #define COMPAT_USER_HZ 100 |
10 | 11 | ||
@@ -149,4 +150,14 @@ static __inline__ void __user *compat_alloc_user_space(long len) | |||
149 | return (void __user *)regs->gr[30]; | 150 | return (void __user *)regs->gr[30]; |
150 | } | 151 | } |
151 | 152 | ||
153 | static inline int __is_compat_task(struct task_struct *t) | ||
154 | { | ||
155 | return personality(t->personality) == PER_LINUX32; | ||
156 | } | ||
157 | |||
158 | static inline int is_compat_task(void) | ||
159 | { | ||
160 | return __is_compat_task(current); | ||
161 | } | ||
162 | |||
152 | #endif /* _ASM_PARISC_COMPAT_H */ | 163 | #endif /* _ASM_PARISC_COMPAT_H */ |