|
@@ -1977,6 +1977,11 @@ static inline void clear_tsk_need_resched(struct task_struct *tsk)
|
|
clear_tsk_thread_flag(tsk,TIF_NEED_RESCHED);
|
|
clear_tsk_thread_flag(tsk,TIF_NEED_RESCHED);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+static inline int test_tsk_need_resched(struct task_struct *tsk)
|
|
|
|
+{
|
|
|
|
+ return unlikely(test_tsk_thread_flag(tsk,TIF_NEED_RESCHED));
|
|
|
|
+}
|
|
|
|
+
|
|
static inline int signal_pending(struct task_struct *p)
|
|
static inline int signal_pending(struct task_struct *p)
|
|
{
|
|
{
|
|
return unlikely(test_tsk_thread_flag(p,TIF_SIGPENDING));
|
|
return unlikely(test_tsk_thread_flag(p,TIF_SIGPENDING));
|
|
@@ -1991,7 +1996,7 @@ static inline int fatal_signal_pending(struct task_struct *p)
|
|
|
|
|
|
static inline int need_resched(void)
|
|
static inline int need_resched(void)
|
|
{
|
|
{
|
|
- return unlikely(test_thread_flag(TIF_NEED_RESCHED));
|
|
|
|
|
|
+ return unlikely(test_tsk_need_resched(current));
|
|
}
|
|
}
|
|
|
|
|
|
/*
|
|
/*
|