diff options
Diffstat (limited to 'include/asm-alpha')
-rw-r--r-- | include/asm-alpha/thread_info.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/include/asm-alpha/thread_info.h b/include/asm-alpha/thread_info.h index 69ffd93f8e22..eeb3bef91e11 100644 --- a/include/asm-alpha/thread_info.h +++ b/include/asm-alpha/thread_info.h | |||
@@ -92,5 +92,27 @@ register struct thread_info *__current_thread_info __asm__("$8"); | |||
92 | #define _TIF_ALLWORK_MASK (_TIF_WORK_MASK \ | 92 | #define _TIF_ALLWORK_MASK (_TIF_WORK_MASK \ |
93 | | _TIF_SYSCALL_TRACE) | 93 | | _TIF_SYSCALL_TRACE) |
94 | 94 | ||
95 | #define ALPHA_UAC_SHIFT 6 | ||
96 | #define ALPHA_UAC_MASK (1 << TIF_UAC_NOPRINT | 1 << TIF_UAC_NOFIX | \ | ||
97 | 1 << TIF_UAC_SIGBUS) | ||
98 | |||
99 | #define SET_UNALIGN_CTL(task,value) ({ \ | ||
100 | (task)->thread_info->flags = (((task)->thread_info->flags & \ | ||
101 | ~ALPHA_UAC_MASK) \ | ||
102 | | (((value) << ALPHA_UAC_SHIFT) & (1<<TIF_UAC_NOPRINT))\ | ||
103 | | (((value) << (ALPHA_UAC_SHIFT + 1)) & (1<<TIF_UAC_SIGBUS)) \ | ||
104 | | (((value) << (ALPHA_UAC_SHIFT - 1)) & (1<<TIF_UAC_NOFIX)));\ | ||
105 | 0; }) | ||
106 | |||
107 | #define GET_UNALIGN_CTL(task,value) ({ \ | ||
108 | put_user(((task)->thread_info->flags & (1 << TIF_UAC_NOPRINT)) \ | ||
109 | >> ALPHA_UAC_SHIFT \ | ||
110 | | ((task)->thread_info->flags & (1 << TIF_UAC_SIGBUS)) \ | ||
111 | >> (ALPHA_UAC_SHIFT + 1) \ | ||
112 | | ((task)->thread_info->flags & (1 << TIF_UAC_NOFIX)) \ | ||
113 | >> (ALPHA_UAC_SHIFT - 1), \ | ||
114 | (int __user *)(value)); \ | ||
115 | }) | ||
116 | |||
95 | #endif /* __KERNEL__ */ | 117 | #endif /* __KERNEL__ */ |
96 | #endif /* _ALPHA_THREAD_INFO_H */ | 118 | #endif /* _ALPHA_THREAD_INFO_H */ |