Unified Memory Protection for Virtual Machines

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing virtual machine (VM) systems face challenges in protecting memory pages from improper access by both software and hardware devices, leading to potential corruption and crashes, as current mechanisms for software and hardware access are separately managed and lack coordination.

Innovation Solution

A memory protection mechanism that allows a guest VM to selectively share memory pages with another VM and hardware I/O devices, using a combined DVM virtual address space and IOMMU table to ensure explicit sharing and address translation, thereby preventing unauthorized access.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If separate memory management techniques are used for software and hardware access, then protection against improper access is provided, but the system complexity increases and coordination between mechanisms becomes difficult

Engineering Contradiction:
Improvememory protectionVSAvoidmemory management system
Core Design Contradiction:
ReliabilityVSDevice complexity

Solution Approach 1:

The patent combines separate memory management techniques (software access control and hardware access control) into a unified memory management mechanism. The host operating system maintains a single page table that simultaneously manages both software (guest OS) and hardware (I/O devices) access permissions, eliminating the need for separate management structures and reducing system complexity while maintaining comprehensive protection.

Inventive Principle:
Principle #5Merging (Combining)

Solution Approach 2:

The patent creates a universal memory management system where the host OS page table serves multiple functions: it manages guest OS memory access, controls hardware device access, and provides address translation for both software and hardware. This multi-functional approach replaces multiple specialized mechanisms with a single versatile system.

Inventive Principle:
Principle #6Universality (Multi-functionality)

2Productivity

If memory pages are shared with hardware devices, then I/O operations are enabled, but the risk of memory corruption from hardware devices increases

Engineering Contradiction:
ImproveI/O operation efficiencyVSAvoidmemory corruption risk
Core Design Contradiction:
ProductivityVSObject-affected harmful factors

Solution Approach 1:

The patent applies preliminary protective measures by having the host operating system pre-configure the page table with specific permission bits for each memory page before allowing hardware access. The host OS explicitly grants or denies hardware access permissions in advance, preventing unauthorized or harmful hardware access to memory pages that could cause corruption.

Inventive Principle:
Principle #9Preliminary anti-action

Solution Approach 2:

The host operating system acts as an intermediary between hardware devices and memory pages. Instead of allowing direct hardware-to-memory access, the host OS mediates through the page table mechanism, translating hardware address requests and enforcing access permissions, thereby enabling safe I/O operations while protecting against memory corruption.

Inventive Principle:
Principle #24Intermediary (Mediator)

3Reliability

If explicit sharing mechanisms are implemented, then memory protection is improved, but the overhead of managing shared memory increases

Engineering Contradiction:
Improvememory access controlVSAvoidmemory management overhead
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

The patent implements a self-service memory management approach where the host operating system automatically manages shared memory permissions through the page table without requiring manual intervention or complex coordination protocols. The page table structure itself provides the enforcement mechanism, automatically checking permissions on each access and eliminating the need for separate grant/revoke handshaking processes.

Inventive Principle:
Principle #25Self-service

Data Source

PatentUS8392628B2Sharing memory spaces for access by hardware and software in a virtual machine environment
Publication Date: 2013.03.05 HEWLETT PACKARD ENTERPRISE DEV LP
  • US8392628B2 patent drawing
  • US8392628B2 patent drawing
  • US8392628B2 patent drawing

AI summary

Example methods, apparatus, and articles of manufacture to share memory spaces for access by hardware and software in a virtual machine environment are disclosed. A disclosed example method involves enabling a sharing of a memory page of a source domain executing on a first virtual machine with a destination domain executing on a second virtual machine. The example method also involves mapping the memory page to an address space of the destination domain and adding an address translation entry for the memory page in a table. In addition, the example method involves sharing the memory page with a hardware device for direct memory access of the memory page by the hardware device.