Kernel Driver Hot Swap Using Wrapped Endpoints

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Updating or servicing kernel-mode drivers in an operating system often requires a system reboot or shutdown, leading to downtime and loss of productivity.

Innovation Solution

A driver proxy component that wraps endpoints with a synchronization mechanism to stall, defer, or fail external calls during driver servicing, enabling seamless swapping between driver instances without restarting the OS or tearing down device stacks, using a combination of driver proxy and hot patch components to manage transitions.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If kernel-mode drivers are updated or serviced using traditional methods, then driver functionality can be improved or fixed, but system downtime and productivity loss occur due to required reboots or shutdowns

Engineering Contradiction:
Improvedriver functionalityVSAvoidsystem downtime
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

The driver instance is transformed from a static, monolithic component to a dynamic, replaceable entity. The system maintains multiple driver instances in memory simultaneously, allowing the active driver to be swapped with a new instance without system shutdown. The wrapper function dynamically redirects calls between old and new driver instances based on the swap state, enabling continuous operation during driver updates.

Inventive Principle:
Principle #15Dynamics

Solution Approach 2:

A wrapper function is introduced as an intermediary layer between the OS/hardware and the driver instance. This wrapper intercepts all calls to the driver, manages the swap process, and ensures proper transition between old and new driver instances. The wrapper maintains call stacks and coordination information, acting as a mediator that enables seamless driver replacement without affecting the overall system operation.

Inventive Principle:
Principle #24Intermediary (Mediator)

2Reliability

If kernel-mode drivers are updated using traditional methods, then driver updates can be applied, but device stacks must be shut down causing operational disruption

Engineering Contradiction:
Improvedriver updatesVSAvoidoperational continuity
Core Design Contradiction:
ReliabilityVSEase of operation

Solution Approach 1:

The driver instance is transformed from a static, monolithic component to a dynamic, replaceable entity. The system maintains multiple driver instances in memory simultaneously, allowing the active driver to be swapped with a new instance without system shutdown. The wrapper function dynamically redirects calls between old and new driver instances based on the swap state, enabling continuous operation during driver updates.

Inventive Principle:
Principle #15Dynamics

Solution Approach 2:

A new driver instance is loaded and initialized in memory before the swap operation occurs. The system prepares the new driver instance with all necessary resources and configurations in advance, so that when the swap is triggered, the transition is immediate and seamless. This preliminary loading of the new instance eliminates the need to shut down device stacks during the update process.

Inventive Principle:
Principle #10Preliminary action

3Ease of operation

If driver endpoints are wrapped with synchronization mechanisms to enable hot swapping, then seamless driver replacement is achieved, but system complexity increases

Engineering Contradiction:
Improveseamless driver replacementVSAvoidsystem architecture
Core Design Contradiction:
Ease of operationVSDevice complexity

Solution Approach 1:

A wrapper function is introduced as an intermediary layer between the OS/hardware and the driver instance. This wrapper intercepts all calls to the driver, manages the swap process, and ensures proper transition between old and new driver instances. The wrapper maintains call stacks and coordination information, acting as a mediator that enables seamless driver replacement without affecting the overall system operation.

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

The driver system is segmented into distinct components: the wrapper function, the driver instance, and the call stack management structures. This segmentation allows each component to be independently managed and replaced. The wrapper handles the complexity of coordination and swapping, while the driver instance remains a simple, replaceable binary blob, making the overall system more manageable despite the added abstraction layer.

Inventive Principle:
Principle #1Segmentation

4Adaptability or versatility

If multiple driver instances are maintained in memory simultaneously, then driver hot swapping is enabled, but memory usage increases

Engineering Contradiction:
Improvedriver hot swap capabilityVSAvoidmemory consumption
Core Design Contradiction:
Adaptability or versatilityVSQuantity of substance

Solution Approach 1:

The driver instance is transformed from a static, monolithic component to a dynamic, replaceable entity. The system maintains multiple driver instances in memory simultaneously, allowing the active driver to be swapped with a new instance without system shutdown. The wrapper function dynamically redirects calls between old and new driver instances based on the swap state, enabling continuous operation during driver updates.

Inventive Principle:
Principle #15Dynamics

Solution Approach 2:

The system changes the state parameter of driver instances from 'single active instance' to 'multiple concurrent instances'. By allowing multiple instances to coexist in memory with different states (active, inactive, pending swap), the system enables hot swapping capability. The wrapper function manages which instance is active at any given time, optimizing memory usage by keeping only necessary instances in memory.

Inventive Principle:
Principle #35Parameter changes

Data Source

PatentUS12547556B2Driver hot swap for servicing kernel-mode drivers
Publication Date: 2026.02.10 MICROSOFT TECHNOLOGY LICENSING LLC
  • US12547556B2 patent drawing
  • US12547556B2 patent drawing
  • US12547556B2 patent drawing

AI summary

A method implemented in a computer system involving a processor system includes loading a first version of a driver into memory, identifying a first endpoint set within the driver, and wrapping each endpoint in the set with a wrapper. The wrappers are registered within the operating system for calling endpoints in the first endpoint set. Subsequently, a second version of the driver is loaded into memory, and the first version is swapped with the second version. The swap process involves determining if the first version has active external calls, ceasing execution if no active calls are present, configuring the wrappers to use the second endpoint set, and initiating execution of the second version of the driver.