diff options
Diffstat (limited to 'arch/microblaze/include/asm/thread_info.h')
| -rw-r--r-- | arch/microblaze/include/asm/thread_info.h | 24 | 
1 files changed, 17 insertions, 7 deletions
diff --git a/arch/microblaze/include/asm/thread_info.h b/arch/microblaze/include/asm/thread_info.h index b73da2ac21b..8c9d36591a0 100644 --- a/arch/microblaze/include/asm/thread_info.h +++ b/arch/microblaze/include/asm/thread_info.h @@ -106,8 +106,6 @@ static inline struct thread_info *current_thread_info(void)  /* thread information allocation */  #endif /* __ASSEMBLY__ */ -#define PREEMPT_ACTIVE		0x10000000 -  /*   * thread information flags   * - these are process state flags that various assembly files may @@ -121,11 +119,9 @@ static inline struct thread_info *current_thread_info(void)  #define TIF_NEED_RESCHED	3 /* rescheduling necessary */  /* restore singlestep on return to user mode */  #define TIF_SINGLESTEP		4 -#define TIF_IRET		5 /* return with iret */  #define TIF_MEMDIE		6	/* is terminating due to OOM killer */  #define TIF_SYSCALL_AUDIT	9       /* syscall auditing active */  #define TIF_SECCOMP		10      /* secure computing */ -#define TIF_FREEZE		14	/* Freezing for suspend */  /* true if poll_idle() is polling TIF_NEED_RESCHED */  #define TIF_POLLING_NRFLAG	16 @@ -135,9 +131,7 @@ static inline struct thread_info *current_thread_info(void)  #define _TIF_SIGPENDING		(1 << TIF_SIGPENDING)  #define _TIF_NEED_RESCHED	(1 << TIF_NEED_RESCHED)  #define _TIF_SINGLESTEP		(1 << TIF_SINGLESTEP) -#define _TIF_IRET		(1 << TIF_IRET)  #define _TIF_POLLING_NRFLAG	(1 << TIF_POLLING_NRFLAG) -#define _TIF_FREEZE		(1 << TIF_FREEZE)  #define _TIF_SYSCALL_AUDIT	(1 << TIF_SYSCALL_AUDIT)  #define _TIF_SECCOMP		(1 << TIF_SECCOMP) @@ -168,7 +162,23 @@ static inline void set_restore_sigmask(void)  {  	struct thread_info *ti = current_thread_info();  	ti->status |= TS_RESTORE_SIGMASK; -	set_bit(TIF_SIGPENDING, (unsigned long *)&ti->flags); +	WARN_ON(!test_bit(TIF_SIGPENDING, (unsigned long *)&ti->flags)); +} +static inline void clear_restore_sigmask(void) +{ +	current_thread_info()->status &= ~TS_RESTORE_SIGMASK; +} +static inline bool test_restore_sigmask(void) +{ +	return current_thread_info()->status & TS_RESTORE_SIGMASK; +} +static inline bool test_and_clear_restore_sigmask(void) +{ +	struct thread_info *ti = current_thread_info(); +	if (!(ti->status & TS_RESTORE_SIGMASK)) +		return false; +	ti->status &= ~TS_RESTORE_SIGMASK; +	return true;  }  #endif  | 
