From: Peter Xu <peterx@redhat.com>
To: Prasad Pandit <ppandit@redhat.com>
Cc: qemu-devel@nongnu.org, Fabiano Rosas <farosas@suse.de>,
Lukas Straub <lukasstraub2@web.de>,
Juraj Marcin <jmarcin@redhat.com>
Subject: Re: [PATCH 1/2] tests/migration-test: Remove postcopy_data from MigrateCommon
Date: Wed, 14 Jan 2026 10:34:45 -0500 [thread overview]
Message-ID: <aWe3lXEsr_dsKzVU@x1.local> (raw)
In-Reply-To: <CAE8KmOzCYg_55J9J6Dh6Pr2D5wp_YLOXZqa4cm=Vt35ZDkiUXQ@mail.gmail.com>
On Thu, Jan 08, 2026 at 03:08:04PM +0530, Prasad Pandit wrote:
> On Wed, 7 Jan 2026 at 22:42, Peter Xu <peterx@redhat.com> wrote:
> >> * Should 'hook_data' pointer be g_autofree too? Where is it free'd otherwise?
> >
> > hook_data is freed in end_hook(). This patch doesn't change that fact for
> > postcopy. It's the smae to non-postcopy tests.
> >
> >> * The changes look okay; But if tests define hook_data = NULL; Where
> >> does it get populated?
> >
> > It's populated in start_hook() conditionally. When populated, it is always
> > (and a must) to be released in end_hook().
>
> ===
> $ grep -Eri 'test_postcopy_common|test_postcopy_recovery_common'
> tests/qtest/migration/ -l
> tests/qtest/migration/framework.h
> tests/qtest/migration/framework.c
> tests/qtest/migration/tls-tests.c
> tests/qtest/migration/postcopy-tests.c
> ===
>
> * Only tls-tests above seem to define and use these hooks properly
> along with the hook_data. Postcopy-tests and all other users of
> start_hook/end_hook don't seem to use [postcopy|hook]_data at all. Do
> we really need this hook_data parameter? Couldn't it be defined as a
> tls-tests specific object. (just wondering)
Sorry I don't follow. We need the hook_data for cleaning up tls objects
later in end_hook, for either postcopy or other tls tests.
>
> Reviewed-by: Prasad Pandit <pjp@fedoraproject.org>
Thanks,
>
> Thank you.
> ---
> - Prasad
>
--
Peter Xu
next prev parent reply other threads:[~2026-01-14 15:35 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-06 20:33 [PATCH 0/2] tests/migration-test: Small cleanup series on postcopy tests Peter Xu
2026-01-06 20:33 ` [PATCH 1/2] tests/migration-test: Remove postcopy_data from MigrateCommon Peter Xu
2026-01-07 11:23 ` Prasad Pandit
2026-01-07 17:12 ` Peter Xu
2026-01-08 9:38 ` Prasad Pandit
2026-01-14 15:34 ` Peter Xu [this message]
2026-01-15 11:11 ` Prasad Pandit
2026-01-06 20:33 ` [PATCH 2/2] tests/migration-test: Remove postcopy_recovery_fail_stage " Peter Xu
2026-01-07 11:37 ` Prasad Pandit
2026-01-07 17:14 ` Peter Xu
2026-01-08 9:41 ` Prasad Pandit
2026-01-14 15:36 ` Peter Xu
2026-01-15 11:57 ` Prasad Pandit
2026-01-15 13:44 ` Peter Xu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aWe3lXEsr_dsKzVU@x1.local \
--to=peterx@redhat.com \
--cc=farosas@suse.de \
--cc=jmarcin@redhat.com \
--cc=lukasstraub2@web.de \
--cc=ppandit@redhat.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.