* Re: [PATCH] qom/object: Fix object_child_foreach_recursive() return value
2020-04-04 15:33 [PATCH] qom/object: Fix object_child_foreach_recursive() return value Cédric Le Goater
@ 2020-04-06 7:24 ` Cédric Le Goater
2020-04-06 10:18 ` Marc-André Lureau
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: Cédric Le Goater @ 2020-04-06 7:24 UTC (permalink / raw)
To: Peter Maydell
Cc: Paolo Bonzini, David Gibson, Daniel P . Berrangé,
Eduardo Habkost, qemu-devel
Hello David,
On 4/4/20 5:33 PM, Cédric Le Goater wrote:
> When recursing, the return value of do_object_child_foreach() is not
> taken into account.
Patch "ppc/pnv: Create BMC devices only when defaults are enabled" :
http://patchwork.ozlabs.org/patch/1266421
depends on this fix.
May be it can go through the ppc branch ? A patchset with these
two patches would have been easier to track :/ Sorry about that.
Thanks,
C.
> Cc: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
> Fixes: d714b8de7747 ("qom: Add recursive version of object_child_for_each")
> Signed-off-by: Cédric Le Goater <clg@kaod.org>
> ---
> qom/object.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/qom/object.c b/qom/object.c
> index 1812f792247d..b68a707a5e65 100644
> --- a/qom/object.c
> +++ b/qom/object.c
> @@ -1057,7 +1057,10 @@ static int do_object_child_foreach(Object *obj,
> break;
> }
> if (recurse) {
> - do_object_child_foreach(child, fn, opaque, true);
> + ret = do_object_child_foreach(child, fn, opaque, true);
> + if (ret != 0) {
> + break;
> + }
> }
> }
> }
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] qom/object: Fix object_child_foreach_recursive() return value
2020-04-04 15:33 [PATCH] qom/object: Fix object_child_foreach_recursive() return value Cédric Le Goater
2020-04-06 7:24 ` Cédric Le Goater
@ 2020-04-06 10:18 ` Marc-André Lureau
2020-05-08 14:13 ` Cédric Le Goater
2020-05-08 15:31 ` Philippe Mathieu-Daudé
3 siblings, 0 replies; 5+ messages in thread
From: Marc-André Lureau @ 2020-04-06 10:18 UTC (permalink / raw)
To: Cédric Le Goater
Cc: Peter Maydell, Peter Crosthwaite, Daniel P . Berrangé,
Eduardo Habkost, QEMU, Paolo Bonzini
Hi,
On Sat, Apr 4, 2020 at 5:34 PM Cédric Le Goater <clg@kaod.org> wrote:
>
> When recursing, the return value of do_object_child_foreach() is not
> taken into account.
>
> Cc: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
> Fixes: d714b8de7747 ("qom: Add recursive version of object_child_for_each")
> Signed-off-by: Cédric Le Goater <clg@kaod.org>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
> ---
> qom/object.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/qom/object.c b/qom/object.c
> index 1812f792247d..b68a707a5e65 100644
> --- a/qom/object.c
> +++ b/qom/object.c
> @@ -1057,7 +1057,10 @@ static int do_object_child_foreach(Object *obj,
> break;
> }
> if (recurse) {
> - do_object_child_foreach(child, fn, opaque, true);
> + ret = do_object_child_foreach(child, fn, opaque, true);
> + if (ret != 0) {
> + break;
> + }
> }
> }
> }
> --
> 2.25.1
>
>
--
Marc-André Lureau
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] qom/object: Fix object_child_foreach_recursive() return value
2020-04-04 15:33 [PATCH] qom/object: Fix object_child_foreach_recursive() return value Cédric Le Goater
2020-04-06 7:24 ` Cédric Le Goater
2020-04-06 10:18 ` Marc-André Lureau
@ 2020-05-08 14:13 ` Cédric Le Goater
2020-05-08 15:31 ` Philippe Mathieu-Daudé
3 siblings, 0 replies; 5+ messages in thread
From: Cédric Le Goater @ 2020-05-08 14:13 UTC (permalink / raw)
To: Peter Maydell
Cc: Paolo Bonzini, Daniel P . Berrangé, Eduardo Habkost,
qemu-devel
Hello,
On 4/4/20 5:33 PM, Cédric Le Goater wrote:
> When recursing, the return value of do_object_child_foreach() is not
> taken into account.
>
> Cc: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
> Fixes: d714b8de7747 ("qom: Add recursive version of object_child_for_each")
> Signed-off-by: Cédric Le Goater <clg@kaod.org>
What are the plans to merge this one ?
Thanks,
C.
> ---
> qom/object.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/qom/object.c b/qom/object.c
> index 1812f792247d..b68a707a5e65 100644
> --- a/qom/object.c
> +++ b/qom/object.c
> @@ -1057,7 +1057,10 @@ static int do_object_child_foreach(Object *obj,
> break;
> }
> if (recurse) {
> - do_object_child_foreach(child, fn, opaque, true);
> + ret = do_object_child_foreach(child, fn, opaque, true);
> + if (ret != 0) {
> + break;
> + }
> }
> }
> }
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] qom/object: Fix object_child_foreach_recursive() return value
2020-04-04 15:33 [PATCH] qom/object: Fix object_child_foreach_recursive() return value Cédric Le Goater
` (2 preceding siblings ...)
2020-05-08 14:13 ` Cédric Le Goater
@ 2020-05-08 15:31 ` Philippe Mathieu-Daudé
3 siblings, 0 replies; 5+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-08 15:31 UTC (permalink / raw)
To: Cédric Le Goater, Peter Maydell
Cc: Paolo Bonzini, Peter Crosthwaite, Daniel P . Berrangé,
Eduardo Habkost, qemu-devel
On 4/4/20 5:33 PM, Cédric Le Goater wrote:
> When recursing, the return value of do_object_child_foreach() is not
> taken into account.
>
> Cc: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
> Fixes: d714b8de7747 ("qom: Add recursive version of object_child_for_each")
Indeed.
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
> Signed-off-by: Cédric Le Goater <clg@kaod.org>
> ---
> qom/object.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/qom/object.c b/qom/object.c
> index 1812f792247d..b68a707a5e65 100644
> --- a/qom/object.c
> +++ b/qom/object.c
> @@ -1057,7 +1057,10 @@ static int do_object_child_foreach(Object *obj,
> break;
> }
> if (recurse) {
> - do_object_child_foreach(child, fn, opaque, true);
> + ret = do_object_child_foreach(child, fn, opaque, true);
> + if (ret != 0) {
> + break;
> + }
> }
> }
> }
>
^ permalink raw reply [flat|nested] 5+ messages in thread