On 10/1/2025 3:07 PM, Steven Sistare wrote:
On 10/1/2025 2:56 PM, Peter Xu wrote:
On Wed, Oct 01, 2025 at 08:33:52AM -0700, Steve Sistare wrote:
This patch series adds the live migration cpr-exec mode.

The new user-visible interfaces are:
   * cpr-exec (MigMode migration parameter)
   * cpr-exec-command (migration parameter)

cpr-exec mode is similar in most respects to cpr-transfer mode, with the
primary difference being that old QEMU directly exec's new QEMU.  The user
specifies the command to exec new QEMU in the migration parameter
cpr-exec-command.

It turns out I was right where I replied to patch 5; this fails the Windows
build.

Smallest fix is to wrap qemu_memfd_create() with a CONFIG_LINUX ifdef,
returning -1 to mfd otherwise.

That does not make sense.  It already does that, which is why I used it:

util/memfd.c

int qemu_memfd_create(const char *name, size_t size, bool hugetlb,
                       uint64_t hugetlbsize, unsigned int seals, Error **errp)
{
     ...
#ifdef CONFIG_LINUX
     ...
     return mfd;
#else
     error_setg_errno(errp, ENOSYS, "failed to create memfd");
#endif
     return -1;
}

Did the windows build fail due to a different error?

A better one is we only include cpr*.c in meson.build if it's linux.
Personally I'm OK if we go with the smaller one as of now, however then it
would definitely be nice to have a follow up series to reach the better
solution, if that makes sense.

Feel free to use "make docker-test-build@fedora-win64-cross" for verifying
the changes.  I hope it'll work for you, even if for me currently it didn't
work due to a gitlab.com dns resolution pulling dtc src, where I didn't dig
deeper yet..

The other thing is, this series doesn't apply on master branch.  I didn't
feel confident to do it myself on the vfio change, please have a look on
both issues.
Ugh, they renamed everything.  I will rebase and send V6.

Actually that was easy to resolve, not worth a V6?

In patch "vfio: cpr-exec mode", drop the change in container.c, and instead
add MIG_MODE_CPR_EXEC to container-legacy.c here:

        if (migrate_add_blocker_modes(&vbasedev->cpr.mdev_blocker, errp,
                                      MIG_MODE_CPR_TRANSFER, MIG_MODE_CPR_EXEC,
                                      -1) < 0) {

- Steve



Reply via email to