> Now, if we race with another task doing utrace_task_alloc() and see
> ->utrace != NULL, why should we see the correctly initialized *utrace?
> 
> utrace_task_alloc() needs wmb(), and the code like above 
> read_barrier_depends().

Ok.  Please review what I put in (esp. commit c575558) and send patches
relative to the latest tree if that's not right.  Perhaps it is overkill to
do read_barrier_depends() in task_utrace_struct().  But AFAICT if we don't
actually need it all those places, that is only because of some
less-obvious barrier effect with checks on ->utrace_flags or something.
Do you think it's not really needed in all those places we extract the
pointer before spin_lock et al?


Thanks,
Roland

Reply via email to