aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-sh/thread_info.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-sh/thread_info.h')
-rw-r--r--include/asm-sh/thread_info.h10
1 files changed, 7 insertions, 3 deletions
diff --git a/include/asm-sh/thread_info.h b/include/asm-sh/thread_info.h
index 1f7e1deb8d92..c50e5d35fe84 100644
--- a/include/asm-sh/thread_info.h
+++ b/include/asm-sh/thread_info.h
@@ -68,14 +68,16 @@ struct thread_info {
68#define init_stack (init_thread_union.stack) 68#define init_stack (init_thread_union.stack)
69 69
70/* how to get the current stack pointer from C */ 70/* how to get the current stack pointer from C */
71register unsigned long current_stack_pointer asm("r15") __attribute_used__; 71register unsigned long current_stack_pointer asm("r15") __used;
72 72
73/* how to get the thread information struct from C */ 73/* how to get the thread information struct from C */
74static inline struct thread_info *current_thread_info(void) 74static inline struct thread_info *current_thread_info(void)
75{ 75{
76 struct thread_info *ti; 76 struct thread_info *ti;
77#ifdef CONFIG_CPU_HAS_SR_RB 77#if defined(CONFIG_SUPERH64)
78 __asm__("stc r7_bank, %0" : "=r" (ti)); 78 __asm__ __volatile__ ("getcon cr17, %0" : "=r" (ti));
79#elif defined(CONFIG_CPU_HAS_SR_RB)
80 __asm__ __volatile__ ("stc r7_bank, %0" : "=r" (ti));
79#else 81#else
80 unsigned long __dummy; 82 unsigned long __dummy;
81 83
@@ -111,6 +113,7 @@ static inline struct thread_info *current_thread_info(void)
111#define TIF_NEED_RESCHED 2 /* rescheduling necessary */ 113#define TIF_NEED_RESCHED 2 /* rescheduling necessary */
112#define TIF_RESTORE_SIGMASK 3 /* restore signal mask in do_signal() */ 114#define TIF_RESTORE_SIGMASK 3 /* restore signal mask in do_signal() */
113#define TIF_SINGLESTEP 4 /* singlestepping active */ 115#define TIF_SINGLESTEP 4 /* singlestepping active */
116#define TIF_SYSCALL_AUDIT 5
114#define TIF_USEDFPU 16 /* FPU was used by this task this quantum (SMP) */ 117#define TIF_USEDFPU 16 /* FPU was used by this task this quantum (SMP) */
115#define TIF_POLLING_NRFLAG 17 /* true if poll_idle() is polling TIF_NEED_RESCHED */ 118#define TIF_POLLING_NRFLAG 17 /* true if poll_idle() is polling TIF_NEED_RESCHED */
116#define TIF_MEMDIE 18 119#define TIF_MEMDIE 18
@@ -121,6 +124,7 @@ static inline struct thread_info *current_thread_info(void)
121#define _TIF_NEED_RESCHED (1<<TIF_NEED_RESCHED) 124#define _TIF_NEED_RESCHED (1<<TIF_NEED_RESCHED)
122#define _TIF_RESTORE_SIGMASK (1<<TIF_RESTORE_SIGMASK) 125#define _TIF_RESTORE_SIGMASK (1<<TIF_RESTORE_SIGMASK)
123#define _TIF_SINGLESTEP (1<<TIF_SINGLESTEP) 126#define _TIF_SINGLESTEP (1<<TIF_SINGLESTEP)
127#define _TIF_SYSCALL_AUDIT (1<<TIF_SYSCALL_AUDIT)
124#define _TIF_USEDFPU (1<<TIF_USEDFPU) 128#define _TIF_USEDFPU (1<<TIF_USEDFPU)
125#define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) 129#define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG)
126#define _TIF_FREEZE (1<<TIF_FREEZE) 130#define _TIF_FREEZE (1<<TIF_FREEZE)