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

From: Hugh Dickins
Date: Fri Apr 24 2009 - 00:33:36 EST


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@xxxxxxxxxxx>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/