On 26/05/2015 15:28, Alexey Kardashevskiy wrote:
> 
> My initial concern was if I can or cannot do:
> 
> memory_region_init_iommu + memory_region_add_subregion
> and
> memory_region_del_subregion + object_unref
> 
> outside of init/realize/unrealize/finalize.
> 
> You said I cannot do unparenting but as I am not doing this (and I just
> do unref()) - I am fine. That's what I meant.

Well, if you do the above you have two different bugs:

1) you leak the original child property

2) you initialize the second region on top of the first, so you have two
regions pointing to the same memory

This is even worse than unparenting :) and would have been wrong even
without the RCU changes.

Paolo

Reply via email to