whp, virt_whp: migrate from winapi to windows-sys#2835
Open
justus-camp-microsoft wants to merge 2 commits intomicrosoft:mainfrom
Open
whp, virt_whp: migrate from winapi to windows-sys#2835justus-camp-microsoft wants to merge 2 commits intomicrosoft:mainfrom
justus-camp-microsoft wants to merge 2 commits intomicrosoft:mainfrom
Conversation
|
This PR modifies files containing For more on why we check whole files, instead of just diffs, check out the Rustonomicon |
12bd1df to
8416efc
Compare
Contributor
There was a problem hiding this comment.
Pull request overview
This PR migrates the whp crate from the deprecated winapi crate to windows-sys as part of the effort to unify Windows API dependencies across the OpenVMM codebase (issue #1061). The migration replaces all winapi imports with their windows-sys equivalents while maintaining the same functionality.
Changes:
- Removed the
winapidependency from the whp crate - Updated all Windows API type imports to use
windows-syswith appropriate module paths - Configured windows-sys features for both main dependencies and dev dependencies
Reviewed changes
Copilot reviewed 6 out of 7 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| vm/whp/Cargo.toml | Removed winapi dependency; added windows-sys with Win32_Foundation and Win32_System_Power features for main deps, plus Win32_System_Memory and Win32_System_Threading for dev deps |
| vm/whp/src/partition_prop.rs | Updated BOOL import from winapi::shared::minwindef to windows_sys::core |
| vm/whp/src/lib.rs | Updated LUID, ERROR_BAD_PATHNAME, and DEVICE_POWER_STATE imports from winapi to windows-sys |
| vm/whp/src/api.rs | Updated HANDLE, DEVICE_POWER_STATE, and HRESULT imports from winapi to windows-sys |
| vm/whp/src/abi.rs | Updated LUID import from winapi::shared::ntdef to windows_sys::Win32::Foundation |
| vm/whp/benches/primitives.rs | Updated memory and threading API imports from winapi to windows-sys |
| Cargo.lock | Reflects the removal of winapi dependency from whp crate |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of #1061, migrate whp and virt_whp off of winapi