vmm: Add postcopy support to receive-migration

Plumb the SocketUffdMemorySource into the receiving side of live
migration. When memory_mode=postcopy is requested, the destination
brings up a dedicated fault connection, registers userfaultfd on the
restored memory regions, and serves guest pages on demand over that
connection while the VM resumes early.

Signed-off-by: Sebastien Boeuf <sboeuf@meta.com>
Assisted-by: Claude:claude-opus-4-7
This commit is contained in:
Sebastien Boeuf
2026-06-23 08:56:25 -07:00
parent 282d1c989d
commit 48ba1f1417
5 changed files with 258 additions and 55 deletions

View File

@@ -47,6 +47,9 @@ pub enum UffdError {
#[error("Region at {addr:#x}+{len:#x} missing COPY/WAKE support")]
MissingIoctlSupport { addr: u64, len: u64 },
#[error("Failed to configure socket")]
SetSocket(#[source] io::Error),
#[error("Failed to spawn handler thread")]
SpawnThread(#[source] io::Error),