Hypervisor Interrupt Delivery for Virtual Machine Functions
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
In virtualized computer systems, interrupts such as non-maskable interrupts (NMIs) are suspended during the execution of VM functions, potentially breaking security by interrupting the VM function execution, and existing methods do not effectively manage interrupt delivery to virtual machines executing privileged functions.
Innovation Solution
The hypervisor determines if a virtual CPU (vCPU) is executing a VM function by inspecting the Extended Page Table base Pointer (EPTP) value or the code being executed, and if so, delays interrupt delivery until the VM function completes, ensuring secure and uninterrupted execution by modifying the Virtual Machine Control Structure (VMCS) or monitoring the VM function code execution.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If interrupts are delivered during VM function execution, then interrupt responsiveness is improved, but security and integrity of privileged operations are compromised
Solution Approach 1:
The hypervisor performs preliminary actions by checking the execution state of the vCPU before delivering interrupts. It inspects the EPTP value or code being executed to determine if a VM function is in progress, and proactively delays interrupt delivery until the VM function completes, ensuring security is maintained before the interrupt can be delivered
Solution Approach 2:
The hypervisor acts as an intermediary between the interrupt source and the vCPU. It intercepts interrupt delivery requests, checks whether they would interfere with VM function execution, and mediates the timing of interrupt delivery to balance security requirements with interrupt responsiveness
2Reliability
If interrupts are suspended during VM function execution, then security is maintained, but interrupt responsiveness deteriorates
Solution Approach 1:
The interrupt delivery mechanism is made dynamic rather than static. The hypervisor continuously monitors the execution state of the vCPU and dynamically adjusts interrupt delivery timing based on whether a VM function is currently executing, allowing the system to switch between interrupt delivery and suspension modes as needed
3Measurement precision
If the hypervisor inspects EPTP value or code to determine VM function execution, then accuracy of interrupt timing is improved, but system complexity increases
Solution Approach 1:
The hypervisor extracts and monitors specific key indicators (EPTP value or code being executed) that directly indicate VM function execution state. By focusing on these extracted indicators rather than analyzing the entire system state, the hypervisor achieves accurate detection while minimizing the complexity overhead
Data Source
AI summary
Systems and methods for delivering certain types of interrupts to virtual machines executing privileged virtual machine functions. An example method may comprise: receiving, by a hypervisor being executed by a processing device of a host computer system, a request to send an interrupt to a virtual central processing unit (vCPU) of a virtual machine; responsive to detecting that the vCPU is executing a virtual machine (VM) function, monitoring the vCPU for completion of the VM function; and responsive to detecting that execution of the VM function is complete, delivering the interrupt to the vCPU.


