On 12/20/19 10:50 PM, Damien Hedde wrote:
> Add a function resettable_change_parent() to do the required
> plumbing when changing the parent a of Resettable object.
> 
> We need to make sure that the reset state of the object remains
> coherent with the reset state of the new parent.
> 
> We make the 2 following hypothesis:
> + when an object is put in a parent under reset, the object goes in
> reset.
> + when an object is removed from a parent under reset, the object
> leaves reset.
> 
> The added function avoids any glitch if both old and new parent are
> already in reset.
> 
> Signed-off-by: Damien Hedde <damien.he...@greensocs.com>
> ---
>  include/hw/resettable.h | 16 +++++++++++
>  hw/core/resettable.c    | 62 +++++++++++++++++++++++++++++++++++++++--
>  hw/core/trace-events    |  1 +
>  3 files changed, 77 insertions(+), 2 deletions(-)

Reviewed-by: Richard Henderson <richard.hender...@linaro.org>


r~

Reply via email to