Pass-Through VM Migration With DMA Dirty Page Tracking

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

In virtual machine migration, ensuring memory consistency between source and destination machines when a pass-through device is configured is challenging due to the lack of memory write protection mechanisms, leading to reduced performance.

Innovation Solution

A method and apparatus that utilize a physical function (PF) driver to instruct a pass-through device to record dirty page data addresses, ensuring memory consistency by using direct memory access (DMA) and allocating reserved storage space for migration instructions, thereby improving performance.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If a pass-through device is configured for direct memory access to improve throughput and reduce latency, then resource utilization and performance are improved, but memory write protection mechanism cannot be triggered and memory consistency cannot be ensured

Engineering Contradiction:
ImprovethroughputVSAvoidmemory consistency
Core Design Contradiction:
ProductivityVSReliability

Solution Approach 1:

The patent introduces a pass-through device as an intermediary component that sits between the virtual machine and the physical memory. This device enables direct memory access for high performance while simultaneously acting as a mediator that can trigger memory write protection mechanisms and track dirty pages, thus resolving the contradiction between throughput and memory consistency

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

The patent replaces the traditional CPU-mediated memory access mechanism with a direct memory access mechanism through the pass-through device. This substitution eliminates CPU intervention in data transfer paths, improving throughput while the pass-through device maintains memory consistency through hardware-level dirty page tracking and protection mechanisms

Inventive Principle:
Principle #28Mechanics substitution (Replace mechanical system)

2Productivity

If a pass-through device is configured to reduce virtualization layer overheads, then resource utilization is improved, but memory write protection mechanism may not be triggered

Engineering Contradiction:
Improveresource utilizationVSAvoidmemory protection mechanism
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The pass-through device is designed to autonomously track dirty pages and trigger memory write protection mechanisms without requiring CPU intervention or complex virtualization layer management. This self-service capability improves resource utilization by reducing overhead while maintaining a relatively simple protection mechanism

Inventive Principle:
Principle #25Self-service

3Speed

If direct memory access is used to achieve low latency, then performance is improved, but memory consistency between source and destination virtual machines cannot be ensured

Engineering Contradiction:
ImprovelatencyVSAvoidmemory consistency
Core Design Contradiction:
SpeedVSReliability

Solution Approach 1:

The pass-through device performs preliminary tracking of dirty pages before migration occurs. By maintaining a record of which memory pages have been modified through direct memory access, the system can ensure memory consistency during migration without adding latency to the data access path

Inventive Principle:
Principle #10Preliminary action

Applied Scientific Principles

This section explains which scientific principles are used to turn an abstract innovation direction into a practical engineering solution.

Function Achieved in This Case

Ensures memory consistency and enhances virtual machine migration performance by allowing direct memory access without CPU intervention, optimizing resource utilization and reducing migration duration.

Implementation Method 1

the dirty page data is data written by the source-end pass-through device to the source-end virtual machine in a direct memory access (direct memory access, DMA) manner

Methodology Applied
Scientific EffectDirect memory access (DMA):

Data Source

PatentUS12561156B2Method and apparatus for migrating a virtual machine configured with a pass-through device
Publication Date: 2026.02.24 HUAWEI TECH CO LTD
  • US12561156B2 patent drawing
  • US12561156B2 patent drawing
  • US12561156B2 patent drawing

AI summary

This application provides a method for migrating a virtual machine and an apparatus. The method is applied to a source-end physical host, the source-end physical host includes a host machine operating system and a source-end virtual machine running in the host machine operating system, and the host machine operating system includes a physical function (PF) driver. According to the technical solutions of this application, memory consistency, before and after a migration process, of a virtual machine configured with a pass-through device can be ensured.