Re: [PATCH 2/2] check_unsafe_exec: s/lock_task_sighand/rcu_read_lock/

Hugh Dickins
2009-04-24T04:33:35Z

On Fri, 23 Apr 2009, Oleg Nesterov wrote:
> write_lock(&p->fs->lock);
> - lock_task_sighand(p, &flags);
> + rcu_read_lock();
> for (t = next_thread(p); t != p; t = next_thread(t)) {
> if (t->fs == p->fs)
> n_fs++;
> }
> + rcu_read_lock();

Not quite! if second rcu_read_lock() changed to rcu_read_unlock(), then
Acked-by: Hugh Dickins <hugh@veritas.com>