On 23/07/2015 04:56, Wen Congyang wrote:
>> > Otherwise, grace periods are detected too early!
> We always use qemu_thread_create() in qemu. So I think we can do it like this:
> wrapped_fn()
> {
>     rcu_register_thread();
>     call thread_fn() here
>     rcu_unregister_thread();
> }
> 
> So we will never forget to call rcu_register_thread() when creating a new 
> thread.

That's a good idea.  Would you like to propose a patch for 2.5?  Then we
can also use it to run the thread_atexit notifiers and avoid the bug
that Peter reported for OS X.

Paolo

Reply via email to