Re: [PATCH] fs, proc: Introduce the /proc/<pid>/children entry v2
From: Oleg Nesterov
Date: Wed Dec 07 2011 - 13:59:09 EST
Hi Cyrill,
Sorry, I didn't read this patch yet, but
On 12/06, Cyrill Gorcunov wrote:
>
> +static void *children_seq_start(struct seq_file *seq, loff_t *pos)
> +{
> + struct task_struct *task;
> +
> + rcu_read_lock();
> + task = seq->private;
> + if (task)
> + return seq_list_start(&task->children, *pos);
This looks "obviously wrong".
We can not trust ->children->next after rcu_read_unlock(). Another
rcu_read_lock() can't help.
Once again, I can be easily wrong, need to read the patch first.
Oleg.
--
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/