diff options
| author | Ingo Molnar <mingo@elte.hu> | 2008-11-23 08:55:47 +0100 |
|---|---|---|
| committer | Ingo Molnar <mingo@elte.hu> | 2008-11-23 08:55:47 +0100 |
| commit | ca9eed76133c00e7f4b1eeb4c1a6cb800cd2654c (patch) | |
| tree | 5f011f4bd00c921e41605b1915c227aeaf411a0d /kernel/posix-cpu-timers.c | |
| parent | 8652cb4b0d87accbe78725fd2a13be2787059649 (diff) | |
| parent | 13d428afc007fcfcd6deeb215618f54cf9c0cae6 (diff) | |
| download | olio-linux-3.10-ca9eed76133c00e7f4b1eeb4c1a6cb800cd2654c.tar.xz olio-linux-3.10-ca9eed76133c00e7f4b1eeb4c1a6cb800cd2654c.zip | |
Merge commit 'v2.6.28-rc6' into x86/debug
Diffstat (limited to 'kernel/posix-cpu-timers.c')
| -rw-r--r-- | kernel/posix-cpu-timers.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/kernel/posix-cpu-timers.c b/kernel/posix-cpu-timers.c index 153dcb2639c..895337b16a2 100644 --- a/kernel/posix-cpu-timers.c +++ b/kernel/posix-cpu-timers.c @@ -1308,9 +1308,10 @@ static inline int task_cputime_expired(const struct task_cputime *sample, */ static inline int fastpath_timer_check(struct task_struct *tsk) { - struct signal_struct *sig = tsk->signal; + struct signal_struct *sig; - if (unlikely(!sig)) + /* tsk == current, ensure it is safe to use ->signal/sighand */ + if (unlikely(tsk->exit_state)) return 0; if (!task_cputime_zero(&tsk->cputime_expires)) { @@ -1323,6 +1324,8 @@ static inline int fastpath_timer_check(struct task_struct *tsk) if (task_cputime_expired(&task_sample, &tsk->cputime_expires)) return 1; } + + sig = tsk->signal; if (!task_cputime_zero(&sig->cputime_expires)) { struct task_cputime group_sample; |